Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

just write the codes and add any information you need! . Write an m-file in which you do the following Define the input parameters to

just write the codes and add any information you need! image text in transcribed
. Write an m-file in which you do the following Define the input parameters to be passed to your bounce.m function from the previous Homework assignment.(i.e. vo, thetao, CR, n, dt). Call bounce.m to calculate X, 2, and t vectors for the trajectory of a bouncing ball. Write data to an Excel file, bounce.xlsx, with the following properties: o Write the parameter values, along with headers, to a separate sheet named Parameters o Write the trajectory data, along with headers, to a separate sheet named Trajectory Trajectory data should be organized in three columns:t, X, and z. . Refer to the p-code for an illustration of how the Excel file should be formatted. A few suggestions fo writing to the Excel file. While there are multiple ways to write column headers and data, it may be simplest to perform two separate write operations for each data set: one for the headers, starting at cell A1, and one for the data, starting one row down at cell A2. MATLAB's xlswrite.mdoes not clear the contents of the file before performing a write, so if you change your parameters from one run to the next, such that the new trajectory is shorter, the file will still contain data from the end of the previously written trajectory. To avoid this potential problem, you can delete the file before writing to it by doing one of the following: delete bounce.xlsx; . or delete('bounce.xlsx'); or file - 'bounce.xlsx'; delete (file); When you submit your m-file, set the input parameters to: v0-5, theta0-50, CR-0.8, N-10, and dt=1/128. . Write an m-file in which you do the following Define the input parameters to be passed to your bounce.m function from the previous Homework assignment.(i.e. vo, thetao, CR, n, dt). Call bounce.m to calculate X, 2, and t vectors for the trajectory of a bouncing ball. Write data to an Excel file, bounce.xlsx, with the following properties: o Write the parameter values, along with headers, to a separate sheet named Parameters o Write the trajectory data, along with headers, to a separate sheet named Trajectory Trajectory data should be organized in three columns:t, X, and z. . Refer to the p-code for an illustration of how the Excel file should be formatted. A few suggestions fo writing to the Excel file. While there are multiple ways to write column headers and data, it may be simplest to perform two separate write operations for each data set: one for the headers, starting at cell A1, and one for the data, starting one row down at cell A2. MATLAB's xlswrite.mdoes not clear the contents of the file before performing a write, so if you change your parameters from one run to the next, such that the new trajectory is shorter, the file will still contain data from the end of the previously written trajectory. To avoid this potential problem, you can delete the file before writing to it by doing one of the following: delete bounce.xlsx; . or delete('bounce.xlsx'); or file - 'bounce.xlsx'; delete (file); When you submit your m-file, set the input parameters to: v0-5, theta0-50, CR-0.8, N-10, and dt=1/128

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Processing

Authors: David M. Kroenke

12th Edition International Edition

1292023422, 978-1292023427

More Books

Students also viewed these Databases questions