function error_frobenius = r8mat_is_symmetric ( m, n, a )

%*****************************************************************************80
%
%% R8MAT_IS_SYMMETRIC checks a real matrix for symmetry.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    13 April 2017
%
%  Author:
%
%    John Burkardt
%
%  Parameters:
%
%    Input, integer M, N, the number of rows and columns of A.
%
%    Input, real A(M,N), the matrix.
%
%    Output, real ERROR_FROBENIUS, measures the Frobenius norm of ( A - A' ).
%
  if ( ~ r8mat_is_square ( m, n, a ) )
    error_frobenius = Inf;
    return
  end

  error_frobenius = sqrt ( sum ( sum ( ( abs ( a - a' ) ).^2 ) ) );

  return
end
