|
C(++)ECCO
C++ Error Control COding: a header-only library for ECC simulations and experiments, modeling complete coding systems across arbitrary finite fields and complex inter-field relationships - Christian Senger <senger@inue.uni-stuttgart.de>
|
Extension field 𝔽_{q^m} ≅ B[x]/(f(x)), constructed from a base field and an irreducible monic modulus polynomial. More...
#include <fields.hpp>

Public Types | |
| using | label_t = ::CECCO::label_t<Q> |
| using | BASE_FIELD = B |
Public Member Functions | |
| constexpr | Ext () noexcept |
| Default constructor: 0. | |
| Ext (int l) | |
| Construct from an integer label l ∈ {0, …, Q − 1}; throws std::invalid_argument otherwise. | |
| constexpr | Ext (const Ext &other) noexcept=default |
| constexpr | Ext (Ext &&other) noexcept=default |
| Ext (const B &other) | |
| Embed a base-field element via the natural embedding B → Ext<B, modulus, mode>. | |
| template<FiniteFieldType S, MOD ext_modulus, LutMode ext_mode> | |
| Ext (const Ext< S, ext_modulus, ext_mode > &other) | |
| Cross-field conversion from another extension field of the same characteristic. | |
| template<FiniteFieldType T> | |
| Ext (const Vector< T > &v) | |
| Construct from a coefficient vector over a subfield. | |
| template<FiniteFieldType MAIN, FiniteFieldType... OTHERS> | |
| Ext (const Iso< MAIN, OTHERS... > &other) | |
| Cross-field conversion from an Iso of the same characteristic. | |
| template<uint16_t p> requires SubfieldOf<Ext<B, modulus, mode>, Fp<p>> && (!std::is_same_v<B, Fp<p>>) | |
| constexpr | Ext (const Fp< p > &other) |
| Embed a prime-field element when 𝔽_p is a (possibly indirect) subfield. | |
| constexpr Ext & | operator= (int l) |
| Assign integer label l ∈ {0, …, Q − 1}; throws std::invalid_argument otherwise. | |
| constexpr Ext & | operator= (const Ext &rhs) noexcept=default |
| Ext & | operator= (Ext &&rhs) noexcept=default |
| template<FiniteFieldType S, MOD ext_modulus, LutMode ext_mode> | |
| Ext & | operator= (const Ext< S, ext_modulus, ext_mode > &other) |
| Cross-field assignment from another extension (copy-and-swap; same semantics as the constructor). | |
| template<uint16_t p> | |
| Ext & | operator= (const Fp< p > &other) |
| Embed an Fp element of matching characteristic (copy-and-swap). | |
| template<FiniteFieldType MAIN, FiniteFieldType... OTHERS> | |
| Ext & | operator= (const Iso< MAIN, OTHERS... > &other) |
| Cross-field assignment from an Iso of matching characteristic (copy-and-swap). | |
| constexpr bool | operator== (const Ext &rhs) const noexcept |
| constexpr Ext | operator- () const & |
| Additive inverse (lvalue): returns a new element. | |
| constexpr Ext & | operator- () && |
| Additive inverse (rvalue): in place. | |
| constexpr Ext & | operator+= (const Ext &rhs) |
| *this += rhs via the addition LUT | |
| constexpr Ext & | operator-= (const Ext &rhs) |
| *this -= rhs via the addition LUT applied to −rhs | |
| constexpr Ext & | operator*= (const Ext &rhs) |
| *this *= rhs via the multiplication LUT | |
| constexpr Ext & | operator*= (int s) |
| Scalar multiplication by an int (repeated addition, reduced mod characteristic). | |
| Ext & | operator/= (const Ext &rhs) |
| *this /= rhs; throws std::invalid_argument if rhs is zero | |
| Ext & | randomize () |
| Uniform random element in {0, …, Q − 1}. | |
| Ext & | randomize_force_change () |
| Like randomize but guaranteed to differ from the current value. | |
| size_t | get_multiplicative_order () const |
| Multiplicative order in the field's multiplicative group. | |
| size_t | get_additive_order () const |
| Additive order: 1 for zero, characteristic p otherwise. | |
| template<FiniteFieldType S = B> requires SubfieldOf<Ext<B, modulus, mode>, S> | |
| Polynomial< S > | get_minimal_polynomial () const |
| Minimal polynomial of this element over a subfield S (defaults to immediate base field B). | |
| constexpr size_t | get_label () const noexcept |
| Underlying integer label in {0, …, Q − 1}. | |
| constexpr bool | has_positive_sign () const noexcept |
| Always true (finite fields are unordered). | |
| constexpr bool | is_zero () const noexcept |
| True iff this is the additive identity. | |
| constexpr Ext & | erase () noexcept |
| Mark this element as erased (encoded as label == max(label_t)). | |
| constexpr Ext & | unerase () noexcept |
| Clear the erasure flag, resetting to the additive identity. | |
| constexpr bool | is_erased () const noexcept |
| Test whether this element is currently erased. | |
| template<FiniteFieldType T = B> | |
| Vector< T > | as_vector () const |
| Coordinate vector over a proper subfield T (defaults to the base field B). | |
| template<FiniteFieldType T> | |
| Isomorphism< Ext< B, modulus, mode >, T > | isomorphism_to () |
| template<FiniteFieldType S, MOD ext_modulus, LutMode ext_mode> | |
| Ext< B, modulus, mode > & | operator= (const Ext< S, ext_modulus, ext_mode > &rhs) |
| template<uint16_t p> | |
| Ext< B, modulus, mode > & | operator= (const Fp< p > &rhs) |
| template<FiniteFieldType MAIN, FiniteFieldType... OTHERS> | |
| Ext< B, modulus, mode > & | operator= (const Iso< MAIN, OTHERS... > &rhs) |
| Public Member Functions inherited from CECCO::details::Field< Ext< B, modulus, LutMode::RunTime > > | |
| Ext< B, modulus, LutMode::RunTime > & | operator= (int l)=delete |
| Assign from int — derived must implement. | |
| constexpr bool | operator!= (const Ext< B, modulus, LutMode::RunTime > &rhs) const |
| Inequality, defined as !(*this == rhs). | |
| constexpr Ext< B, modulus, LutMode::RunTime > | operator+ () const & |
| Unary + on an lvalue: returns a copy. | |
| Ext< B, modulus, LutMode::RunTime > | operator- () const &noexcept=delete |
| Additive inverse on an lvalue — derived must implement. | |
| Ext< B, modulus, LutMode::RunTime > & | operator+= (const Ext< B, modulus, LutMode::RunTime > &rhs) noexcept=delete |
| *this += rhs — derived must implement | |
| Ext< B, modulus, LutMode::RunTime > & | operator-= (const Ext< B, modulus, LutMode::RunTime > &rhs) noexcept=delete |
| *this -= rhs — derived must implement | |
| Ext< B, modulus, LutMode::RunTime > & | operator*= (const Ext< B, modulus, LutMode::RunTime > &rhs) noexcept=delete |
| *this *= rhs — derived must implement | |
| Ext< B, modulus, LutMode::RunTime > & | operator/= (const Ext< B, modulus, LutMode::RunTime > &rhs)=delete |
| *this /= rhs; throws std::invalid_argument if rhs is zero — derived must implement | |
| Field & | randomize ()=delete |
| Uniform random element of the field — derived must implement; may return the same value. | |
| Field & | randomize_force_change ()=delete |
| Like randomize but guaranteed to differ from the current value — derived must implement. | |
| size_t | get_multiplicative_order () const=delete |
| Smallest k > 0 with this^k == 1; throws std::invalid_argument if *this is zero. | |
| size_t | get_additive_order () const=delete |
| Smallest k > 0 with k * *this == 0; for finite fields of characteristic p this is p (or 1 for zero); for ℚ it is 1 for zero and 0 (infinite) otherwise. | |
| bool | has_positive_sign () const noexcept=delete |
| True if the element is "positive" (always true for finite fields; sign of numerator for ℚ). | |
| bool | is_zero () const noexcept=delete |
| True if *this is the additive identity. | |
| Field & | erase () noexcept=delete |
| Mark this element as erased (out-of-field marker for erasure decoding). | |
| Field & | unerase () noexcept=delete |
| Clear the erasure flag, resetting to additive identity. | |
| bool | is_erased () const noexcept=delete |
| Test whether this element is currently erased. | |
Static Public Member Functions | |
| static std::string | get_info () |
| Human-readable description (size, base field, modulus). | |
| static constexpr size_t | get_characteristic () noexcept |
| static constexpr bool | is_constexpr_ready () noexcept |
| True for LutMode::CompileTime, false for LutMode::RunTime. | |
| static constexpr Polynomial< B > | get_modulus () |
| Modulus polynomial f(x) — the irreducible used to construct this field. | |
| static Ext | get_generator () |
| Generator (primitive element) of the multiplicative group. | |
| static constexpr size_t | get_p () noexcept |
| static constexpr size_t | get_m () noexcept |
| static constexpr size_t | get_q () noexcept |
| static constexpr size_t | get_size () noexcept |
| template<FiniteFieldType T> | |
| static Isomorphism< Ext, T > | isomorphism_to () |
| Isomorphism mapping Ext → T for any Isomorphic<Ext, T> target. | |
| static void | show_tables () |
| Print all lookup tables to std::cout (debugging aid). | |
| static constexpr bool | ready () |
| Compile-time signal that all LUTs are constructed. | |
Precomputed Lookup Tables | |
Compile-time generated tables for field operations | |
| using | LUT_COEFF = details::LutHolderNoProvider<Lut2Dcoeff, lambda, mode> |
| using | LUT_ADD = details::LutHolder<Lut2D, Lut2Dcoeff, &lut_coeff, &compute_add_lut_wrapper, mode> |
| using | LUT_MUL = details::LutHolder<Lut2D, Lut2Dcoeff, &lut_coeff, &compute_mul_lut_wrapper, mode> |
| using | LUT_NEG = details::LutHolder<Lut1D, Lut2D, &lut_add, &compute_neg_lut_wrapper, mode> |
| using | LUT_INV = details::LutHolder<Lut1D, Lut2D, &lut_mul, &compute_inv_lut_wrapper, mode> |
| using | LUT_MUL_ORD = details::LutHolder<Lut1D, Lut2D, &lut_mul, &compute_mul_ord_lut_wrapper, mode> |
| using | LUT_GEN = details::LutHolder<Gen, Lut1D, &lut_mul_ord, &compute_generator_wrapper, mode> |
| static constexpr auto | lambda |
| Element coefficients: lut_coeff[i] = polynomial coefficients of element i. | |
| static constexpr bool | luts_ready |
| static constexpr auto & | lut_coeff () |
| static constexpr Lut2D | compute_add_lut_wrapper (const Lut2Dcoeff &(*provider)()) |
| Addition table: lut_add(a,b) = (polynomial_a + polynomial_b) mod f(X). | |
| static constexpr auto & | lut_add () |
| static constexpr Lut2D | compute_mul_lut_wrapper (const Lut2Dcoeff &(*provider)()) |
| Multiplication table: lut_mul(a,b) = (polynomial_a * polynomial_b) mod f(X). | |
| static constexpr auto & | lut_mul () |
| static constexpr Lut1D | compute_neg_lut_wrapper (const Lut2D &(*provider)()) |
| Additive inverse table: lut_neg[a] = -a. | |
| static constexpr auto & | lut_neg () |
| static constexpr Lut1D | compute_inv_lut_wrapper (const Lut2D &(*provider)()) |
| Multiplicative inverse table: lut_inv[a] = a^(-1). | |
| static constexpr auto & | lut_inv () |
| static constexpr Lut1D | compute_mul_ord_lut_wrapper (const Lut2D &(*provider)()) |
| Multiplicative order table: lut_mul_ord[a] = order of a in multiplicative group. | |
| static constexpr auto & | lut_mul_ord () |
| static constexpr Gen | compute_generator_wrapper (const Lut1D &(*provider)()) |
| Primitive element (generator) of the multiplicative group. | |
| static constexpr auto & | g () |
| static constexpr label_t | lut_add (label_t a, label_t b) |
| static constexpr label_t | lut_mul (label_t a, label_t b) |
| static constexpr label_t | lut_neg (label_t a) |
| static constexpr label_t | lut_inv (label_t a) |
Additional Inherited Members | |
| Protected Member Functions inherited from CECCO::details::Field< Ext< B, modulus, LutMode::RunTime > > | |
| ~Field () noexcept=default | |
| Protected Member Functions inherited from CECCO::details::Base | |
| Base ()=default | |
Extension field 𝔽_{q^m} ≅ B[x]/(f(x)), constructed from a base field and an irreducible monic modulus polynomial.
| B | Base field, either CECCO::Fp, another CECCO::Ext, or CECCO::Iso |
| modulus | Coefficients of f(x) low-to-high (constant term first); leading coefficient must be 1, degree m ≥ 2; f(x) must be irreducible over B |
| mode | CECCO::LutMode::RunTime (default) or CECCO::LutMode::CompileTime |
The result has q = |B| and Q = q^m elements; elements are stored as label_t integers in {0, …, Q − 1}. Towers are built by re-using Ext as the base. Pick CompileTime for small fields (zero startup, larger binary) or RunTime for large fields (faster compilation, lazy initialisation on first use). LUT modes mix freely across a tower; a CompileTime extension can only be built when its base satisfies CECCO::Ext::is_constexpr_ready.
modulus is detected during LUT construction and surfaces as std::invalid_argument at runtime, or as a constexpr-evaluation error at compile time when mode == LutMode::CompileTime. Use CECCO::find_irreducible to obtain a valid one.Definition at line 2221 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::BASE_FIELD = B |
Definition at line 2235 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::label_t = ::CECCO::label_t<Q> |
Definition at line 2234 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::LUT_ADD = details::LutHolder<Lut2D, Lut2Dcoeff, &lut_coeff, &compute_add_lut_wrapper, mode> |
Definition at line 2503 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::LUT_COEFF = details::LutHolderNoProvider<Lut2Dcoeff, lambda, mode> |
Definition at line 2495 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::LUT_GEN = details::LutHolder<Gen, Lut1D, &lut_mul_ord, &compute_generator_wrapper, mode> |
Definition at line 2543 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::LUT_INV = details::LutHolder<Lut1D, Lut2D, &lut_mul, &compute_inv_lut_wrapper, mode> |
Definition at line 2527 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::LUT_MUL = details::LutHolder<Lut2D, Lut2Dcoeff, &lut_coeff, &compute_mul_lut_wrapper, mode> |
Definition at line 2511 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::LUT_MUL_ORD = details::LutHolder<Lut1D, Lut2D, &lut_mul, &compute_mul_ord_lut_wrapper, mode> |
Definition at line 2535 of file fields.hpp.
| using CECCO::Ext< B, modulus, mode >::LUT_NEG = details::LutHolder<Lut1D, Lut2D, &lut_add, &compute_neg_lut_wrapper, mode> |
Definition at line 2519 of file fields.hpp.
|
inlineconstexprnoexcept |
Default constructor: 0.
Definition at line 2238 of file fields.hpp.
| CECCO::Ext< B, modulus, mode >::Ext | ( | int | l | ) |
Construct from an integer label l ∈ {0, …, Q − 1}; throws std::invalid_argument otherwise.
Definition at line 2576 of file fields.hpp.
|
constexprdefaultnoexcept |
|
constexprdefaultnoexcept |
| CECCO::Ext< B, modulus, mode >::Ext | ( | const B & | other | ) |
Embed a base-field element via the natural embedding B → Ext<B, modulus, mode>.
Definition at line 2582 of file fields.hpp.
| CECCO::Ext< B, modulus, mode >::Ext | ( | const Ext< S, ext_modulus, ext_mode > & | other | ) |
Cross-field conversion from another extension field of the same characteristic.
| S | Base of the source extension field |
| ext_modulus | Modulus of the source extension field |
| std::invalid_argument | on a downcast whose source value lies outside the target |
Picks the cheapest available path: direct copy if the type matches; cached Isomorphism for isomorphic fields; cached Embedding for tower relationships (upcast cannot fail, downcast may); two-step conversion via details::largest_common_subfield_t for unrelated towers.
Definition at line 2618 of file fields.hpp.
| CECCO::Ext< B, modulus, mode >::Ext | ( | const Vector< T > & | v | ) |
Construct from a coefficient vector over a subfield.
| T | Subfield type |
| std::invalid_argument | if v.length() does not match the extension degree of this field over T |
Reads v as base-|T| coefficients (low-to-high). With CECCO_ERASURE_SUPPORT, an erased component in v produces an erased element here.
Definition at line 2663 of file fields.hpp.
| CECCO::Ext< B, modulus, mode >::Ext | ( | const Iso< MAIN, OTHERS... > & | other | ) |
Cross-field conversion from an Iso of the same characteristic.
Delegates to the Ext(other.main()) overload, letting the Ext-to-Ext logic choose the conversion path; works equally for downcasts, upcasts, and cross-tower bridges.
| std::invalid_argument | if no conversion path exists |
Definition at line 2718 of file fields.hpp.
|
constexpr |
Embed a prime-field element when 𝔽_p is a (possibly indirect) subfield.
Uses the cached Embedding from Fp<p> to this Ext; cannot fail for any value permitted by SubfieldOf<Ext, Fp<p>>.
Definition at line 2793 of file fields.hpp.
| Vector< T > CECCO::Ext< B, modulus, mode >::as_vector | ( | ) | const |
Coordinate vector over a proper subfield T (defaults to the base field B).
| T | Subfield (SubfieldOf<Ext, T> and T ≠ Ext) |
Definition at line 3006 of file fields.hpp.
|
inlinestaticconstexpr |
Addition table: lut_add(a,b) = (polynomial_a + polynomial_b) mod f(X).
Definition at line 2499 of file fields.hpp.
|
inlinestaticconstexpr |
Primitive element (generator) of the multiplicative group.
Definition at line 2539 of file fields.hpp.
|
inlinestaticconstexpr |
Multiplicative inverse table: lut_inv[a] = a^(-1).
Definition at line 2523 of file fields.hpp.
|
inlinestaticconstexpr |
Multiplication table: lut_mul(a,b) = (polynomial_a * polynomial_b) mod f(X).
Definition at line 2507 of file fields.hpp.
|
inlinestaticconstexpr |
Multiplicative order table: lut_mul_ord[a] = order of a in multiplicative group.
Definition at line 2531 of file fields.hpp.
|
inlinestaticconstexpr |
Additive inverse table: lut_neg[a] = -a.
Definition at line 2515 of file fields.hpp.
|
constexprnoexcept |
Mark this element as erased (encoded as label == max(label_t)).
Definition at line 2603 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2544 of file fields.hpp.
| size_t CECCO::Ext< B, modulus, mode >::get_additive_order | ( | ) | const |
Additive order: 1 for zero, characteristic p otherwise.
Definition at line 2943 of file fields.hpp.
|
inlinestaticconstexprnoexcept |
Definition at line 2374 of file fields.hpp.
|
static |
Generator (primitive element) of the multiplicative group.
Smallest label with multiplicative order |field| − 1; cached statically.
Definition at line 2993 of file fields.hpp.
|
static |
Human-readable description (size, base field, modulus).
Definition at line 2973 of file fields.hpp.
|
inlineconstexprnoexcept |
Underlying integer label in {0, …, Q − 1}.
Definition at line 2376 of file fields.hpp.
|
inlinestaticconstexprnoexcept |
Definition at line 2397 of file fields.hpp.
| Polynomial< S > CECCO::Ext< B, modulus, mode >::get_minimal_polynomial | ( | ) | const |
Minimal polynomial of this element over a subfield S (defaults to immediate base field B).
| S | Subfield (SubfieldOf<Ext, S>) |
Computed from the S-conjugacy orbit { α, α^{|S|}, α^{|S|²}, … } as the polynomial whose roots are exactly those conjugates. Useful for working with polynomials over an intermediate or the prime subfield in a tower.
Definition at line 2953 of file fields.hpp.
|
staticconstexpr |
Modulus polynomial f(x) — the irreducible used to construct this field.
Definition at line 2982 of file fields.hpp.
| size_t CECCO::Ext< B, modulus, mode >::get_multiplicative_order | ( | ) | const |
Multiplicative order in the field's multiplicative group.
| std::invalid_argument | if *this is zero |
Definition at line 2934 of file fields.hpp.
|
inlinestaticconstexprnoexcept |
Definition at line 2396 of file fields.hpp.
|
inlinestaticconstexprnoexcept |
Definition at line 2398 of file fields.hpp.
|
inlinestaticconstexprnoexcept |
Definition at line 2399 of file fields.hpp.
|
inlineconstexprnoexcept |
Always true (finite fields are unordered).
Definition at line 2409 of file fields.hpp.
|
inlinestaticconstexprnoexcept |
True for LutMode::CompileTime, false for LutMode::RunTime.
Used by extensions further up in a tower to gate their own CompileTime instantiation (a CompileTime field cannot be built on a RunTime base).
Definition at line 2384 of file fields.hpp.
|
inlineconstexprnoexcept |
Test whether this element is currently erased.
Definition at line 2424 of file fields.hpp.
|
inlineconstexprnoexcept |
True iff this is the additive identity.
Definition at line 2411 of file fields.hpp.
| Isomorphism< Ext< B, modulus, mode >, T > CECCO::Ext< B, modulus, mode >::isomorphism_to | ( | ) |
Definition at line 2597 of file fields.hpp.
|
static |
Isomorphism mapping Ext → T for any Isomorphic<Ext, T> target.
|
inlinestaticconstexpr |
Definition at line 2504 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2548 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2496 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2528 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2551 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2512 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2549 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2536 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2520 of file fields.hpp.
|
inlinestaticconstexpr |
Definition at line 2550 of file fields.hpp.
|
constexpr |
*this *= rhs via the multiplication LUT
Definition at line 2884 of file fields.hpp.
|
constexpr |
Scalar multiplication by an int (repeated addition, reduced mod characteristic).
Definition at line 2893 of file fields.hpp.
|
constexpr |
*this += rhs via the addition LUT
Definition at line 2866 of file fields.hpp.
|
constexpr |
Additive inverse (rvalue): in place.
Definition at line 2857 of file fields.hpp.
|
constexpr |
Additive inverse (lvalue): returns a new element.
Definition at line 2847 of file fields.hpp.
|
constexpr |
*this -= rhs via the addition LUT applied to −rhs
Definition at line 2875 of file fields.hpp.
| Ext< B, modulus, mode > & CECCO::Ext< B, modulus, mode >::operator/= | ( | const Ext< B, modulus, mode > & | rhs | ) |
*this /= rhs; throws std::invalid_argument if rhs is zero
Definition at line 2904 of file fields.hpp.
|
constexprdefaultnoexcept |
| Ext & CECCO::Ext< B, modulus, mode >::operator= | ( | const Ext< S, ext_modulus, ext_mode > & | other | ) |
Cross-field assignment from another extension (copy-and-swap; same semantics as the constructor).
| Ext< B, modulus, mode > & CECCO::Ext< B, modulus, mode >::operator= | ( | const Ext< S, ext_modulus, ext_mode > & | rhs | ) |
Definition at line 2822 of file fields.hpp.
| Ext & CECCO::Ext< B, modulus, mode >::operator= | ( | const Fp< p > & | other | ) |
Embed an Fp element of matching characteristic (copy-and-swap).
| Ext< B, modulus, mode > & CECCO::Ext< B, modulus, mode >::operator= | ( | const Fp< p > & | rhs | ) |
Definition at line 2831 of file fields.hpp.
| Ext & CECCO::Ext< B, modulus, mode >::operator= | ( | const Iso< MAIN, OTHERS... > & | other | ) |
Cross-field assignment from an Iso of matching characteristic (copy-and-swap).
| Ext< B, modulus, mode > & CECCO::Ext< B, modulus, mode >::operator= | ( | const Iso< MAIN, OTHERS... > & | rhs | ) |
Definition at line 2840 of file fields.hpp.
|
defaultnoexcept |
|
constexpr |
Assign integer label l ∈ {0, …, Q − 1}; throws std::invalid_argument otherwise.
Definition at line 2813 of file fields.hpp.
|
inlineconstexprnoexcept |
Definition at line 2319 of file fields.hpp.
| Ext< B, modulus, mode > & CECCO::Ext< B, modulus, mode >::randomize | ( | ) |
Uniform random element in {0, …, Q − 1}.
Definition at line 2914 of file fields.hpp.
| Ext< B, modulus, mode > & CECCO::Ext< B, modulus, mode >::randomize_force_change | ( | ) |
Like randomize but guaranteed to differ from the current value.
Definition at line 2924 of file fields.hpp.
|
inlinestaticconstexpr |
Compile-time signal that all LUTs are constructed.
Used by extensions further up in a tower to defer their own LUT computation until this one is fully instantiated, preventing compiler recursion-depth issues. The implementation is the constexpr luts_ready flag, which forces immediate evaluation of every LUT on a CompileTime instantiation.
Definition at line 2454 of file fields.hpp.
|
static |
Print all lookup tables to std::cout (debugging aid).
Definition at line 3037 of file fields.hpp.
|
constexprnoexcept |
Clear the erasure flag, resetting to the additive identity.
Definition at line 2609 of file fields.hpp.
|
staticconstexpr |
Element coefficients: lut_coeff[i] = polynomial coefficients of element i.
Definition at line 2479 of file fields.hpp.
|
staticconstexpr |
Definition at line 2553 of file fields.hpp.