[petsc-users] MAT_COPY_VALUES not allowed for unassembled matrix

baikadi pranay pranayreddy865 at gmail.com
Sat Oct 10 04:31:31 CDT 2020


Hello,
I am using the MatDuplicate routine so that I use the Jacobian matrix as a
preconditioning matrix as well. However, I get the error "MAT_COPY_VALUES
not allowed for unassembled matrix". The exact command I use is the
following:
*call MatDuplicate(jac,MAT_COPY_VALUES,prec,ierr)*
I am attaching you the error output in a text file for your reference.
Could you please let me know how to solve this problem?.
Thank you in advance.
Best Regards,
Pranay.

ᐧ
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20201010/72fe9887/attachment.html>
-------------- next part --------------
[0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------
[0]PETSC ERROR: Object is in wrong state
[0]PETSC ERROR: MAT_COPY_VALUES not allowed for unassembled matrix
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.11.1, Apr, 12, 2019 
[0]PETSC ERROR: ./a.out on a linux-gnu-c-debug named cg17-6.agave.rc.asu.edu by pbaikadi Sat Oct 10 02:25:11 2020
[0]PETSC ERROR: Configure options 
[0]PETSC ERROR: #1 MatDuplicate() line 4606 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/mat/interface/matrix.c
[0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------
[0]PETSC ERROR: Object is in wrong state
[0]PETSC ERROR: Not for unassembled matrix
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.11.1, Apr, 12, 2019 
[0]PETSC ERROR: ./a.out on a linux-gnu-c-debug named cg17-6.agave.rc.asu.edu by pbaikadi Sat Oct 10 02:25:11 2020
[0]PETSC ERROR: Configure options 
[0]PETSC ERROR: #2 MatGetOrdering() line 180 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/mat/order/sorder.c
[0]PETSC ERROR: #3 PCSetUp_ILU() line 134 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/ksp/pc/impls/factor/ilu/ilu.c
[0]PETSC ERROR: #4 PCSetUp() line 932 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/ksp/pc/interface/precon.c
[0]PETSC ERROR: #5 KSPSetUp() line 391 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/ksp/ksp/interface/itfunc.c
[0]PETSC ERROR: #6 KSPSolve() line 725 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/ksp/ksp/interface/itfunc.c
[0]PETSC ERROR: #7 SNESSolve_NEWTONLS() line 225 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/snes/impls/ls/ls.c
[0]PETSC ERROR: #8 SNESSolve() line 4560 in /packages/7x/petsc/3.11.1/petsc-3.11.1/src/snes/interface/snes.c


More information about the petsc-users mailing list