'NDimArray instances can be compared to each other.
Instances equal if they have same shape and data.
Examples
>>> from sympy import MutableDenseNDimArray
>>> a = MutableDenseNDimArray.zeros(2, 3)
>>> b = MutableDenseNDimArray.zeros(2, 3)
>>> a == b
True
>>> c = a.reshape(3, 2)
>>> c == b
False
>>> a[0,0] = 1
>>> b[0,0] = 2
>>> a == b
False'

def __eq__(self, other):

    if (not isinstance(other, NDimArray)):
        return False
    return ((self.shape == other.shape) and (list(self) == list(other)))
