Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2008

[Date Index] [Thread Index] [Author Index]

Search the Archive

Using FindRoot or interpolation function with symbolic argument

  • To: mathgroup at smc.vnet.net
  • Subject: [mg92164] Using FindRoot or interpolation function with symbolic argument
  • From: exoptery at gmail.com
  • Date: Mon, 22 Sep 2008 05:26:07 -0400 (EDT)

     I'd like to use NDSolve to integrate a pair of ODEs.  Expressing
the system as a set of explicit equations, however, requires the
inverse of ArcTanh[x] / x.  I thought I'd define a function for this
as follows:


     f = Compile[{{y, _Real}}, x /. FindRoot[ArcTanh[x] == y x, {x,
99/100}]];


However, when I set, say,


      eqn1 = u'[R] == u[R] f[(u[R] (1 + v[R])^2)/(1 + v[R]^2)]


Mathematica clearly dislikes the use of symbols instead of a numerical
argument.


     Is there a way to define an NDSolve-digestible equation that
calls FindRoot with symbolic arguments?

     Thank you for your attention.

     J.


  • Prev by Date: Re: Debracketing array symbols
  • Next by Date: Changing names of variables in a loop
  • Previous by thread: How to collect terms based the total power of x and y in (x + y +
  • Next by thread: Re: Using FindRoot or interpolation function with symbolic argument