Limiting reagent, equivalents charged and theoretical product amount
rxn_limiting_reagent
Finds the limiting reagent, the equivalents charged and the theoretical amount of product.
- Runs
- On the server
- Level
- Checked against a reference: exact arithmetic in a Python program on hand-typed CIAAW weights, with the Green Book's printed ammonia example; a second implementation in Python by a separate agent of the same model family
What it is
Returns the limiting reagent (least n/ν, ties named), equivalents charged and theoretical product, in exact arithmetic. Use when the reactants are charged and the coefficients are known. Not for planning amounts from equivalents: use `rxn_stoichiometry_table`; not for the percent yield: use `rxn_yield`; not for one substance's moles: use `calc_formula_mass`. Coefficients are taken as stated, not balanced; every quantity needs its unit, and purity (w/w) or density where the form needs it.
What it does
You give
reagents(required): Every reactant as charged, with its coefficient.product(required): The product: a formula or a molar mass, and its coefficient.
No request is recorded for this tool.
Limits
- Bench and process arithmetic on a reaction you write down.
- Research and education software: it does not predict products or routes, check that the chemistry will work, or assess hazards.
- Arithmetic on the reaction, quantities and roles you supply.
- It does not check that a formula is the substance meant, that the coefficients balance or describe the reaction that occurs, or that a density, coefficient or purity (a mass fraction, not a chromatographic area percent) is right.
- Every computed number a reply returns, other than an integer or an exact decimal, is rounded once to 12 significant figures: to the nearest, a change of at most 5 × 10⁻¹² of its value, except that a lower bound is rounded down and an upper bound up, a change of less than 1 × 10⁻¹¹; the method computes, and decides any pass or fail, on the unrounded value.
It will not answer when
- a substance gives both, or neither, of a formula and a molar mass.
- a formula reads as a SMILES (= # @ / \ or a lower-case letter not after an upper-case one); for a structure, molecule_descriptors.
- the formula cannot be read exactly as written: it is an electron; it writes a charge of zero; the formula-mass parser refuses it (an unknown symbol or one without a standard atomic weight, an ambiguous charge such as Fe3+, an unclosed bracket, a number before the formula such as 13CH4); it holds a count of zero; a count or the charge is above 2^53 − 1; or its molar-mass sum is too large to hold exactly (the shared routine formula-reading).
- a solid, a substance or a neat liquid has no stated purity (never defaulted).
Every input, with its units2 inputs
reagents(required): Every reactant as charged, with its coefficient.product(required): The product: a formula or a molar mass, and its coefficient.
Every refusal, with its code10 refusals
| Code | When |
|---|---|
MOLAR_MASS_SOURCE | a substance gives both, or neither, of a formula and a molar mass. |
FORMULA_IS_SMILES | a formula reads as a SMILES (= # @ / \ or a lower-case letter not after an upper-case one); for a structure, molecule_descriptors. |
FORMULA_INVALID | the formula cannot be read exactly as written: it is an electron; it writes a charge of zero; the formula-mass parser refuses it (an unknown symbol or one without a standard atomic weight, an ambiguous charge such as Fe3+, an unclosed bracket, a number before the formula such as 13CH4); it holds a count of zero; a count or the charge is above 2^53 − 1; or its molar-mass sum is too large to hold exactly (the shared routine formula-reading). |
PURITY_MISSING | a solid, a substance or a neat liquid has no stated purity (never defaulted). |
MASS_FRACTION_MISSING | a solution by mass fraction has no stated mass fraction. |
DENSITY_MISSING | a liquid, a mass-fraction solution or a line given by volume has no density. |
CONCENTRATION_MISSING | a solution by concentration has no concentration. |
QUANTITY_SOURCE | a charge or a line gives not exactly one of its quantities (amount, mass or volume), or a reagent other than the reference carries a scale. |
QUANTITY_FORM | a quantity does not fit the form: a volume for a solid or a substance, a mass for a solution by concentration. |
OUT_OF_RANGE | reagents[*].massFraction outside above 0 and at most 1. |
The calculation
The method's equations, constants and worked example.
Equation 1
n_i = n as stated
= m · w / M for a mass
= V · ρ · w / M for a liquid
= V · c for a solution by concentration
w = purity in % ÷ 100
| Symbol | Meaning |
|---|---|
n_i | amount of reactant i charged, mol |
m | mass as charged, g |
w | mass fraction (purity), the stated % divided by 100 |
M | molar mass (formula-reading), g/mol |
Source 1.
Equation 2
ξmax = min_i (n_i / ν_i)
| Symbol | Meaning |
|---|---|
ξmax | maximum extent of reaction, mol |
n_i | amount of reactant i charged, mol |
ν_i | stoichiometric coefficient of i (magnitude) |
Source 2.
Equation 3
limiting = every i with n_i / ν_i = ξmax, compared exactly in rational arithmetic on the decimal inputs
| Symbol | Meaning |
|---|---|
i | reactant |
Source 2.
Equation 4
equiv_i = n_i / n_lim
stoichiometric ratio_i = (n_i / ν_i) / ξmax
| Symbol | Meaning |
|---|---|
n_lim | amount of the first-named limiting reagent, mol |
Equation 5
n_P = ν_P · ξmax
| Symbol | Meaning |
|---|---|
n_P | theoretical amount of product, mol |
ν_P | product coefficient |
M_P | product molar mass, g/mol |
Source 2.
| Constant | Value | From |
|---|---|---|
standard atomic weights (CIAAW abridged), through formula-mass 1.1.0 A_r | a table of values, part of the method | Source 3 |
A definition, not a model: the equation states what the quantity means. A different convention gives a different number.
Worked example
Worked example: one case of rxn-limiting-reagent@1.0.4, from its inputs through each step to the answer. Values are written as a person writes them; the working carries more digits, so your own figure may differ in the last digit shown.
Inputs
- reagents[0].name = hydrogen
- reagents[0].formula = H2
- reagents[0].coefficient = 2
- reagents[0].form = substance
- reagents[0].purity = 100 %
- reagents[0].mass = 4 g
- reagents[1].name = oxygen
- reagents[1].formula = O2
- reagents[1].coefficient = 1
- reagents[1].form = substance
- reagents[1].purity = 100 %
- reagents[1].mass = 16 g
- product.formula = H2O
- product.coefficient = 2
Steps
- nH2 = 1.984127 mol, from reagents[0].mass, reagents[0].formula, reagents[0].purity; by equation 1; gives rows[0].amount.
- nO2 = 0.50003125 mol, from reagents[1].mass, reagents[1].formula, reagents[1].purity; by equation 1; gives rows[1].amount.
- xi = 0.50003125 mol, from nH2, nO2, reagents[0].coefficient, reagents[1].coefficient; by equation 2; gives extentOfReaction.
- water = 1.0000625 mol, from xi, product.coefficient; by equation 5; gives theoreticalProduct.amount.
The working, as the case writes it:
n(H2) = 4.00/2.0160 = 1.98413 mol, /2 = 0.99206
n(O2) = 16.0/31.998 = 0.500031 mol, /1 = 0.500031: oxygen limits
ξmax = 0.500031 mol
water 2 × 0.500031 = 1.000063 mol.
Answer
rows[0].amount = 1.984127 mol
rows[1].amount = 0.50003125 mol
extentOfReaction = 0.50003125 mol
theoreticalProduct.amount = 1.0000625 mol
Where these values came from: our own exact-arithmetic script and a hand-worked case; hand-worked in the fixture (derivation and worked steps).
At build the tool returned this answer within the tolerance the file states: every number relative 1e-12; names, limiting reagents, statuses and codes exact.
Sources
Thompson A, Taylor BN. Guide for the Use of the International System of Units (SI), NIST Special Publication 811, Chapter 8: Comments on Some Quantities and Their Units
Used for: Limiting reagent, equivalents charged and theoretical product amount. At: section §8.6.4 (M = m/n), §8.6.10 (w_B = m_B/m), §8.6.7 (ρ = m/V) and §8.6.5 (c_B = n_B/V), as the IUPAC Green Book, 4th edition abridged, §4.10 p. 44 (M_B = m_B/n_B, w_B and c_B = n_B/V; read 17 November 2026).
Read in full, 14 November 2026IUPAC, Quantities, Units and Symbols in Physical Chemistry (the IUPAC Green Book), 4th edition, abridged version, eds. Brett CMA, Frey JG, Hinde R, Kuroda Y, Marquardt R, Pavese F, Quack M, Stohner J, Thor AJ, RSC Publishing 2023
Used for: Limiting reagent, equivalents charged and theoretical product amount. At: p. 45, section §4.10, notes 13 and 14: n_j = n_j,0 + ν_j ξ, ν_j negative for reactants, and ξmax is the value of ξ when at least one of the reactants is exhausted; the minimum over reactants of n_i/|ν_i| is the record's derivation from it (reactant i is exhausted at ξ = n_i,0/|ν_i|); p. 45, section §4.10, note 14: ξmax, when at least one of the reactants is exhausted; every reactant exhausted at ξmax is named, the record's derivation; p. 45, section §4.10, note 14: n_j = n_j,0 + ν_j ξ, taken at ξmax with no product charged (n_P,0 = 0); note 13: ν_j positive for products.
Read in full, 17 November 2026IUPAC Commission on Isotopic Abundances and Atomic Weights (CIAAW), Abridged Standard Atomic Weights
Used for: Limiting reagent, equivalents charged and theoretical product amount. At: table Abridged Standard Atomic Weights.
Read in full, 10 November 2026
How it is checked
- Level
Checked against a reference.
- Checked against
Our own exact-arithmetic script and a hand-worked case.
- Cases
No case set is linked to this version.
- Not checked
Whether the coefficients balance or describe the reaction that occurs (rxn_atom_economy checks balance), side reactions, or that the product forms at all. A formula starting with a digit (13H2) is refused FORMULA_INVALID since 1.0.4, through formula-mass 1.3.0, with no case in this method's fixtures; the refusal is covered by stored reference values and unit tests only.
Changes to its methods1 change
- 25 November 2026, rxn-limiting-reagent@1.0.4: In 1.0.4, through formula-mass 1.3.0, a formula starting with a digit is now refused (FORMULA_INVALID); every other output is unchanged, and every pinned output hash is the same.