analytical.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2011-2017 OpenFOAM Foundation
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 Class
27  Foam::integrationSchemes::analytical
28 
29 Description
30  Analytical integration scheme
31 
32  \f[
33  \Delta \phi = (A - B \phi^n) \frac{1}{B} (1 - e^{- B \Delta t})
34  \f]
35 
36 \*---------------------------------------------------------------------------*/
37 
38 #ifndef analytical_H
39 #define analytical_H
40 
41 #include "integrationScheme.H"
42 
43 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
44 
45 namespace Foam
46 {
47 namespace integrationSchemes
48 {
49 
50 /*---------------------------------------------------------------------------*\
51  Class analytical Declaration
52 \*---------------------------------------------------------------------------*/
53 
54 class analytical
55 :
56  public integrationScheme
57 {
58 public:
59 
60  //- Runtime type information
61  TypeName("analytical");
62 
63 
64  // Constructors
65 
66  //- Construct
67  analytical();
68 
69  //- Construct and return clone
70  virtual autoPtr<integrationScheme> clone() const
71  {
72  return autoPtr<integrationScheme>(new analytical(*this));
73  }
74 
75 
76  //- Destructor
77  virtual ~analytical();
78 
79 
80  // Member Functions
81 
82  //- Return the integration effective time step
83  virtual scalar dtEff(const scalar dt, const scalar Beta) const;
84 
85  //- Return the integral of the effective time step
86  virtual scalar sumDtEff(const scalar dt, const scalar Beta) const;
87 };
88 
89 
90 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
91 
92 } // End namespace integrationSchemes
93 } // End namespace Foam
94 
95 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
96 
97 #endif
98 
99 // ************************************************************************* //
Foam::integrationSchemes::analytical
Analytical integration scheme.
Definition: analytical.H:53
Foam::integrationSchemes::analytical::~analytical
virtual ~analytical()
Destructor.
Definition: analytical.C:50
Foam::integrationScheme
Base for a set of schemes which integrate simple ODEs which arise from semi-implcit rate expressions.
Definition: integrationScheme.H:90
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::integrationSchemes::analytical::dtEff
virtual scalar dtEff(const scalar dt, const scalar Beta) const
Return the integration effective time step.
Definition: analytical.C:57
Foam::autoPtr
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: HashPtrTable.H:53
Foam::integrationSchemes::analytical::analytical
analytical()
Construct.
Definition: analytical.C:44
Foam::integrationSchemes::analytical::TypeName
TypeName("analytical")
Runtime type information.
integrationScheme.H
Foam::integrationSchemes::analytical::clone
virtual autoPtr< integrationScheme > clone() const
Construct and return clone.
Definition: analytical.H:69
Foam::integrationSchemes::analytical::sumDtEff
virtual scalar sumDtEff(const scalar dt, const scalar Beta) const
Return the integral of the effective time step.
Definition: analytical.C:70