Changes for compiling with Visual Studio, rm unused files from distro.
Change to latex for documentation, put references in output.