finding if two binary quadratic forms represent the same integers

596 Views Asked by At

I am currently working with quadratic forms for a given discriminant D; to get all primitive forms (one for each equivalence class) I found this website : http://www.numbertheory.org/php/classnoneg.html

For instance for the case D=-23, the three primitive forms are given by : (1,1,6), (2,1,3), (2,-1,3); and I know that the two last ones represent the same integers.

I need now to work with some discriminant such that the class number is larger (h(D)=4,5..) and I need to know if two forms represent the same integers. Would you know of a similar software where I can check this?

Thanks.

1

There are 1 best solutions below

2
On

EDIT: most of what a beginner might need to know is in the first chapter of David A. Cox, Primes of the Form $x^2 + n y^2,$ which is still in print. I got more information, especially about Gauss composition, Pell equations, and how to write correct computer programs for everything, in Duncan A. Buell, Binary Quadratic Forms. Similar to this is Binary Quadratic Forms by J. Buchmann and U. Vollmer, although it strikes me as being a little harder to read; it is still in print though. My favorite, Buell, is available used but perhaps a bit pricey.

The bad news is that this is pretty much solved by VOIGHT, item number 6, which appeared in Math. Comp. about 2007.

On the other hand, you are welcome to my C++ program for this, sample output below. As you can see, the program finds the whole class group and then finds the principal genus ("squares"). I can usually figure out the other genera myself, and always can if there are just one or two genera. Hmmm...I also have programs that show me the numbers represented by a positive form, up to a bound I type in, different program for just primes, third program for primitively represented numbers.


jagy@phobeusjunior:~/old drive/home/jagy/Cplusplus$ ./classGroup
Absolute value of discriminant? 
56
  class  number  4

 all  
( 1, 0, 14)
( 2, 0, 7)
( 3, -2, 5)
( 3, 2, 5)

 squares  
( 1, 0, 14)
( 2, 0, 7)

 fourths  
( 1, 0, 14)


Discriminant        -56     h :    4     Squares :    2     Fourths :    1
jagy@phobeusjunior:~/old drive/home/jagy/Cplusplus$

jagy@phobeusjunior:~/old drive/home/jagy/Cplusplus$ ./classGroup
Absolute value of discriminant? 
47
  class  number  5

 all  
( 1, 1, 12)
( 2, -1, 6)
( 2, 1, 6)
( 3, -1, 4)
( 3, 1, 4)

 squares  
( 1, 1, 12)
( 2, -1, 6)
( 2, 1, 6)
( 3, -1, 4)
( 3, 1, 4)

 fourths  
( 1, 1, 12)
( 2, -1, 6)
( 2, 1, 6)
( 3, -1, 4)
( 3, 1, 4)


Discriminant        -47     h :    5     Squares :    5     Fourths :    5
jagy@phobeusjunior:~/old drive/home/jagy/Cplusplus$