On Tue, 30 Sep 2008, Adam Arbree wrote:
> I have an application where I need to solve three nearly identical systems.
> For each system, the matrix entries and the rhs will be slightly different,
> but the mesh and finite element type and degree will be identical. I have
> three questions: 1) I would like to reuse the DofMap between each of these
> systems to save memory (and any other memory that is possible, I am not sure
> what the overhead per system is);
We'd like to make that an option, but it's not currently possible in
the library, and because of the way our data is distributed (the
DofMap mostly just manipulates info stored on DofObjects) it might be
tricky to change the data structures to make those savings. I don't
see an easy way to do it without requiring API changes (to make
DofObject::dof_number require a DofMap reference, at least).
Ben was looking at how to save some time and memory for duplicate
variables in the same system, though, which has similar difficulties,
so maybe he's had some ideas. In any case it's not going to be an
available feature in the near term.
> can I specify an initial guess for the solution when using an iterative
> solver so that I can use the solution of one system as the initial guess for
> the another.
Yes; the current solution vector is the initial guess for us; just
copy system1.solution to system2.solution.