Worked on kdtree and simulation.