% example3.m
% Plot exp(-x/2) sin(10x) over 0 <= x <= 3
%
%  Set the data pairs.
%
xlist = linspace ( 0.0, 3.0, 201 );
ylist = exp ( - xlist / 2 ) .* sin ( 10.0 * xlist );
%
%  Clear the screen.
%
clf
%
%  Draw with a GREEN (g) LINES (-).
%
plot ( xlist, ylist, 'g-', 'LineWidth', 5 );
%
%  Allow us to add more plots to same picture.
%
hold on
%
%  Add BLACK (k) DASHED LINES (--) from (-2,0) to (3,0).
%
plot ( [ 0.0, 3.0], [0.0, 0.0], 'k--' );
%
%  We are done adding to our plot.
%
hold off
%
%  Add grid, title, labels.
%
grid on
title ( 'Example 3, 201 data points.', 'FontSize', 24 );
xlabel ( '<-- X -->' );
ylabel ( '<-- Y -->' );
%
%  Make x and y scale the same.
%
axis equal
%
%  Save a JPG copy of the plot.
%
print ( '-djpeg', 'example3.jpg' );