Karim BELABAS on Wed, 5 Feb 2003 00:02:01 +0100 (MET) |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: quadclassunit() bug |
On Thu, 30 Jan 2003, Igor Schein wrote: > On Thu, Jan 30, 2003 at 03:40:29PM -0500, Igor Schein wrote: >> ? setrand(178);quadclassunit(82421)[1] >> 2 >> >> This is wrong, should be 1. It looks like it can be related to the >> top priority items in section BUGS (general) of TODO file. > > Actually, it looks like regression, since it was working fine prior > to this change: > > \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ > revision 1.49 > date: 2002/09/02 21:15:07; author: karim; state: Exp; lines: +365 -450 > major cleanup buchquad [preliminary] > \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ > > Or maybe, rather, this change exposed previously hidden bug. Not really. Before the patch, an approximation to L(chi, 1) was computed using the first 30000 primes. After, we use the p <= cbach2 * (log D)^2 [ as the generic program bnfinit() does ]. This is not enough for quadratic fields of small discriminants, because we cheat even more on the default value for cbach than we do in the case of general fields... [ cbach = 0.1 where it should be 6. For general fields, it's 0.3 where it should be 12 ] I have added a sanity check to use at least all primes less than 100 [ arbitrary, tested OK for a while; we'll see if bad examples crop up... ] Karim. -- Karim Belabas Tel: (+33) (0)1 69 15 57 48 Dép. de Mathématiques, Bât. 425 Fax: (+33) (0)1 69 15 60 19 Université Paris-Sud Email: Karim.Belabas@math.u-psud.fr F-91405 Orsay (France) http://www.math.u-psud.fr/~belabas/ -- PARI/GP Home Page: http://www.parigp-home.de/