Simulation of 4D Emittance Measurement at the Spallation Neutron Source