2.1. Introduction

The ARKODE infrastructure provides adaptive-step time integration modules for stiff, nonstiff and mixed stiff/nonstiff systems of ordinary differential equations (ODEs). ARKODE itself is structured to support a wide range of one-step (but multi-stage) methods, allowing for rapid development of parallel implementations of state-of-the-art time integration methods. At present, ARKODE is packaged with four time-stepping modules, ARKStep, ERKStep, SPRKStep, and MRIStep.

ARKStep supports ODE systems posed in split, linearly-implicit form,

(2.1)\[M(t)\, \dot{y} = f^E(t,y) + f^I(t,y), \qquad y(t_0) = y_0,\]

where \(t\) is the independent variable, \(y\) is the set of dependent variables (in \(\mathbb{R}^N\)), \(M\) is a user-specified, nonsingular operator from \(\mathbb{R}^N\) to \(\mathbb{R}^N\), and the right-hand side function is partitioned into up to two components:

  • \(f^E(t,y)\) contains the “nonstiff” time scale components to be integrated explicitly, and

  • \(f^I(t,y)\) contains the “stiff” time scale components to be integrated implicitly.

Either of these operators may be disabled, allowing for fully explicit, fully implicit, or combination implicit-explicit (ImEx) time integration.

The algorithms used in ARKStep are adaptive- and fixed-step additive Runge–Kutta methods. Such methods are defined through combining two complementary Runge–Kutta methods: one explicit (ERK) and the other diagonally implicit (DIRK). Through appropriately partitioning the ODE right-hand side into explicit and implicit components (2.1), such methods have the potential to enable accurate and efficient time integration of stiff, nonstiff, and mixed stiff/nonstiff systems of ordinary differential equations. A key feature allowing for high efficiency of these methods is that only the components in \(f^I(t,y)\) must be solved implicitly, allowing for splittings tuned for use with optimal implicit solver algorithms.

This framework allows for significant freedom over the constitutive methods used for each component, and ARKODE is packaged with a wide array of built-in methods for use. These built-in Butcher tables include adaptive explicit methods of orders 2-9, adaptive implicit methods of orders 2-5, and adaptive ImEx methods of orders 2-5.

ERKStep focuses specifically on problems posed in explicit form,

(2.2)\[\dot{y} = f(t,y), \qquad y(t_0) = y_0.\]

allowing for increased computational efficiency and memory savings. The algorithms used in ERKStep are adaptive- and fixed-step explicit Runge–Kutta methods. As with ARKStep, the ERKStep module is packaged with adaptive explicit methods of orders 2-9.

SPRKStep focuses on Hamiltonian systems posed in the form,

\[H(t, p, q) = T(t, p) + V(t, q)\]
(2.3)\[\dot{p} = f_1(t,q) = \frac{\partial V(t,q)}{\partial q}, \quad \dot{q} = f_2(t,p) = \frac{\partial T(t,p)}{\partial p},\]

allowing for conservation of quadratic invariants.

MRIStep focuses specifically on problems posed in additive form,

(2.4)\[\dot{y} = f^E(t,y) + f^I(t,y) + f^F(t,y), \qquad y(t_0) = y_0.\]

where here the right-hand side function is additively split into three components:

  • \(f^E(t,y)\) contains the “slow-nonstiff” components of the system (this will be integrated using an explicit method and a large time step \(h^S\)),

  • \(f^I(t,y)\) contains the “slow-stiff” components of the system (this will be integrated using an implicit method and a large time step \(h^S\)), and

  • \(f^F(t,y)\) contains the “fast” components of the system (this will be integrated using a possibly different method than the slow time scale and a small time step \(h^F \ll h^S\)).

For such problems, MRIStep provides fixed-step slow step multirate infinitesimal step (MIS), multirate infinitesimal GARK (MRI-GARK), and implicit-explicit MRI-GARK (IMEX-MRI-GARK) methods, allowing for evolution of the problem (2.4) using multirate methods having orders of accuracy 2-4.

For ARKStep or MRIStep problems that include nonzero implicit term \(f^I(t,y)\), the resulting implicit system (assumed nonlinear, unless specified otherwise) is solved approximately at each integration step, using a SUNNonlinearSolver module, supplied either by the user or from the underlying SUNDIALS infrastructure. For nonlinear solver algorithms that internally require a linear solver, ARKODE may use a variety of SUNLinearSolver modules provided with SUNDIALS, or again may utilize a user-supplied module.

2.1.1. Changes to SUNDIALS in release 6.1.0

Major Features

Created shared user interface functions for ARKODE to allow more uniform control over time-stepping algorithms, improved extensibility, and simplified code maintenance. The corresponding stepper-specific user-callable functions are now deprecated and will be removed in a future major release.

Added CMake infrastructure that enables externally maintained addons/plugins to be optionally built with SUNDIALS. See Contributing for details.

New Features and Enhancements

Added support for Kokkos Kernels v4.

Added the following Runge-Kutta Butcher tables

  • ARKODE_FORWARD_EULER_1_1

  • ARKODE_RALSTON_EULER_2_1_2

  • ARKODE_EXPLICIT_MIDPOINT_EULER_2_1_2

  • ARKODE_BACKWARD_EULER_1_1

  • ARKODE_IMPLICIT_MIDPOINT_1_2

  • ARKODE_IMPLICIT_TRAPEZOIDAL_2_2

Added the following MRI coupling tables

  • ARKODE_MRI_GARK_FORWARD_EULER

  • ARKODE_MRI_GARK_RALSTON2

  • ARKODE_MRI_GARK_RALSTON3

  • ARKODE_MRI_GARK_BACKWARD_EULER

  • ARKODE_MRI_GARK_IMPLICIT_MIDPOINT

  • ARKODE_IMEX_MRI_GARK_EULER

  • ARKODE_IMEX_MRI_GARK_TRAPEZOIDAL

  • ARKODE_IMEX_MRI_GARK_MIDPOINT

Added ARKodeButcherTable_ERKIDToName() and ARKodeButcherTable_DIRKIDToName() to convert a Butcher table ID to a string representation.

Added the function ARKodeSetAutonomous() in ARKODE to indicate that the implicit right-hand side function does not explicitly depend on time. When using the trivial predictor, an autonomous problem may reuse implicit function evaluations across stage solves to reduce the total number of function evaluations.

Users may now disable interpolated output in ARKODE by passing ARK_INTERP_NONE to ARKodeSetInterpolantType(). When interpolation is disabled, rootfinding is not supported, implicit methods must use the trivial predictor (the default option), and interpolation at stop times cannot be used (interpolating at stop times is disabled by default). With interpolation disabled, calling ARKodeEvolve() in ARK_NORMAL mode will return at or past the requested output time (setting a stop time may still be used to halt the integrator at a specific time). Disabling interpolation will reduce the memory footprint of an integrator by two or more state vectors (depending on the interpolant type and degree) which can be beneficial when interpolation is not needed e.g., when integrating to a final time without output in between or using an explicit fast time scale integrator with an MRI method.

Added “Resize” capability to ARKODE’s SPRKStep time-stepping module.

Enabled the Fortran interfaces to build with 32-bit sunindextype.

Bug Fixes

Updated the CMake variable HIP_PLATFORM default to amd as the previous default, hcc, is no longer recognized in ROCm 5.7.0 or newer. The new default is also valid in older version of ROCm (at least back to version 4.3.1).

Renamed the DPCPP value for the SUNDIALS_GINKGO_BACKENDS CMake option to SYCL to match Ginkgo’s updated naming convention.

Changed the CMake version compatibility mode for SUNDIALS to AnyNewerVersion instead of SameMajorVersion. This fixes the issue seen here.

Fixed a CMake bug that caused an MPI linking error for our C++ examples in some instances. Fixes GitHub Issue #464.

Fixed the runtime library installation path for windows systems. This fix changes the default library installation path from CMAKE_INSTALL_PREFIX/CMAKE_INSTALL_LIBDIR to CMAKE_INSTALL_PREFIX/CMAKE_INSTALL_BINDIR.

Fixed conflicting .lib files between shared and static libs when using MSVC on Windows

Fixed invalid SUNDIALS_EXPORT generated macro when building both shared and static libs.

Fixed a bug in some Fortran examples where c_null_ptr was passed as an argument to a function pointer instead of c_null_funptr. This caused compilation issues with the Cray Fortran compiler.

Fixed a bug in the HIP execution policies where WARP_SIZE would not be set with ROCm 6.0.0 or newer.

Fixed a bug that caused error messages to be cut off in some cases. Fixes GitHub Issue #461.

Fixed a memory leak when an error handler was added to a SUNContext. Fixes GitHub Issue #466.

Fixed a bug where MRIStepEvolve() would not handle a recoverable error produced from evolving the inner stepper.

Added missing SetRootDirection and SetNoInactiveRootWarn functions to ARKODE’s SPRKStep time-stepping module.

Fixed a bug in ARKodeSPRKTable_Create() where the coefficient arrays were not allocated.

Fix bug on LLP64 platforms (like Windows 64-bit) where KLU_INDEXTYPE could be 32 bits wide even if SUNDIALS_INT64_T is defined.

Check if size of SuiteSparse_long is 8 if the size of sunindextype is 8 when using KLU.

Fixed several build errors with the Fortran interfaces on Windows systems.

Deprecation Notices

Numerous ARKODE stepper-specific functions are now deprecated in favor of ARKODE-wide functions.

Deprecated the ARKStepSetOptimalParams function. Since this function does not have an ARKODE-wide equivalent, instructions have been added to the user guide for how to retain the current functionality using other user-callable functions.

The unsupported implementations of N_VGetArrayPointer and N_VSetArrayPointer for the hypre and PETSc vectors are now deprecated. Users should access the underlying wrapped external library vector objects instead with N_VGetVector_ParHyp and N_VGetVector_Petsc, respectively.

For changes in prior versions of SUNDIALS see §15.

2.1.2. Reading this User Guide

This user guide is a combination of general usage instructions and specific example programs. We expect that some readers will want to concentrate on the general instructions, while others will refer mostly to the examples, and the organization is intended to accommodate both styles.

The structure of this document is as follows:

2.1.3. SUNDIALS License and Notices

All SUNDIALS packages are released open source, under the BSD 3-Clause license for more details see the LICENSE and NOTICE files provided with all SUNDIALS packages.