[petsc-users] Way to remove zero entries from an assembled matrix

Leidy Catherine Ramirez Villalba leidy-catherine.ramirez-villalba at ec-nantes.fr
Tue Dec 6 11:25:23 CST 2016


Hello PETSc team: 

I'm doing the parallelization of the assembling of a system, previously assembled in a serial way (manual), but solved using PETSc in parallel. 
Therefore I have the old assembled matrix to compare with the one assembled with PETSc. 

While doing the assembling of the matrix, I avoid the zero entries using the option 'MAT_IGNORE_ZERO_ENTRIES' in MatSetOption, however the final matrix has zero values (or almost) due to the addition of non zero elements. 
Below the example of added values: 

1664 i 1663 j -165509.423650377 
1664 i 1663 j 165509.423650377 
1664 i 1663 j -165509.423650377 
1664 i 1663 j 165509.423650377 

Due to this difference between the two matrices I'm not able to get the solution for the matrix assembled with petsc. 

Therefore I wonder if there is a way to remove zero entries from an assembled matrix, or which solver to use so that zeros will not be a problem. 

Thanks in advance, 
Catherine 




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20161206/a5ddb29e/attachment-0001.html>


More information about the petsc-users mailing list