  Inspired by the statistical mechanics of an ensemble of interacting particles
(BBGKY hierarchy), we propose to account for small-scale inhomogeneities in
self-gravitating astrophysical fluids by deriving a non-ideal Virial theorem
and non-ideal Navier-Stokes equations using a decomposition of the
gravitational force into a near- and far-field component. These equations
involve the pair radial distribution function (similar to the two-point
correlation function), similarly to the interaction energy and equation of
state in liquids. Small-scale correlations lead to a non-ideal amplification of
the gravitational interaction energy, whose omission leads to a missing mass
problem, e.g., in galaxies and galaxy clusters. We also propose an extension of
the Friedmann equations in the non-ideal regime. We estimate the non-ideal
amplification factor of the gravitational interaction energy of the baryons to
lie between 5 and 20, potentially explaining the observed value of the Hubble
parameter. Within this framework, the acceleration of the expansion emerges
naturally because of the increasing number of sub-structures induced by
gravitational collapse, which increases their contribution to the total
gravitational energy. A simple estimate predicts a non-ideal deceleration
parameter qni~-1;this is potentially the first determination of the observed
value based on an intuitively physical argument. We suggest that correlations
and gravitational interactions could produce a transition to a viscous regime
that can lead to flat rotation curves. This transition could also explain the
dichotomy between (Keplerian) LSB elliptical galaxy and (non-Keplerian) spiral
galaxy rotation profiles. Overall, our results demonstrate that non-ideal
effects induced by inhomogeneities must be taken into account in order to
properly determine the gravitational dynamics of galaxies and the larger scale
universe.
