Reactions
A reaction has reactants, an arrow, and products. Conditions sit in bracketed groups immediately after the arrow.
Arrow types
Section titled “Arrow types”| Arrow | Kind | Use |
|---|---|---|
-> | :forward | Net forward reaction |
<- | :reverse | Net reverse reaction |
<=> | :equilibrium | Equilibrium (Haber, acid/base) |
<-> | :resonance | Resonance structures |
Basic reactions
Section titled “Basic reactions”2H_2 + O_2 -> 2H_2OHCl + NaOH -> NaCl + H_2OCH_4 + 2O_2 -> CO_2 + 2H_2OReactants and products are each a +-separated list of molecules. The
+ operators are stripped from the model; the renderer reinserts them.
Equilibrium with conditions
Section titled “Equilibrium with conditions”The Haber process — nitrogen and hydrogen over an iron catalyst at elevated temperature:
N_2 + 3H_2 <=>[Fe][400°C] 2NH_3The first bracketed group [Fe] is the above condition (catalyst).
The second bracketed group [400°C] is the below condition
(temperature). Both are captured as Reaction#conditions.
The MathML renderer emits the arrow as an <munderover>:
<munderover> <mo>⇌</mo> <mtext>Fe</mtext> <mtext>400°C</mtext></munderover>One-sided conditions
Section titled “One-sided conditions”Only the above condition:
A <=>[H_2O] BOnly the below:
A <=>[Δ] B(Use the second form when the condition is energy/heat, by convention placed below the arrow.)
Spectators and ionic equations
Section titled “Spectators and ionic equations”Ag^+ + Cl^- -> AgClIons on either side are full Molecule instances with their charge
captured on the relevant atom. Round-trip is exact.
What’s not yet in v1
Section titled “What’s not yet in v1”- Reversible resonance is supported; tautomerism arrows are not.
- Multi-step reactions (chained arrows) require explicit Reaction nodes per step.
- Rates and stoichiometry validation are out of scope for the parser — a separate linter pass can verify balancing.