This is the mail archive of the gsl-discuss@sources.redhat.com mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: erroneous claim at sources.redhat.com/gsl/ref/gsl-ref_4.html#SEC32


keith.briggs@bt.com writes:
 > > Function: double gsl_pow_int (double x, int n) 
 > 	>This routine computes the power x^n for integer n. The power is
 > computed using the minimum number of multiplications. 
 > A glance at the source code shows that this is wrong.   It uses repeated
 > squaring, so, for example, x^15 is computed
 > with 6 multiplies, whereas it can be done with 5.

Thanks for pointing that out.  I've changed the manual to say the
algorithm is "efficient" rather than using the minimum number of
multiplications.

-- 
Brian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]