# Sound Speed in cosmology

$$v_{s}^{2}=\frac{c^{2}}{3} \frac{\partial \rho_{\gamma}}{\partial (\rho_{\gamma}+\rho_{B}) }|_{s}=\frac{c^{2}}{3}(1+\frac{\partial \rho_{B}}{\partial \rho_{\gamma}}|_{s})^{-1}$$
$$v_{s}^{2}=\frac{c^{2}}{3}(1+\frac{\partial \rho_{\gamma}}{\partial \rho_{B}}|_{s})$$ But I don't see how to obtain the other equation
Explanation: In the article the author is trying to calculate the speed of sound in the cosmological fluid that consists of radiation and baryons. Now the baryons are almost pressureless when compared to radiation while the radiation has a pressure $$P=\frac{1}{3}\rho_\gamma c^2$$. Thus for the speed of sound in the radiation+baryon fluid one has $$v_s^2=\frac{\partial P_{total}}{\partial \rho_{total}}=\frac{\partial (P_\gamma+P_B)}{\partial(\rho_\gamma+\rho_B)}\Big|_s=\frac{c^2}{3}\frac{\partial \rho_\gamma}{\partial(\rho_\gamma+\rho_B)}\Big|_s.$$ Note that the partial derivatives are taken at constant entropy. Now to derive the formula OP has quoted one proceeds as follows, $$v_s^2=\frac{c^2}{3}\frac{\partial \rho_\gamma}{\partial(\rho_\gamma+\rho_B)}\Big|_s=\frac{c^2}{3}\frac{1}{\frac{\partial(\rho_\gamma+\rho_B)}{\partial \rho_\gamma}\Big|_s}=\frac{c^2}{3}\frac{1}{1+\frac{\partial\rho_B}{\partial\rho_\gamma}\Big|_s}=\frac{c^2}{3}\left(1+\frac{\partial\rho_B}{\partial\rho_\gamma}\Big|_s\right)^{-1}$$