# How do you calculate the empirical formula of a hydrocarbon?

And $\text{empirical}$ actually means $\text{experimental}$. And thus you take a known mass of hydrocarbon, combust it in a furnace, and the volumes of carbon dioxide and water that are evolved in the combustion may be accurately measured. See here. And from the %C, %H, %N figures we can get an $\text{empirical formula}$, and given a measurement of molecular weight, we can calculate a $\text{molecular formula.}$