feynlag

Tree-level Feynman rules from Beyond-Standard-Model Lagrangians, in pure SymPy.

You declare particle fields with their gauge and discrete-symmetry representations, write the Lagrangian explicitly with library building blocks (Dmu, dag, Bilinear), and feynlag takes it from there: gauge/discrete invariance and hermiticity checks, electroweak symmetry breaking, mass-matrix diagonalization, rotation to the physical basis, vertex extraction across the closed Lorentz catalog, and export to LaTeX tables or UFO (MadGraph and friends). The feynlag.pheno module turns the resulting Feynman rules into decay widths, branching ratios and tree-level 2→2 cross sections.

The centerpiece of this site is the Algorithms Manual: one chapter per pipeline stage, with the physics statement, the algorithm as it’s actually coded, a full derivation of the key results, the design gotchas that shaped the implementation, and the pinned test that fixes each physical result.

Getting Started

Install, and the quick tour from the README.

Getting Started
Algorithms Manual

Full derivations, stage by stage: declare → write → check → break → diagonalize → extract → export.

1. The Pipeline
Tutorials

Executed notebooks walking the SM and its extensions end to end, plus decays and scattering.

Tutorials
Examples

Annotated gallery of the worked models in examples/.

Examples Gallery
Conventions

Every sign, metric, and normalization choice, pinned by tests.

Conventions
API Reference

Auto-generated reference for every public module.

API Reference