X-Git-Url: https://ginac.de/CLN/cln.git//cln.git?a=blobdiff_plain;f=src%2Ffloat%2Ftranscendental%2Fcl_F_atanhx.cc;h=2d15ede2f1122349043c856b8f93c6ad0ad02b88;hb=c84c6db5d56829d69083c819688a973867694a2a;hp=fc732eb1badbbff78adad4d33f06cfd83bd55ca2;hpb=850abfde7f0d985ba01526c346bcd0d733562943;p=cln.git diff --git a/src/float/transcendental/cl_F_atanhx.cc b/src/float/transcendental/cl_F_atanhx.cc index fc732eb..2d15ede 100644 --- a/src/float/transcendental/cl_F_atanhx.cc +++ b/src/float/transcendental/cl_F_atanhx.cc @@ -51,10 +51,10 @@ const cl_LF atanhx (const cl_LF& x) { if (zerop(x)) return x; - var uintL actuallen = TheLfloat(x)->len; - var uintL d = float_digits(x); + var uintC actuallen = TheLfloat(x)->len; + var uintC d = float_digits(x); var sintL e = float_exponent(x); - if (e <= (sintL)(-d)>>1) // e <= -d/2 <==> e <= -ceiling(d/2) + if (e <= (sintC)(-d)>>1) // e <= -d/2 <==> e <= -ceiling(d/2) return x; // ja -> x als Ergebnis if (actuallen >= 34) { DeclareType(cl_LF,x); @@ -105,7 +105,7 @@ const cl_LF atanhx (const cl_LF& x) } else { // naive2: // floating-point representation with smooth precision reduction - var cl_LF eps = scale_float(b,-(sintL)d-10); + var cl_LF eps = scale_float(b,-(sintC)d-10); loop { var cl_LF new_sum = sum + LF_to_LF(b/(cl_I)i,actuallen); // (+ sum (/ b i)) if (new_sum == sum) // = sum ? @@ -129,9 +129,9 @@ const cl_F atanhx (const cl_F& x) } if (zerop(x)) return x; - var uintL d = float_digits(x); + var uintC d = float_digits(x); var sintL e = float_exponent(x); - if (e <= (sintL)(-d)>>1) // e <= -d/2 <==> e <= -ceiling(d/2) + if (e <= (sintC)(-d)>>1) // e <= -d/2 <==> e <= -ceiling(d/2) return x; // ja -> x als Ergebnis var uintL k = 0; // Rekursionszähler k:=0 // Bei e <= -1-limit_slope*floor(sqrt(d)) kann die Potenzreihe