  We model the intensity of emission lines from the CO molecule, based on
hydrodynamic simulations of spirals, mergers, and high-redshift galaxies with
very high resolutions (3pc and 10^3 Msun) and detailed models for the
phase-space structure of the interstellar gas including shock heating, stellar
feedback processes and galactic winds. The simulations are analyzed with a
Large Velocity Gradient (LVG) model to compute the local emission in various
molecular lines in each resolution element, radiation transfer and opacity
effects, and the intensity emerging from galaxies, to generate synthetic
spectra for various transitions of the CO molecule. This model reproduces the
known properties of CO spectra and CO-to-H2 conversion factors in nearby
spirals and starbursting major mergers. The high excitation of CO lines in
mergers is dominated by an excess of high-density gas, and the high turbulent
velocities and compression that create this dense gas excess result in broad
linewidths and low CO intensity-to-H2 mass ratios. When applied to
high-redshift gas-rich disks galaxies, the same model predicts that their
CO-to-H2 conversion factor is almost as high as in nearby spirals, and much
higher than in starbursting mergers. High-redshift disk galaxies contain giant
star-forming clumps that host a high-excitation component associated to gas
warmed by the spatially-concentrated stellar feedback sources, although CO(1-0)
to CO(3-2) emission is overall dominated by low-excitation gas around the
densest clumps. These results overall highlight a strong dependence of CO
excitation and the CO-to-H2 conversion factor on galaxy type, even at similar
star formation rates or densities. The underlying processes are driven by the
interstellar medium structure and turbulence and its response to stellar
feedback, which depend on global galaxy structure and in turn impact the CO
emission properties.
