  We extend the concept of galaxy environment from the local galaxy number
density to the gravitational potential and its functions like the shear tensor.
For this purpose we examine whether or not one can make an accurate estimation
of the gravitational potential from an observational sample which is finite in
volume, biased due to galaxy biasing, and subject to redshift space distortion.
Dark halos in a $\Lambda$CDM simulation are used in this test. We find that one
needs to stay away from the sample boundaries by more than 30$h^{-1}$Mpc to
reduce the error within 20% of the root mean square values of the potential or
the shear tensor. The error due to the galaxy biasing can be significantly
reduced by using the galaxy mass density field instead of the galaxy number
density field. The error caused by the redshift space distortion can be
effectively removed by correcting galaxy positions for the peculiar velocity
effects. We inspect the dependence of dark matter halo properties on four
environmental parameters; local density, gravitational potential, and the
ellipticity and prolateness of the shear tensor. We find the local density has
the strongest correlation with halo properties. This is evidence that the
internal physical properties of dark halos are mainly controlled by small-scale
physics. In high density regions dark halos are on average more massive and
spherical, and have higher spin parameter and velocity dispersion. In high
density regions dark halos are on average more massive and spherical, and have
higher spin parameter and velocity dispersion. We also study the relation
between the environmental parameters and the subtypes of dark halos. The spin
parameter of satellite halos depends only weakly on the local density for all
mass ranges studied while that of isloated or central halos depends more
sensitively on the local density. (abridged)
