Skip to main content

Crate laddu_expr

Crate laddu_expr 

Source
Expand description

Symbolic expression graphs and parameter definitions used throughout laddu.

This crate provides shareable expression DAGs, parameter layouts and values, and optional graph visualization support.

Modules§

parameters
Parameter definitions, layouts, registries, and concrete values.

Macros§

parameter
Convenience macro for creating parameters. Usage: parameter!("name") for a free parameter, or parameter!("name", 1.0) for a fixed one.

Structs§

DisplayColor
An RGB color used by tree and Graphviz displays.
Expr
Shareable symbolic expression represented internally as a directed acyclic graph.
ExprGraph
Topologically ordered, serializable representation of an Expr DAG.
ExprGraphDotDisplay
Configurable Graphviz DOT display for an ExprGraph.
ExprGraphTreeDisplay
Configurable indented-tree display for an ExprGraph.
ExprId
Stable identifier for a node in a serialized ExprGraph.
ExprMetadata
User-facing annotations and origin information for an expression node.
ExprShapeError
Describes an operation applied to an expression with an incompatible shape.
NodeStyle
Optional foreground, fill, and border colors for a displayed node.
NodeStyleRule
A selector and the style to overlay on matching nodes.

Enums§

BinaryOp
Binary operation in an expression graph.
ColorPreset
Built-in color palette for expression graphs.
ExprError
Errors produced while constructing or rebuilding expressions.
ExprGraphError
Structural validation errors for serialized expression graphs.
ExprNode
Serialized node in a topologically ordered ExprGraph.
ExprNodeKind
Node categories available to visualization style selectors.
ExprShape
Structural shape of an expression.
ExprSourceKind
Broad origin category recorded in ExprMetadata.
NodeSelector
Predicate selecting expression nodes for a NodeStyleRule.
P4Component
A named component of a four-momentum in (E, px, py, pz) order.
ParamError
Errors produced while defining, laying out, or assigning parameters.
RepeatedSubtrees
Controls how graph displays handle nodes reached through multiple paths.
UnaryOp
Unary operation in an expression graph.
ValueKind
Runtime value category produced by an expression node.

Traits§

ComponentIndex
Converts a component selector into a zero-based index.

Functions§

acos
Constructs the principal arccosine of value.
atan2
Constructs the two-argument arctangent atan2(y, x).
cis
Constructs cos(phase) + i sin(phase).
complex
Constructs a complex scalar from real and imaginary expressions.
dot
Constructs a vector dot-product expression.
event_p4_component
References one component of a named event four-momentum.
event_scalar
References a named scalar column in each event.
matmul
Constructs a matrix-matrix multiplication expression.
matrix
Constructs a row-major matrix expression from a nested array.
matrix_from_flat
Constructs a row-major matrix from a flat sequence.
matvec
Constructs a matrix-vector multiplication expression.
polar_complex
Constructs a complex scalar from magnitude and phase expressions.
solve
Constructs an expression that solves a linear system.
vector
Constructs a vector expression from scalar elements.

Type Aliases§

ExprResult
Result type for expression construction and validation operations.
ParamResult
Result type for parameter construction and lookup operations.