fixed an error in setMatrixValue() where the regex ignored negative signs