Mole Fraction Calculator

x₁ = n₁/n_total for two or three components.

The formula behind it

x₁ = n₁ ÷ (n₁ + n₂ + …); Σxᵢ = 1
x
mole fraction — dimensionless share of total moles

Mole fraction states a mixture's composition as each component's share of the total moles. It is the concentration unit gas laws and Raoult's law are written in: partial pressure is x·P_total, and vapor pressure above an ideal solution is x·P°. Fractions are dimensionless and must sum to 1 — the calculator normalizes whatever you enter (two or three components) and shows the check sum.

How to use this calculator

  1. 1

    Enter moles of each component (the third field is optional).

  2. 2

    Press Calculate to see every fraction and mole percent.

  3. 3

    Add a value to the optional third field and watch the fractions renormalize so they still sum to exactly 1.

Worked examples

Air, simplified

0.78 mol N₂ + 0.21 mol O₂ + 0.01 mol Ar → x(N₂) = 0.78, matching the 78% you memorized.

Ethanol–water

2 mol ethanol + 3 mol water → x(ethanol) = 0.4; vapor above it follows Raoult from there.

Frequently asked questions

Explore more categories

Command Palette

Search for a command to run...