Skip to main content

Module lagrange

Module lagrange 

Source
Expand description

Lagrange interpolation helpers for share re-sharing.

Re-sharing works by computing Lagrange interpolation of existing shares at new party indices. The result is a new share that is consistent with the same aggregate secret.

Structs§

FieldElement
A field element for Lagrange interpolation. Stored as raw bytes; the algorithm-specific crate (FROST, CMP20, etc.) interprets them per the underlying curve/group.

Functions§

interpolate_at
Compute the new share for party at index target_x given existing (x, y) pairs and arithmetic ops. This is the core of re-sharing.
lagrange_basis_at
Compute the Lagrange coefficient λ_i(x) evaluated at point x, given the set of x-coordinates xs and the index i.