':param i: a row in *M*
:type i: user or item id
:param j: a row in *M*
:type j: user or item id
:returns: the similarity between the two elements *i* and *j*'

def similarity(self, i, j):

    if ((not self.get_matrix_similarity()) or (self.get_matrix_similarity().get() is None)):
        self.compute()
    return self.get_matrix_similarity().value(i, j)
