[petsc-users] 2nd order time-stepping in PETSc
Matthew Knepley
knepley at gmail.com
Wed May 26 16:58:57 CDT 2010
On Wed, May 26, 2010 at 11:33 PM, Hong Zhang <hzhang at mcs.anl.gov> wrote:
> Mark:
>
> You need convert your equation into 1st order ODEs and use petsc
> TS method (see examples under ~petsc/src/ts/examples/ ),
> or use petsc KSP/SNES method with your own time step control.
>
> Hong
>
> > I am a new user of PETSC and I have a hopefully not too embarassing
> > question. I am trying to integrate and timestep the 3D acoustic wave
> > equation:
> >
> > u_tt = ( c2 ) * LAPLACIAN( u )
> >
> > Does any of the timestepping operators in PETSc work with a second-order
> > derivative with the one above? Normally, I would just expand u_tt as a
> > finite difference approximation using Leapfrog (or CN or RK ...) and
> > explicitly solve for the u field at timestep n+1. However I would like
> to
> > use the vector-matrix formulation in PETSc -my goal is to be able to
> solve
> > the acoustic wave equation explicitly or implicitly (the user would
> decide
> > with a command-line option).
>
>
It sounds like you could formulate it to solve for timestep n+1, and then
the RHS
would depend on timestep n (which PETSc would give you), and timestep n-1.
You
could save t^{n-1} yourself with a custom Monitor and get it in your RHS
function
through the user context.
Matt
> > Thanks,
> > Mark
> >
> > --
> > Mark Patrick Cheeseman
> >
> > Research Scientist
> > KSL (KAUST Supercomputing Laboratory)
> > Building 1, Office #126
> > King Abdullah University of Science & Technology
> > Thuwal 23955-6900
> > Kingdom of Saudi Arabia
> >
> > EMAIL : mark.cheeseman at kaust.edu.sa
> > PHONE : +966 (2) 808 0221 (office)
> > +966 (54) 470 1082 (mobile)
> > SKYPE : mark.patrick.cheeseman
> >
>
--
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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20100527/996e80c8/attachment.htm>
More information about the petsc-users
mailing list