From: Nikhil V. <nik...@gm...> - 2018-09-07 07:26:29
|
I am trying to make some manipulations to sparse matrices. I have a function that sets some pre-determined entries in a sparse matrix to a pre-determined value. I have multiple sparse matrices to which I apply this procedure. None of the said sparse matrices contain non-zero elements at (0,0) before the modification. Yet during the modification, only one of the many sparse matrices gives me the following error message: [0]PETSC ERROR: Argument out of range [0]PETSC ERROR: New nonzero at (0,0) caused a malloc Use MatSetOption(A, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_FALSE) to turn off this check I cannot understand the reason for this behaviour. Best, Nikhil |