question about Integrate
- To: mathgroup at smc.vnet.net
- Subject: [mg49241] question about Integrate
- From: "Florian Jaccard" <florian.jaccard at eiaj.ch>
- Date: Fri, 9 Jul 2004 02:26:11 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
Dear specialists, I asked my students to compute the area of the following closed curve : x[t_] := Sin[t]; y[t_] := E^Cos[t]; ParametricPlot[{x[t], y[t]}, {t, 0, 2*Pi}]; I expected the following input : 2*NIntegrate[x[t]* Derivative[1][y][t],{t, Pi, 0}] which gives the following output : 3.5509993784243483 (They also could have done it like this : 2*NIntegrate[y[t]*Derivative[1][x][t],{t, 0, Pi}] and it gives the same output) As the help browser says "N[Integrate[ . ]] calls NIntegrate for integrals that cannot be done symbolically" , I never told my students to avoid that way : 2*N[Integrate[x[t]*Derivative[1][y][t],{t, Pi, 0}]] But, surprise, it gives an other answer : 2.1262 Checking carefully, I could see that NIntegrate did it fine, but N[Integrate...] is wrong. It seems that the special functions BesselI and StruveL (used by Mathematica if you type Integrate[...]) are making the mistake... Now, what should I tell my students ? To never believe Integrate if not checked with NIntegrate ? Must I recognize that there is a bug in Integrate, or what did I understand wrong ? Thanks for your help ! Florian JACCARD
- Follow-Ups:
- Re: question about Integrate
- From: Andrzej Kozlowski <akoz@mimuw.edu.pl>
- Re: question about Integrate