Sample code for my (yet) unpublished thesis.