R=5;
g=9.8;
sol = NDsolve[{theta''[t]==-g/m*sin[theta[t]],theta[0]==20,theta'[0]==0},theta,{t,0,100}]
Plot[theta[t]/.sol,{t,0,100}]
Asked
Active
Viewed 398 times
1
Alphonse
- 11
- 1
1 Answers
0
See also this Q&A for some very important advice about Built-in symbols and so on.
g = 9.8;
m = 10^3;
sol = NDSolve[{theta''[t] == -g/m*Sin[theta[t]], theta[0] == 20,
theta'[0] == 0}, theta, {t, 0, 100}]
Plot[theta[t] /. sol, {t, 0, 100}]
Since the variable R is not used anywhere, I have leftout this piece of Code.



NDSolverather thanNDsolve. UseSinrather thansin. You need to assign a value tom. – Bob Hanlon Sep 19 '16 at 05:37