Empirical Formula Calculator

Empirical Formula Calculator determines simplest whole-number ratio of atoms in compounds, using elemental percentages or mass values efficiently.

Format: Symbol=amount, Symbol: amount, or Symbol amount. Use element symbols (e.g., C, H, O, Na). Amounts may be grams or percentages; Math.js expressions are supported.
Examples
Click an example to autofill, then press Calculate.

Results

Equation (exact Math.js expression)
C=40.0, H=6.7, O=53.3
Empirical Formula
CH2O
Elements
3
Min moles
3.3333
Multiplier
1
Formula
CH2O

Helping notes

  • If you enter percentages, the calculator assumes a 100 g sample; if grams, it uses the values as is.
  • Each amount is divided by the element's atomic mass to get moles, then all moles are divided by the smallest to get a ratio. If needed, a small multiplier (×2, ×3, …) is applied to reach whole numbers.
  • Math.js expressions are supported anywhere an amount is expected.

What is an Empirical Formula Calculator?

An Empirical Formula Calculator is a chemistry tool that finds the simplest whole-number ratio of elements in a compound. The empirical formula differs from the molecular formula: while the molecular formula gives the actual number of atoms of each element, the empirical formula provides the lowest integer ratio. For example, glucose has molecular formula \(C_6H_{12}O_6\) but empirical formula \(CH_2O\). This calculator simplifies the process by taking percentage composition or mass of elements, converting them to moles, and reducing ratios to the smallest whole numbers.

$$\textbf{Steps:}\quad \text{1. Convert mass or % to moles: } n_i=\frac{m_i}{M_i},\qquad \text{2. Divide by smallest }n_{\min},\qquad \text{3. Round to nearest whole number.}$$

About the Empirical Formula Calculator

The Empirical Formula Calculator uses math.js for precise numerical handling and MathJax for clear, responsive formula rendering. It accepts either mass values (grams) or percent composition of each element in the compound. Internally, it divides each given mass by the molar mass of the element, yielding moles. Then, each mole value is divided by the smallest one to generate a ratio. If ratios are not close to integers, the calculator multiplies by a factor (e.g., 2 or 3) to eliminate fractions. The output is the empirical formula, displayed in chemical notation.

$$\textbf{Ratio step:}\quad r_i=\frac{n_i}{n_{\min}},\qquad \text{Empirical formula}=\prod_i E_i^{\,\text{round}(r_i)}.$$

How to Use this Empirical Formula Calculator

  1. Enter either mass (in grams) or percent composition of each element.
  2. Provide molar mass of each element (from periodic table).
  3. Click calculate: the tool computes moles, ratios, and the final empirical formula.
  4. Interpret results: simplest whole-number formula shows the proportional makeup of the compound.

Examples

Example 1: Compound contains 40% C, 6.7% H, and 53.3% O.
Convert to moles: \(n_C=40/12=3.33,\; n_H=6.7/1=6.7,\; n_O=53.3/16=3.33.\)
Divide by smallest (3.33): \(C=1,\ H=2,\ O=1.\)
Empirical formula: $$CH_2O.$$

Example 2: Compound with 70% Fe and 30% O.
\(n_{Fe}=70/55.85=1.25,\; n_O=30/16=1.88.\)
Ratio: \(1.25:1.88\Rightarrow 2:3.\)
Empirical formula: $$Fe_2O_3.$$

Example 3: Given 10 g Na, 20 g S, and 30 g O.
\(n_{Na}=10/23=0.435,\; n_S=20/32=0.625,\; n_O=30/16=1.875.\)
Divide by smallest (0.435): \(Na=1,\ S=1.44,\ O=4.31.\)
Multiply all by 3: \(Na_3S_4O_{13}.\)

FAQs on Empirical Formula Calculator

Q1: What is the difference between empirical and molecular formula?
Empirical formula shows the simplest integer ratio of elements, while molecular formula shows the actual number of atoms.

Q2: Can empirical and molecular formulas be the same?
Yes, when the compound’s molecular formula is already in the lowest whole-number ratio, like H2O or CO2.

Q3: Why do we use empirical formulas in chemistry?
They provide the simplest representation of a compound’s composition, useful in stoichiometry and chemical analysis.

Q4: Can the calculator handle fractional ratios?
Yes, it multiplies ratios by factors (2, 3, etc.) to convert fractions into whole numbers for the formula.

More Math & Algebra Calculators