mzwiki Mass spectrometry
knowledge commons by UniMZ
Guides & terminologyAll Guides
Guide 39 · Computation

Molecular-formula inference from mass and isotope evidence

Test ion assignments, exact-mass windows, elemental constraints, isotope patterns, and fragments without confusing a formula with a structure.

Infer atom counts before claiming a structure

Molecular-formula inference asks which elemental compositions could explain an ion's measured mass and isotope pattern. It is a constrained search, not a direct reading of a compound name. Several formulas can fall inside one mass window, and several structures can share one formula. This Guide extends small-molecule annotation with a reproducible sequence: establish the ion, generate candidates, test independent evidence, and preserve alternatives. All numerical examples are constructed.

Make the ion hypothesis explicit

Record polarity, charge, monoisotopic-peak assignment, and proposed adduct. Check the isotope spacing and chromatographic relationships before converting an observed m/z to neutral mass. For [M+H]+, subtract a proton mass; for [M−H]−, add it. Multimers, in-source losses, and other adducts require different bookkeeping. Software distinguishes these possibilities because the same m/z can imply different neutral compositions. [1] If the ion form remains uncertain, run separate hypotheses rather than silently fixing the most familiar one.

Calculate a candidate and its tolerance

Consider neutral C8H10N4O2. Using 12C = 12, 1H = 1.00782503223, 14N = 14.00307400443, and 16O = 15.99491461957 Da gives:

m = 8(12) + 10(1.00782503223) + 4(14.00307400443) + 2(15.99491461957) = 194.08037557916 Da. These are isotope masses, not average atomic weights. [2] [3] [4] [5]

For [M+H]+, adding 1.007276467 Da gives m/z 195.087652 after rounding. A proton is not a neutral hydrogen atom. [6] If the measured m/z is 195.087847, the signed error relative to that rounded prediction is (195.087847 − 195.087652)/195.087652 × 106 ≈ +1.00 ppm. A hypothetical ±5 ppm window has half-width about 0.000975 m/z here. The candidate passes this filter; that is compatibility, not identification. Choose the actual tolerance from demonstrated measurement performance.

Use chemistry with declared assumptions

Generate atom-count combinations within the mass window using an explicitly stated element set and count limits. Excluding nitrogen would make the example formula impossible to find. Element ratios and valence checks can prioritize candidates, but empirical rules have exceptions and depend on the chemical space. [7]

Mass defect compares monoisotopic and nominal mass. Here we define its sign as Δ = monoisotopic mass − nominal mass. The nominal mass is 194 Da, so Δ = +0.080376 Da after rounding. This is not a mass measurement error or a nuclear binding-energy calculation. Always state the subtraction order. [8]

Double bond equivalent provides another consistency check. For a connected, closed-shell neutral formula with tetravalent C, trivalent N, divalent O, and monovalent H and halogens X, DBE = 1 + C − (H + X)/2 + N/2. Our example gives 1 + 8 − 10/2 + 4/2 = 6. This counts rings plus double bonds plus twice triple bonds under those assumptions. It neither locates them nor justifies applying the formula unchanged to radicals, charged ions, or variable-valence elements. [7] [9]

Test the isotope envelope, not just one peak

Predict candidate-specific isotope masses and relative abundances, then compare them with clean coeluting signals. In an intentionally carbon-only model with 13C fraction p = 0.0107, eight carbons give I(M+1)/I(M) = 8p/(1−p) ≈ 0.08653, or 8.65%. [2] This is a ratio to M, not a fraction of the entire envelope. Real C8H10N4O2 also has heavy H, N, and O contributions; use its full composition for a real prediction.

Interference, insufficient counts, saturation, and incorrect peak grouping can spoil isotope ratios. A missing weak isotope peak is not decisive evidence against a candidate when the acquisition could not detect it. Label-enriched samples require a different abundance model from ordinary natural-abundance formula inference.

Ask whether fragments support the composition

MS/MS adds constraints when product formulas and neutral losses can be reconciled with the precursor's atoms and charge. SIRIUS combines isotope-pattern evidence with fragmentation-tree evidence to rank molecular formulas. A fragmentation tree represents proposed formula-to-formula losses; it is not a direct picture of bond connectivity. [10] [11] Check coisolation and ion chemistry before interpreting an incompatible fragment as grounds to reject the precursor formula.

Report the surviving hypotheses

Save measured m/z, signed error, calibration context, ion alternatives, element restrictions, isotope fit, fragment evidence, software version, and rejected candidates. Rank is conditional on the candidates considered. Neither the smallest ppm error nor a single remaining formula establishes a unique structure.

Check your understanding

The closest formula has the wrong isotope envelope. Should mass error win?

No. Investigate interference and ratio reliability, then compare all reliable evidence. A smaller mass error alone does not override a contradictory envelope.

Does DBE 6 mean six double bonds?

No. Rings and triple bonds also contribute, and the calculation assumes the stated neutral valences.

Beyond the basics

Return to fragmentation for charge-aware losses and to stable-isotope tracing when labeling deliberately changes the isotope distribution.

References & further reading

  1. SIRIUS. Adduct Handling in SIRIUS.

    Official documentation inspected 2026-10-17. Supports distinguishing neutral compounds, ionization, adducts, losses, and measured ion formulas. Software defaults are not prescribed as universal settings.

  2. NIST. Atomic Weights and Isotopic Compositions for Carbon.

    Representative carbon-13 fraction 0.0107 and carbon-13 mass 13.00335483507 Da. Teaching models hold these inputs fixed; natural sample compositions vary.

  3. NIST. Atomic Weights and Isotopic Compositions for Hydrogen.

    Neutral hydrogen-1 relative atomic mass 1.00782503223, used in the water example.

  4. NIST. Atomic Weights and Isotopic Compositions for Nitrogen.

    Nitrogen-14 relative atomic mass 14.00307400443, used with carbon-12, hydrogen-1, and oxygen-16 in the constructed alanine-residue calculation.

  5. NIST. Atomic Weights and Isotopic Compositions for Oxygen.

    Oxygen-16 and oxygen-18 relative atomic masses 15.99491461957 and 17.99915961286, with representative isotope compositions.

  6. NIST. CODATA recommended values of the fundamental physical constants: proton mass in u and electron mass in u.

    Official constants table. Examples round the proton mass to 1.007276467 Da; u and Da name the same mass unit.

  7. Kind and Fiehn (2007). Seven Golden Rules for heuristic filtering of molecular formulas obtained by accurate mass spectrometry. BMC Bioinformatics 8, 105.

    Primary method paper. Supports formula filtering with isotope, element, and chemical constraints; no benchmark success rate or universal exclusion rule is adopted.

  8. IUPAC Gold Book. Mass defect (in mass spectrometry), entry 12478.

    Official indexed definition inspected 2026-10-17; direct plain-page access returned 403. Supports comparison of nominal and monoisotopic mass and positive or negative values. These lessons explicitly choose monoisotopic minus nominal mass, rather than infer a subtraction order from the definition.

  9. IUPAC Gold Book. Ring and double bond equivalent, entry 12561.

    Official indexed plain definition inspected 2026-10-17; direct access returned 403. The lessons use a deliberately restricted C/H/N/O/halogen, connected closed-shell neutral model with declared valences; no universal variable-valence or ion rule is claimed.

  10. Dührkop et al. (2019). SIRIUS 4: a rapid tool for turning tandem mass spectra into metabolite structure information. Nature Methods 16, 299–302.

    Publisher-indexed metadata and supplementary descriptions verified 2026-10-17 against PubMed PMID 30886413. Supports molecular-formula candidates and fragmentation-tree-based analysis; mechanism details are additionally checked against official SIRIUS documentation. No historical benchmark rate is generalized.

  11. SIRIUS. Methods and algorithms: molecular formula identification.

    Official documentation inspected 2026-10-17. Supports candidate generation and combination of isotope-pattern and fragmentation-tree evidence. A tree is not asserted to be a unique molecular structure or a directly observed fragmentation pathway.

Help make this article clearer.Edit this article →Suggest a correction →