Jeroen Demeyer on Mon, 26 Jul 2010 14:40:26 +0200 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Real zero in libpari |
Hello pari-users, I have a technical question about the t_REAL type. The documentation says that real zero is characterized by having the sign equal to zero. My question is: does a real zero NEED to have lg == 2 in order to be a valid GEN? I am asking because the following program gives an error: #include <pari/pari.h> int main() { pari_init(1000000, 500000); GEN x = cgetr(3); /* Normally, lg would be 2 */ setsigne(x, 0); setexpo(x, -63); dbgGEN(x, -1); /* The following line gives: *** overflow in expo(). *** Error in the PARI system. End of program. */ gexp(x, 100); } Cheers, Jeroen.