3.4.4. Using the SPRKStep time-stepping module

This chapter is concerned with the use of the SPRKStep time-stepping module for the solution of initial value problems (IVPs) of the form (3.13) in a C or C++ language setting. The following sections discuss the header files and the layout of the user’s main program, and provide descriptions of the SPRKStep user-callable functions and user-supplied functions.

The example programs located in the source code examples/arkode folder, may be helpful as templates for new codes. In particular,

  • examples/arkode/C_serial/ark_harmonic_symplectic.c

  • examples/arkode/C_serial/ark_damped_harmonic_symplectic.c, and

  • examples/arkode/C_serial/ark_kepler.c

demonstrate SPRKStep usage.

SPRKStep uses the input and output constants from the shared ARKODE infrastructure. These are defined as needed in this chapter, but for convenience the full list is provided separately in §3.7.

The relevant information on using SPRKStep’s C and C++ interfaces is detailed in the following subsections.