Replies: 1 comment 5 replies
-
@trilinos/tpetra |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
As I mentioned in an earlier question, I've started an attempt to port an old code from Epetra to Tpetra, since Epetra is being deprecated.
There are a couple uses of Epetra in the old code. In one, I'm doing the usual routing of assembling a global matrix for a linear finite element calculation: looping over elements "owned" by a processing element and summing their stiffness matrices into the global matrix. I do this in two steps, first assembling an
Epetra_FECrsGraph
by looping over the elements almost as if I were assembling the matrix proper (except not calculating the stiffness matrices), and second by constructing anEpetra_FECrsMatrix
from the graph and then looping over the elements again and summing their stiffness matrices into this matrix. (I think this was done in an example code from Didasko.)The other use was to generate an adjacency list from a list of elements and the nodes that belonged to each of them. Again, I was looping over elements "owned" by a processing element, and the process went much like the aforementioned assembly of the graph.
In both of these uses, I relied on
Epetra_FECrsGraph
having a dynamic profile. It was unclear to me how many nonzeros per row I needed, so I let the process of finite element assembly do it for me. Now, with the constructors of Tpetra'sCrsGraph
andFECrsGraph
all requiring upfront knowledge of the number of nonzeros (or something that entails that knowledge), the lack of a dynamic profile in Tpetra presents a problem.Are there known workarounds for this issue, or some sane straightforward way of finding the number of nonzeros that I hadn't thought of?
Tagging @trilinos/tpetra
Beta Was this translation helpful? Give feedback.
All reactions