[petsc-users] Updating TS solution outside PETSc

Ellen M. Price ellen.price at cfa.harvard.edu
Thu Dec 5 10:00:11 CST 2019

Hi PETSc users,

I am working with a code that solves a set of PDEs on a rectangular
domain with Neumann boundary conditions. My understanding of
implementing the boundary condition is that I should set the boundary
value to be the value that makes the finite difference derivative go to
zero (or some other prescribed value) on that boundary.

I was attempting to update the solution from TS using a pre- or
post-step/stage function and TSGetSolution, but this does not appear to
work as expected. What would be the correct way to prescribe the
boundary condition, given that I'm using TSRK for timestepping and a
DMDA for discretization?

Looking forward to any help!

Ellen Price

More information about the petsc-users mailing list