Markus Grassl on Wed, 15 Nov 2023 23:09:17 +0100


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Question on ternary quadratic form


It took me a bit longer to find the corresponding functions in Pari - slightly different from Bill's solution:

? G=[1, 0,  0; 0,  5,  28; 0, 28, 157]
%1 =
[1  0   0]

[0  5  28]

[0 28 157]

? qflllgram(G)
%2 =
[1  0   0]

[0 -6 -11]

[0  1   2]


I'm not sure whether this works for all cases.

More generally, given a quadratic form, one can look for short vectors in the lattice with the give Gram matrix whose length is a square. Those vectors can be used in a Gram-Schmidt like procedure, and the normalisation of the vectors does not introduce a square root if the the length of the vectors is a square.


Markus


Am 15/11/2023 um 22:28 schrieb hermann@stamm-wilbrandt.de:
Centrum Informatyczne UG: Ta wiadomość e-mail pochodzi spoza Uczelni Fahrenheita. Zachowaj ostrożność. Nie klikaj linków ani nie otwieraj załączników, chyba że rozpoznajesz nadawcę i wiesz, że zawartość jest bezpieczna.
________________________________
UG IT Center: This email comes from outside the Fahrenheit Universities. Use caution. Do not click links or open attachments unless you recognize the sender and know that the content is safe.

After two modifications I got this ternary quadratic form:

? Qt

[1  0   0]

[0  5  28]

[0 28 157]

?

I know it can be transformed to ternary identity form.
In order to determine the transformation I define:

? X

[1 0 0]

[0 a b]

[0 c d]

?

And get this:

? X~*Qt*X

[1                                   0
0]

[0            5*a^2 + 56*c*a + 157*c^2 (5*b + 28*d)*a + (28*c*b +
157*d*c)]

[0 (5*b + 28*d)*a + (28*c*b + 157*d*c)            5*b^2 + 56*d*b +
157*d^2]

?

Now I switch to wolframscript and determine a solution for the three
equations:

In[4]:= FindInstance[5*a^2 + 56*c*a + 157*c^2==1&&5*b^2 + 56*d*b +
157*d^2==1&&(
5*b + 28*d)*a + (28*c*b + 157*d*c)==0,{a,b,c,d},Integers]

Out[4]= {{a -> -6, b -> -11, c -> 1, d -> 2}}

In[5]:=

With that I define matrix Y:

? Y

[1  0   0]

[0 -6 -11]

[0  1   2]

?

And really Y is transformation matrix to ternary quadratic form:

? Y~*Qt*Y

[1 0 0]

[0 1 0]

[0 0 1]

?


How can I determine integer {a,b,c,d} solutions in PARI/GP without using
wolframscript?


Regards,

Hermann.