homalg · ExteriorElement¶
21 accepted declarations. Python and Rust forms, contracts, evidence, failure boundaries, and checked usages are kept together below.
Worked example¶
The complete checked program Compute in an exterior algebra and induce a linear map on two-forms uses this API directly.
# SPDX-License-Identifier: MIT
# Copyright (c) 2026 Benjamin Antieau and Deven Manam
"""Compute in an exterior algebra and induce a linear map on two-forms."""
from noether import Q
from noether.commalg import PolynomialRing
from noether.homalg import FreeModule, ModuleElement, ModuleHomomorphism
from noether.linalg import Matrix, Vector
def main() -> None:
ring = PolynomialRing(Q, ["t"])
module = FreeModule(ring, 3, basis_labels=["e0", "e1", "e2"])
exterior = module.exterior_algebra()
e0, e1, e2 = [exterior.generator(position) for position in range(3)]
volume = e0 * e1 * e2
assert volume == exterior.alternating_product(
[
ModuleElement(module, Vector.from_values(ring, [1, 0, 0])),
ModuleElement(module, Vector.from_values(ring, [0, 1, 0])),
ModuleElement(module, Vector.from_values(ring, [0, 0, 1])),
]
)
assert e1 * e0 == -(e0 * e1)
assert e0 * e0 == exterior.zero()
e0_dual = ModuleElement(module.dual(), Vector.from_values(ring, [1, 0, 0]))
assert volume.contract(e0_dual) == e1 * e2
linear_map = ModuleHomomorphism(
module,
module,
Matrix.from_rows(ring, [[1, 1, 0], [0, 1, 0], [0, 0, 2]]),
)
on_two_forms = linear_map.exterior_power(2)
on_two_forms.verify()
assert on_two_forms.apply_exterior(e1 * e2) == 2 * (e0 * e2 + e1 * e2)
print(
"Λ² has basis",
exterior.basis(2),
"and the induced map sends e1∧e2 to",
on_two_forms.apply_exterior(e1 * e2).terms,
)
if __name__ == "__main__":
main()
Run it with .venv/bin/python examples/40_exterior_algebra.py.
homalg.ExteriorElement¶
A canonical sparse, possibly inhomogeneous, exact exterior-algebra element.
noether::homalg::ExteriorElement · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/homalg/test_exterior_algebra.py:19 · validation/unit/homalg/test_exterior_algebra.py:202 · validation/unit/homalg/test_exterior_algebra.py:222 · validation/unit/homalg/test_exterior_algebra.py:379 · validation/unit/homalg/test_exterior_algebra.py:393 · validation/unit/homalg/test_exterior_algebra.py:396
homalg.ExteriorElement.__add__¶
Add another compatible value to this value.
Detailed contract
Add an element of the same exterior algebra. Returns the argument unchanged.
noether::homalg::ExteriorElement::add · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/infra/test_discovery.py:211 · validation/unit/infra/test_public_api_index.py:293
homalg.ExteriorElement.__mul__¶
Multiply this value by another compatible value.
noether::homalg::ExteriorElement::mul · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/infra/test_public_api_index.py:214
homalg.ExteriorElement.__neg__¶
Return the additive inverse of this value.
Detailed contract
Negate every retained coefficient.
noether::homalg::ExteriorElement::neg · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
homalg.ExteriorElement.__rmul__¶
Multiply this value by a compatible value on its left.
noether::homalg::ExteriorElement · Python projection
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
homalg.ExteriorElement.__sub__¶
Subtract another compatible value from this value.
Detailed contract
Subtract an element of the same exterior algebra.
noether::homalg::ExteriorElement::sub · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/infra/test_discovery.py:212
homalg.ExteriorElement.algebra¶
Exact exterior-algebra parent carried by this element.
Detailed contract
Exact exterior-algebra parent.
noether::homalg::ExteriorElement::algebra · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/40_exterior_algebra.py:3 · examples/distributed/f2_linear_algebra.py:3 · validation/unit/commalg/test_acceptance_workload.py:3 · validation/unit/commalg/test_construction_algebras.py:41 · validation/unit/commalg/test_construction_algebras.py:71 · validation/unit/commalg/test_construction_algebras.py:72
homalg.ExteriorElement.coefficient¶
Coefficient of one strictly increasing exterior basis sequence.
Detailed contract
Coefficient of one canonical basis monomial.
noether::homalg::ExteriorElement::coefficient · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/17_weighted_power_series.py:19 · examples/22_matroids_and_tutte.py:11 · examples/22_matroids_and_tutte.py:12 · examples/22_matroids_and_tutte.py:13 · examples/33_simplicial_cohomology_operations.py:31 · validation/unit/combin/test_acceptance_workload.py:45
homalg.ExteriorElement.contract¶
Contract with a covector from the exact dual based module.
Detailed contract
Contract by a covector in the exact dual based module. On e_(i1) wedge ... wedge e_(ik), the summand deleting position j has coefficient (-1)^j phi(e_ij). Degree-zero terms contract to zero.
noether::homalg::ExteriorElement::contract · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/40_exterior_algebra.py:29 · validation/unit/combin/test_acceptance_workload.py:77 · validation/unit/combinatorics/test_matroid.py:55 · validation/unit/homalg/test_exterior_algebra.py:129 · validation/unit/homalg/test_exterior_algebra.py:130 · validation/unit/homalg/test_exterior_algebra.py:131
homalg.ExteriorElement.degrees¶
Sorted exterior degrees carrying nonzero homogeneous components.
Detailed contract
Sorted degrees with nonzero support.
noether::homalg::ExteriorElement::degrees · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/14_weighted_polynomials.py:18 · examples/33_simplicial_cohomology_operations.py:32 · validation/unit/homalg/test_chain_complex.py:102 · validation/unit/homalg/test_chain_complex.py:26 · validation/unit/homalg/test_exterior_algebra.py:91 · validation/unit/homalg/test_padic_homology_facade.py:237
homalg.ExteriorElement.from_json¶
Restore and revalidate a canonical exterior element from typed JSON.
Detailed contract
Deserialize and revalidate an exact exterior element.
noether::homalg::ExteriorElement::from_json · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/category/test_category.py:14 · validation/unit/combin/test_acceptance_workload.py:65 · validation/unit/combin/test_acceptance_workload.py:86 · validation/unit/combin/test_graph_facade.py:106 · validation/unit/combin/test_graph_facade.py:25 · validation/unit/combinatorics/test_kashiwara_crystal.py:32
homalg.ExteriorElement.homogeneous_component¶
Extract one homogeneous component without changing its parent.
Detailed contract
Retain only the requested homogeneous component.
noether::homalg::ExteriorElement::homogeneous_component · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
homalg.ExteriorElement.homogeneous_degree¶
Unique exterior degree, or None for a nonzero inhomogeneous value.
Detailed contract
Degree when every nonzero term has one degree. The zero element returns None, since it belongs to every homogeneous component. An inhomogeneous nonzero element also returns None; use Self::degrees to distinguish the two cases.
noether::homalg::ExteriorElement::homogeneous_degree · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/commalg/test_polynomial_facade.py:260 · validation/unit/commalg/test_polynomial_facade.py:261 · validation/unit/commalg/test_polynomial_facade.py:262 · validation/unit/commalg/test_polynomial_facade.py:305 · validation/unit/homalg/test_exterior_algebra.py:90 · validation/unit/homalg/test_finite_group_cohomology.py:163
homalg.ExteriorElement.is_zero¶
Whether the canonical sparse term table is empty.
Detailed contract
Whether this is the additive identity.
noether::homalg::ExteriorElement::is_zero · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/17_weighted_power_series.py:16 · examples/17_weighted_power_series.py:17 · examples/39_kahler_differentials.py:20 · validation/unit/commalg/test_graded_commutative_facade.py:26 · validation/unit/commalg/test_kahler_differentials.py:113 · validation/unit/commalg/test_kahler_differentials.py:38
homalg.ExteriorElement.scalar_mul¶
Multiply every term by a scalar in the exact coefficient context.
Detailed contract
Multiply every coefficient by a scalar in the exact base context.
noether::homalg::ExteriorElement::scalar_mul · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/commalg/test_intersection_theory.py:30 · validation/unit/commalg/test_intersection_theory.py:37 · validation/unit/commalg/test_intersection_theory.py:51 · validation/unit/commalg/test_power_series_facade.py:152 · validation/unit/numthy/test_elliptic_curve_facade.py:36 · validation/bench/macaulay2_derived.py:693
homalg.ExteriorElement.term_count¶
Number of nonzero canonical sparse terms.
Detailed contract
Number of retained nonzero basis terms.
noether::homalg::ExteriorElement::term_count · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
homalg.ExteriorElement.terms¶
Canonical (increasing basis positions, coefficient) terms.
Detailed contract
Iterate over canonical (basis positions, coefficient) terms.
noether::homalg::ExteriorElement::terms · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | attached / bounded |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/07_integer_factorization.py:14 · examples/40_exterior_algebra.py:43 · validation/unit/combin/test_acceptance_workload.py:45 · validation/unit/combin/test_acceptance_workload.py:81 · validation/unit/combinatorics/test_boundary.py:31 · validation/unit/combinatorics/test_boundary.py:44
homalg.ExteriorElement.to_json¶
Serialize the value as faithful typed JSON.
Detailed contract
Serialize the parent and exact canonical sparse terms.
noether::homalg::ExteriorElement::to_json · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/category/test_category.py:14 · validation/unit/category/test_category.py:15 · validation/unit/combin/test_acceptance_workload.py:30 · validation/unit/combin/test_acceptance_workload.py:65 · validation/unit/combin/test_acceptance_workload.py:86 · validation/unit/combin/test_graph_facade.py:106
homalg.ExteriorElement.to_power_element¶
Convert a homogeneous value to canonical exterior-power coordinates.
Detailed contract
Convert a homogeneous component to the existing exterior-power coordinate module. Zero converts to every degree. A nonzero inhomogeneous element or a homogeneous element of another degree is rejected explicitly.
noether::homalg::ExteriorElement::to_power_element · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: validation/unit/homalg/test_exterior_algebra.py:219 · validation/unit/homalg/test_exterior_algebra.py:359
homalg.ExteriorElement.verify¶
Replay canonicality and coefficient-context checks.
Detailed contract
Revalidate canonical ordering, coefficient ownership, and alternating bases.
noether::homalg::ExteriorElement::verify · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/01_bezout_certificates.py:10 · examples/01_bezout_certificates.py:3 · examples/03_exact_linear_systems.py:13 · examples/03_exact_linear_systems.py:3 · examples/04_smith_normal_form.py:12 · examples/06_shortest_lattice_vectors.py:12
homalg.ExteriorElement.wedge¶
Exact wedge product; material sparse work runs without the Python GIL.
Detailed contract
Exterior product with exact Koszul signs. Repeated basis positions vanish by the alternating law. In characteristic two, negation is the identity and the same algorithm therefore gives the correct commutative-but-alternating product.
noether::homalg::ExteriorElement::wedge · Direct Rust declaration
| Contract | Value |
|---|---|
| Guarantee | checked deterministic result |
| Determinism | deterministic |
| Availability | default CPU build |
| Domain implementation crates | noether, flint-core, groebner-kernel, m4rst, m4rste, module-core, resolution-kernel, sparla |
| GIL | released |
| Semantic ID | noether/homalg/ExteriorElement@1 |
Executable usage: examples/27_weight_characters.py:28 · validation/unit/homalg/test_exterior_algebra.py:308 · validation/unit/homalg/test_exterior_algebra.py:351 · validation/unit/homalg/test_exterior_algebra.py:393 · validation/unit/homalg/test_exterior_algebra.py:396 · validation/unit/homalg/test_exterior_algebra.py:397