  In this paper I generalize the halo model for the clustering of dark matter
in order to produce the power spectra of the two main baryonic matter
components in the Universe: stars and hot gas. As a natural extension, this can
be also used to describe the clustering of all mass. According to the design of
the halo model, the large-scale power spectra of the various matter components
are physically connected with the distribution of each component within bound
structures and thus, ultimately, with the complete set of physical processes
that drive the formation of galaxies and galaxy clusters. Besides being
practical for cosmological and parametric studies, the semi-analytic model
presented here has also other advantages. Most importantly, it allows one to
understand on physical ground what is the relative contribution of each matter
component to the total clustering of mass as a function of scale, and thus it
opens an interesting new window to infer the distribution of baryons through
high precision cosmic shear measurements. This is particularly relevant for
future wide-field photometric surveys such as Euclid. In this work the concept
of the model and its uncertainties are illustrated in detail, while in a
companion paper we use a set of numerical hydrodynamic simulations to show a
practical application and to investigate where the model itself needs to be
improved.
