Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor updates to the ARKode documentation. #15247

Merged
merged 1 commit into from
May 23, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
19 changes: 11 additions & 8 deletions include/deal.II/sundials/arkode.h
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ namespace SUNDIALS
* -k^2 &0
* \end{pmatrix}
* \f]
* and $y(0)=(0, k)$.
* and $y(0)=(0, k)^T$.
*
* The exact solution is $y_0(t) = \sin(k t)$, $y_1(t) = y_0'(t) = k \cos(k
*t)$, $y_1'(t) = -k^2 \sin(k t)$.
Expand All @@ -306,22 +306,25 @@ namespace SUNDIALS
*
* SUNDIALS::ARKode<VectorType> ode;
*
* const double kappa = 1.0;
* const double k = 1.0;
*
* ode.explicit_function = [kappa] (double,
* const VectorType &y,
* VectorType &ydot) -> int
* ode.explicit_function = [k] (const double / * time * /,
* const VectorType &y,
* VectorType &ydot)
* {
* ydot[0] = y[1];
* ydot[1] = -kappa*kappa*y[0];
* return 0;
* ydot[1] = -k*k*y[0];
* };
*
* Vector<double> y(2);
* y[1] = kappa;
* y[1] = k;
*
* ode.solve_ode(y);
* @endcode
*
* In practice, you would of course at least want to set the end time up
* to which the time integrator should run. In the example code shown here,
* it is taken from the default value defined by ARKode::AdditionalData.
*/
template <typename VectorType = Vector<double>>
class ARKode
Expand Down