MathGroup Archive 2003

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

Search the Archive

Re: Can someone tell me why NDso

  • To: mathgroup at smc.vnet.net
  • Subject: [mg44058] Re: Can someone tell me why NDso
  • From: "Peter Pein" <nospam at spam.no>
  • Date: Sun, 19 Oct 2003 01:11:13 -0400 (EDT)
  • References: <200310180712.DAA28012@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

lve isn't working here?

Five out of six functions do not occur as derivatives w.r.t. t:
Fx,Rx,Fy,Ry and if you rename x''[t] as x2[t]!

you'll get a single DE.

In[1]:=
eqns = {Fx[t] + Rx[t] == 2*M*Derivative[2][x][t], Fy[t] + Ry[t] == 0,
    Fx[t]*R == -(M*R*Derivative[2][x][t]),
    -Rx[t] == (1*L*M*Sin[-\[Theta][t]]*Derivative[1][\[Theta]][t]^2)/2 +
M*Derivative[2][x][t] +
      (1*L*M*Cos[-\[Theta][t]]*Derivative[2][\[Theta]][t])/2,
    -Ry[t] == (1*M*L*Derivative[2][\[Theta]][t]*Sin[-\[Theta][t]])/2 -
      (1*M*L*Derivative[1][\[Theta]][t]^2*Cos[-\[Theta][t]])/2,
    (1*L*Sin[\[Theta][t]])/2 - (1*L*Cos[\[Theta][t]]*Rx[t])/2 ==
(1*M*L^2*Derivative[2][\[Theta]][t])/
      12};
In[2]:=
eq2 = Collect[Eliminate[eqns, {Derivative[2][x][t], Fx[t], Fy[t], Ry[t],
Rx[t]}],
   {\[Theta], Derivative[1][\[Theta]], Derivative[2][\[Theta]]},
FullSimplify]
Out[2]=
L*R*(6*Sin[\[Theta][t]]*(3*L*M*Cos[\[Theta][t]]*Derivative[1][\[Theta]][t]^2
 - 8) -
    L*M*(9*Cos[2*\[Theta][t]] + 1)*Derivative[2][\[Theta]][t]) == 0
In[3]:=
R = 1; M = 1; L = 1;
  f = \[Theta] /. NDSolve[eq2 && \[Theta][0] == Pi/2 &&
Derivative[1][\[Theta]][0] == -((3*Pi)/4), \[Theta],
      {t, 0, 1}][[1]];
NDSolve::"ndsz": "At \!\(t\) == \!\(0.9027410098372591`\), step size is \
effectively zero; singularity suspected."

Peter Pein, Berlin
petsie at arcAND.de
replace && by || to write to me


----- Original Message -----
From: "Mizrandir" <mizrandir at hotmail.com>
To: mathgroup at smc.vnet.net
Subject: [mg44058]  Can someone tell me why NDsolve isn't working here?


> Hello, Im trying to solve a system of 6 differential equations with
> NDSolve but I can't get Mathematica to do it. I wrote:
>
> R = 1;
> M = 1;
> L = 1;
> NDSolve[{Rx[t] + Fx[t] == 2M x''[t], Ry[t] + Fy[t] == 0,
>     Fx[t] R == -M R x''[t], -Rx[t] ==
>       M x''[t] + (M L \[Theta]''[t] Cos[-\[Theta][t]])/
>           2 + (M L \[Theta]'[t]^2 Sin[-\[Theta][t]])/2, -Ry[
>           t] == (M L \[Theta]''[t] Sin[-\[Theta][t]])/
>           2 - (M L \[Theta]'[t]^2 Cos[-\[Theta][t]])/
>           2, -(L Cos[\[Theta][t]] Rx[t])/2 + (L Sin[\[Theta][t]])/
>           2 == (M L^2 \[Theta]''[t])/12, x[0] == 0, \[Theta][0] ==
> Pi/2,
>     Ry[0] == -M/2, Rx[0] == 0, Fy[0] == 5M/2, Fx[0] == 0}, {x,
> \[Theta], Ry,
>     Rx, Fy, Fx}, {t, 0, 1}]
>
> And Mathematica gave me the following error:
>
> NDSolve::"ndode": "Input is not an ordinary differential equation."
>
> Does anybody know what am I doing wrong. Can I use Mathematica to
> solve this?
>
> Thanks in advance, miz.
>


  • Prev by Date: Re: Re: Running The Combinatorica GraphEditor
  • Next by Date: Re: Problem with Sum
  • Previous by thread: Can someone tell me why NDsolve isn't working here?
  • Next by thread: Re: Can someone tell me why NDsolve isn't working here?