CurrentModule = Oscar
DocTestSetup = Oscar.doctestsetup()
We recall the definition of localization. All rings considered are commutative, with multiplicative identity 1.
Let R
be a ring, and let U \subset R
be a multiplicatively closed subset. That is,
Consider the equivalence relation on R\times U
defined by setting
Write \frac{r}{u}
for the equivalence class of (r, u)
and R[U^{-1}]
for the set of all equivalence classes.
Mimicking the standard arithmetic for fractions, R[U^{-1}]
can be made into a ring. This ring is called the
localization of R
at U
. It comes equipped with the natural ring homomorphism
Given an R
-module M
, the analogous construction yields an R[U^{-1}]
-module M[U^{-1}]
which is
called the localization of M
at U
. See the section on [modules](@ref modules_multivariate).
Our focus in this section is on localizing multivariate polynomial rings and their quotients. The starting point
for this is to provide functionality for handling (several types of) multiplicatively closed subsets of multivariate
polynomial rings. Given such a polynomial ring R
and a multiplicatively closed subset U
of R
whose type
is supported by OSCAR, entering localization(R, U)
creates the localization of R
at U
. Given a quotient
RQ
of R
, with projection map p
: R
\to
RQ
, and given a multiplicatively closed subset U
of R
,
entering localization(RQ, U)
creates the localization of RQ
at p(U)
: Since every multiplicatively
closed subset of RQ
is of type p(U)
for some U
, there is no need to support an extra type for
multiplicatively closed subsets of quotients.
!!! note Most functions described here rely on the computation of standard bases. Recall that OSCAR supports standard bases for multivariate polynomial rings over fields (exact fields supported by OSCAR) and for multivariate polynomial rings over the integers.
The OSCAR types discussed in this section are all parametrized. To simplify the presentation, details on the parameters are omitted.
All types for multiplicatively closed subsets of rings belong to the abstract type AbsMultSet
.
For multiplicatively closed subsets of multivariate polynomial rings, there are the abstract subtype
AbsPolyMultSet
and its concrete descendants MPolyComplementOfKPointIdeal
,
MPolyComplementOfPrimeIdeal
, and MPolyPowersOfElement
.
The general abstract type for localizations of rings is AbsLocalizedRing
. For localizations of multivariate
polynomial rings, there is the concrete subtype MPolyLocRing
. For localizations of quotients of
multivariate polynomial rings, there is the concrete subtype MPolyQuoLocRing
.
In accordance with the above mentioned types, we have the following constructors for multiplicatively closed subsets of multivariate polynomial rings.
complement_of_point_ideal(R::MPolyRing, a::Vector)
complement_of_prime_ideal(P::MPolyIdeal; check::Bool=false)
powers_of_element(f::MPolyRingElem)
It is also possible to build products of multiplicatively closed sets already given:
product(T::AbsMPolyMultSet, U::AbsMPolyMultSet)
Containment in multiplicatively closed subsets can be checked via the in
function:
in(f::MPolyRingElem, U::AbsMPolyMultSet)
localization(R::MPolyRing, U::AbsMPolyMultSet)
localization(RQ::MPolyQuoRing, U::AbsMPolyMultSet)
If Rloc
is the localization of a multivariate polynomial ring R
at a multiplicatively closed subset
U
of R
, then
base_ring(Rloc)
refers toR
, andinverted_set(Rloc)
toU
.
If RQ
is a quotient of a multivariate polynomial ring R
, p
: R
\to
RQ
is the projection map, U
is a
multiplicatively closed subset of R
, and RQL
is the localization of RQ
at p(U)
, then
base_ring(RQL)
refers toR
, andinverted_set(RQL)
toU
.
This reflects the way of creating localizations of quotients of multivariate polynomial rings in OSCAR.
julia> R, (x, y, z) = polynomial_ring(QQ, ["x", "y", "z"]);
julia> P = ideal(R, [x])
Ideal generated by
x
julia> U = complement_of_prime_ideal(P)
Complement
of prime ideal (x)
in multivariate polynomial ring in 3 variables over QQ
julia> Rloc, _ = localization(U);
julia> R === base_ring(Rloc)
true
julia> U === inverted_set(Rloc)
true
julia> T, t = polynomial_ring(QQ, "t");
julia> K, a = number_field(2*t^2-1, "a");
julia> R, (x, y) = polynomial_ring(K, ["x", "y"]);
julia> I = ideal(R, [2*x^2-y^3, 2*x^2-y^5])
Ideal generated by
2*x^2 - y^3
2*x^2 - y^5
julia> P = ideal(R, [y-1, x-a])
Ideal generated by
y - 1
x - a
julia> U = complement_of_prime_ideal(P)
Complement
of prime ideal (y - 1, x - a)
in multivariate polynomial ring in 2 variables over K
julia> RQ, _ = quo(R, I);
julia> RQL, _ = localization(RQ, U);
julia> R == base_ring(RQL)
true
julia> U == inverted_set(RQL)
true
The general abstract type for elements of localizations of rings is AbsLocalizedRingElem
.
For elements of localizations of multivariate polynomial rings, there is the concrete subtype MPolyLocRingElem
.
For elements of localizations of quotients of multivariate polynomial rings, there is the concrete subtype MPolyQuoLocRingElem
.
If Rloc
is the localization of a multivariate polynomial ring R
at a multiplicatively closed subset
U
of R
, then elements of Rloc
are created as (fractions of) images of elements of R
under
the localization map or by coercing (pairs of) elements of R
into fractions.
If RQ
is a quotient of a multivariate polynomial ring R
, p
: R
\to
RQ
is the projection map, U
is a
multiplicatively closed subset of R
, and RQL
is the localization of RQ
at p(U)
, then elements of
RQL
are created similarly, starting from elements of R
.
julia> R, (x, y, z) = polynomial_ring(QQ, ["x", "y", "z"])
(Multivariate polynomial ring in 3 variables over QQ, QQMPolyRingElem[x, y, z])
julia> P = ideal(R, [x])
Ideal generated by
x
julia> U = complement_of_prime_ideal(P)
Complement
of prime ideal (x)
in multivariate polynomial ring in 3 variables over QQ
julia> Rloc, iota = localization(U);
julia> iota(x)
x
julia> Rloc(x)
x
julia> f = iota(y)/iota(z)
y/z
julia> g = Rloc(y, z)
y/z
julia> X, Y, Z = Rloc.(gens(R));
julia> h = Y/Z
y/z
julia> f == g == h
true
julia> f+g
2*y/z
julia> f*g
y^2/z^2
julia> T, t = polynomial_ring(QQ, "t");
julia> K, a = number_field(2*t^2-1, "a");
julia> R, (x, y) = polynomial_ring(K, ["x", "y"]);
julia> I = ideal(R, [2*x^2-y^3, 2*x^2-y^5])
Ideal generated by
2*x^2 - y^3
2*x^2 - y^5
julia> P = ideal(R, [y-1, x-a])
Ideal generated by
y - 1
x - a
julia> U = complement_of_prime_ideal(P)
Complement
of prime ideal (y - 1, x - a)
in multivariate polynomial ring in 2 variables over K
julia> RQ, p = quo(R, I);
julia> RQL, iota = localization(RQ, U);
julia> phi = compose(p, iota);
julia> phi(x)
x
julia> RQL(x)
x
julia> f = phi(x)/phi(y)
x/y
julia> g = RQL(x, y)
x/y
julia> X, Y = gens(RQL);
julia> h = X/Y
x/y
julia> f == g == h
true
julia> f+g
2*x/y
julia> f*g
x^2/y^2
If Rloc
is a localization of a multivariate polynomial ring R
, and f
is an element of Rloc
, internally
represented by a pair (r, u)
of elements of R
, then
parent(f)
refers toRloc
,numerator(f)
tor
, anddenominator(f)
tou
. IfRQL
is a localization of a quotientRQ
of a multivariate polynomial ringR
, andf
is an element ofRQL
, internally represented by a pair(r, u)
of elements ofR
, thenparent(f)
refers toRQL
,numerator(f)
to the image ofr
inRQ
, anddenominator(f)
to the image ofu
inRQ
. That is, the behavior of the functionsnumerator
anddenominator
reflects the mathematical viewpoint of representingf
by pairs of elements ofRQ
and not the internal representation off
as pairs of elements ofR
.
julia> R, (x, y, z) = polynomial_ring(QQ, ["x", "y", "z"]);
julia> P = ideal(R, [x])
Ideal generated by
x
julia> U = complement_of_prime_ideal(P)
Complement
of prime ideal (x)
in multivariate polynomial ring in 3 variables over QQ
julia> Rloc, iota = localization(U);
julia> f = iota(x)/iota(y)
x/y
julia> parent(f)
Localization
of multivariate polynomial ring in 3 variables x, y, z
over rational field
at complement of prime ideal (x)
julia> g = iota(y)/iota(z)
y/z
julia> r = numerator(f*g)
x
julia> u = denominator(f*g)
z
julia> typeof(r) == typeof(u) <: MPolyRingElem
true
julia> T, t = polynomial_ring(QQ, "t");
julia> K, a = number_field(2*t^2-1, "a");
julia> R, (x, y) = polynomial_ring(K, ["x", "y"]);
julia> I = ideal(R, [2*x^2-y^3, 2*x^2-y^5])
Ideal generated by
2*x^2 - y^3
2*x^2 - y^5
julia> P = ideal(R, [y-1, x-a])
Ideal generated by
y - 1
x - a
julia> U = complement_of_prime_ideal(P)
Complement
of prime ideal (y - 1, x - a)
in multivariate polynomial ring in 2 variables over K
julia> RQ, p = quo(R, I);
julia> RQL, iota = localization(RQ, U);
julia> phi = compose(p, iota);
julia> f = phi(x)
x
julia> parent(f)
Localization
of quotient
of multivariate polynomial ring in 2 variables x, y
over number field of degree 2 over QQ
by ideal (2*x^2 - y^3, 2*x^2 - y^5)
at complement of prime ideal (y - 1, x - a)
julia> g = f/phi(y)
x/y
julia> r = numerator(f*g)
x^2
julia> u = denominator(f*g)
y
julia> typeof(r) == typeof(u) <: MPolyQuoRingElem
true
is_unit(f::MPolyLocRingElem)
is_unit(f::MPolyQuoLocRingElem)
The general abstract type for ring homomorphisms starting from localized rings is AbsLocalizedRingHom
.
For ring homomorphisms starting from localizations of multivariate polynomial rings, there is the concrete
subtype MPolyLocalizedRingHom
. For ring homomorphisms starting from quotients of multivariate polynomial
rings, there is the concrete subtype MPolyQuoLocalizedRingHom
. We describe the construction of such
homomorphisms. Let
R
be a multivariate polynomial ringU
be a multiplicatively closed subset ofR
,RQ = R/I
be a quotient ofR
with projection mapp
:R
\to
RQ
,Rloc
(RQL
) be the localization ofR
atU
(ofRQ
atp(U)
), andS
be another ring. Then, to give a ring homomorphismPHI
fromRloc
toS
(fromRQL
toS
) is the same as to give a ring homomorphismphi
fromR
toS
which sends elements ofU
to units inS
(and elements ofI
to zero). That is,PHI
is determined by composing it with the localization mapR
\to
Rloc
(by composing it with the composition of the localization mapRQ
\to
RQL
and the projection mapR
\to
RQ
). The constructors below take this into account.
hom(Rloc::MPolyLocRing, S::Ring, F::Map)
Given a ring homomorphism PHI
from Rloc
to S
(from RQL
to S
), domain(PHI)
and codomain(PHI)
refer to Rloc
and S
(RQL
and S
), respectively. The corresponding homomorphism phi
from R
to S
is recovered as follows:
restricted_map(PHI::MPolyLocalizedRingHom)
The general abstract type for ideals in localized rings is AbsLocalizedIdeal
. For ideals in localizations of multivariate polynomial rings,
there is the concrete subtype MPolyLocalizedIdeal
. For ideals in localizations of quotients of multivariate polynomial rings, there is
the concrete subtype MPolyQuoLocalizedIdeal
.
Given a localization Rloc
of a multivariate polynomial ring R
, and given a vector V
of elements of
Rloc
(of R
), the ideal of Rloc
which is generated by (the images) of the entries of V
is created by entering ideal(Rloc, V)
. The construction of ideals in localizations of quotients of
multivariate polynomial rings is similar..
julia> R, (x, y) = polynomial_ring(QQ, ["x", "y"]);
julia> f = x^3+y^4
x^3 + y^4
julia> V = [derivative(f, i) for i=1:2]
2-element Vector{QQMPolyRingElem}:
3*x^2
4*y^3
julia> U = complement_of_point_ideal(R, [0, 0]);
julia> Rloc, _ = localization(R, U);
julia> MI = ideal(Rloc, V)
Ideal generated by
3*x^2
4*y^3
If I
is an ideal of a localized multivariate polynomial ring Rloc
, then
base_ring(I)
refers toRloc
,gens(I)
to the generators ofI
,number_of_generators(I)
/ngens(I)
to the number of these generators, andgen(I, k)
as well asI[k]
to thek
-th such generator.
Similarly, if I
is an ideal of a localized quotient of a multivariate polynomial ring.
If I
, J
are ideals of a localized multivariate polynomial ring Rloc
, then
I^k
refers to thek
-th power ofI
,I+J
,I*J
, andintersect(I, J)
to the sum, product, and intersection ofI
andJ
, andquotient(I, J)
as well asI:J
to the ideal quotient ofI
byJ
.
Similarly, if I
and J
are ideals of a localized quotient of a multivariate polynomial ring.
The usual tests f in J
, issubset(I, J)
, and I == J
are available.
If Rloc
is the localization of a multivariate polynomial ring R
at a multiplicative subset U
of R
,
then the ideal theory of Rloc
is a simplified version of the ideal theory of R
(see, for instance, Eis95).
In particular, each ideal I
of Rloc
is the extension
is independent of the choice of R
which extends to I
. It is, thus,
the contraction of I
to R
, that is, the preimage of I
under the localization map.
We call this ideal the saturation of I
over R
. In OSCAR, it is obtained by entering
saturated_ideal(I)
.
If RQL
is the localization of a quotient RQ
of a multivariate polynomial ring R
, and
I
is an ideal of RQL
, then the return value of saturated_ideal(I)
is the preimage of
the saturation of I
over RQ
under the projection map R \to RQ
(and not
the saturation of I
over RQ
itself).
saturated_ideal(I::MPolyLocalizedIdeal)