MathGroup Archive 2007

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

Search the Archive

NDSolve with functions of vectors

  • To: mathgroup at smc.vnet.net
  • Subject: [mg82853] NDSolve with functions of vectors
  • From: John Lee <johnlee_15 at hotmail.com>
  • Date: Thu, 1 Nov 2007 05:17:44 -0500 (EST)

Hi,
I'm trying to integrate a function with NDSolve (ExplicitRungeKutta method), and it doesn't seem to recognize vector variables (I keep getting an incorrect dimension error). In addition, I would like to integrate over an absolute distance and I don't know how to do that in Mathematica. For simplicity's sake, I will post a random example of what I'm talking about:
U[x] = {2*x[[2]],x[[1]]/3,x[[3]]} is the derivative
X0 = {1,1,1} is the initial condition
so if a'[s] = U[x[s]], I'd like to solve for a[s] where s is the total distance. And s is to be integrated from 0 to 6 with a[0]=X0.
Ultimately, I have a derivative that depends on a 3-component position vector. I want to integrate that derivative over a total distance traveled from a starting point.

Any advice would be helpful. Thanks,
John


  • Prev by Date: Manipulating a complex modulus expression
  • Next by Date: Re: Re: wrong answer or no answer?
  • Previous by thread: Re: Re: Manipulating a complex modulus expression
  • Next by thread: Re: NDSolve with functions of vectors