DA Jacobian
Matthew Knepley
knepley at gmail.com
Sat Dec 9 11:49:29 CST 2006
ADIC is not able to be freely distributed. You must contact the developers.
Matt
On 12/9/06, Jianing Shi <js2615 at columbia.edu> wrote:
> I just added PETSC_HAVE_ADIC, and seems that the compiler does not
> complain any more.
>
> #if defined(PETSC_HAVE_ADIC)
> if (adicmf_jacobian)
> {
> ierr =
> DASetLocalAdicMFFunction(user.da,admf_FormFunctionLocal);CHKERRQ(ierr);
> ierr = MatRegisterDAAD();CHKERRQ(ierr);
> ierr = MatCreateDAAD(user.da,&A);CHKERRQ(ierr);
> ierr = MatDAADSetSNES(A,snes);CHKERRQ(ierr);
> ierr = MatDAADSetCtx(A,&user);CHKERRQ(ierr);
> }
> #endif
>
> Though what is the trick if I really want to use ADIC?
>
> Jianing
>
> Quoting Matthew Knepley <knepley at gmail.com>:
>
> > Are you really using ADIC?
> >
> > Matt
> >
> > On 12/9/06, Jianing Shi <js2615 at columbia.edu> wrote:
> > > I have a question about creating the jacobian here.
> > > Here is the code I use to create it.
> > >
> > > -------------------------------------------------------
> > > ierr = DAGetMatrix(user.da,MATAIJ,&J);CHKERRQ(ierr);
> > > A = J;
> > >
> > > ierr =
> > >
> >
> DASetLocalAdicMFFunction(user.da,admf_FormFunctionLocal);CHKERRQ(ierr);
> > > ierr = MatRegisterDAAD();CHKERRQ(ierr);
> > > ierr = MatCreateDAAD(user.da,&A);CHKERRQ(ierr);
> > > ierr = MatDAADSetSNES(A,snes);CHKERRQ(ierr);
> > > ierr = MatDAADSetCtx(A,&user);CHKERRQ(ierr);
> > > ------------------------------------------------------
> > >
> > > I included the head files
> > > petscsnes.h petscda.h
> > >
> > > When I compile it, I got the following linking error:
> > >
> > > ld: Undefined symbols:
> > > _MatCreateDAAD
> > > _MatDAADSetCtx
> > > _MatDAADSetSNES
> > > _MatRegisterDAAD
> > > make: [paraImplicitV1] Error 1 (ignored)
> > >
> > > Not sure what went wrong.
> > >
> > > Jianing
> > >
> > >
> >
> >
> > --
> > "Failure has a thousand explanations. Success doesn't need one"
> > -- Sir
> > Alec Guiness
> >
> >
>
>
>
--
"Failure has a thousand explanations. Success doesn't need one" -- Sir
Alec Guiness
More information about the petsc-users
mailing list