Lecture 3 Homework
Bob Astrom
Exercise 3.1
By trial and error the lowest value of n is
n = 24
with an answer of
1.475773161594552
Calculation by TI
‐
89 with the significant digits set at the maximum is 1.47577316159
Thus the answer given by MATLab is more accurate than the TI
‐
89 can display
When the answer is input into the program the output contains 4 more significant digits and converges
again after 7 more iterations.
Code and Answers for Exercise 3.2
%l3p2
%Math 344
%Homework Problem 3.2
%
or
%Homework Lecture 2 Problem 2 ==> (l3p2)
%Written by Bob Astrom
%
%***Returns the distance traveled by a ball after "n" bounces***
function
distance = l3p2(n)
% Solves for the total distance traveled after each cycle of the periodic
motion
% of a bouncing ball with a coefficient of elasticity of 0.9 by performing n
iterations
% of the equation with an initial height of 2 meters.
% The program also outputs the distance the ball drops and height of the
% return bounce.
%
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
This is the end of the preview.
Sign up
to
access the rest of the document.
 Spring '08
 Staff
 Bounce message, Bob Astrom

Click to edit the document details