  We use a mock galaxy catalogue based upon the Millennium Run simulation to
investigate the intrinsic spatial properties of compact groups of galaxies. We
find that approximately 30% of galaxy associations identified in our mock
catalogue are physically dense systems of four or more galaxies with no
interlopers, approximately half are close associations of 2, 3 or 4 galaxies
with one or more interlopers, and the remainder are not physically dense.
Genuine compact groups are preferentially brighter and more isolated than those
with interlopers; by increasing the required minimum surface brightness of a
group from the canonical value of 26mags/arcsec^2 to 22mags/arcsec^2, we can
increase the proportion of genuinely compact systems identified with no
interlopers from 29% to 75%. Of the genuine compact groups identified, more
than half consist of a single dark matter halo with all the member galaxies
deeply embedded within it. In some cases, there are other galaxies which share
the same halo (typically with mass ~ 10^13 h^{-1} M_\odot) but which are not
identified as being members of the compact group. This implies that compact
groups are associated with group environments, some or all members of which are
in the compact group. For those compact groups where all galaxies are in the
same halo, the three-dimensional velocity dispersion of the compact group
correlates broadly with the virial velocity of the dark matter halo. However,
the scale-size of the group - and hence the fraction of the halo mass which the
group samples - is completely uncorrelated with the properties of the dark
matter halo. This means that masses derived under the simple assumption of
virial equilibrium using the observed velocity dispersions and sizes of compact
groups give incorrect estimates of the true mass of the underlying dark matter.
