Question: Please do not use for and while loops Please copy and paste the code 2. (30 points) At time t=0, when the engine of a
Please do not use for and while loops
Please copy and paste the code

2. (30 points) At time t=0, when the engine of a missile stops, it has reached an altitude of 400 m and is rising at a velocity of 250 m/s. At this point, gravity takes over. The height (m) of the rocket as a function of time (s) is h(t) = -4.9t2 + 250t + 400 for t > 0 Construct a table that displays two columns, time (t) and height (h) of the rocket using a MATLAB script or M file called missile.m (a) Create a vector t for time from 0 to 30 seconds in 2.5 second increments. (b) Create the corresponding vector h for height, which is computed from t with the above formula. (c) Construct a matrix called table from t and h, with t as first column and h as second. (d) Display the table using fprintf with the appropriate column headings and title. Indicate units in the column headings. Once you've created the M file, open a new live script and write in the following commands before executing (run all) the live script and saving to PDF. Make sure all vectors/matrices t, h, table are displayed during execution. Upload PDF to WTClass Exam. %NAME, PROBLEM, DATE type missile.m missile
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
