Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
f355d6b2
Commit
f355d6b2
authored
Jan 04, 2012
by
andy
Browse files
ENH: Updated R utility: added compatibility BCs and converted to use postCalc
parent
b2cb1001
Changes
6
Hide whitespace changes
Inline
Side-by-side
applications/utilities/postProcessing/turbulence/R/Make/files
View file @
f355d6b2
R.C
compatibilityFvPatchFields/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchSymmTensorField.C
EXE = $(FOAM_APPBIN)/R
applications/utilities/postProcessing/turbulence/R/Make/options
View file @
f355d6b2
EXE_INC = \
-I$(LIB_SRC)/postProcessing/postCalc \
-I$(LIB_SRC)/turbulenceModels \
-I$(LIB_SRC)/turbulenceModels/incompressible/RAS/RASModel \
-I$(LIB_SRC)/transportModels \
-I$(LIB_SRC)/finiteVolume/lnInclude
EXE_LIBS = \
$(FOAM_LIBBIN)/postCalc.o \
-lincompressibleRASModels \
-lincompressibleTransportModels \
-lfiniteVolume \
...
...
applications/utilities/postProcessing/turbulence/R/R.C
View file @
f355d6b2
...
...
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011
-2012
OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
...
...
@@ -29,22 +29,17 @@ Description
\*---------------------------------------------------------------------------*/
#include
"calc.H"
#include
"fvCFD.H"
#include
"incompressible/singlePhaseTransportModel/singlePhaseTransportModel.H"
#include
"RASModel.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
int
main
(
int
argc
,
char
*
argv
[]
)
void
Foam
::
calc
(
const
argList
&
args
,
const
Time
&
runTime
,
const
fvMesh
&
mesh
)
{
#include
"setRootCase.H"
#include
"createTime.H"
#include
"createMesh.H"
#include
"createFields.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info
<<
"
\n
Calculating the Reynolds Stress R
\n
"
<<
endl
;
volSymmTensorField
R
...
...
@@ -63,8 +58,6 @@ int main(int argc, char *argv[])
R
.
write
();
Info
<<
"End"
<<
endl
;
return
0
;
}
...
...
applications/utilities/postProcessing/turbulence/R/compatibilityFvPatchFields/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchSymmTensorField.C
0 → 100644
View file @
f355d6b2
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
\*---------------------------------------------------------------------------*/
#include
"turbulentIntensityKineticEnergyInletFvPatchSymmTensorField.H"
#include
"addToRunTimeSelectionTable.H"
#include
"volFields.H"
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
fvPatch
&
p
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
iF
)
:
fixedValueFvPatchSymmTensorField
(
p
,
iF
)
{}
Foam
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
&
ptf
,
const
fvPatch
&
p
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
iF
,
const
fvPatchFieldMapper
&
mapper
)
:
fixedValueFvPatchSymmTensorField
(
ptf
,
p
,
iF
,
mapper
)
{}
Foam
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
fvPatch
&
p
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
iF
,
const
dictionary
&
dict
)
:
fixedValueFvPatchSymmTensorField
(
p
,
iF
)
{
fvPatchSymmTensorField
::
operator
=
(
symmTensorField
(
"value"
,
dict
,
p
.
size
()));
}
Foam
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
&
ptf
)
:
fixedValueFvPatchSymmTensorField
(
ptf
)
{}
Foam
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
&
ptf
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
iF
)
:
fixedValueFvPatchSymmTensorField
(
ptf
,
iF
)
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
void
Foam
::
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
::
write
(
Ostream
&
os
)
const
{
fvPatchSymmTensorField
::
write
(
os
);
writeEntry
(
"value"
,
os
);
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace
Foam
{
makePatchTypeField
(
fvPatchSymmTensorField
,
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
);
}
// ************************************************************************* //
applications/utilities/postProcessing/turbulence/R/compatibilityFvPatchFields/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchSymmTensorField.H
0 → 100644
View file @
f355d6b2
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
Class
Foam::turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
Description
Dummy version of turbulentIntensityKineticEnergyInlet patch type for
symmetric tensors provided for compatibility with R utility.
Value is given by a fixed-value condition.
SourceFiles
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField.C
\*---------------------------------------------------------------------------*/
#ifndef turbulentIntensityKineticEnergyInletFvPatchSymmTensorField_H
#define turbulentIntensityKineticEnergyInletFvPatchSymmTensorField_H
#include
"fixedValueFvPatchFields.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace
Foam
{
/*---------------------------------------------------------------------------*\
Class turbulentIntensityKineticEnergyInletFvPatchSymmTensorField Declaration
\*---------------------------------------------------------------------------*/
class
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
:
public
fixedValueFvPatchSymmTensorField
{
public:
//- Runtime type information
TypeName
(
"turbulentIntensityKineticEnergyInlet"
);
// Constructors
//- Construct from patch and internal field
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
fvPatch
&
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
);
//- Construct from patch, internal field and dictionary
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
fvPatch
&
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
,
const
dictionary
&
);
//- Construct by mapping given
// turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
// onto a new patch
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
&
,
const
fvPatch
&
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
,
const
fvPatchFieldMapper
&
);
//- Construct as copy
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
&
);
//- Construct and return a clone
virtual
tmp
<
fvPatchSymmTensorField
>
clone
()
const
{
return
tmp
<
fvPatchSymmTensorField
>
(
new
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
*
this
)
);
}
//- Construct as copy setting internal field reference
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
const
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
&
,
const
DimensionedField
<
symmTensor
,
volMesh
>&
);
//- Construct and return a clone setting internal field reference
virtual
tmp
<
fvPatchSymmTensorField
>
clone
(
const
DimensionedField
<
symmTensor
,
volMesh
>&
iF
)
const
{
return
tmp
<
fvPatchSymmTensorField
>
(
new
turbulentIntensityKineticEnergyInletFvPatchSymmTensorField
(
*
this
,
iF
)
);
}
// Member functions
//- Write
virtual
void
write
(
Ostream
&
)
const
;
};
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
}
// End namespace Foam
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#endif
// ************************************************************************* //
applications/utilities/postProcessing/turbulence/R/createFields.H
View file @
f355d6b2
...
...
@@ -12,7 +12,7 @@
mesh
);
#
include "createPhi.H"
#
include
"createPhi.H"
singlePhaseTransportModel
laminarTransport
(
U
,
phi
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment