Chemical Equation Balancer illustration

Chemical Equation Balancer

Balances a chemical equation by solving the conservation-of-atoms linear system, returning the smallest whole-number coefficients and an atom-by-atom check of both sides.

Separate species with "+" and the two sides with "=" or "->".

Notes

  • Balancing enforces conservation of mass: the same number of each atom must appear on both sides.
  • The coefficients come from the null space of the element matrix, scaled to the smallest positive integers.