feynlag.fields

Particle field classes.

A Field is declared with its gauge representations and expands into explicit component symbols (the representation the whole pipeline works in — commuting SymPy Symbols for bosons, IndexedBase for fermion flavor structure).

  • Scalar — complex (default) or real; supports VEV registration φ⁰ → (v + h + i a)/√2 (explicit 1/√2 per CONVENTIONS.md).

  • Fermion and its Weyl/Dirac/Majorana subclasses — chirality-aware, flavor-indexed (dynamics arrive in Phase 4).

  • GaugeBoson — created by gauge groups, one component per generator.

Discrete-symmetry membership is registered on the group (S3.assign('2', H1, H2)), not in reps, because discrete multiplets usually span several fields.

Functions

bar_partner(indexed_base)

The paired IndexedBase for a Fermion component or bar component.

conjugate_pair(sym[, name])

Antiparticle symbol for a complex physical field.

dag(obj)

Hermitian conjugate: Field → row Matrix; Matrix → .H; expr → complex conjugate (valid for bosonic expressions).

hc(expr)

Hermitian conjugate of a bosonic Lagrangian term (complex conjugate).

Classes

DiracFermion(*args, **kwargs)

Four-component fermion (both chiralities) — not yet supported.

Fermion(name[, reps, component_names, ...])

Spin-1/2 field with chirality and flavor structure.

Field(name[, reps, component_names, real, ...])

Base class for all fields.

GaugeBoson(name, group[, component_names, tex])

Spin-1 gauge field; one real component per group generator.

MajoranaFermion(name[, reps])

Self-conjugate fermion; mass matrix is complex symmetric (Takagi).

Scalar(name[, reps, component_names, real, ...])

Spin-0 field.

WeylFermion(name[, reps, chirality])

Two-component chiral fermion (chirality required).