Question: HW 2 - Q 4 ) MATLAB, PLEASE MAKE CODE COPYABLE The trajectory of a ball thrown by a right fielder as defined in the

HW2-Q4) MATLAB, PLEASE MAKE CODE COPYABLE
The trajectory of a ball thrown by a right fielder as defined in the (x,y) coordinates can be modeled as:
y=x(tan(1800))-g2v02cos2(1800)x2+y0
where the angle at which the ball leaves the right fielder's hand is 0=6, the initial velocity is
v0=92mph, the distance between the right fielder and the catcher is 50m, and the throw leaves
the right fielder's hand at an elevation of 2.1m. You must use g=9.81ms2 and the following
conversion factors: 1 mile =5280 feet and 1 meter =3.28 feet.
a) Plot the function using the plot command in figure 1. Title the plot "MAE 284, Homework 2,
Problem 4, Part a". Use the axis command to change the axis so that the x axis starts at 0
and goes to 50 meters and the y axis goes from 0 to 5m.
b) If the catcher cannot reach above an elevation of 2.6m, will she catch the ball? Use
conditional statements and an fprintf to display the result (e.g. "The elevation at
x=xxm is x.xxxxm. The catcher CAN/CANNOT catch the ball"
where either can or cannot is displayed.)
c) Compute the maximum height reached by the ball using each of the following methods. Use
the fprintf function to print the result. For example, "The maximum height
using goldmin is X.XXXXXXXX m". Display 8 digits to the right of the decimal
point. You may create functions for golden-section and parabolic interpolation.
i. Golden-section search ({:xl=9,xu=49,s=0.2%)
ii. Parabolic interpolation (x1=0x2=21,x3=49, maxiterations =2)
iii. MATLAB's fminbond with iterations displayed. Use a range of 0 to the distance of the
catcher.
 HW2-Q4) MATLAB, PLEASE MAKE CODE COPYABLE The trajectory of a ball

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!