From 975e40774a66be4d4da8374cbe5341b27135efc5 Mon Sep 17 00:00:00 2001 From: Martin Bies Date: Thu, 31 Aug 2023 14:54:46 +0200 Subject: [PATCH] [Schemes] Optimize toric ideal sheaves --- experimental/Schemes/IdealSheaves.jl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/experimental/Schemes/IdealSheaves.jl b/experimental/Schemes/IdealSheaves.jl index d0bb2d1b8cf0..0680f2e6288e 100644 --- a/experimental/Schemes/IdealSheaves.jl +++ b/experimental/Schemes/IdealSheaves.jl @@ -1263,10 +1263,11 @@ function IdealSheaf(X::NormalToricVariety, I::MPolyIdeal) # following dictionary lazy. But this requires partial rewriting of the # ideal sheaves as a whole, so we postpone it for the moment. + IM = maximal_cones(IncidenceMatrix, X) for (k, U) in enumerate(affine_charts(X)) # We first create the morphism \pi_s* from p. 224, l. 3. - indices = [j for j in 1:nrays(X) if ray_indices(maximal_cones(X))[k,j]] + indices = [k for k in row(IM, k)] help_ring, x_rho = polynomial_ring(QQ, ["x_$j" for j in indices]) imgs_phi_star = [j in indices ? x_rho[findfirst(k->k==j, indices)] : one(help_ring) for j in 1:nrays(X)] phi_s_star = hom(cox_ring(X), help_ring, imgs_phi_star)