function c = r8mat_add ( m, n, alpha, a, beta, b )

%*****************************************************************************80
%
%% r8mat_add() computes C = alpha * A + beta * B for R8MAT's.
%
%  Discussion:
%
%    An R8MAT is an array of R8 values.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    01 December 2011
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    integer M, N, the number of rows and columns.
%
%    real ALPHA, the multiplier for A.
%
%    real A(M,N), the first matrix.
%
%    real BETA, the multiplier for A.
%
%    real B(M,N), the second matrix.
%
%  Output:
%
%    real C(M,N), the sum of alpha*A+beta*B.
%
  c(1:m,1:n) = alpha * a(1:m,1:n) + beta * b(1:m,1:n);

  return
end
