[petsc-users] Poisson problem with boundaries inside the domain

Mani Chandra mc0710 at gmail.com
Mon Oct 30 11:37:16 CDT 2017


Thanks!  f[j][i] = u[j][i] - ub did it. It even works with the automated
Jacobian assembly.

On Mon, Oct 30, 2017 at 9:28 PM, Smith, Barry F. <bsmith at mcs.anl.gov> wrote:

>
>    If you using DMDA then you can't just "remove" some grid points from
> the vector.
>
>    What you need to do is for your function evaluation at these interior
> grid points do f[j][i] = u[j][i] - ub in the FormFunction (ub is the
> Dirichlet value) and put a 1 one the diagonal of that row of the Jacobian
> (and nothing off diagonal).
>
>   Barry
>
> > On Oct 30, 2017, at 10:49 AM, Mani Chandra <mc0710 at gmail.com> wrote:
> >
> > Hello,
> >
> > I'm trying to solve the Poisson problem but with Dirichlet boundaries
> inside the domain (in addition to those imposed in the ghost zones). I'm
> using DMDA to create a structured grid and SNES coupled to this DMDA to
> solve the problem.
> >
> > The issue is that SNES doesn't converge when I impose Dirichlet boundary
> values inside the domain. I tried setting the residual corresponding to
> these internal points to zero but that isn't helping. Is there a right way
> to approach this problem? I just want to tell SNES to remove the chosen
> internal grid points from the solver iterations.
> >
> > Thanks,
> > Mani
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20171030/dae97955/attachment.html>


More information about the petsc-users mailing list