surfaceArrheniusReactionRateI.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2019-2021 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 \*---------------------------------------------------------------------------*/
25 
26 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
27 
29 (
30  const speciesTable& species,
31  const objectRegistry& ob,
32  const dictionary& dict
33 )
34 :
35  ArrheniusReactionRate(species, dict),
36  aName_(dict.lookup("a")),
37  aField_
38  (
40  )
41 {}
42 
43 
44 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
45 
47 {
49 }
50 
51 
53 {
55 }
56 
57 
58 inline Foam::scalar Foam::surfaceArrheniusReactionRate::operator()
59 (
60  const scalar p,
61  const scalar T,
62  const scalarField& c,
63  const label li
64 ) const
65 {
66  return ArrheniusReactionRate::operator()(p, T, c, li)*aField_[li];
67 }
68 
69 
71 (
72  const scalar p,
73  const scalar T,
74  const scalarField& c,
75  const label li
76 ) const
77 {
78  return ArrheniusReactionRate::ddT(p, T, c, li)*aField_[li];
79 }
80 
81 
83 {
85  writeEntry(os, "a", aName_);
86 }
87 
88 
89 inline Foam::Ostream& Foam::operator<<
90 (
91  Ostream& os,
93 )
94 {
95  arr.write(os);
96  return os;
97 }
98 
99 
100 // ************************************************************************* //
void postEvaluate() const
Post-evaluation hook.
virtual Ostream & write(const char)=0
Write character.
void write(Ostream &os) const
Write to stream.
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:156
scalar ddT(const scalar p, const scalar T, const scalarField &c, const label li) const
The derivative of the rate w.r.t. temperature.
void preEvaluate() const
Pre-evaluation hook.
void postEvaluate() const
Post-evaluation hook.
void preEvaluate() const
Pre-evaluation hook.
scalar ddT(const scalar p, const scalar T, const scalarField &c, const label li) const
Evaluate the derivative.
const Type & lookupObject(const word &name) const
Lookup and return the object of the given Type.
const dimensionedScalar c
Speed of light in a vacuum.
surfaceArrheniusReactionRate(const speciesTable &species, const objectRegistry &ob, const dictionary &dict)
Construct from dictionary.
A modified Arrhenius reaction rate given by:
scalar operator()(const scalar p, const scalar T, const scalarField &c, const label li) const
Return the rate.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Definition: Ostream.H:54
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
void writeEntry(Ostream &os, const HashTable< T, Key, Hash > &ht)
Definition: HashTableIO.C:96
A wordList with hashed indices for faster lookup by name.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
Arrhenius reaction rate given by:
volScalarField & p
Registry of regIOobjects.
void write(Ostream &os) const
Write to stream.
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
Definition: dictionary.C:864