When we plot a sine function or a Gaussian modulated sine function in Matlab, the plotted picture in a Matlab window would be very smooth. In another word, if you magnify the picture, it will still be a smooth curve. However, if we save the picture as a png file, the picture will have step-like oscillations or squiggles (See all figures in this question).
Using fellowing code, a Gaussian intensity modulated sine function is plotted.
close ('all')
omega=1; % frequency
T=2*pi/omega; % period
width=2*T; % Full width at half maximum
tstep=T/1000; % time step
t1=-6*T+tstep:tstep:6*T; % time range -6T to 6T
A1=sin(omega*t1).*exp(-2*log(2)*t1.^2/width.^2); % Gaussian intensity modulated sine pulse
% which different from the Gaussian amplitude modulation by a factor of 2
y1=exp(-2*log(2)*t1.^2/width.^2); % Gaussian intensity envelope
hold on
plot(t1/(2*pi),A1,'r','linewidth',2)
plot(t1/(2*pi),y1,'b','linewidth',2)
box on
set(get(gca,'XLabel'),'FontSize',12);
set(get(gca,'YLabel'),'FontSize',12);
set(get(gca,'Yaxis'),'FontSize',12);
set(gca,'FontSize',12,'LineWidth',2);
set(get(gca,'Xaxis'),'FontSize',12);
xlabel('t/2\pi')
ylabel('E(t)')
legend('E(t)','Envelope')