PhoSim (The Photon Simulator)