The science
Overall reaction. 6 CO2 + 6 H2O + light → C6H12O6 + 6 O2. Atoms are balanced (the page counts them), and the model books 1 CO2 : 1 CH2O : 1 O2.
Leaf photosynthesis (Farquhar–von Caemmerer–Berry, simplified C3). A = min(Ac, Aj) − Rd, Ac = Vcmax(Ci−Γ*)/(Ci+Kc(1+O/Ko)) (Rubisco-limited) and Aj = J(Ci−Γ*)/(4Ci+8Γ*) (light / RuBP-regeneration-limited). Electron transport follows the non-rectangular hyperbola θJ² − (αI+Jmax)J + αI Jmax = 0 with θ = 0.7, α = 0.3. Temperature uses Arrhenius factors (Ea: Vcmax 65, Jmax 44 kJ/mol) and a high-temperature decline above about 38 °C. Parameters are textbook-type model values (Bernacchi-style at 25 °C), not a fit to any species.
Stomata. Ball–Berry: gs = g0 + g1 A hs/Ca, supply A = gs/1.6 (Ca−Ci); the pair is solved by fixed-point iteration (20 steps). Transpiration E = gs VPD / P. Drying soil closes stomata linearly between ψs = −0.5 and −2.5 MPa (Campbell retention curve for the soil). Open stomata let CO2 in and water out: that trade-off is the central story.
Canopy, carbon and growth. Light per leaf area follows Beer–Lambert (k = 0.5) averaged over the canopy (big-leaf). Net CO2 uptake is converted to CH2O (30.03 g/mol); half is kept as dry mass (Y = 0.5, the rest stands for construction and maintenance respiration) and split leaf / stem / root 40 / 20 / 40 %, shifting to roots in drought and to leaves in shade. Leaf area = leaf mass × SLA.
Water. A single soil bucket (0.4 m deep under 0.05 m²) is filled by irrigation/rain, emptied by transpiration and drains above field capacity; the page checks the water ledger closes.
Honest simplifications. Big-leaf C3 only (no C4/CAM), no nitrogen limitation, no self-shading beyond Beer–Lambert, fixed leaf temperature = air temperature, one soil layer, quasi-steady leaf at 1-minute steps, particle counts are symbolic (not one per molecule). Typical-value model for teaching; not agronomic advice.
Educational model, not agronomic advice. The plant is a generic decorative herb. Models built with Blender (plant, roots, soil, terrain, molecules) and rendered with Three.js.