[petsc-users] How to efficiently assemble this matrix?

Italo Tasso bichinhoverde at spwinternet.com.br
Thu Jul 17 06:35:54 CDT 2014


I have two matrices: matrix A is 4n x 4n and matrix C is n x n. I want to
set the values of A using the values of C, like this:

A[4i+k][4j+k] = C[i][j]
0 < i < n
0 < j < n
0 < k < 3

How can I do this efficiently?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20140717/b13dd52d/attachment.html>


More information about the petsc-users mailing list