'Allows to set items to MutableDenseNDimArray.
Examples
>>> from sympy import MutableSparseNDimArray
>>> a = MutableSparseNDimArray.zeros(2, 2)
>>> a[0, 0] = 1
>>> a[1, 1] = 1
>>> a
[[1, 0], [0, 1]]'

def __setitem__(self, index, value):

    index = self._parse_index(index)
    if (not isinstance(value, MutableNDimArray)):
        value = _sympify(value)
    if isinstance(value, NDimArray):
        return NotImplementedError
    if ((value == 0) and (index in self._sparse_array)):
        self._sparse_array.pop(index)
    else:
        self._sparse_array[index] = value
