Adds the initial version originally published as a gist. This is already slightly different from the gist in that it contains a section on derivations. This is not yet complete.