Skip to content

Commit

Permalink
Merge branch 'master' into intersection_matrix
Browse files Browse the repository at this point in the history
  • Loading branch information
thofma authored Aug 29, 2024
2 parents 8d005fc + ab3d42c commit 3a18e23
Show file tree
Hide file tree
Showing 16 changed files with 376 additions and 89 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ JSON = "^0.20, ^0.21"
JSON3 = "1.13.2"
LazyArtifacts = "1.6"
Markdown = "1.6"
Nemo = "0.46.0"
Nemo = "0.46.2"
Pkg = "1.6"
Polymake = "0.11.20"
Random = "1.6"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,6 @@ integrate(c::CohomologyClass; check::Bool = true)
cohomology_ring(v::NormalToricVarietyType; check::Bool = true)
volume_form(v::NormalToricVariety)
intersection_form(v::NormalToricVariety)
chern_class(v::NormalToricVariety, k::Int; check::Bool = true)
chern_classes(v::NormalToricVariety; check::Bool = true)
```
7 changes: 5 additions & 2 deletions experimental/FTheoryTools/docs/src/generalities.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,16 +59,19 @@ classes_of_model_sections(m::AbstractFTheoryModel)
defining_classes(m::AbstractFTheoryModel)
gauge_algebra(m::AbstractFTheoryModel)
global_gauge_quotients(m::AbstractFTheoryModel)
chern_class_c1(m::AbstractFTheoryModel; check::Bool = true)
chern_class_c2(m::AbstractFTheoryModel; check::Bool = true)
chern_class(m::AbstractFTheoryModel, k::Int; check::Bool = true)
chern_classes(m::AbstractFTheoryModel; check::Bool = true)
euler_characteristic(m::AbstractFTheoryModel; check::Bool = true)
```


## Properties of all (or most) F-theory models

```@docs
is_base_space_fully_specified(m::AbstractFTheoryModel)
is_calabi_yau(m::AbstractFTheoryModel; check::Bool = true)
is_partially_resolved(m::AbstractFTheoryModel)
verify_euler_characteristic_from_hodge_numbers(m::AbstractFTheoryModel; check::Bool = true)
```


Expand Down
162 changes: 90 additions & 72 deletions experimental/FTheoryTools/src/AbstractFTheoryModels/attributes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1100,128 +1100,146 @@ end


@doc raw"""
chern_class_c1(m::AbstractFTheoryModel)
chern_class(m::AbstractFTheoryModel, k::Int; check::Bool = true)
If the elliptically fibered n-fold $Y_n$ underlying the F-theory model in question is given
as a hypersurface in a toric ambient space, we can compute a cohomology class $h$ on the
toric ambient space $X_\Sigma$, such that its restriction to $Y_n$ is the first Chern class
$c_1$ of the tangent bundle of $Y_n$. If those assumptions are satisfied, this method returns
this very cohomology class $h$, otherwise it raises and error.
toric ambient space $X_\Sigma$, such that its restriction to $Y_n$ is the k-th Chern class
$c_k$ of the tangent bundle of $Y_n$. If those assumptions are satisfied, this method returns
this very cohomology class $h$, otherwise it raises an error.
Note that $Y_n$ is a Calabi-Yau variety precisely if $c_1$ is trivial. Thus, the restriction
of $h$ to the hypersurface $Y_n$ must be trivial. Upon closer inspection, in the given toric
setting, this is equivalent to $h$ being trivial.
The computation of the cohomology ring verifies if the toric variety is simplicial and
complete. The check for it to be complete can be very time consuming. This can be switched
off by setting the optional argument `check` to the value `false`, as in the example below.
The theory guarantees that the implemented algorithm works for toric ambient spaces which are
smooth and complete. The check for completeness can be very time consuming. This check can
be switched off by setting the optional argument `check` to the value `false`, as demonstrated below.
```jldoctest; setup = :(Oscar.LazyArtifacts.ensure_artifact_installed("QSMDB", Oscar.LazyArtifacts.find_artifacts_toml(Oscar.oscardir)))
julia> qsm_model = literature_model(arxiv_id = "1903.00009", model_parameters = Dict("k" => 4))
Hypersurface model over a concrete base
julia> h = chern_class_c1(qsm_model; check = false)
Cohomology class on a normal toric variety given by 0
julia> h = chern_class(qsm_model, 4; check = false);
julia> is_trivial(h)
true
false
```
"""
function chern_class_c1(m::AbstractFTheoryModel; check::Bool = true)
@req (m isa WeierstrassModel || m isa GlobalTateModel || m isa HypersurfaceModel) "First Chern class of F-theory model supported for Weierstrass, global Tate and hypersurface models only"
@req base_space(m) isa NormalToricVariety "First Chern class of F-theory model currently supported only for toric base"
@req ambient_space(m) isa NormalToricVariety "First Chern class of F-theory model currently supported only for toric ambient space"
function chern_class(m::AbstractFTheoryModel, k::Int; check::Bool = true)
@req (m isa WeierstrassModel || m isa GlobalTateModel || m isa HypersurfaceModel) "Chern class of F-theory model supported for Weierstrass, global Tate and hypersurface models only"
@req base_space(m) isa NormalToricVariety "Chern class of F-theory model currently supported only for toric base"
@req ambient_space(m) isa NormalToricVariety "Chern class of F-theory model currently supported only for toric ambient space"

# Check if the answer is known
if has_attribute(m, :chern_class_c1)
return get_attribute(m, :chern_class_c1)
end
# Consistency checks
@req k >= 0 "Chern class index must be non-negative"
@req k <= dim(ambient_space(m)) - 1 "Chern class index must not exceed dimension of the space"

# Trigger potential short-cut computation of cohomology ring
cohomology_ring(ambient_space(m); check)

# Compute the cohomology class corresponding to the hypersurface equation
if m isa WeierstrassModel
cl = toric_divisor_class(ambient_space(m), degree(weierstrass_polynomial(m)))
# Check if we can compute the Chern classes for the toric ambient space
if check
@req is_smooth(ambient_space(m)) && is_complete(ambient_space(m)) "The Chern classes of the tangent bundle of the toric ambient space are only supported if the toric ambient space is smooth and complete"
end
if m isa GlobalTateModel
cl = toric_divisor_class(ambient_space(m), degree(tate_polynomial(m)))

# If thus far, no non-trivial Chern classes have been computed for this toric variety, add an "empty" vector
if !has_attribute(m, :chern_classes)
cs = Vector{Union{Nothing,CohomologyClass}}(nothing, dim(ambient_space(m)))
cs[1] = cohomology_class(ambient_space(m), one(cohomology_ring(ambient_space(m), check = check)))
cy = cohomology_class(toric_divisor_class(ambient_space(m), degree(hypersurface_equation(m))))
cs[2] = chern_class(ambient_space(m), 1, check = check) - cy
set_attribute!(m, :chern_classes, cs)
end
if m isa HypersurfaceModel
cl = toric_divisor_class(ambient_space(m), degree(hypersurface_equation(m)))

# Check if the Chern class in question is known
cs = get_attribute(m, :chern_classes)::Vector{Union{Nothing,CohomologyClass}}
if cs[k+1] !== nothing
return cs[k+1]::CohomologyClass
end
cy = cohomology_class(cl)

# Compute and set h
c1_t_ambient = cohomology_class(anticanonical_divisor(ambient_space(m)))
set_attribute!(m, :chern_class_c1, c1_t_ambient - cy)
return get_attribute(m, :chern_class_c1)
# Chern class is not known, so compute and return it...
cy = cohomology_class(toric_divisor_class(ambient_space(m), degree(hypersurface_equation(m))))
cs[k+1] = chern_class(ambient_space(m), k, check = check) - cy * chern_class(m, k-1; check = check)
set_attribute!(m, :chern_classes, cs)
return cs[k+1]
end


@doc raw"""
chern_class_c2(m::AbstractFTheoryModel)
chern_classes(m::AbstractFTheoryModel; check::Bool = true)
If the elliptically fibered n-fold $Y_n$ underlying the F-theory model in question is given
as a hypersurface in a toric ambient space, we can compute a cohomology class $h$ on the
toric ambient space $X_\Sigma$, such that its restriction to $Y_n$ is the 2nd Chern class
$c_2$ of the tangent bundle of $Y_n$. If those assumptions are satisfied, this method returns
this very cohomology class $h$, otherwise it raises and error.
toric ambient space $X_\Sigma$, such that its restriction to $Y_n$ is the k-th Chern class
$c_k$ of the tangent bundle of $Y_n$. If those assumptions are satisfied, this method returns
a vector with the cohomology classes corresponding to all non-trivial Chern classes $c_k$ of
$Y_n$. Otherwise, this methods raises an error.
As of right now, this method is computationally quite expensive for involved toric varieties,
such as in the example below. Therefore, think carefully if you truly want to compute this quantity.
As of right now, this method is computationally expensive for involved toric ambient spaces,
such as in the example below.
The computation of the cohomology ring verifies if the toric variety is simplicial and
complete. The check for it to be complete can be very time consuming. This can be switched
off by setting the optional argument `check` to the value `false`, as in the example below.
The theory guarantees that the implemented algorithm works for toric ambient spaces which are
simplicial and complete. The check for completeness can be very time consuming. This check can
be switched off by setting the optional argument `check` to the value `false`, as demonstrated below.
```jldoctest; setup = :(Oscar.LazyArtifacts.ensure_artifact_installed("QSMDB", Oscar.LazyArtifacts.find_artifacts_toml(Oscar.oscardir)))
julia> qsm_model = literature_model(arxiv_id = "1903.00009", model_parameters = Dict("k" => 4))
Hypersurface model over a concrete base
julia> h = chern_class_c2(qsm_model; check = false);
julia> h = chern_classes(qsm_model; check = false);
julia> is_trivial(h)
julia> is_one(polynomial(h[1]))
true
julia> is_trivial(h[2])
true
julia> is_trivial(h[3])
false
```
"""
function chern_class_c2(m::AbstractFTheoryModel; check::Bool = true)
@req (m isa WeierstrassModel || m isa GlobalTateModel || m isa HypersurfaceModel) "Second Chern class of F-theory model supported for Weierstrass, global Tate and hypersurface models only"
@req base_space(m) isa NormalToricVariety "Second Chern class of F-theory model currently supported only for toric base"
@req ambient_space(m) isa NormalToricVariety "Second Chern class of F-theory model currently supported only for toric ambient space"
function chern_classes(m::AbstractFTheoryModel; check::Bool = true)
@req (m isa WeierstrassModel || m isa GlobalTateModel || m isa HypersurfaceModel) "Chern class of F-theory model supported for Weierstrass, global Tate and hypersurface models only"
@req base_space(m) isa NormalToricVariety "Chern class of F-theory model currently supported only for toric base"
@req ambient_space(m) isa NormalToricVariety "Chern class of F-theory model currently supported only for toric ambient space"
return [chern_class(m, k, check = check) for k in 0:dim(ambient_space(m))-1]
end


@doc raw"""
euler_characteristic(m::AbstractFTheoryModel; check::Bool = true)
If the elliptically fibered n-fold $Y_n$ underlying the F-theory model in question is given
as a hypersurface in a toric ambient space, we can compute the Euler characteristic. If this
assumptions is satisfied, this method returns the Euler characteristic, otherwise it raises an
error.
```jldoctest; setup = :(Oscar.LazyArtifacts.ensure_artifact_installed("QSMDB", Oscar.LazyArtifacts.find_artifacts_toml(Oscar.oscardir)))
julia> qsm_model = literature_model(arxiv_id = "1903.00009", model_parameters = Dict("k" => 4))
Hypersurface model over a concrete base
julia> h = euler_characteristic(qsm_model; check = false)
378
```
"""
function euler_characteristic(m::AbstractFTheoryModel; check::Bool = true)
@req (m isa WeierstrassModel || m isa GlobalTateModel || m isa HypersurfaceModel) "Euler characteristic of F-theory model supported for Weierstrass, global Tate and hypersurface models only"
@req base_space(m) isa NormalToricVariety "Euler characteristic of F-theory model currently supported only for toric base"
@req ambient_space(m) isa NormalToricVariety "Euler characteristic of F-theory model currently supported only for toric ambient space"

# Check if the answer is known
if has_attribute(m, :chern_class_c2)
return get_attribute(m, :chern_class_c2)
if has_attribute(m, :euler_characteristic)
return get_attribute(m, :euler_characteristic)::CohomologyClass
end

# Trigger potential short-cut computation of cohomology ring
cohomology_ring(ambient_space(m); check)

# Compute the cohomology class corresponding to the hypersurface equation
if m isa WeierstrassModel
cl = toric_divisor_class(ambient_space(m), degree(weierstrass_polynomial(m)))
end
if m isa GlobalTateModel
cl = toric_divisor_class(ambient_space(m), degree(tate_polynomial(m)))
end
if m isa HypersurfaceModel
cl = toric_divisor_class(ambient_space(m), degree(hypersurface_equation(m)))
end
cy = cohomology_class(cl)
cy = cohomology_class(toric_divisor_class(ambient_space(m), degree(hypersurface_equation(m))))

# Compute sum of products of cohomolgy classes of torus invariant prime divisors
c_ds = [polynomial(cohomology_class(d)) for d in torusinvariant_prime_divisors(ambient_space(m))]
c2_t_ambient = sum(c_ds[i]*c_ds[j] for i in 1:length(c_ds)-1 for j in i+1:length(c_ds))
c2_t_ambient = cohomology_class(ambient_space(m), c2_t_ambient)

# Compute and set h
h = c2_t_ambient - cy * chern_class_c1(m; check = check)
set_attribute!(m, :chern_class_c2, h)
# Compute the Euler characteristic
h = integrate(chern_class(m, 4; check) * cy; check)
set_attribute!(m, :euler_characteristic, h)
return h
end



##########################################
### (4) Attributes specially for the QSMs
##########################################
Expand Down
82 changes: 82 additions & 0 deletions experimental/FTheoryTools/src/AbstractFTheoryModels/properties.jl
Original file line number Diff line number Diff line change
Expand Up @@ -98,3 +98,85 @@ has_weighted_resolution_zero_sections(m::AbstractFTheoryModel) = has_attribute(m
has_zero_section(m::AbstractFTheoryModel) = has_attribute(m, :zero_section)
has_gauge_algebra(m::AbstractFTheoryModel) = has_attribute(m, :gauge_algebra)
has_global_gauge_quotients(m::AbstractFTheoryModel) = has_attribute(m, :global_gauge_quotients)



##########################################
### (4) Consistency checks
##########################################

@doc raw"""
verify_euler_characteristic_from_hodge_numbers(m::AbstractFTheoryModel; check::Bool = true)
Verify if the Euler characteristic, as computed from integrating the 4-th Chern class,
agrees with the results obtained from using the alternating sum of the Hodge numbers.
If so, this method returns `true`. However, should information be missing, (e.g. some
Hodge numbers), or the dimension of the F-theory model differ form 4, then this method
raises an error.
```jldoctest; setup = :(Oscar.LazyArtifacts.ensure_artifact_installed("QSMDB", Oscar.LazyArtifacts.find_artifacts_toml(Oscar.oscardir)))
julia> qsm_model = literature_model(arxiv_id = "1903.00009", model_parameters = Dict("k" => 4))
Hypersurface model over a concrete base
julia> verify_euler_characteristic_from_hodge_numbers(qsm_model, check = false)
true
```
"""
function verify_euler_characteristic_from_hodge_numbers(m::AbstractFTheoryModel; check::Bool = true)
@req (m isa WeierstrassModel || m isa GlobalTateModel || m isa HypersurfaceModel) "Verification of Euler characteristic of F-theory model supported for Weierstrass, global Tate and hypersurface models only"
@req base_space(m) isa NormalToricVariety "Verification of Euler characteristic of F-theory model currently supported only for toric base"
@req ambient_space(m) isa NormalToricVariety "Verification of Euler characteristic of F-theory model currently supported only for toric ambient space"
@req dim(base_space(m)) == 3 "Verification of Euler characteristic of F-theory model currently supported only for toric base spaces of dimension 3"
@req dim(ambient_space(m)) == 5 "Verification of Euler characteristic of F-theory model currently supported only for toric ambient spaces of dimension 5"
@req has_attribute(m, :h11) "Verification of Euler characteristic of F-theory model requires h11"
@req has_attribute(m, :h12) "Verification of Euler characteristic of F-theory model requires h12"
@req has_attribute(m, :h13) "Verification of Euler characteristic of F-theory model requires h13"
@req has_attribute(m, :h22) "Verification of Euler characteristic of F-theory model requires h22"

# Check if the answer is known
if has_attribute(m, :verify_euler_characteristic_from_hodge_numbers)
return get_attribute(m, :verify_euler_characteristic_from_hodge_numbers)::Bool
end

# Computer Euler characteristic from integrating c4
ec = euler_characteristic(m, check = check)

# Compute Euler characteristic from adding Hodge numbers
ec2 = 4 + 2 * hodge_h11(m) - 4 * hodge_h12(m) + 2 * hodge_h13(m) + hodge_h22(m)

# Compute result of verification
h = (ec == ec2)
set_attribute!(m, :verify_euler_characteristic_from_hodge_numbers, h)
return h
end


@doc raw"""
is_calabi_yau(m::AbstractFTheoryModel; check::Bool = true)
Verify if the first Chern class of the tangent bundle of the F-theory geometry
$Y_n$ vanishes. If so, this confirms that this geometry is indeed Calabi-Yau,
as required by the reasoning of F-theory.
The implemented algorithm works for hypersurface, Weierstrass and global Tate models,
which are defined in a toric ambient space. It expresses $c_1(Y_n)$ as the restriction
of a cohomology class $h$ on the toric ambient space. This in turn requires that the
toric ambient space is simplicial and complete. We provide a switch to turn off
these computationally very demanding checks. This is demonstrated in the example below.
```jldoctest; setup = :(Oscar.LazyArtifacts.ensure_artifact_installed("QSMDB", Oscar.LazyArtifacts.find_artifacts_toml(Oscar.oscardir)))
julia> qsm_model = literature_model(arxiv_id = "1903.00009", model_parameters = Dict("k" => 4))
Hypersurface model over a concrete base
julia> is_calabi_yau(qsm_model, check = false)
true
```
"""
function is_calabi_yau(m::AbstractFTheoryModel; check::Bool = true)
@req (m isa WeierstrassModel || m isa GlobalTateModel || m isa HypersurfaceModel) "Verification of Euler characteristic of F-theory model supported for Weierstrass, global Tate and hypersurface models only"
@req base_space(m) isa NormalToricVariety "Verification of Euler characteristic of F-theory model currently supported only for toric base"
@req ambient_space(m) isa NormalToricVariety "Verification of Euler characteristic of F-theory model currently supported only for toric ambient space"
return get_attribute!(m, :is_calabi_yau) do
return is_trivial(chern_class(m, 1, check = check))
end
end
13 changes: 2 additions & 11 deletions experimental/FTheoryTools/src/G4Fluxes/properties.jl
Original file line number Diff line number Diff line change
Expand Up @@ -41,22 +41,13 @@ true
@req ambient_space(m) isa NormalToricVariety "Elementary quantization checks for G4-flux currently supported only for toric ambient space"

# Compute the cohomology class corresponding to the hypersurface equation
if m isa WeierstrassModel
cl = toric_divisor_class(ambient_space(m), degree(weierstrass_polynomial(m)))
end
if m isa GlobalTateModel
cl = toric_divisor_class(ambient_space(m), degree(tate_polynomial(m)))
end
if m isa HypersurfaceModel
cl = toric_divisor_class(ambient_space(m), degree(hypersurface_equation(m)))
end
cy = polynomial(cohomology_class(cl))
cy = polynomial(cohomology_class(toric_divisor_class(ambient_space(m), degree(hypersurface_equation(m)))))

# Now check quantization condition G4 + 1/2 c2 is integral.
c_ds = [polynomial(cohomology_class(d)) for d in torusinvariant_prime_divisors(ambient_space(m))]

# explicitly switched off an expensive test in the following line
twist_g4 = polynomial(cohomology_class(g4) + 1//2 * chern_class_c2(m; check = false))
twist_g4 = polynomial(cohomology_class(g4) + 1//2 * chern_class(m, 2; check = false))

# now execute elementary checks of the quantization condition
for i in 1:length(c_ds)
Expand Down
Loading

0 comments on commit 3a18e23

Please sign in to comment.