[petsc-dev] TS max_steps and max_time

Lisandro Dalcin dalcinl at gmail.com
Sat Mar 20 15:09:47 CDT 2010


On 20 March 2010 14:32, Jed Brown <jed at 59a2.org> wrote:
> On Fri, 19 Mar 2010 17:09:05 -0200, Lisandro Dalcin <dalcinl at gmail.com> wrote:
>> Jed, just a wild idea (after some Python scripting with THETA and GL
>> reproducing ROBER and CE from ex8.c)...
>
> It would be cool, and significantly easier from the Python side, to
> implement a suite of stiff ODE and DAE.  This is a start for
> low-dimensional systems.
>
>  http://pitagora.dm.uniba.it/~testset/
>

I'll take a look...

>> Would it make sense that, by default, max_steps and max_time be set to
>> the maximum possible value, i.e max_steps=PETSC_MAX_INT and
>> max_time=PETSC_MAX?
>
> I don't know, why do you say this?
>

Because I find particularly annoying to call TSSetDuration having to
pass both max_steps and max_time... depending on the problem, all I
want is to just pass one of them, and do not bother with the other...
Because of this, I've implemented separate calls for these to limits
in petsc4py:

http://code.google.com/p/petsc4py/source/browse/src/PETSc/TS.pyx#244

Despite of this, I still have to:

1) To loop a fixed number of time steps, call setMaxSteps(max_steps)
AND also call  setMaxTime(arbitrarily_large_final_time)
2) To loop up to a final time, pass setMaxTime(max_time) AND and
setMaxSteps(arbitrarily_large_number_of_steps).



-- 
Lisandro Dalcin
---------------
Centro Internacional de Métodos Computacionales en Ingeniería (CIMEC)
Instituto de Desarrollo Tecnológico para la Industria Química (INTEC)
Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET)
PTLC - Güemes 3450, (3000) Santa Fe, Argentina
Tel/Fax: +54-(0)342-451.1594



More information about the petsc-dev mailing list