function clock2 ( )

%% CLOCK2 plots a function that is the difference between minute and hour hand rotations.

  m = linspace ( 120, 180, 61 );
  f = mh_diff ( m );
  z = zeros ( size ( m ) );

  clf
  hold on
  plot ( m, f, 'r-', 'linewidth', 3 );
  plot ( m, z, 'k-', 'linewidth', 1 );
  hold off

  title ( 'Minute and Hour Hand rotations, between 2:00 and 3:00' )

  return
end

function value = mh_diff ( m )

  h = m / 60.0;
  ma = mod ( m / 60.0, 1.0 );
  ha = mod ( h / 12.0, 1.0 );

  value = ha - ma;

  return
end
