       Re: Bug of Integrate

• To: mathgroup at smc.vnet.net
• Subject: [mg83028] Re: Bug of Integrate
• From: danl at wolfram.com
• Date: Thu, 8 Nov 2007 06:06:05 -0500 (EST)
• References: <fg4dfv\$6c3\$1@smc.vnet.net><fgs908\$4m9\$1@smc.vnet.net>

```On Nov 7, 5:53 am, Miguel <misv... at gmail.com> wrote:
> [...]
>
> By other hand, I think everybody knows the solution of the following
> problem:
> "Derive the formula for the circunference of a circle of radius "a" by
> computing the length of the arc     x=a cost; y= a sint  for 0<=t<=Pi
> "
>
> L=Integrate[Sqrt[1+(y'[t]/x'[t])^2]*x'[t],{t,0,2Pi}]

Not quite. It needs an absolute value for the last factor.

> I have tried to resolve with version 5.2 and version 6.0.1. The
> results have been differents.
>
> When the result is unknown, version 6.0.1 is reliable?

It seems straightforward to verify via numerical computation.

In:= x = a*Cos[t]; y = a*Sin[t];

In:= ll = Integrate[Sqrt[1+(D[y,t]/D[x,t])^2]*Abs[D[x,t]], {t,
0,2*Pi},
Assumptions->a>0]

Out= 2 a Pi

In:= a = 2;

In:= NIntegrate[Sqrt[1+(D[y,t]/D[x,t])^2]*Abs[D[x,t]], {t,0,2*Pi}]

Out= 12.5664

Without the Abs[] one (correctly) obtains 0 for both exact and numeric
integrals.

By the way, when dealing with a parametrized curve, it is often
simpler to avoid implicitly treating y as a function of x; instead
just work directly with the parametrization.

In:= a=.

In:= ll = Integrate[Sqrt[D[x,t]^2+D[y,t]^2], {t,0,2*Pi},
Assumptions->a>0]

Out= 2 a Pi

Daniel Lichtblau
Wolfram Research

```

• Prev by Date: Re: Crash with simple plot command
• Next by Date: Re: Re: ListPointPlot3D
• Previous by thread: Re: Re: Bug of Integrate
• Next by thread: Re: Bug of Integrate