From: Wolfgang Bangerth Date: Tue, 21 May 2024 22:19:58 +0000 (-0600) Subject: Minor updates to the IDA documentation and test cases. X-Git-Tag: v9.6.0-rc1~238^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bdbb1f0d62a49354f1979c9b950f66ec2639e76e;p=dealii.git Minor updates to the IDA documentation and test cases. --- diff --git a/include/deal.II/sundials/ida.h b/include/deal.II/sundials/ida.h index 0a392906bb..8dc48791aa 100644 --- a/include/deal.II/sundials/ida.h +++ b/include/deal.II/sundials/ida.h @@ -151,10 +151,10 @@ namespace SUNDIALS * \end{matrix} * \f] * - * That is $F(y', y, t) = y' + A y = 0 $ + * That is, $F(y', y, t) = y' + A y = 0 $ * where - * A = * \f[ + * A = * \begin{pmatrix} * 0 & -1 \\ * k^2 &0 @@ -206,8 +206,8 @@ namespace SUNDIALS * { * J = A; * - * J(0,0) = alpha; - * J(1,1) = alpha; + * J(0,0) += alpha; + * J(1,1) += alpha; * * Jinv.invert(J); * }; diff --git a/tests/sundials/ida_01.cc b/tests/sundials/ida_01.cc index afbf867508..1df9c52d70 100644 --- a/tests/sundials/ida_01.cc +++ b/tests/sundials/ida_01.cc @@ -30,7 +30,7 @@ * u (0) = 0 * u'(0) = k * - * write in terms of a first order ode: + * written in terms of a first order ode: * * y[0]' - y[1] = 0 * y[1]' + k^2 y[0] = 0 @@ -89,8 +89,8 @@ public: J = A; - J(0, 0) = alpha; - J(1, 1) = alpha; + J(0, 0) += alpha; + J(1, 1) += alpha; Jinv.invert(J); }; diff --git a/tests/sundials/ida_02.cc b/tests/sundials/ida_02.cc index 0af53390ab..ecc7882dea 100644 --- a/tests/sundials/ida_02.cc +++ b/tests/sundials/ida_02.cc @@ -33,7 +33,7 @@ * u (0) = 0 * u'(0) = k * - * write in terms of a first order ode: + * written in terms of a first order ode: * * y[0]' - y[1] = 0 * y[1]' + k^2 y[0] = 0 @@ -92,8 +92,8 @@ public: J = A; - J(0, 0) = alpha; - J(1, 1) = alpha; + J(0, 0) += alpha; + J(1, 1) += alpha; }; time_stepper.solve_with_jacobian =