function value = r8_divide_i4 ( i, j )

%*****************************************************************************80
%
%% r8_divide_i4() returns an I4 fraction as an R8.
%
%  Discussion:
%
%    In MATLAB, this function doesn't really serve any purpose.
%
%    Given integer variables I and J, both FORTRAN and C will evaluate 
%    an expression such as "I/J" using what is called "integer division",
%    with the result being an integer.  It is often convenient to express
%    the parts of a fraction as integers but expect the result to be computed
%    using real arithmetic.  This function carries out that operation.
%
%       I     J   I/J  R8_DIVIDE_I4(I,J
%
%       1     2     0  0.5
%       7     4     1  1.75
%       8     4     2  2.00
%       9     4     2  2.25
%
%  Licensing:
%
%    This code is distributed under the MIT license. 
%
%  Modified:
%
%    05 June 2012
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    integer I, J, the numerator and denominator.
%
%  Output:
%
%    real VALUE, the value of (I/J).
%
  value = i / j;

  return
end
