written some of the thesis, added some tests, reasoniiiiiiiiing...