is_symmetric

openpnm.utils.misc.is_symmetric(a, rtol=1e-10)[source]

Is a a symmetric matrix?

Parameters
  • a (ndarray or sparse matrix) – Object to check for being a symmetric matrix.

  • rtol (float) – Relative tolerance with respect to the smallest entry in a that is used to determine if a is symmetric.

Returns

True if a is a symmetric matrix, False otherwise.

Return type

bool