# 'Little h' usage in cosmological simulations

I am running a cosmological simulation and am having some trouble putting things into code units. The physical distance units in my simulation are in terms of $$\text{Mpc/h}$$, where $$h$$ is the dimensionless Hubble parameter. This makes enough sense because, as noted elsewhere, simulations are often scale-free so it makes sense to factor out the $$h$$ dependence and make it explicit. This unit convention is causing me some confusion however. In one calculation I have to do during the simulation, I essentially (ignoring context which I can provide later) have to multiply the speed of light $$c$$ by an inverse distance $$1/x_0$$ which is given in units of $$\text{Mpc/h}$$.

In order to properly have the units cancel, I first put $$c$$ in units of $$\text{Mpc/s}$$ to get $$9.716 \times10^{-15} \text{Mpc/s}$$ However, should I know factor out the $$h$$ dependence? These seems strange to me because in my mind, the value of the speed of light should not depend on the underlying cosmology I have simulated. On the other hand, I feel that I should not cancel units of $$\text{Mpc}$$ with units of $$\text{Mpc/h}$$. To make things concrete, let's assume I have a value of $$h=.7$$. Should I then take the quantity above and multiply it by $$.7$$ to yield $$6.802 \times 10^{-15} \text{(Mpc/h)/s}$$

and use that result in my calculations? I think this situation confuses me because it doesn't involve measurements, where it is clear how $$h$$ can enter, and it involves a constant of nature, which should be independent of the assumed cosmology.

• If the result of your computation is in units of $hs^{-1}$ then that can be ok. Depending on the value of $h$ the process is longer or shorter in physical time.
– user26287
May 14, 2020 at 12:18

As argued in the paper you cite, you shouldn't think of $$h$$ as a unit, but rather as a part of the value. Although it's commonly seen, and although numerically it's not wrong, I therefore think the term "$$10h^{-1}\,\mathrm{Mpc}$$" is preferred to "$$10\,\mathrm{Mpc}/h$$".
There's no need to express $$c$$ in terms of $$h$$, because our lack of knowledge about the value of $$h$$ doesn't affect the value of $$c$$. If your distance is, say, $$x_0 = 10h^{-1}\,\mathrm{Mpc}$$, so that your inverse distance is $$1/x_0 = 0.1h\,\mathrm{Mpc}^{-1}$$, your calculation becomes $$\begin{array}{rcl} c\frac{1}{x_0} & = & \left[9.716\times10^{-15}\,\mathrm{Mpc}\,\mathrm{s}^{-1}\right] \times \left[0.1h\,\mathrm{Mpc}^{-1}\right] \\ & = & 9.716\times10^{-16}h\,\mathrm{s}^{-1} \\ \big( & \simeq & 0.7\times10^{-15}\,\mathrm{s}^{-1}.\big) \end{array}$$