Skip to content

Instantly share code, notes, and snippets.

View arleighdickerson's full-sized avatar
🦊
Returning to Westinghouse in the fall. Go Bulldogs! 🐶🤓🤠

Arleigh Dickerson arleighdickerson

🦊
Returning to Westinghouse in the fall. Go Bulldogs! 🐶🤓🤠
View GitHub Profile
PlotTableau[t_] := Grid[t /. i_Integer -> Item[i, Frame -> Blue], Alignment -> Right]
@arleighdickerson
arleighdickerson / TableauxForShape
Created September 20, 2014 14:15
How to get all possible standard fillings for a given partition
Quiet[Needs["Combinatorica`"]];
lambda = {7,3,3,1};
(* May take a few seconds *)
fillings = Tableaux[lambda]
@arleighdickerson
arleighdickerson / FilterTableauByInterest
Last active August 29, 2015 14:06
Create nonstandard tableaux, filter by a predicate, and print french style
ClearAll["Global`"];
Quiet[Needs["Combinatorica`"]];
(********************************** Definitions. Don't change unless you know what you are doing. *)
(**
* Map a function2 across a collection
*)
Map2=#@@@Partition[#2,2,1]&;
@arleighdickerson
arleighdickerson / FileSystemResource.php
Last active February 10, 2017 07:57
Yii2 behavior to link a filesystem resource to an ActiveRecord instance
<?php
namespace common\models;
use yii\base\Behavior;
use yii\db\ActiveRecord;
use yii\web\UploadedFile;
/**
* @author: Arleigh Dickerson
*/
@arleighdickerson
arleighdickerson / PerceptronExample.py
Last active August 29, 2015 14:15
A simple numpy perceptron implementation
import numpy as np
def perceptronLearn(D, maxIter=10, alpha=0.1, b=0):
w = np.zeros(np.shape(D)[1] - 1)
iterCounter = 0
while iterCounter < maxIter:
iterCounter += 1
print("Iteration " + str(iterCounter) + " " + ("-" * 20))
iterError = 0
for row in D:
inoremap jk <Esc>
execute pathogen#infect()
syntax on
set noexpandtab
set autoindent
set tabstop=4
set shiftwidth=4
filetype plugin indent on
set nu
set noswapfile
#!/bin/bash
xcape -e '#66=Escape'
inoremap jk <Esc>
@arleighdickerson
arleighdickerson / InstanceAuthorizationTest.php
Created July 22, 2015 13:49
Instance Authorization Test
<?php
namespace tests\codeception\unit\models;
use Yii;
use yii\codeception\TestCase;
use Codeception\Specify;
use yii\rbac\PhpManager;
class MockRule extends \yii\rbac\Rule {
@arleighdickerson
arleighdickerson / phpstorm64.vmoptions
Last active December 24, 2016 16:03
phpstorm64.vmoptions
-server
-XX:+UseG1GC
-XX:MaxGCPauseMillis=100
-XX:G1HeapRegionSize=2
-XX:ParallelGCThreads=8
-XX:ConcGCThreads=2
-XX:+UseStringDeduplication
-Xms3678m
-Xmx3678m
-XX:SoftRefLRUPolicyMSPerMB=50