# Maple, anyone?

• Maple
Hey all,

I'm having trouble setting initial conditions when solving differential equations in Maple. Here's the equation:

$$\theta(t)''+4\pi^2 sin(\theta(t))=0$$, with $$\theta(0)=A$$ and $$\theta'(0)=B$$ as initial conditions.

I'd like to solve it with a command like:
solution:=dsolve({diff(theta(t), t, t) + 4*Pi*sin(theta(t)=0, init_conds},theta(t),numeric,range=0..4);

with something like:
init_conds:={theta(0)=A, diff(theta, t)=B);

But it seems Maple doesn't like my way of doing things... I've searched the help file, but couldn't find one that suits my problem.

Anyone? Thank you!!

Try this:

dsol:=(A,B)->dsolve({(D@@2)(theta)(t)+4*Pi^2*sin(theta(t)), theta(0)=A, D(theta)(0)=B}, numeric);

then the command

dsol(a,b)(T);

will evaluate the solution with ICs A = a, B = b, at t = T.

here is what i did
doesnt give u a nice solution but it works nonetheless
(student):
diff(theta(t),t,t)+4*Pi*Pi*sin(theta(t))=0;
dsolve({%,theta(0)=A,D(theta)(0)=B},theta(t));

perhaps if u plugged in some values instead of "A" and "B" it might give u something more exciting

Man, I didn't know about that D operator, the only thing I used was diff. Your help is extremely appreciated. Thanks a bunch both of you!! See my appreciation in the attachment! #### Attachments

• Sans titre.GIF
6 KB · Views: 455