Empirical formula calculator
Find a formula from masses or mass percentages.
How it works
For mass percentages, assume a 100 g sample. Divide each mass by its atomic weight to get moles, then divide by the smallest amount of moles. Try multipliers from 1 to 12 until every scaled ratio is within 0.05 of a whole atom. For the molecular formula, the given molar mass divided by the empirical molar mass must be within 0.05 of a positive integer.
Worked example
For 12.011 g carbon, 2.016 g hydrogen and 15.999 g oxygen, the mole ratio is 1:2:1, giving CH2O. Its empirical molar mass is 30.026 g/mol. A molar mass of 180.156 g/mol gives 180.156 ÷ 30.026 = 6, so the molecular formula is C6H12O6.