New answers tagged

4

Certainly. There are a few things you have to define for your type that are listed on this page in the documentation: https://eigen.tuxfamily.org/dox/TopicCustomizing_CustomScalar.html It basically boils down to defining arithmetic operators appropriately for your type, plus specializing a traits template NumTraits that describes your type. The link above ...


1

I would recommend Chapter 8 in Sparse Matrix Technology, by Sergio Pissanetzky, 1984. He shows how the element-node connectivity array, once put into a sparse matrix format, can be used to generate the node-node connectivity. This connectivity is the sparse matrix indices for a finite element method. This connectivity can be used to initialize the sparse ...


1

Start with a matrix that only stores those entries you have explicitly written something nonzero to. For example (not particularly efficient, but feasible), you could do class SparseMatrix { using std::pair<int,int> ij_coordinates; std::map<ij_coordinates,double> entries; ... }; Initially, there are no entries, but as you add ones, the ...


1

The sparsity is going to depend on your choice of basis functions and the way you mesh the geometry of the problem you pick. If the basis is trilinear quadrilaterals on the cube meshing a cube that's 15x15x10, that gives one structure, if the domain is L-shaped, that gives something else. If you know all three aspects: element type, underlying domain, and ...


Top 50 recent answers are included