Re: [petsc-users] PetscFEIntegrateBdResidual_Basic

2017-11-21 Thread Matthew Knepley
On Mon, Nov 20, 2017 at 7:19 PM, David Fuentes wrote: > Sorry, If I call this AddBoundary Twice with different markers/ids, the > bcFunc seems to be applied to set values for DM_BC_ESSENTIAL not > DM_BC_NATURAL? > > Can I callierr = PetscDSSetBdResidual(prob, 0, f0_bd_u, f1_bd_zero) > twice t

Re: [petsc-users] PetscFEIntegrateBdResidual_Basic

2017-11-20 Thread David Fuentes
Sorry, If I call this AddBoundary Twice with different markers/ids, the bcFunc seems to be applied to set values for DM_BC_ESSENTIAL not DM_BC_NATURAL? Can I callierr = PetscDSSetBdResidual(prob, 0, f0_bd_u, f1_bd_zero) twice to set the f0 functions different for each boundary ? /*@C Petsc

Re: [petsc-users] PetscFEIntegrateBdResidual_Basic

2017-11-20 Thread David Fuentes
Thanks! will give that a try! df On Mon, Nov 20, 2017 at 11:23 AM, Matthew Knepley wrote: > On Mon, Nov 20, 2017 at 12:20 PM, David Fuentes > wrote: > >> Thanks for the quick reply. Indeed it does work like this. I have added a >> location dependence on the boundary to differentiate the two. Ho

Re: [petsc-users] PetscFEIntegrateBdResidual_Basic

2017-11-20 Thread Matthew Knepley
On Mon, Nov 20, 2017 at 12:20 PM, David Fuentes wrote: > Thanks for the quick reply. Indeed it does work like this. I have added a > location dependence on the boundary to differentiate the two. However, when > my mesh moves then the BC will be applied incorrectly. > I don't think you should hav

Re: [petsc-users] PetscFEIntegrateBdResidual_Basic

2017-11-20 Thread David Fuentes
Thanks for the quick reply. Indeed it does work like this. I have added a location dependence on the boundary to differentiate the two. However, when my mesh moves then the BC will be applied incorrectly. *// PetscFEIntegrateBdResidual_Basic DMPlexComputeBdResidual_Internal* *static* *void** f0_

Re: [petsc-users] PetscFEIntegrateBdResidual_Basic

2017-11-20 Thread Matthew Knepley
On Mon, Nov 20, 2017 at 11:46 AM, David Fuentes wrote: > *Is there a way to pass the boundary set id to the function pointers for > the residual evaluation on the boundary ?* > > *https://bitbucket.org/petsc/petsc/src/d89bd21cf2b5366df29efb6006298d2bc22fb509/src/dm/dt/interface/dtfe.c?at=master&f

[petsc-users] PetscFEIntegrateBdResidual_Basic

2017-11-20 Thread David Fuentes
*Is there a way to pass the boundary set id to the function pointers for the residual evaluation on the boundary ?* *https://bitbucket.org/petsc/petsc/src/d89bd21cf2b5366df29efb6006298d2bc22fb509/src/dm/dt/interface/dtfe.c?at=master&fileviewer=file-view-default#dtfe.c-4245