Sandals  v0.0.0
A C++ library for ODEs/DAEs integration
Loading...
Searching...
No Matches
ImplicitEuler.hxx
Go to the documentation of this file.
1/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\
2 * Copyright (c) 2025, Davide Stocco and Enrico Bertolazzi. *
3 * *
4 * The Sandals project is distributed under the BSD 2-Clause License. *
5 * *
6 * Davide Stocco Enrico Bertolazzi *
7 * University of Trento University of Trento *
8 * e-mail: davide.stocco@unitn.it e-mail: enrico.bertolazzi@unitn.it *
9\* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
10
11#pragma once
12
13#ifndef SANDALS_IMPLICITEULER_HXX
14#define SANDALS_IMPLICITEULER_HXX
15
16namespace Sandals
17{
31 class ImplicitEulerTableau : public Tableau<1>
32 {
33 public:
34 using Tableau<1>::Type;
35 using Tableau<1>::Vector;
36 using Tableau<1>::Matrix;
37
42 this->name = "ImplicitEuler";
43 this->type = Type::IRK;
44 this->order = 1;
45 this->A << 1.0;
46 this->b << 1.0;
47 this->c << 1.0;
48 }
49 }; // class ImplicitEulerTableau
50
58 template <Integer N, Integer M = 0>
59 class ImplicitEuler : public RungeKutta<1, N, M>
60 {
61 public:
63
68
73 ImplicitEuler(System t_system) : RungeKutta<1, N, M>(ImplicitEulerTableau(), t_system) {}
74
75 }; // class ImplicitEuler
76
77} // namespace Sandals
78
79#endif // SANDALS_IMPLICITEULER_HXX
ImplicitEuler(System t_system)
Definition ImplicitEuler.hxx:73
typename Implicit< N, M >::Pointer System
Definition ImplicitEuler.hxx:62
ImplicitEuler()
Definition ImplicitEuler.hxx:67
Butcher tableau for the Implicit Euler method.
Definition ImplicitEuler.hxx:32
ImplicitEulerTableau()
Definition ImplicitEuler.hxx:41
std::shared_ptr< Implicit< N, M > > Pointer
Definition Implicit.hxx:42
RungeKutta(const RungeKutta &)=delete
The namespace for the Sandals library.
Definition Sandals.hh:73
Struct container for the Butcher tableau of a Runge-Kutta method.
Definition Tableau.hxx:36
enum class type :Integer {ERK=0, IRK=1, DIRK=2} Type
Definition Tableau.hxx:37
Eigen::Matrix< Real, S, S > Matrix
Definition Tableau.hxx:39
Integer order
Definition Tableau.hxx:43
Type type
Definition Tableau.hxx:42
Eigen::Vector< Real, S > Vector
Definition Tableau.hxx:38
Matrix A
Definition Tableau.hxx:45
std::string name
Definition Tableau.hxx:41
Vector b
Definition Tableau.hxx:46
Vector c
Definition Tableau.hxx:48