[petsc-users] Matrix is missing diagonal entry

Orxan Shibliyev orxan.shibli at gmail.com
Wed Jan 21 17:06:14 CST 2015

I am solving Ax=b with KSP. I set the matrix (A) so that from first row to
a certain row (row N) I used negative indices (see below). I got an error
indicating that the matrix is missing diagonal entry at 0 (zero). Does this
mean that negative indexing is not working so that the row zero points to
the actual first row which has negative index? Should not the rows with
negative indices be ignored? In case, I checked the first row without
negative index (row N) and its diagonal entry is not zero anyway.

A =
| negative index   |
| "                         |
| "                         |
| "                         |
| non-zero value  | --> row N
| non-zero value  |
| "                         |
| ...                       |
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20150121/ad2dc253/attachment.html>

More information about the petsc-users mailing list