DMMG and DA
Barry Smith
bsmith at mcs.anl.gov
Wed Jun 14 13:21:24 CDT 2006
Christophe,
You should create two DA's with ONE dof; the first DA will be used
twice, to solve the first then the second system. The other DA will
be used to solve the third system. Then create two DMMG, one for the first
DA and one for the second.
On Wed, 14 Jun 2006, Christophe Picard wrote:
> Hello,
>
> I have been trying to used DMMG and DA in the following way.
> I have a DA with several degree of freedom, and several of them have the same
> jacobian but different RHS (what I want to do is solve Ax1=b1(x1,x,2,x3),
> Ax2=b2(x1,x2,x3)).
> So how does DMMGsolve handle that?
> Since x1,x2,x3 are DA variables, but I want to solve only x1 and x2 using the
> same Jacobian, I figured that I can have some kind of switch in the
> definition of the RHS function that will make the selection, and calling
> dmmgSolve several times, but by modifyng the switch trough DMMGSetUser and
> DMMGGetUser before each call. But then where the output of the solve
> operation is stored?
Call DMMGGetX() to get access to the solution vector.
> The way I understand
>it now is that it is overwritting
> x1. Am I right?
Yes,
> Is there a way to solve x1 and x2 simultaneously, I mean by only 1 call of
> dmmgSolve, and without solving x3?
No, you need to call DMMGSolve on the initial DA twice, once for the first
system (then call DMMGSetUser()) then for the second system.
Barry
>
> I hope I am not too confusing.
>
> Thank you,
>
> Christophe
> ---
>
>
>
More information about the petsc-users
mailing list