Opened 7 years ago

Closed 7 years ago

#13183 closed enhancement (fixed)

Implement index(cone) for fan morphisms

Reported by: novoselt Owned by: mhampton
Priority: major Milestone: sage-5.9
Component: geometry Keywords: toric
Cc: vbraun Merged in: sage-5.9.beta2
Authors: Andrey Novoseltsev Reviewers: Volker Braun
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: #12544 Stopgaps:

Description (last modified by novoselt)

For #12892 it would be useful to compute indices of cones as they define the number of components of each fiber. The index is defined in

Yi Hu, Chien-Hao Liu, and Shing-Tung Yau. Toric morphisms and fibrations of toric Calabi-Yau hypersurfaces. Adv. Theor. Math. Phys., 6(3):457-506, 2002. arXiv:math/0010082v2 [math.AG].

for the case of surjection of complete fans. The attached patch extends the definition to any morphism:

  • if the corresponded quotient of lattices is finite, return its order;
  • if it has free generators, return infinity;
  • if the codomain cone does not have covering domain cones at all, return None.

Apply:

  1. trac_13183_index_of_codomain_cone.patch
  2. trac_13183_untwist_lattice_splitting.patch

Attachments (2)

trac_13183_untwist_lattice_splitting.patch (5.9 KB) - added by novoselt 7 years ago.
Rebased for Sage-5.2.rc0
trac_13183_index_of_codomain_cone.patch (15.6 KB) - added by novoselt 7 years ago.
Rebased for Sage-5.7.beta1

Download all attachments as: .zip

Change History (14)

comment:1 Changed 7 years ago by novoselt

Hi Volker, does the description definition sound OK?

The patch also improves handling of (non-saturated) sublattices and quotient lattices. In the process I had to cut _split_ambient_lattice - it will not split the dual one anymore. Note that this dual splitting was not documented and was used only to construct the dual quotient lattice - I have reimplemented the latter one in a more mathematically straightforward way, everything works as before, but choice of generators in doctest examples is now different (I checked that it is equivalent).

I'll put a ready for review version in a few days.

comment:2 Changed 7 years ago by vbraun

How about fiber_index() to distinguish it from the already existing index method?

The point of _split_ambient_lattice was that you only had to compute the Smith normal form once for the cone. Why not make use of cached data?

The index is always finite according to p.464.

If there is no preimage cone, I would also be fine with returning 0 instead of None in accord with counting fiber connected components.

comment:3 Changed 7 years ago by novoselt

Well, we don't really have fibers yet here and since it is defined as "index over cone" I thought index(cone) is the way to go.

The initial reason for dropping M splitting was that I couldn't figure out how to make it work nicely with sublattices when I need to split an already quotient lattice. Since my replacement is a straightforward implementation in terms of the dual lattice of a sublattice, in retrospect I also think that it would be better. Speedwise I didn't do precise measurements, but I was keeping an eye on timings of doctests and so far they don't seem to be affected.

The index is always finite in the case when the lattice morphism is surjective (assumption on p. 463) and fans are complete (implicit assumption of the paper). Take P2 and embed A1 over one of its rays. Then 3 fixed points and 2 lines are not covered at all, one line has only its distinguished point covered, and the torus itself has a lower dimensional torus in it. So my proposal is to return None for non-covered cones and infinity for two others. I'll also include a details explanation of this example into documentation.

On the level of toric morphisms, I think (component, count) would be the best output, with (None, None) for the case of non-covered orbits. For "partially covered" ones I am not sure yet. (component, -count) where count is multiplicity over distinguish point is one option, but I don't think I like it. Maybe (component, count, codimension)? Where codimension is for the "covered points" relative to the whole orbit. So for surjective case it is 0 and in the above example 1. In this case perhaps we should always return a triple. Anyway, let me know what you think! (Although I'll be off the grid for a few days.)

comment:4 Changed 7 years ago by vbraun

I see. I wouldn't mind if we just implicitly required surjectivity for all fiber_something() methods and raise a ValueError otherwise. Otherwise there isn't really any meaningful fibration structure. Having to always report extra codimensions over the base torus orbits seems painful/confusing with very little utility.

comment:5 Changed 7 years ago by novoselt

Fibers are defined for any morphism, no matter whether it is a fibration or not, so I'd like fiber methods to do something useful still. After some more thinking I'd like to use None as described above, but return 0 for non-finite index. Reason: I compute the index as the product of invariants, then if it is 0 (indicating ZZ-factors) replace it with infinity. Dropping this extra replacement simplifies life here and then we can also just return this index for "incomplete covering", i.e. if there is some fiber over the distinguished point, we return it with zero to indicate that generically there are no such components at all. So possible cases will be:

  • (component, count) - surjective, count has to be positive;
  • (component, 0) - non-surjective, but the distinguished point is covered;
  • (None, None) - even the distinguished point is not covered;

where the second element is always the index of a cone in the sense of this ticket. Those who want more details in the 0-case can use restrict_to_image method, which makes only two other cases possible.

comment:6 Changed 7 years ago by vbraun

Every morphism has inverse images, but I would reserve "fiber" for the case where you have a fibration. If only because it has the same English root.

comment:7 Changed 7 years ago by novoselt

  • Dependencies set to #12544
  • Status changed from new to needs_review

OK, ready for review, with infinity for the infinite index, otherwise it is confusing. It also turned out that old implementation was not generic enough to handle sublattices, I've added a workaround using the index over the origin, which is mathematically exactly the same. More general code is also added to _Cone_from_PPL and normalize_rays, which turned out to be quite a bit slower than existing one. So I made sure that we still use the old route when it is sufficient, in particular I don't see any speed regression on testing sage/geometry and sage/schemes/toric (by the way Volker - thanks for the idea to move toric files to a separate folder - very convenient for testing!).

The second patch is somewhat optional, but I propose to include it: since now we mostly deal with matrices whose rows (and not columns) are ray generators, it is more natural. Code is the third hunk, the rest is doctest adjustment due to a different choice of generators.

Changed 7 years ago by novoselt

Rebased for Sage-5.2.rc0

Changed 7 years ago by novoselt

Rebased for Sage-5.7.beta1

comment:8 Changed 7 years ago by novoselt

  • Description modified (diff)

Apply trac_13183_index_of_codomain_cone.patch trac_13183_untwist_lattice_splitting.patch

comment:9 follow-up: Changed 7 years ago by vbraun

Looks good to me

comment:10 in reply to: ↑ 9 Changed 7 years ago by novoselt

Replying to vbraun:

Looks good to me

As in "positive review"?-)

comment:11 Changed 7 years ago by vbraun

  • Reviewers set to Volker Braun
  • Status changed from needs_review to positive_review

Yes, forgot to press the button ;-)

comment:12 Changed 7 years ago by jdemeyer

  • Merged in set to sage-5.9.beta2
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.