Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2009

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

Search the Archive

Query about using FindRoot on function defined via Module

  • To: mathgroup at smc.vnet.net
  • Subject: [mg102818] Query about using FindRoot on function defined via Module
  • From: "J." <exoptery at gmail.com>
  • Date: Fri, 28 Aug 2009 00:45:18 -0400 (EDT)

     I have defined a function F[x,y,z,u,v,w] by setting

     F[x_,y_,z_,u_,v_,w_] := a Module expression.

Within the Module, several of the inputs are used as parameters in a
repeated NDSolve command.

     I would like to fix y, z, u,v, and w, and find the first zero of
the resulting function of x alone.  I assign values to y, z, u, v, and
w, and type

     FindRoot[ F[x,y,z,u,v,w] , {x,y} ]

The failure notification that I get indicates that NDSolve is cannot
operate because x is not a number.  I was under the impression that
FindRoot would first evaluate F[y,y,z,u,v,w], where y, z, u, v, and w
have already been assigned values.  That must not be happening.

     Does anyone know how I must modify my use of FindRoot to get
NDSolve to run inside the Module expression?

     Thank you for your attention.

     J.



  • Prev by Date: Viewing .mx files (Question)
  • Next by Date: Eigenvalues broken?
  • Previous by thread: Viewing .mx files (Question)
  • Next by thread: Re: Query about using FindRoot on function defined via Module