initial commit for version 1.6.x patch release
[OpenFOAM-1.6.x.git] / src / thermophysicalModels / radiation / submodels / absorptionEmissionModel / binaryAbsorptionEmission / binaryAbsorptionEmission.C
blob5cc3ac9b27a4582e0b35edbf26b0be858ea74509
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 1991-2009 OpenCFD Ltd.
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
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 the
13     Free Software Foundation; either version 2 of the License, or (at your
14     option) any later version.
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.
21     You should have received a copy of the GNU General Public License
22     along with OpenFOAM; if not, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 \*---------------------------------------------------------------------------*/
27 #include "binaryAbsorptionEmission.H"
28 #include "addToRunTimeSelectionTable.H"
30 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
32 namespace Foam
34     namespace radiation
35     {
36         defineTypeNameAndDebug(binaryAbsorptionEmission, 0);
38         addToRunTimeSelectionTable
39         (
40             absorptionEmissionModel,
41             binaryAbsorptionEmission,
42             dictionary
43         );
44     }
48 // * * * * * * * * * * * * * * * * Constructors  * * * * * * * * * * * * * * //
50 Foam::radiation::binaryAbsorptionEmission::binaryAbsorptionEmission
52     const dictionary& dict,
53     const fvMesh& mesh
56     absorptionEmissionModel(dict, mesh),
57     coeffsDict_(dict.subDict(typeName + "Coeffs")),
58     model1_
59     (
60         absorptionEmissionModel::New(coeffsDict_.subDict("model1"), mesh)
61     ),
62     model2_
63     (
64         absorptionEmissionModel::New(coeffsDict_.subDict("model2"), mesh)
65     )
69 // * * * * * * * * * * * * * * * * Destructor  * * * * * * * * * * * * * * * //
71 Foam::radiation::binaryAbsorptionEmission::~binaryAbsorptionEmission()
75 // * * * * * * * * * * * * * * * Member Functions  * * * * * * * * * * * * * //
77 Foam::tmp<Foam::volScalarField>
78 Foam::radiation::binaryAbsorptionEmission::aCont(const label bandI) const
80     return model1_->aCont(bandI) + model2_->aCont(bandI);
84 Foam::tmp<Foam::volScalarField>
85 Foam::radiation::binaryAbsorptionEmission::aDisp(const label bandI) const
87     return model1_->aDisp(bandI) + model2_->aDisp(bandI);
91 Foam::tmp<Foam::volScalarField>
92 Foam::radiation::binaryAbsorptionEmission::eCont(const label bandI) const
94     return model1_->eCont(bandI) + model2_->eCont(bandI);
98 Foam::tmp<Foam::volScalarField>
99 Foam::radiation::binaryAbsorptionEmission::eDisp(const label bandI) const
101     return model1_->eDisp(bandI) + model2_->eDisp(bandI);
105 Foam::tmp<Foam::volScalarField>
106 Foam::radiation::binaryAbsorptionEmission::ECont(const label bandI) const
108     return model1_->ECont(bandI) + model2_->ECont(bandI);
112 Foam::tmp<Foam::volScalarField>
113 Foam::radiation::binaryAbsorptionEmission::EDisp(const label bandI) const
115     return model1_->EDisp(bandI) + model2_->EDisp(bandI);
119 // ************************************************************************* //