Compute intersection of cone with lattice?
My question: Consider a full dimension cone and a full rank lattice in $\mathbb{R}^d$ (so the cone and lattice each have $d$ generators, with potentially non-integer coordinates). Does Sage have functions to compute their intersection?
For me, a cone $C$ with generators $v_1, \ldots, v_d$ is the set of all combinations $\sum_{i} c_i v_i \text{ with } c_i \in \mathbb{R}_{>0}$.
Meanwhile, a lattice $L$ with generators $v_1, \ldots, v_d$ is the set of all combinations $\sum_{i} n_i v_i \text{ with } n_i \in \mathbb{Z}$.
I want the intersection of $C$ and $L$ (modulo positive translates of the cone generators). As such, it might suffice to compute the intersection between a "fundamental parallelpiped" for $C$ and the lattice $L$... Perhaps with a condition on the relationship between the generators of $C$ and $L$?
I am currently constructing my cones with the "convex rational polyhedral cones" module. And I couldn't find a class for a lattice with non-integer coordinates (I only found the "Integral lattices" module). When $d = 2$, I might write
cone_generators = [[1.1, 2.3], [3, 0.2]]
cone = Cone(cone_generators).interior()
lattice_generators = [[1, 0], [0.2, 0.3]]
lattice = ??
intersection = ?? (modulo positive translates of the cone generators)
Context of question, in case helpful: The problem arises from algebraic number theory. I am regarding (fractional) ideals in number fields as lattices via the embeddings of the number field. See Conrad's "The Different Ideal" for some pictures/examples -- pdf available online, my karma is insufficient to include a link.
I'd like to determine the intersection between those lattices and various cones.
Unless there is a better solution, you can construct lattice as a cone with original generators and their negations:
Would that generate a lattice? My understanding of Cone is that it uses non-negative real combinations of vectors, while a lattice uses integer combinations.
And I would still remain at a loss for the intersection. When I try code like
I get an error "no common canonical parent for objects with parents Polyhedra and ToricLattice".
Indeed, I thought about integer cones, which is not the case with
Cone()
. In what form you expect to see the result of intersection of a cone and a lattice?Mmmm thank you for asking, I've edited my question with some discussion. I want the intersection of $C$ and $L$ modulo positive translates of the cone generators (and then I can add linear combos of cone generators to get other lattice points in the cone).