checked for higher dimension, there is some discrepancy with the way data was generated, as in the error threshold for which Matlab converges is higher than the error in the vector with which the data was generated