Expand description
Multilinear tensor expansions, generic over the hypercube the coefficients are indexed by.
An n-variate multilinear is stored as 2^n coefficients.
The basis those coefficients are taken against factors as a tensor product over the variables.
Every variable contributes the same two-element basis (b_0, b_1) of linear polynomials.
That single choice fixes the cube, and with it what each coefficient means:
basis (1 - X, X) vertices {0, 1} coefficients are evaluations
basis (1, X) vertices {0, inf} coefficients are monomial coefficientsThe object built over a cube again and again is the equality indicator.
Written eq(X, Y), it extends the predicate X == Y multilinearly over the cube.
Fixing one operand to a point leaves 2^n coefficients, called the expansion of that point.
Every routine here is generic over the cube. The Boolean-cube specializations live beside them, in the sibling equality indicator module.
Structs§
- InfCube
- The infinity cube
{0, inf}^n, whose per-variable basis is(1, X). - OneCube
- The Boolean cube
{0, 1}^n, whose per-variable basis is(1 - X, X).
Traits§
- Hypercube
- A hypercube of coefficients for multilinear polynomials.
Functions§
- eq_ind
- Evaluates the equality indicator multilinear at a pair of points.
- eq_
ind_ partial_ eval - Computes the partial evaluation of the equality indicator polynomial.
- eq_
ind_ partial_ eval_ in - Builds the equality indicator expansion of a point into a buffer drawn from an allocator.
- eq_
ind_ partial_ eval_ scalars - Computes the partial evaluation of the equality indicator polynomial, returning scalars.
- eq_
ind_ truncate_ low_ inplace - Truncates a built equality indicator expansion to its low indexed variables.
- eq_
ind_ zero - Evaluates the equality indicator multilinear with one operand fixed to all zeros.
- scaled_
eq_ ind_ partial_ eval - Computes the partial evaluation of the equality indicator polynomial, scaled by a constant.
- scaled_
eq_ ind_ partial_ eval_ into - Builds the scaled equality indicator expansion of a point in a caller-supplied store.
- scaled_
eq_ ind_ partial_ eval_ scalars - Computes the scaled partial evaluation of the equality indicator, returning scalars.
- tensor_
prod_ eq_ ind - Tensor of values with the equality indicator evaluated at extra coordinates.