Re: Debug of FindRoot
- To: mathgroup at smc.vnet.net
- Subject: [mg78879] Re: Debug of FindRoot
- From: "David Park" <djmpark at comcast.net>
- Date: Thu, 12 Jul 2007 05:09:22 -0400 (EDT)
- References: <f72c9h$d75$1@smc.vnet.net>
It's because the algorithm jumps out of the local region that contains the
local root.
Go to MathSource and find Ted Ersek's RootSearch package.
Needs["Ersek`RootSearch`"]
Bi=0.5;
RootSearch[BesselJ[0,z]/BesselJ[1,z]==z/Bi, {z, 0.2, 12}]
{{z->0.940771},{z->3.95937},{z->7.08638},{z->10.2225}}
The problem is that RootSearch is a more general algorithm than simply
finding roots along a real line. It will, for example, find complex roots.
However, it does not work well for the real line root case, the most common
application by far, and a cause of many questions on this news group. WRI
might consider making arrangements with Ted Ersek to incorporate his
algorithm as a special form of FindRoot.
--
David Park
djmpark at comcast.net
http://home.comcast.net/~djmpark/
"Miguel" <misvrne at gmail.com> wrote in message
news:f72c9h$d75$1 at smc.vnet.net...
> To resolve one of the heat equations it is necesary to calculate the
> solution of z for BesselJ[0,z]/BesselJ[1,z]==z/Bi, where Bi is the
> Biot number (equal to 0.5, for example).
>
> 1.- Plot[{BesselJ[0,z]/BesselJ[1,z],z/Bi},{z,0.001,12}].
>
>>From this plot I deduce the ranges, more or less, {1,4,7,10}.
>
> 2.- FindRoot[BesselJ[0,z]/BesselJ[1,z]==z/Bi,{z,#}]&/@{1,4,7,10}
> {{z->0.940771},{z->3.95937},{z->0.940771},{z->3.95937}}
>
> I dont understand the reason. With others differents intervals it
> works fine.
>
>