Skip to content

Commit

Permalink
Rename new_ray to exceptional_ray (#4433)
Browse files Browse the repository at this point in the history
[ToricVarieties] Rename variable new_ray to exceptional_ray
  • Loading branch information
paemurru authored Jan 9, 2025
1 parent 8ab4265 commit 3505630
Show file tree
Hide file tree
Showing 9 changed files with 88 additions and 79 deletions.
12 changes: 6 additions & 6 deletions docs/src/AlgebraicGeometry/ToricVarieties/BlowupMorphisms.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@ For this reason, the methods below should be considered experimental.

We focus mainly on toric blowups given by a star subdivision of a
polyhedral fan along a primitive vector, see 11.1 Star Subdivisions in
[CLS11](@cite). Below, we refer to this new primitive vector as
`new_ray`. The main constructor is the following
- `blow_up(Y::NormalToricVariety, new_ray::AbstractVector{<:IntegerUnion}; coordinate_name::String)`
[CLS11](@cite). Below, we refer to this primitive vector as
`exceptional_ray`. The main constructor is the following
- `blow_up(Y::NormalToricVariety, exceptional_ray::AbstractVector{<:IntegerUnion}; coordinate_name::String)`
This will also construct the underlying toric morphism. We can specify
the name for the coordinate in the Cox ring that is assigned to
`new_ray` using the optional argument `coordinate_name`.
`exceptional_ray` using the optional argument `coordinate_name`.

More generally, we can construct a blowup along a closed subscheme given
by an ideal in the Cox ring or by an ideal sheaf of the corresponding
Expand All @@ -47,7 +47,7 @@ Star Subdivisions in [CLS11](@cite). The resulting star subdivision
leads to a polyhedral fan, or put differently, the blowup is always
toric:
```@docs
blow_up(v::NormalToricVariety, new_ray::AbstractVector{<:IntegerUnion}; coordinate_name::String = "e")
blow_up(v::NormalToricVariety, exceptional_ray::AbstractVector{<:IntegerUnion}; coordinate_name::String = "e")
```
Most generally, we encode the closed subscheme along which we blow up by
a homogeneous ideal in the Cox ring. Such blowups are often non-toric,
Expand All @@ -67,7 +67,7 @@ blow_up(m::NormalToricVariety, I::ToricIdealSheafFromCoxRingIdeal; coordinate_na

```@docs
underlying_morphism(bl::ToricBlowupMorphism)
index_of_new_ray(bl::ToricBlowupMorphism)
index_of_exceptional_ray(bl::ToricBlowupMorphism)
center_data(bl::ToricBlowupMorphism)
center_unnormalized(bl::ToricBlowupMorphism)
exceptional_prime_divisor(bl::ToricBlowupMorphism)
Expand Down
2 changes: 1 addition & 1 deletion docs/src/PolyhedralGeometry/fans.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,6 @@ rays(PF::PolyhedralFan)
rays_modulo_lineality(PF::PolyhedralFan)
primitive_collections(PF::PolyhedralFan)
star_subdivision(PF::PolyhedralFan, n::Int)
star_subdivision(PF::PolyhedralFan, new_ray::AbstractVector{<:IntegerUnion})
star_subdivision(PF::PolyhedralFan, exceptional_ray::AbstractVector{<:IntegerUnion})
*(PF1::PolyhedralFan{QQFieldElem}, PF2::PolyhedralFan{QQFieldElem})
```
4 changes: 2 additions & 2 deletions experimental/FTheoryTools/src/auxiliary.jl
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ function _strict_transform(bd::ToricBlowupMorphism, II::ToricIdealSheafFromCoxRi
return strict_transform(bd, II)
end
S = cox_ring(domain(bd))
_e = gen(S, index_of_new_ray(bd))
_e = gen(S, index_of_exceptional_ray(bd))
images = MPolyRingElem[]
g_list = gens(S)
g_center = [string(k) for k in symbols(ideal_in_cox_ring(center_unnormalized(bd)))]
Expand All @@ -489,7 +489,7 @@ end

function _strict_transform(bd::ToricBlowupMorphism, tate_poly::MPolyRingElem)
S = cox_ring(domain(bd))
_e = gen(S, index_of_new_ray(bd))
_e = gen(S, index_of_exceptional_ray(bd))
g_list = string.(symbols(S))
g_center = [string(k) for k in gens(ideal_in_cox_ring(center_unnormalized(bd)))]
position_of_center_variables = [findfirst(==(g), g_list) for g in g_center]
Expand Down
4 changes: 2 additions & 2 deletions experimental/Schemes/src/Schemes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,12 @@ export germ_at_point
export has_du_val_singularities
export hypersurface_germ
export ideal_sheaf
export index_of_new_ray
export index_of_exceptional_ray
export is_isolated_singularity
export intersection_matrix
export milnor_algebra
export milnor_number
export minimal_supercone_coordinates_of_new_ray
export minimal_supercone_coordinates_of_exceptional_ray
export point
export rational_point_coordinates
export standard_covering
Expand Down
12 changes: 6 additions & 6 deletions experimental/Schemes/src/ToricBlowups/attributes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ underlying_morphism(bl::ToricBlowupMorphism) = bl.toric_morphism


@doc raw"""
index_of_new_ray(bl::ToricBlowupMorphism)
index_of_exceptional_ray(bl::ToricBlowupMorphism)
Return the index of the new ray used in the construction of the toric
Return the index of the exceptional ray used in the construction of the toric
blowup.
# Examples
Expand All @@ -39,11 +39,11 @@ Normal toric variety
julia> f = blow_up(P3, [0, 1, 1])
Toric blowup morphism
julia> index_of_new_ray(f)
julia> index_of_exceptional_ray(f)
5
```
"""
index_of_new_ray(bl::ToricBlowupMorphism) = bl.index_of_new_ray
index_of_exceptional_ray(bl::ToricBlowupMorphism) = bl.index_of_exceptional_ray


@doc raw"""
Expand Down Expand Up @@ -102,7 +102,7 @@ function center_unnormalized(bl::ToricBlowupMorphism)
X = domain(bl)
S = cox_ring(X)
x = gens(S)
j = index_of_new_ray(bl)
j = index_of_exceptional_ray(bl)
I = ideal(S, x[j])
II = ideal_sheaf(X, I)
JJ = pushforward(bl, II)::IdealSheaf
Expand Down Expand Up @@ -141,7 +141,7 @@ function exceptional_prime_divisor(bl::ToricBlowupMorphism)
X = domain(bl)
S = cox_ring(X)
x = gens(S)
j = index_of_new_ray(bl)
j = index_of_exceptional_ray(bl)
help_list = [i == j ? 1 : 0 for i in 1:ngens(S)]
td = toric_divisor(X, help_list)
@assert is_prime(td) "exceptional prime divisor must be prime"
Expand Down
32 changes: 16 additions & 16 deletions experimental/Schemes/src/ToricBlowups/constructors.jl
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,10 @@ end


@doc raw"""
blow_up(v::NormalToricVariety, new_ray::AbstractVector{<:IntegerUnion}; coordinate_name::String)
blow_up(v::NormalToricVariety, exceptional_ray::AbstractVector{<:IntegerUnion}; coordinate_name::String)
Blow up the toric variety by subdividing the fan of the variety with the
provided new ray. This function returns the corresponding morphism.
provided exceptional ray. This function returns the corresponding morphism.
Note that this ray must be a primitive element in the lattice Z^d, with
d the dimension of the fan. In particular, it is currently impossible to
Expand Down Expand Up @@ -157,24 +157,24 @@ julia> typeof(center_unnormalized(f))
IdealSheaf{NormalToricVariety, AbsAffineScheme, Ideal, Map}
```
"""
function blow_up(v::NormalToricVarietyType, new_ray::AbstractVector{<:IntegerUnion}; coordinate_name::Union{String, Nothing} = nothing)
function blow_up(v::NormalToricVarietyType, exceptional_ray::AbstractVector{<:IntegerUnion}; coordinate_name::Union{String, Nothing} = nothing)
coordinate_name = _find_blowup_coordinate_name(v, coordinate_name)
new_variety = normal_toric_variety(star_subdivision(v, new_ray))
blown_up_variety = normal_toric_variety(star_subdivision(v, exceptional_ray))
if is_smooth(v) == false
return ToricBlowupMorphism(v, new_variety, coordinate_name, new_ray, new_ray)
return ToricBlowupMorphism(v, blown_up_variety, coordinate_name, exceptional_ray, exceptional_ray)
end
inx = _get_maximal_cones_containing_vector(polyhedral_fan(v), new_ray)
inx = _get_maximal_cones_containing_vector(polyhedral_fan(v), exceptional_ray)
old_rays = matrix(ZZ, rays(v))
cone_generators = matrix(ZZ, [old_rays[i,:] for i in 1:nrows(old_rays) if ray_indices(maximal_cones(v))[inx[1], i]])
powers = solve_non_negative(ZZMatrix, transpose(cone_generators), transpose(matrix(ZZ, [new_ray])))
powers = solve_non_negative(ZZMatrix, transpose(cone_generators), transpose(matrix(ZZ, [exceptional_ray])))
if nrows(powers) != 1
return ToricBlowupMorphism(v, new_variety, coordinate_name, new_ray, new_ray)
return ToricBlowupMorphism(v, blown_up_variety, coordinate_name, exceptional_ray, exceptional_ray)
end
gens_S = gens(cox_ring(v))
variables = [gens_S[i] for i in 1:nrows(old_rays) if ray_indices(maximal_cones(v))[inx[1], i]]
list_of_gens = [variables[i]^powers[i] for i in 1:length(powers) if powers[i] != 0]
center_unnormalized = ideal_sheaf(v, ideal([variables[i]^powers[i] for i in 1:length(powers) if powers[i] != 0]))
return ToricBlowupMorphism(v, new_variety, coordinate_name, new_ray, new_ray, center_unnormalized)
return ToricBlowupMorphism(v, blown_up_variety, coordinate_name, exceptional_ray, exceptional_ray, center_unnormalized)
end

@doc raw"""
Expand Down Expand Up @@ -212,10 +212,10 @@ function blow_up(v::NormalToricVarietyType, n::Int; coordinate_name::Union{Strin
coordinate_name = _find_blowup_coordinate_name(v, coordinate_name)
gens_S = gens(cox_ring(v))
center_unnormalized = ideal_sheaf(v, ideal([gens_S[i] for i in 1:number_of_rays(v) if cones(v)[n,i]]))
new_variety = normal_toric_variety(star_subdivision(v, n))
blown_up_variety = normal_toric_variety(star_subdivision(v, n))
rays_of_variety = matrix(ZZ, rays(v))
new_ray = vec(sum([rays_of_variety[i, :] for i in 1:number_of_rays(v) if cones(v)[n, i]]))
return ToricBlowupMorphism(v, new_variety, coordinate_name, new_ray, new_ray, center_unnormalized)
exceptional_ray = vec(sum([rays_of_variety[i, :] for i in 1:number_of_rays(v) if cones(v)[n, i]]))
return ToricBlowupMorphism(v, blown_up_variety, coordinate_name, exceptional_ray, exceptional_ray, center_unnormalized)
end


Expand Down Expand Up @@ -274,11 +274,11 @@ function blow_up(v::NormalToricVarietyType, I::MPolyIdeal; coordinate_name::Unio
indices = [findfirst(==(x), gens(cox)) for x in gens(I)]
if all(!isnothing, indices)
rs = matrix(ZZ, rays(v))
new_ray = vec(sum(rs[index, :] for index in indices))
new_ray = new_ray ./ gcd(new_ray)
new_variety = normal_toric_variety(star_subdivision(v, new_ray))
exceptional_ray = vec(sum(rs[index, :] for index in indices))
exceptional_ray = exceptional_ray ./ gcd(exceptional_ray)
blown_up_variety = normal_toric_variety(star_subdivision(v, exceptional_ray))
center_unnormalized = ideal_sheaf(v, I)
return ToricBlowupMorphism(v, new_variety, coordinate_name, new_ray, I, center_unnormalized)
return ToricBlowupMorphism(v, blown_up_variety, coordinate_name, exceptional_ray, I, center_unnormalized)
else
return _generic_blow_up(v, I)
end
Expand Down
22 changes: 11 additions & 11 deletions experimental/Schemes/src/ToricBlowups/methods.jl
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ function strict_transform(f::ToricBlowupMorphism, I::MPolyIdeal)
X = codomain(f)
@req !has_torusfactor(X) "Only implemented when there are no torus factors"
S = cox_ring(domain(f))
new_var = S[index_of_new_ray(f)]
exceptional_var = S[index_of_exceptional_ray(f)]
J = cox_ring_module_homomorphism(f, I)
return saturation(J, ideal(S, new_var))
return saturation(J, ideal(S, exceptional_var))
end

@doc raw"""
Expand Down Expand Up @@ -139,9 +139,9 @@ function strict_transform_with_index(f::ToricBlowupMorphism, I::MPolyIdeal)
@req !has_torusfactor(X) "Only implemented when there are no torus factors"
@req is_smooth(X) "Only implemented when the fan is smooth"
S = cox_ring(domain(f))
new_var = S[index_of_new_ray(f)]
exceptional_var = S[index_of_exceptional_ray(f)]
J = total_transform(f, I)
return saturation_with_index(J, ideal(new_var))
return saturation_with_index(J, ideal(exceptional_var))
end

@doc raw"""
Expand All @@ -158,7 +158,7 @@ corresponding to the ray $\rho$ and where $d = 0$ if $\rho$ belongs to
the fan of $X$ and $d = \lceil a \cdot p \rceil$ otherwise, where $a$ is
the exponent vector of $g$, $p$ is the minimal supercone coordinate
vector of $v$ in the fan of $X$, as returned by
`minimal_supercone_coordinates_of_new_ray(X, v)`, and where $(\cdot)$
`minimal_supercone_coordinates_of_exceptional_ray(X, v)`, and where $(\cdot)$
denotes the scalar product.
The $\mathbb{C}$-module homomorphism $\Phi$ sends homogeneous ideals to
Expand Down Expand Up @@ -195,8 +195,8 @@ function cox_ring_module_homomorphism(f::ToricBlowupMorphism, g::MPolyDecRingEle
S_vars = elem_type(S)[S[i] for i in 1:nvars(S)]

nvars(R) == nvars(S) && return hom(R, S, S_vars)(g)
ps = minimal_supercone_coordinates_of_new_ray(f)
exceptional_var = S[index_of_new_ray(f)]
ps = minimal_supercone_coordinates_of_exceptional_ray(f)
exceptional_var = S[index_of_exceptional_ray(f)]
make_S_term(c, exps) = c*prod(map(^, S_vars, exps))
coeff_exps = collect(zip(coefficients(g), exponents(g)))
h = S(0)
Expand All @@ -213,7 +213,7 @@ function cox_ring_module_homomorphism(f::ToricBlowupMorphism, I::MPolyIdeal)
end

@doc raw"""
minimal_supercone_coordinates_of_new_ray(f::ToricBlowupMorphism) -> Vector{QQFieldElem}
minimal_supercone_coordinates_of_exceptional_ray(f::ToricBlowupMorphism) -> Vector{QQFieldElem}
Let $f\colon Y \to X$ be the toric blowup corresponding to a star
subdivision along a ray with minimal generator $v$.
Expand All @@ -228,15 +228,15 @@ Normal toric variety
julia> f = blow_up(X, [2, 3])
Toric blowup morphism
julia> minimal_supercone_coordinates_of_new_ray(f)
julia> minimal_supercone_coordinates_of_exceptional_ray(f)
2-element Vector{QQFieldElem}:
2
3
```
"""
@attr Vector{QQFieldElem} function minimal_supercone_coordinates_of_new_ray(f::ToricBlowupMorphism)
@attr Vector{QQFieldElem} function minimal_supercone_coordinates_of_exceptional_ray(f::ToricBlowupMorphism)
PF = polyhedral_fan(codomain(f))
v = rays(domain(f))[index_of_new_ray(f), :][1]
v = rays(domain(f))[index_of_exceptional_ray(f), :][1]
v_ZZ = primitive_generator(v)
return minimal_supercone_coordinates(PF, v_ZZ)
end
Expand Down
27 changes: 15 additions & 12 deletions experimental/Schemes/src/ToricBlowups/types.jl
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,24 @@
} <: AbsSimpleBlowupMorphism{DomainType, CodomainType, ToricBlowupMorphism}

toric_morphism::ToricMorphism
index_of_new_ray::Integer
index_of_exceptional_ray::Integer
center_data::CenterDataType
center_unnormalized::CenterUnnormalizedType
exceptional_prime_divisor::ToricDivisor

function _toric_blowup_morphism(v::NormalToricVarietyType, new_variety::NormalToricVarietyType, coordinate_name::String, new_ray::AbstractVector{<:IntegerUnion}, center_data::CenterDataType) where CenterDataType <: Union{
function _toric_blowup_morphism(v::NormalToricVarietyType, new_variety::NormalToricVarietyType, coordinate_name::String, exceptional_ray::AbstractVector{<:IntegerUnion}, center_data::CenterDataType) where CenterDataType <: Union{
AbstractVector{<:IntegerUnion},
MPolyIdeal,
ToricIdealSheafFromCoxRingIdeal,
IdealSheaf,
}
# Compute position of new ray
# Compute position of exceptional ray
new_rays = matrix(ZZ, rays(new_variety))
position_new_ray = findfirst(i->new_ray==new_rays[i,:], 1:n_rays(new_variety))
@req position_new_ray !== nothing "Could not identify position of new ray"
position_exceptional_ray = findfirst(
i->exceptional_ray==new_rays[i,:],
1:n_rays(new_variety)
)
@req position_exceptional_ray !== nothing "Could not identify position of exceptional ray"

# Set variable names of the new variety
old_vars = string.(symbols(cox_ring(v)))
Expand All @@ -54,22 +57,22 @@

# Construct the toric morphism and construct the object
bl_toric = toric_morphism(new_variety, identity_matrix(ZZ, ambient_dim(polyhedral_fan(v))), v; check=false)
return bl_toric, position_new_ray, center_data
return bl_toric, position_exceptional_ray, center_data
end

function ToricBlowupMorphism(v::NormalToricVarietyType, new_variety::NormalToricVarietyType, coordinate_name::String, new_ray::AbstractVector{<:IntegerUnion}, center_data::CenterDataType, center_unnormalized::ToricIdealSheafFromCoxRingIdeal) where CenterDataType <: Union{
function ToricBlowupMorphism(v::NormalToricVarietyType, new_variety::NormalToricVarietyType, coordinate_name::String, exceptional_ray::AbstractVector{<:IntegerUnion}, center_data::CenterDataType, center_unnormalized::ToricIdealSheafFromCoxRingIdeal) where CenterDataType <: Union{
AbstractVector{<:IntegerUnion},
MPolyIdeal,
ToricIdealSheafFromCoxRingIdeal,
IdealSheaf,
}
bl_toric, position_new_ray, center_data = _toric_blowup_morphism(v, new_variety, coordinate_name, new_ray, center_data)
bl_toric, position_exceptional_ray, center_data = _toric_blowup_morphism(v, new_variety, coordinate_name, exceptional_ray, center_data)
bl = new{
typeof(domain(bl_toric)),
typeof(codomain(bl_toric)),
typeof(center_data),
typeof(center_unnormalized),
}(bl_toric, position_new_ray, center_data, center_unnormalized)
}(bl_toric, position_exceptional_ray, center_data, center_unnormalized)
if has_attribute(v, :has_torusfactor)
set_attribute!(bl, :has_torusfactor, has_torusfactor(v))
end
Expand All @@ -79,19 +82,19 @@
return bl
end

function ToricBlowupMorphism(v::NormalToricVarietyType, new_variety::NormalToricVarietyType, coordinate_name::String, new_ray::AbstractVector{<:IntegerUnion}, center_data::CenterDataType) where CenterDataType <: Union{
function ToricBlowupMorphism(v::NormalToricVarietyType, new_variety::NormalToricVarietyType, coordinate_name::String, exceptional_ray::AbstractVector{<:IntegerUnion}, center_data::CenterDataType) where CenterDataType <: Union{
AbstractVector{<:IntegerUnion},
MPolyIdeal,
ToricIdealSheafFromCoxRingIdeal,
IdealSheaf,
}
bl_toric, position_new_ray, center_data = _toric_blowup_morphism(v, new_variety, coordinate_name, new_ray, center_data)
bl_toric, position_exceptional_ray, center_data = _toric_blowup_morphism(v, new_variety, coordinate_name, exceptional_ray, center_data)
bl = new{
typeof(domain(bl_toric)),
typeof(codomain(bl_toric)),
typeof(center_data),
IdealSheaf{typeof(v), AbsAffineScheme, Ideal, Map},
}(bl_toric, position_new_ray, center_data)
}(bl_toric, position_exceptional_ray, center_data)
if has_attribute(v, :has_torusfactor)
set_attribute!(bl, :has_torusfactor, has_torusfactor(v))
end
Expand Down
Loading

0 comments on commit 3505630

Please sign in to comment.