KeyError followed by AttributeError while calling .closest_vector() [closed]
The following code gives me weird KeyError: ((None,), ())
followed by AttributeError: 'sage.symbolic.expression.Expression' object has no attribute 'ceil'
from sage.modules.free_module_integer import IntegerLattice
L = IntegerLattice([[-1, 0, 1],[1,0,2]])
L.closest_vector((1,1,1))
I see it even at SageCell - https://sagecell.sagemath.org/?q=bznwmz
What is wrong?
Which version of sage? Not the same error, but still an error with 9.5.b0
The error on sagemathcell is not the same as the one you give. It rather comes from abs of the basis vectors being symbolic expressions sqrt(2) and sqrt(5).
I"m using Sage 9.4. At sagecell it's the same error - it's KeyError followed by AttributeError. You seem to talk about the second one.
The real error comes from
sqrt(5).ceil()
not working..I've reported this in ticket https://trac.sagemath.org/ticket/32486