We conduct gravitational microlensing experiments in a galaxy taken from a
cosmological N-body simulation. Hypothetical observers measure the optical
depth and event rate toward hypothetical LMCs and compare their results wit
h model predictions. Because we control the accuracy and sophistication of
the model, we can determine how good it has to be for statistical errors to
dominate over systematic ones. Several thousand independent microlensing e
xperiments are performed. When the "best-fit" triaxial model for the mass d
istribution of the halo is used, the agreement between the measured and pre
dicted optical depths is quite good: by and large, the discrepancies are co
nsistent with statistical fluctuations. If on the other hand, a spherical m
odel is used, systematic errors dominate. Even with our "best-fit" model, t
here are a few rare experiments where the deviation between the measured an
d predicted optical depths cannot be understood in terms of statistical flu
ctuations. In these experiments there is typically a clump of particles cro
ssing the line of sight to the hypothetical LMC. These clumps can be either
gravitationally bound systems or transient phenomena in a galaxy that is s
till undergoing phase mixing. Substructure of this type, if present in the
Galactic distribution of MACHOs, can lead to large systematic errors in the
analysis of microlensing experiments. We also describe how hypothetical WI
MP and axion detection experiments might be conducted in a simulated N-body
galaxy.