16.12.2012 Views

Computer Algebra Recipes

Computer Algebra Recipes

Computer Algebra Recipes

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

3.1. FIRST-ORDER MODELS 117<br />

Evil Knievel's velocity is plotted over the time interval t = 0 to 10 time units,<br />

labels being added to the graph.<br />

> plot(Vel,t=0..10,labels=["t","Vel"],tickmarks=[3,3]);<br />

0.3<br />

Vel<br />

0.2<br />

0.1<br />

0<br />

2 4 6 8 10<br />

t<br />

Figure 3.3: Evil Knievel's velocity pro¯le.<br />

The resulting picture is shown in Figure 3.3, the velocity curve increasing from<br />

zero to a maximum and then decreasing to zero again as t !1.<br />

The distance traveled in the time interval t = 0 to 10 is equal to the area<br />

under the velocity curve between these limits, this area obtained by performing<br />

the integration R 10<br />

Vel dt. However, if the integer 10 is used, the integral will<br />

0<br />

not be evaluated. A °oating-point answer could be obtained by apply the evalf<br />

command. An alternative way used here in Professor Nerd's answer key is to<br />

enter the upper limit as 10.0, which forces a °oating-point evaluation of the<br />

integral. It does not imply any increase in accuracy.<br />

> distance:=int(Vel,t=0..10.0); #note floating point number<br />

distance := 0:9943356328<br />

So, Evil Knievel travels just under 1 Erehwonian spatial unit in the time interval.<br />

PROBLEMS:<br />

Problem 3-5: Direct solution<br />

Solve Professor Nerd's problem directly with the dsolve command and check<br />

that the answer is identical to that derived in the text recipe.<br />

Problem 3-6: Di®erent drive force<br />

The drive force in the text recipe is replaced with Fdrive =sin(t) t2 e ¡t . Determine<br />

the velocity as a function of time and plot the result over the interval<br />

t = 0 to 10. What is Evil Knievel's maximum velocity and at what time does<br />

this occur? What is his maximum displacement from the origin in this interval<br />

and at what time does this occur?

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!