Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #6342 > unrolled thread

nested findroot

Started byAnna McCuan <anna.mccuan@gmail.com>
First post2011-11-10 12:06 +0000
Last post2011-11-11 09:54 +0000
Articles 2 — 2 participants

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  nested findroot Anna McCuan <anna.mccuan@gmail.com> - 2011-11-10 12:06 +0000
    Re: nested findroot Ray Koopman <koopman@sfu.ca> - 2011-11-11 09:54 +0000

#6342 — nested findroot

FromAnna McCuan <anna.mccuan@gmail.com>
Date2011-11-10 12:06 +0000
Subjectnested findroot
Message-ID<j9genv$p2n$1@smc.vnet.net>
I'm getting an error finding a root using functions which are defined
using findroot.  This happens in spite of the fact that I can graph
the function and see clearly that there is an easy to find root.  Does
anyone know how to execute this root search successfully?

The file is posted publicly at http://www.math.gatech.edu/~mccuan/temp/problem.nb

[toc] | [next] | [standalone]


#6355

FromRay Koopman <koopman@sfu.ca>
Date2011-11-11 09:54 +0000
Message-ID<j9ircg$88v$1@smc.vnet.net>
In reply to#6342
On Nov 10, 4:06 am, Anna McCuan <anna.mcc...@gmail.com> wrote:
> I'm getting an error finding a root using functions which are defined
> using findroot.  This happens in spite of the fact that I can graph
> the function and see clearly that there is an easy to find root.
> Does anyone know how to execute this root search successfully?
>
> The file is posted publicly at
> http://www.math.gatech.edu/~mccuan/temp/problem.nb

Change the definitions of f and g so that
they apply only when the argument is numeric:

f[w_?NumericQ] := ...
g[w_?NumericQ] := ...

FindRoot[g[soln] - 9 f[soln] == 0, {soln, .13}]
{soln -> 0.131216}

[toc] | [prev] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web