Re: desperate, please help.

*To*: mathgroup at smc.vnet.net*Subject*: [mg27378] Re: desperate, please help.*From*: "Paul Lutus" <nospam at nosite.com>*Date*: Thu, 22 Feb 2001 02:25:24 -0500 (EST)*References*: <97003k$tq@smc.vnet.net>*Sender*: owner-wri-mathgroup at wolfram.com

"Thjqase" <thjqase at aol.com> wrote in message news:97003k$tq at smc.vnet.net... > I need help numerically solving a differential equation coupled with several > algebraic equations. New to Mathematica. Here's code: > > NDSolve[{v'[x] == -F÷r, T[x] == 330 + 43.3*x, F = .9*163, C == 9.3, > k[x] == 31.1Exp(7906*(T - 360)/(T*360)) > , K[x] == 3.03*Exp(-830.3*((T - 333)/(T*333))), > r[x] == -k*C*(1 - (1 + 1/K)*x), > v[0] == 0}, {v} > , {x, 0, .7}] > > Error code is: > > NDSolve::"deql": "The first argument must have both an equation and an \ > initial condition." > > Any suggestions? What am I doing wrong? My head is sore from banging it against > the wall. Without trying to sort out your entry in detail, I recommend that you submit a much simpler expression to NDSolve[], then gradually work up to this very complex expression. Specifically, you are mixing assignments and tests: "F = .9*163, C == 9.3" The first assigns .9*163 to F, the second compares C to 9.3. I am not sure that is what you meant to say. Also, if you have straightforward algebraic equations that you plan to use, they should be placed outside the NDSolve entry, not within it as you are doing. The same for constants. But please try the first suggestion first -- submit something much simpler to NDSolve[], then gradually increase the complexity. This will allow you to identify errors more easily. -- Paul Lutus www.arachnoid.com