Interested readers can find more information in this article.
julia> sigma = positive_hull([1 0; -1 2])
Polyhedral cone in ambient dimension 2
julia> Usigma = affine_normal_toric_variety(sigma)
Normal toric variety
julia> toric_ideal(Usigma)
Ideal generated by
-x1*x2 + x3^2
julia> hilbert_basis(weight_cone(Usigma))
3-element SubObjectIterator{PointVector{ZZRingElem}}:
[2, 1]
[0, 1]
[1, 1]
julia> R = [1 0; 0 -1; -1 0; 0 1];
julia> IM = IncidenceMatrix([[1,2],[2,3],[3,4],[1,4]]);
julia> ntv = normal_toric_variety(IM, R)
Normal toric variety
julia> is_complete(ntv)
true
julia> is_smooth(ntv)
true
julia> c = cube(3)
Polytope in ambient dimension 3
julia> tv = normal_toric_variety(c)
Normal toric variety
julia> PP2 = projective_space(NormalToricVariety, 2)
Normal toric variety
julia> irrelevant_ideal(PP2)
Ideal generated by
x3
x1
x2
julia> stanley_reisner_ideal(PP2)
Ideal generated by
x1*x2*x3
julia> v = normal_toric_variety(IncidenceMatrix([[1], [2], [3]]), [[1, 0], [0, 1], [-1, -1]])
Normal toric variety
julia> is_complete(v)
false
julia> chow_ring(v)
Quotient
of multivariate polynomial ring in 3 variables x1, x2, x3
over rational field
by ideal (x1 - x3, x2 - x3, x1*x2, x1*x3, x2*x3)
julia> M = cycle_matroid(complete_graph(3))
Matroid of rank 2 on 3 elements
julia> chow_ring(M)
Quotient
of multivariate polynomial ring in 3 variables x_{Edge(2, 1)}, x_{Edge(3, 1)}, x_{Edge(3, 2)}
over rational field
by ideal with 5 generators
julia> pp1 = projective_space(NormalToricVariety, 1)
Normal toric variety
julia> tv = pp1 * pp1
Normal toric variety
julia> rays(tv)
4-element SubObjectIterator{RayVector{QQFieldElem}}:
[1, 0]
[-1, 0]
[0, 1]
[0, -1]
julia> maximal_cones(IncidenceMatrix, tv)
4×4 IncidenceMatrix
[1, 3]
[1, 4]
[2, 3]
[2, 4]
julia> Sigma = polyhedral_fan(tv)
Polyhedral fan in ambient dimension 2
julia> P1 = projective_space(NormalToricVariety, 1)
Normal toric variety
julia> l = toric_line_bundle(P1*P1, [-3,1])
Toric line bundle on a normal toric variety
julia> cohomology(l, 1)
4
julia> P1 = projective_space(NormalToricVariety, 1)
Normal toric variety
julia> v0, v1, v2 = vanishing_sets(P1*P1)
3-element Vector{ToricVanishingSet}:
Toric vanishing set for cohomology indices [0]
Toric vanishing set for cohomology indices [1]
Toric vanishing set for cohomology indices [2]
julia> print_constraints(polyhedra(v0)[1])
-x_1 <= 0
-x_2 <= 0
julia> print_constraints(polyhedra(v1)[1])
-x_2 <= 0
x_1 <= -2
julia> print_constraints(polyhedra(v1)[2])
-x_1 <= 0
x_2 <= -2
julia> print_constraints(polyhedra(v2)[1])
x_2 <= -2
x_1 <= -2
julia> normal_toric_varieties_from_glsm([[1,1,1]])
1-element Vector{NormalToricVariety}:
Normal toric variety
julia> normal_toric_varieties_from_glsm([[1,1,-1,-1]])
2-element Vector{NormalToricVariety}:
Normal toric variety
Normal toric variety
julia> rs = [1 1; -1 1];
julia> max_cones = IncidenceMatrix([[1,2]]);
julia> v = normal_toric_variety(IncidenceMatrix([[1,2]]), [1 1; -1 1]);
julia> set_coordinate_names(v, ["u1", "u2"])
julia> is_smooth(v)
false
julia> toric_ideal(v)
Ideal generated by
-x1*x2 + x3^2
julia> rays(maximal_cones(v)[1])
2-element SubObjectIterator{RayVector{QQFieldElem}}:
[1, 1]
[-1, 1]
julia> bu = blow_up(v, [0,1])
Toric blowup morphism
julia> v2 = domain(bu)
Normal toric variety
julia> is_smooth(v2)
true
julia> is_affine(v2)
false
julia> cox_ring(v2)
Multivariate polynomial ring in 3 variables over QQ graded by
u1 -> [1]
u2 -> [1]
e -> [-2]
julia> stanley_reisner_ideal(v2)
Ideal generated by
u1*u2