Trees
MST:
Trees
MST:
helpful sources:
Track file from external directory: git --git-dir=path/to/repository --work-tree=path/to/external/directory/to/track add foobar_file
git init --separate-git-dir /path/to/ext
Squashing last 3 commits to 1 commit: git rebase -i HEAD~3
source
Find an assignment of the jobs to the machines such that total processing time is minimal.
Given bipartite Graph G = (V,E), determine its minimum weight matching:
1. Relabel edge weight of G: E' = {e' := e and e.w *= -1 | forall e in E}
2. Find minimum edge weight min_e in E'
3. E'' = {e'' := e' and e'.w += min_e | forall e' in E'}
4. Apply maximum weight matching problem to G = (V, E'')
% example determining brightness center from a given image A | |
% Args to provide: mask, image, threshold (perhaps). | |
% given a selection mask and image A like the following: | |
mask = | |
1 0 0 0 | |
1 1 0 0 | |
1 1 0 0 | |
0 1 1 1 |
% gives a gaussain kernel of size (dim_n x dim_x) having a variance equal to sigma_value. | |
fspecial('gaussian', dim_n, sigma_value) |
Ruby | |
Game of Life in Ruby - my old omnipresent friend <3 | |
Collection of Sorting algorithms | |
Own DSL arrogating Matlab | |
SVM for higherdimensional classifiers | |
A general Ruby Convas (imagine it would directly make use of OpenGL...) |
# reset local master | |
git fetch origin | |
git reset --hard origin/master | |
# show code diff of a COMMIT | |
git show COMMIT | |
# rabse last NUMBEROFCOMMITS commits (including head) | |
git rebase -i HEAD~NUMBEROFCOMMITS |
# map two lists: e.g sum elementwise | |
[1,2,3].zip([4,5,6]).map{|a,b| a+b} |
// a sample class decleration showing javascript closure examples. | |
// Keep in mind: prototyped properties affect all objects of the | |
// same constructor, simultaneously, even if they already exist. | |
function Knight(hp){ | |
// public attribute of Knight | |
this.hp = hp; | |
// private attribute of Knight | |
var secreteHP = hp+1; | |
Checkboxes | |
- [x] A | |
- [x] B | |
- [x] C | |
~~Durchgestrichen~~ | |
FooImage | |
 |