Skip to content

Equation pipeline check

This page exercises the chain that every later page depends on:

  1. packages/pe-core/equations/equations.yaml holds the expression, its assumptions, its citation and hand-checked test values.
  2. python scripts/gen_equations.py parses it with sympy, generates the LaTeX and the shared test vectors, and fails if a test value disagrees with the expression.
  3. The TypeScript engine is tested against those vectors (1e-9 relative), and every generated formula is rendered by KaTeX in strict mode.
  4. The docs embed the result with <Eq id="…" />; nobody types LaTeX.
M=DM = D
MM
conversion ratio
DD
duty ratio
Buck conversion ratio, CCM✓ verified by 8 tests
Assumptions, convention and source
Assumptions
  • ideal (lossless) switches and passive components
  • continuous conduction mode (CCM)
  • periodic steady state
  • small-ripple approximation
Convention
M=V/VgM = V/V_g
Source
Erickson & Maksimović 2020, Ch. 2 (Principles of Steady-State Converter Analysis)
Derivation
step-by-step sympy derivation
Equation id
buck.ccm.M · equations.yaml entry

Open the expander under the equation for its assumptions and source; the badge links to the parity test. The equation itself is explained on the volt-second balance page.

The chart below is a React island that calls the TypeScript evaluators of the buck and boost CCM conversion ratios in your browser and plots them with Plotly. The equation explorer does the same for any equation in the catalogue.

The numbers in the examples, presets and exercises on this site are synthetic: round teaching values, not data from any real design.