Maple, anyone?

  • Maple
  • Thread starter juef
  • Start date
  • #1
27
0
Hey all,

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

[tex]\theta(t)''+4\pi^2 sin(\theta(t))=0[/tex], with [tex]\theta(0)=A[/tex] and [tex]\theta'(0)=B[/tex] 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? o:) Thank you!!
 

Answers and Replies

  • #2
998
0
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.
 
  • #3
130
0
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
 
  • #4
27
0
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! :smile:
 

Attachments

  • Sans titre.GIF
    Sans titre.GIF
    6 KB · Views: 455

Related Threads on Maple, anyone?

  • Last Post
Replies
2
Views
1K
Replies
1
Views
1K
Replies
3
Views
5K
Replies
9
Views
48K
  • Last Post
Replies
1
Views
2K
  • Last Post
Replies
1
Views
3K
  • Last Post
Replies
0
Views
2K
  • Last Post
Replies
2
Views
2K
  • Last Post
Replies
1
Views
4K
  • Last Post
Replies
1
Views
1K
Top