What the calculator does
For any formula it gives:
- the molar mass in g/mol, to the precision the atomic weights support;
- the number of atoms of each element;
- each element’s contribution to the mass, and its percentage by mass;
- the molecular formula in Hill order (carbon first, then hydrogen, then alphabetical).
How to enter a formula
| Write | For |
|---|---|
H2SO4 |
ordinary formulas |
Ca(OH)2, K4[Fe(CN)6] |
groups in round or square brackets, nested if needed |
CuSO4·5H2O or CuSO4*5H2O |
hydrates |
SO4^2-, NH4+ |
ions |
Element symbols are case-sensitive: Co is cobalt but CO is carbon monoxide.
The formula
Here nᵢ is the number of atoms of element i in the formula and Aᵣ(i) is its standard atomic weight. The mass percentage of an element is
Worked example: glucose, C₆H₁₂O₆
- Count atoms. 6 carbon, 12 hydrogen and 6 oxygen.
- Multiply by atomic weights. 6 × 12.011 = 72.066; 12 × 1.0080 = 12.096; 6 × 15.999 = 95.994.
- Add. M = 72.066 + 12.096 + 95.994 = 180.156 g/mol. The atomic weights of C, H and O carry uncertainties that add up to about ±0.02 g/mol, so the result is reported as 180.16 g/mol.
- Percentages. Carbon 40.00%, hydrogen 6.71%, oxygen 53.28%.
Common mistakes
- Applying a subscript to the wrong atoms. In Ca(OH)₂ the 2 applies to both O and H, giving 2 O and 2 H.
- Forgetting the water in a hydrate. The water of crystallisation is part of the formula’s mass.
- Lower-case symbols.
co2is not a formula; carbon dioxide is CO2. - Over-precise answers. Sulfur’s atomic weight is only known to ±0.02 because its isotopic composition varies in nature, so a molar mass containing sulfur cannot be meaningful to three decimal places.
Practical applications
- Making solutions. Mass needed = concentration × volume × molar mass.
- Stoichiometry. Converting between grams and moles is the first step in any reaction calculation.
- Empirical formulas. Percent composition data from combustion analysis lead back to a formula.
- Fertilisers and food labels. The percentage of nitrogen in a fertiliser, or of sodium in salt, comes from percent composition.
Assumptions and limitations
Atomic weights are the IUPAC abridged standard values, which apply to normal terrestrial materials. Samples with unusual isotopic composition, such as enriched uranium or deuterated compounds, have different molar masses. Elements with no stable isotopes have no standard atomic weight; the calculator uses the mass number of the longest-lived isotope and says so. Isotope labels such as D and ¹³C are not supported.