Karim BELABAS on Mon, 17 Jun 2002 19:31:31 +0200 (MEST)


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

intnum


Received the following bug report:

(19:10) gp > intnum(x=0,Pi,sin(16*x)^2)
%1 = 1.855125350366532182 E-54  \\ should be Pi/2

Cause: integral computed using Romberg method, with equally spaced points
(+ interpolation of successive values for a few runs with increasing number
of points). For highly oscillating functions (esp. integrating over 2^k *
period), we may be unlucky.

Possible solution: pick random point in each subinterval ?

    Karim.
-- 
Karim Belabas                    Tel: (+33) (0)1 69 15 57 48
Dép. de Mathematiques, Bat. 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/