cl_N log(const cl_N& a, const cl_N& b) returns zero when an exact negative integer is expected

Niklas Knutsson nq at altern.org
Fri Jun 18 02:15:55 CEST 2004


hi.
the following bug required a workaround when writing source code for
Qalculate!:

cl_N log(const cl_N& a, const cl_N& b) returns zero when an exact
negative integer is expected.

example:

log(recip(cl_RA(1000)), cl_N(10)); returns 0
log(cl_N(0.001), cl_N(10)); returns -3

using
cln-1.1.6
gmp-4.1.2
gcc-3.3.3
glibc-2.3.3_pre20040207
linux-2.6.5-mm1

//niklas k.




More information about the GiNaC-devel mailing list