Free commutative rings #
The theory of the free commutative ring generated by a type α.
It is isomorphic to the polynomial ring over ℤ with variables
in α
Main definitions #
FreeCommRing α: the free commutative ring on a type αlift (f : α → R): the ring homFreeCommRing α →+* Rinduced by functoriality fromf.map (f : α → β): the ring homFreeCommRing α →*+ FreeCommRing βinduced by functoriality from f.
Main results #
FreeCommRing has functorial properties (it is an adjoint to the forgetful functor).
In this file we have:
of : α → FreeCommRing αlift (f : α → R) : FreeCommRing α →+* Rmap (f : α → β) : FreeCommRing α →+* FreeCommRing βfreeCommRingEquivMvPolynomialInt : FreeCommRing α ≃+* MvPolynomial α ℤ:FreeCommRing αis isomorphic to a polynomial ring.
Implementation notes #
FreeCommRing α is implemented not using MvPolynomial but
directly as the free abelian group on Multiset α, the type
of monomials in this free commutative ring.
Tags #
free commutative ring, free ring
If α is a type, then FreeCommRing α is the free commutative ring generated by α.
This is a commutative ring equipped with a function FreeCommRing.of : α → FreeCommRing α which has
the following universal property: if R is any commutative ring, and f : α → R is any function,
then this function is the composite of FreeCommRing.of and a unique ring homomorphism
FreeCommRing.lift f : FreeCommRing α →+* R.
A typical element of FreeCommRing α is a ℤ-linear combination of
formal products of elements of α.
For example if x and y are terms of type α then 3 * x * x * y - 2 * x * y + 1 is a
"typical" element of FreeCommRing α. In particular if α is empty
then FreeCommRing α is isomorphic to ℤ, and if α has one term t
then FreeCommRing α is isomorphic to the polynomial ring ℤ[t].
One can think of FreeRing α as the free polynomial ring
with coefficients in the integers and variables indexed by α.
Equations
Instances For
Equations
The canonical map from α to the free commutative ring on α.
Equations
Instances For
Lift a map α → R to an additive group homomorphism FreeCommRing α → R.
Instances For
A map f : α → β produces a ring homomorphism FreeCommRing α →+* FreeCommRing β.
Equations
Instances For
is_supported x s means that all monomials showing up in x have variables in s.
Equations
- x.IsSupported s = (x ∈ Subring.closure (FreeCommRing.of '' s))
Instances For
The restriction map from FreeCommRing α to FreeCommRing s where s : Set α, defined
by sending all variables not in s to zero.
Equations
- FreeCommRing.restriction s = FreeCommRing.lift fun (a : α) => if H : a ∈ s then FreeCommRing.of ⟨a, H⟩ else 0
Instances For
The canonical ring homomorphism from the free ring generated by α to the free commutative ring
generated by α.
Instances For
The coercion defined by the canonical ring homomorphism from the free ring generated by α to
the free commutative ring generated by α.
Instances For
Equations
If α has size at most 1 then the natural map from the free ring on α to the
free commutative ring on α is an isomorphism of rings.
Equations
Instances For
Equations
- FreeRing.instCommRing α = { toRing := inferInstanceAs (Ring (FreeRing α)), mul_comm := ⋯ }
The free commutative ring on α is isomorphic to the polynomial ring over ℤ with
variables in α
Equations
- freeCommRingEquivMvPolynomialInt α = RingEquiv.ofRingHom (FreeCommRing.lift fun (a : α) => MvPolynomial.X a) (MvPolynomial.eval₂Hom (Int.castRingHom (FreeCommRing α)) FreeCommRing.of) ⋯ ⋯
Instances For
The free commutative ring on the empty type is isomorphic to ℤ.
Equations
Instances For
Alias of freeCommRingPEmptyEquivInt.
The free commutative ring on the empty type is isomorphic to ℤ.
Instances For
The free commutative ring on a type with one term is isomorphic to ℤ[X].
Equations
Instances For
The free ring on the empty type is isomorphic to ℤ.
Equations
Instances For
Alias of freeRingPEmptyEquivInt.
The free ring on the empty type is isomorphic to ℤ.
Instances For
The free ring on a type with one term is isomorphic to ℤ[X].