Adding d3, fixing latex, tuning up documentation