  The member stars in globular cluster M15 show a substantial spread in the
abundances of r-process elements. We argue that a rare and prolific r-process
event enriched the natal cloud of M15 in an inhomogeneous manner. To critically
examine the possibility, we perform cosmological galaxy formation simulations
and study the physical conditions for the inhomogeneous enrichment. We explore
a large parameter space of the merger event time and the site. Our simulations
reproduce the large r-process abundance spread if a neutron-star merger occurs
at \sim 100 pc away from the formation site of the cluster and in a limited
time range of a few tens million years before the formation. Interestingly, a
bimodal feature is found in the Eu abundance distribution in some cases,
similarly to that inferred from recent observations. M15 member stars do not
show clear correlation between the abundances of Eu and light elements such as
Na that is expected in models with two stellar populations. We thus argue that
a majority of the stars in M15 are formed in a single burst. The ratio of heavy
to light r-process element abundance [Eu/Y] \sim 1.0 is consistent with that of
the so-called r-II stars, suggesting that a lanthanide-rich r-process event
dominantly enriched M15.
