[petsc-users] projection methods in TS

Barry Smith bsmith at mcs.anl.gov
Sat Feb 4 19:49:11 CST 2017


> On Feb 4, 2017, at 7:24 PM, Zhang, Hong <hongzhang at anl.gov> wrote:
> 
> Can you elaborate a bit more on your problem?
> 
> If your problem is an index-1 DAE, there is no need to use a projection method, and it is perfectly fine to set it up as a DAE in PETSc. For high-index DAEs, you may have to use TSSetPostStep() to implement your own projection algorithm.
> 
> If you happen to have a Hamiltonian system to solve, I have a symplectic solver in my own branch that you can use directly.

   Why has this not been moved into master? Feature branches that linger outside of master end up being a pain.

> 
> Hong (Mr.)
> 
>> On Feb 4, 2017, at 9:47 AM, Gideon Simpson <gideon.simpson at gmail.com> wrote:
>> 
>> Would setting it up as a DAE in petsc be algorithmically euivalent to a projected method (i.e., step of standard RK followed by nonlinear projection)?
>> 
>> -gideon
>> 
>>> On Feb 3, 2017, at 11:47 PM, Matthew Knepley <knepley at gmail.com> wrote:
>>> 
>>> That is one answer. Another one is that this particular system is a DAE and we have methods for that.
>>> 
>>>    Matt
>>> 
>>> On Fri, Feb 3, 2017 at 8:40 PM, Barry Smith <bsmith at mcs.anl.gov> wrote:
>>> 
>>> TSSetPostStep(); in your function use TSGetSolution() to get the current solution.
>>> 
>>>   Please let us know how it works out
>>> 
>>>    Barry
>>> 
>>> 
>>> 
>>> > On Feb 3, 2017, at 7:14 PM, Gideon Simpson <gideon.simpson at gmail.com> wrote:
>>> >
>>> > I’m interested in implementing a projection method for an ODE of the form:
>>> >
>>> > y’ = f(y),
>>> >
>>> > such that g(y) = 0 for all time (i.e., g is conserved).  Note that in a projection method, a standard time step is made to produce y* from y_{n}, and then this is corrected to obtain y_{n+1} satisfying g(y) = 0.
>>> >
>>> > There were two ways I was thinking of doing this, and I was hoping to get some input:
>>> >
>>> > Idea 1: Manually loop through using taking a time step and then implementing the projection routine.  I see that there is a TSStep command, but this doesn’t  seem to be much documentation on how to use it in this scenario.  Does anyone have any guidance?
>>> >
>>> > Idea 2: Is there some analog to TSMonitor that allows me to modify the solution after each time step, instead of just allowing for some computation of a statistic?
>>> >
>>> >
>>> 
>>> 
>>> 
>>> 
>>> -- 
>>> What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.
>>> -- Norbert Wiener
>> 
> 



More information about the petsc-users mailing list