Fixed a great many formatting problems, converted prelim to latex