Analytical Derivations (derivations)

Analytical derivations for verification of transport solvers.

SymPy-based symbolic derivations that produce reference eigenvalues for verifying numerical solvers. Each derivation module returns VerificationCase objects with the analytical k_inf, materials, geometry parameters, and LaTeX documentation.

Homogeneous

SymPy derivations for infinite homogeneous medium eigenvalues.

Derives analytical k_inf for 1-group, 2-group, and 4-group systems using symbolic matrix algebra, then evaluates numerically.

orpheus.derivations.homogeneous.derive_1g()[source]

1-group infinite medium eigenvalue.

\[k_\infty = \frac{\nu \Sigma_f}{\Sigma_a}\]
Return type:

VerificationCase

orpheus.derivations.homogeneous.derive_2g()[source]

2-group infinite medium eigenvalue via characteristic polynomial.

The eigenvalue problem is \(\mathbf{A}\phi = \frac{1}{k}\mathbf{F}\phi\) where \(\mathbf{A} = \text{diag}(\Sigma_t) - \Sigma_s^T\) and \(\mathbf{F} = \chi \otimes (\nu\Sigma_f)\).

Return type:

VerificationCase

orpheus.derivations.homogeneous.derive_4g()[source]

4-group infinite medium eigenvalue.

Symbolic 4x4 matrix with numeric XS substituted before solving.

Return type:

VerificationCase

orpheus.derivations.homogeneous.all_cases()[source]

Return all homogeneous verification cases.

Return type:

list[VerificationCase]

Slab Collision Probability

Semi-analytical slab collision probability eigenvalues.

Derives k_inf for {1,2,4} energy groups × {1,2,4} regions using the E₃ exponential integral kernel. The CP matrix is computed numerically to integrator precision; the eigenvalue problem is then a finite matrix solve.

orpheus.derivations.cp_slab.all_cases()[source]

Return all slab CP verification cases: {1,2,4}eg × {1,2,4}rg.

Return type:

list[VerificationCase]

Cylindrical Collision Probability

Semi-analytical cylindrical collision probability eigenvalues.

Derives k_inf for {1,2,4} energy groups × {1,2,4} regions using the Ki₃/Ki₄ Bickley-Naylor kernel. The CP matrix is computed numerically via y-quadrature; the eigenvalue problem is a finite matrix solve.

orpheus.derivations.cp_cylinder.all_cases()[source]

Return all cylindrical CP verification cases: {1,2,4}eg × {1,2,4}rg.

Return type:

list[VerificationCase]

Diffusion

SymPy derivations for 2-group diffusion eigenvalues.

1-region (bare slab): analytical buckling eigenvalue B² = (π/H)². 2-region (fuel + reflector): analytical interface matching — cos/sinh solutions in fuel/reflector, flux and current continuity → transcendental equation for k_eff solved by brentq to machine precision.

orpheus.derivations.diffusion.derive_1rg(fuel_height=50.0)[source]

2-group bare slab: analytical buckling eigenvalue.

Parameters:

fuel_height (float)

Return type:

VerificationCase

orpheus.derivations.diffusion.derive_2rg(fuel_height=50.0, refl_height=30.0)[source]

2-group fuel + reflector slab: Richardson-extrapolated reference.

Geometry: [vacuum] fuel (0 to H_f) | reflector (H_f to H_f+H_r) [vacuum]

The 2-group coupled system with interface matching has a complex transcendental equation. We use Richardson extrapolation from the diffusion solver at 4 mesh refinements (O(h²)) to obtain the reference. Results are cached to avoid recomputation on subsequent test runs.

Parameters:
Return type:

VerificationCase

orpheus.derivations.diffusion.all_cases()[source]

Return analytical diffusion cases (bare slab only).

Return type:

list[VerificationCase]

orpheus.derivations.diffusion.solver_cases()[source]

Return solver-computed diffusion cases (fuel+reflector Richardson).

Return type:

list[VerificationCase]

Kernels

Special-function kernels for collision probability derivations.

Provides E₃ (exponential integral) for slab geometry and Ki₃/Ki₄ (Bickley-Naylor) for cylindrical geometry.

orpheus.derivations._kernels.e3(x)[source]

Third-order exponential integral E₃(x).

Parameters:

x (float)

Return type:

float

orpheus.derivations._kernels.e3_vec(x)[source]

Vectorised E₃.

Parameters:

x (ndarray)

Return type:

ndarray

class orpheus.derivations._kernels.BickleyTables(n_points=20000, x_max=50.0)[source]

Tabulated Ki₃ and Ki₄ Bickley-Naylor functions.

Ki₃(x) = int_0^{pi/2} exp(-x / sin t) sin(t) dt Ki₄(x) = int_x^inf Ki₃(t) dt

Tables are built once and cached.

Parameters:
ki3(x)[source]

Evaluate Ki₃(x) by interpolation.

Parameters:

x (float)

Return type:

float

ki4(x)[source]

Evaluate Ki₄(x) by interpolation.

Parameters:

x (float)

Return type:

float

ki3_vec(x)[source]

Vectorised Ki₃.

Parameters:

x (ndarray)

Return type:

ndarray

ki4_vec(x)[source]

Vectorised Ki₄.

Parameters:

x (ndarray)

Return type:

ndarray

orpheus.derivations._kernels.bickley_tables(n_points=20000, x_max=50.0)[source]

Get (or build) the cached Bickley-Naylor lookup tables.

Parameters:
Return type:

BickleyTables

Types

Types for the analytical verification system.

class orpheus.derivations._types.VerificationCase(name, k_inf, method, geometry, n_groups, n_regions, materials, geom_params, latex, description, tolerance='')[source]

Reference solution from an analytical derivation.

Parameters:
name

Unique identifier following method_geometry_Neg_Nrg convention, e.g. "cp_slab_2eg_2rg". Homogeneous is "homo_Neg".

Type:

str

k_inf

Analytical multiplication factor.

Type:

float

method

Solver method abbreviation: "homo", "cp", "sn", "moc", "mc", "dif".

Type:

str

geometry

Geometry abbreviation: "--", "slab", "cyl1D", "sph1D".

Type:

str

n_groups

Number of energy groups.

Type:

int

n_regions

Number of spatial regions (1 = homogeneous).

Type:

int

materials

Material-ID to Mixture mapping (same convention as solvers).

Type:

dict[int, Any]

geom_params

Geometry constructor keyword arguments (empty for homogeneous).

Type:

dict

latex

SymPy-generated LaTeX showing the derivation steps.

Type:

str

description

Human-readable summary of the verification case.

Type:

str

tolerance

Expected accuracy, e.g. "< 1e-10", "O(h²)", "z < 5σ".

Type:

str