On Mon, Mar 18, 2013 at 2:34 PM, Mengda Wu <wumengda at gmail.com> wrote:
> Hi all, > > I would like to solve a system Ax=b multiple times, with A and b stay > the same from time to time. The difference among each time is that a set of > DOFs in x are fixed and others are free to be solved. And the set of DOFs > to be fixed/ solved varies from time to time. I know I can assemble A each > time and move the set of fixed DOFs to the rhs. But I don't want to do this > because the size of A is changing. > > Is there a simpler and more automated way to deal with this issue? > You should assemble a separate system for each "active" set. This is the simplest and fastest method. You can create the system using MatGetSubMatrix() if you don't want to call your assembly routines each time. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20130318/c88d5250/attachment.html>
