Initial commit

This is the first working version of the code.