We are working on a general tool for adjoining PETSc-Code.
Thats right -- the problem here is, that we can not store the complete 
history ( -- not necessarily a time stepping history, but rather the 
history of all computations) due to memory bounds.

As a case study we have a code calling the snes-solve(). -- And no time 
stepping at all.

We want to skip storing all iteration steps etc. inside snes-solve() by 
exploiting exactly the fact that the solution is unique and satisfies 
f(x)=b.
For doing so, we need to solve a linear system with the transposed 
Jacobian matrix of that corresponding snes-solve() later on. So in fact 
we only need to be able to solve this linear system with the jacobian at 
some point X_new with the same solution method used in the original 
snes-solve(). I thought the handiest approach was to store the SNES-struct.

   Johannes

On 03/04/2013 06:11 PM, Barry Smith wrote:
> On Mar 4, 2013, at 10:43 AM, Jed Brown <jedbrown at mcs.anl.gov> wrote:
>
>> On Mon, Mar 4, 2013 at 10:36 AM, Barry Smith <bsmith at mcs.anl.gov> wrote:
>> So you save the solution at some time step. Then later in another part of 
>> the calculation, you time integrate the solution for a few time steps (from 
>> the saved time-step) to "fill in" the solution values you did not save, then 
>> you use the solutions for those several time steps, then you discard them.
>>
>>     So the question has nothing to do with SNES. It has to do with a "deep 
>> copy" of TS? Or being able to "restart" TS at a saved time step? 
>> Capabilities we want to build towards, but thinking in terms of a deep copy 
>> of SNES is a red herring.
>>
>> Indeed, but presumably Johannes is working with an application that uses 
>> SNES.
>     Why would he be doing that? Surely it is better to use a TS integrator in 
> PETSc rather than to roll your own? If we were missing a feature needed for 
> his integrator from TS then we would gladly add it.
>
>     Barry
>
>>   
>>
>>     So, assuming one is using a single time integrator (not changing the 
>> integration method for different times), shouldn't this already pretty much 
>> work?
>>
>> Yes, that's why I asked what sort of changes he was trying to guard against. 
>> Saving an entire copy of the SNES for each problem is wasteful when by far 
>> the most common case is to reuse configuration in each solve.
>

-- 
Dipl.-Ing. Johannes Lotz
LuFG Informatik 12 der RWTH Aachen
Software and Tools for Computational Engineering
Room 0.25, S?sterfeldstr. 65, D-52072 Aachen
Phone.: + 49 241 80 20127
mailto: lotz at stce.rwth-aachen.de http://www.stce.rwth-aachen.de

Reply via email to