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, orparameter!("name", 1.0)for a fixed one.
Structs§
- Display
Color - An RGB color used by tree and Graphviz displays.
- Expr
- Shareable symbolic expression represented internally as a directed acyclic graph.
- Expr
Graph - Topologically ordered, serializable representation of an
ExprDAG. - Expr
Graph DotDisplay - Configurable Graphviz DOT display for an
ExprGraph. - Expr
Graph Tree Display - Configurable indented-tree display for an
ExprGraph. - ExprId
- Stable identifier for a node in a serialized
ExprGraph. - Expr
Metadata - User-facing annotations and origin information for an expression node.
- Expr
Shape Error - Describes an operation applied to an expression with an incompatible shape.
- Node
Style - Optional foreground, fill, and border colors for a displayed node.
- Node
Style Rule - A selector and the style to overlay on matching nodes.
Enums§
- Binary
Op - Binary operation in an expression graph.
- Color
Preset - Built-in color palette for expression graphs.
- Expr
Error - Errors produced while constructing or rebuilding expressions.
- Expr
Graph Error - Structural validation errors for serialized expression graphs.
- Expr
Node - Serialized node in a topologically ordered
ExprGraph. - Expr
Node Kind - Node categories available to visualization style selectors.
- Expr
Shape - Structural shape of an expression.
- Expr
Source Kind - Broad origin category recorded in
ExprMetadata. - Node
Selector - Predicate selecting expression nodes for a
NodeStyleRule. - P4Component
- A named component of a four-momentum in
(E, px, py, pz)order. - Param
Error - Errors produced while defining, laying out, or assigning parameters.
- Repeated
Subtrees - Controls how graph displays handle nodes reached through multiple paths.
- UnaryOp
- Unary operation in an expression graph.
- Value
Kind - Runtime value category produced by an expression node.
Traits§
- Component
Index - 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§
- Expr
Result - Result type for expression construction and validation operations.
- Param
Result - Result type for parameter construction and lookup operations.