For MATLAB Plot the following functions as assigned by your

For MATLAB: Plot the following functions as assigned by your instructor using subplots, choosing an appropriate lay out for the number of functions displayed. The independent variable(angle) should vary from 0 to 360 degrees.

(a) sin (u)

(b) 3sin(u)

(c) sin(3u)

(d) sin(u) - 3

(e) sin(u+90)

(f) 3sin(2u)-2

Plot all graphs on one plot

Solution

The following script can be used to plot the given functions. Matlab Script: u = 0:360; y1 = sin(u); y2 = 3*sin(u); y3 = sin(3*u); y4 = sin(u)-3; y5 = sin(u+90); y6 = 3*sin(2*u)-2; figure subplot(2,3,1) % add first plot in 2 x 3 grid plot(u,y1) title(\'Subplot 1\') subplot(2,3,2) % add second plot in 2 x 3 grid plot(u,y2,\'+\') % plot using + markers title(\'Subplot 2\') subplot(2,3,3) % add third plot in 2 x 3 grid plot(u,y3,\'o\') % plot using o markers title(\'Subplot 3\') subplot(2,3,4) % add fourth plot in 2 x 3 grid plot(u,y4,\'^\') % plot using ^ markers title(\'Subplot 4\') subplot(2,3,5) % add fifth plot in 2 x 3 grid plot(u,y5,\'>\') % plot using > markers title(\'Subplot 5\') subplot(2,3,6) % add sixth plot in 2 x 3 grid plot(u,y5,\'<\') % plot using < markers title(\'Subplot 6\')
For MATLAB: Plot the following functions as assigned by your instructor using subplots, choosing an appropriate lay out for the number of functions displayed. T

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site