M-File Programming For Subplotting: clc clear subplot(2,2,1) x=0:pi/1800:2*pi; y=sin(x); plot(x,y); title( 'Plot of sin(x)' ); grid subplot(2,2,2) x=0:pi/1800:2*pi; y=sin(x-2*pi/3) plot(x,y); title( 'Plot of sin(x-120)' ); grid subplot(2,2,3) x=0:pi/1800:2*pi; y=sin(x+2*pi/3) plot(x,y); title( 'Plot of sin(x-240)' ); grid (try it)
M-File Programming For Three-Phase Voltage: clc clear t=0:pi/1800:2*pi; v1=100*cos(t); plot(t,v1); grid hold on v2=100*cos(t-2*pi/3); plot(t,v2); v3=100*cos(t+2*pi/3); plot (t,v3); title( 'Plotting Three-Phase Voltage of v1(t), v2(t) and v3(t)' ) xlabel ( 'Time in seconds' ) ylabel ( 'Voltage in volts' ) text (6,6, 'v1(t)' ) text (3,4, 'v2(t)' ) text (1,1, 'v3(t)' )
(try it) Discussion: · Plotting figure is also called graphing figure in MATLAB. · In this programming, we can easily ...
Comments
Post a Comment