x_data = [ 0, 1 ];
y_data = exp ( x_data );

x = linspace ( -0.5, 1.5, 101 );
y = exp ( x );
y2 = y_data(1) * ( x_data(2) - x ) / ( x_data(2) - x_data(1) ) ...
   + y_data(2) * ( x - x_data(1) ) / ( x_data(2) - x_data(1) );
plot ( x, y, 'b-', ...
       x, y2, 'r-', ...
       x_data, y_data, 'k.', 'markersize', 25 )
print ( '-dpng', 'exp_linear.png' );
