Check out Matrix_integer_dense.lllgram, e.g. EXAMPLES: sage: M = Matrix(ZZ, 2, 2, [5,3,3,2]) ; M [5 3] [3 2] sage: U = M.lllgram(); U [-1 1] [ 1 -2] sage: U.transpose() * M * U [1 0] [0 1]
This is only for integer matrix, altough the code should work as is for matrices with real coefficients. Meanwhile, you can actually use pari's qflllgram from sage (just use something like pari(M).qflllgram()) Gonzalo On 9/21/07, John Cremona <[EMAIL PROTECTED]> wrote: > > qflllgram is the gp function I use. It takes as input the gram matrix > and outputs the unimodular transform. > > John > > On 9/21/07, Martin Albrecht <[EMAIL PROTECTED]> wrote: > > > > > > (first) try the FP variants of NTL's LLL first (I overlooked those > > > > before) > > > > > > These use real arithmetic "internally", I think, but do not alow real > > > input data as in my previous posting. > > > > Yes, it seems so. I am not very familiar with GP/Pari, which function > > implements what you want (gflllgram)? It is probably quite easy to wrap it > > for you once I know what to call. > > > > Martin > > > > > > -- > > name: Martin Albrecht > > _pgp: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x8EF0DC99 > > _www: http://www.informatik.uni-bremen.de/~malb > > _jab: [EMAIL PROTECTED] > > > > > > > > > > > > -- > John Cremona > > > > --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/ -~----------~----~----~----~------~----~------~--~---