Renaming file and started writing density plotting code for threshold detection function simulation.