Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Hii please I need your help with the 3rd problem ONLY. It would also be very helpful if you can include comments whwn coming up
Hii please I need your help with the 3rd problem ONLY. It would also be very helpful if you can include comments whwn coming up with your code...PLEASE USE MATLAB ONLY. THANKS!!!
3) Develop a Matlab function to compute the velocity of a particular projectile v as a function of time t. In this problem, the velocity profile is described by a piecewise function, and is parameterized by 11 parameters, a, b, c, d. g. h, k, m, n, p, and q. as at-br 8rsi6 me-P)26 4. else. Your Matlab function must take as input the current time value and a vector of user arguments relating to particular values of the 11 paramaters, a, b, e. d, g. h k, m, . p, and q. So, for example, if your function name is vfinc, then your vfienc function must take as input a single value of time, say , and a vector of user arguments, say user, to yield a velocity value, say v; in this case, the function definition line of your Matlab file, where you define the function, would look like this: nction v functuser) By the way, you are not required to use the function or variable names used above; you are free to name these things how you wish. Test your function by writing a script which incorporates a for loop to step through each value of time in your time vector and calls the velocity profile function with Matlab built-in feval to compute the value of the velocity profile at each time value, one value of time at a time, for the following specific values Lab 2 ELEN 3320 of the 11 parameters (which you will then place into a vector of user parameter values and pass to your function via Matlab built-in feval): a 10, b-5, c 624, d 3. g 36, h 12, k-16, 2136, 0.1, p 26, and q 0. Plot your velocity profile with the above parameter values over time values ranging from -5 to 50 seconds; briefly discuss how you chose your time-step resolution. Add a title, axis labels, and otherwise present your plot in an informative, coherent form. Compare to a hand-generated plot to verify that your code works properly (it would only make sense for you to turn in both your hand-analysis plot and the Matlab plot with your solutions, righ?)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started