Question: 4. Write an m-file in MATLAB to do the following: i) ii) iii) iv) Ask user input for the angle theta (in degrees). Note

  image text in transcribed image text in transcribed 

4. Write an m-file in MATLAB to do the following: i) ii) iii) iv) Ask user input for the angle theta (in degrees). Note angle input on graph. Compute the following functions shown on the next page. Plot fl, f2, and f3 vs x all on the same figure. Use three different markers and colors to differentiate the curves. Include labels on x-axis and y-axis, a title, and a legend. Create a separate figure and plot fl vs x and f2, f3 vs x on subplots that are arranged vertically (i.e., 2 subplots with one above the other). Use the same markers and colors as above. Include labels for x-axis and y-axis, a title, and label curves by using the text command. f = x-2x+1 f = 3 cos(x+20) J = 3 exp(- 3x. Let x vary from 0 to 2. Turn in program and plots.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Ask user input for angle theta in degrees thetadeg inputEnter angle theta in degrees Convert ... View full answer

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 Programming Questions!