

The code snippet is written to display 2 different sine waves on one common plane sharing a single pair of axes. This can be achieved in a single command as shown in the example given below. Presenting multiple sine waves with a common axisĭisplaying multiple sine waves sharing one set of the common axis is also supported by MATLAB. The second sinusoidal wave with an amplitude of 10 and an angular frequency of 5 is generated in the second cell of the layout.ġ. The first sinusoidal wave is generated in the first cell of the layout with an amplitude of 5 and an angular frequency of 3. The resultant graph contains two different sinusoidal plots created in the same layout. The below code is developed to generate 2 sin waves having values for amplitude as 5 and 10 respectively and angular frequency as 3 and 5 respectively. The feature of generating the multiple numbers of sinusoidal plots with different pairs of axes in the same layout using a single command can be applied using ‘subplot’. Generating multiple sine wave plots with different pair of axes The plot is customized by inserting values for xlabel and ylabel and title of the plot. The resultant sine wave is displayed for the time duration of 0 to 10000 attaining the peak amplitude +1 in the first half cycle and -1 in the second half cycle having linear frequency 10. Plot(t,st), xlabel('time-axis'), ylabel('st'), title('Sine wave'),
