mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' of /home/dm4/OpenFOAM/OpenFOAM-dev
This commit is contained in:
@ -41,6 +41,7 @@ Description
|
||||
#include "tetrahedron.H"
|
||||
#include "FixedList.H"
|
||||
#include "polyMeshTetDecomposition.H"
|
||||
#include "particleMacros.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
@ -284,7 +285,7 @@ public:
|
||||
TypeName("particle");
|
||||
|
||||
//- String representation of properties
|
||||
static string propHeader;
|
||||
DefinePropertyList("(Px Py Pz) cellI tetFaceI tetPtI origProc origId");
|
||||
|
||||
//- Cumulative particle counter - used to provode unique ID
|
||||
static label particleCount_;
|
||||
@ -554,13 +555,7 @@ public:
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#include "particleI.H"
|
||||
/*
|
||||
#define defineParticleTypeNameAndDebug(Type, DebugSwitch) \
|
||||
template<> \
|
||||
const Foam::word Particle<Type>::typeName(#Type); \
|
||||
template<> \
|
||||
int Particle<Type>::debug(Foam::debug::debugSwitch(#Type, DebugSwitch));
|
||||
*/
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#ifdef NoRepository
|
||||
|
||||
@ -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,8 +29,7 @@ License
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
Foam::string Foam::particle::propHeader =
|
||||
"(Px Py Pz) cellI tetFaceI tetPtI origProc origId";
|
||||
Foam::string Foam::particle::propertyList_ = Foam::particle::propertyList();
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
68
src/lagrangian/basic/particle/particleMacros.H
Normal file
68
src/lagrangian/basic/particle/particleMacros.H
Normal file
@ -0,0 +1,68 @@
|
||||
/*---------------------------------------------------------------------------*\
|
||||
========= |
|
||||
\\ / 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/>.
|
||||
|
||||
InClass
|
||||
Foam::particle
|
||||
|
||||
Description
|
||||
Macros for adding to particle property lists
|
||||
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#ifndef particleMacros_H
|
||||
#define particleMacros_H
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
namespace Foam
|
||||
{
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#define DefinePropertyList(str) \
|
||||
\
|
||||
static string propertyList_; \
|
||||
\
|
||||
static string propertyList() \
|
||||
{ \
|
||||
return str; \
|
||||
}
|
||||
|
||||
|
||||
#define AddToPropertyList(ParcelType, str) \
|
||||
\
|
||||
static string propertyList_; \
|
||||
\
|
||||
static string propertyList() \
|
||||
{ \
|
||||
return ParcelType::propertyList() + str; \
|
||||
}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
} // End namespace Foam
|
||||
|
||||
#endif
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -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
|
||||
@ -66,7 +66,7 @@ Ostream& operator<<
|
||||
);
|
||||
|
||||
/*---------------------------------------------------------------------------*\
|
||||
Class CollidingParcel Declaration
|
||||
Class CollidingParcel Declaration
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
template<class ParcelType>
|
||||
@ -86,12 +86,22 @@ public:
|
||||
|
||||
// Static data members
|
||||
|
||||
//- String representation of properties
|
||||
static string propHeader;
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("CollidingParcel");
|
||||
|
||||
//- String representation of properties
|
||||
AddToPropertyList
|
||||
(
|
||||
ParcelType,
|
||||
" collisionRecordsPairAccessed"
|
||||
+ " collisionRecordsPairOrigProcOfOther"
|
||||
+ " collisionRecordsPairOrigIdOfOther"
|
||||
+ " (collisionRecordsPairData)"
|
||||
+ " collisionRecordsWallAccessed"
|
||||
+ " collisionRecordsWallPRel"
|
||||
+ " (collisionRecordsWallData)"
|
||||
);
|
||||
|
||||
|
||||
// Constructors
|
||||
|
||||
|
||||
@ -30,15 +30,8 @@ License
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
template<class ParcelType>
|
||||
Foam::string Foam::CollidingParcel<ParcelType>::propHeader =
|
||||
ParcelType::propHeader
|
||||
+ " collisionRecordsPairAccessed"
|
||||
+ " collisionRecordsPairOrigProcOfOther"
|
||||
+ " collisionRecordsPairOrigIdOfOther"
|
||||
+ " (collisionRecordsPairData)"
|
||||
+ " collisionRecordsWallAccessed"
|
||||
+ " collisionRecordsWallPRel"
|
||||
+ " (collisionRecordsWallData)";
|
||||
Foam::string Foam::CollidingParcel<ParcelType>::propertyList_ =
|
||||
Foam::CollidingParcel<ParcelType>::propertyList();
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
@ -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
|
||||
@ -319,12 +319,28 @@ public:
|
||||
|
||||
// Static data members
|
||||
|
||||
//- String representation of properties
|
||||
static string propHeader;
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("KinematicParcel");
|
||||
|
||||
//- String representation of properties
|
||||
AddToPropertyList
|
||||
(
|
||||
ParcelType,
|
||||
" active"
|
||||
+ " typeId"
|
||||
+ " nParticle"
|
||||
+ " d"
|
||||
+ " dTarget "
|
||||
+ " (Ux Uy Uz)"
|
||||
+ " (fx fy fz)"
|
||||
+ " (angularMomentumx angularMomentumy angularMomentumz)"
|
||||
+ " (torquex torquey torquez)"
|
||||
+ " rho"
|
||||
+ " age"
|
||||
+ " tTurb"
|
||||
+ " (UTurbx UTurby UTurbz)"
|
||||
);
|
||||
|
||||
|
||||
// Constructors
|
||||
|
||||
|
||||
@ -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
|
||||
@ -31,21 +31,8 @@ License
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
template<class ParcelType>
|
||||
Foam::string Foam::KinematicParcel<ParcelType>::propHeader =
|
||||
ParcelType::propHeader
|
||||
+ " active"
|
||||
+ " typeId"
|
||||
+ " nParticle"
|
||||
+ " d"
|
||||
+ " dTarget "
|
||||
+ " (Ux Uy Uz)"
|
||||
+ " (fx fy fz)"
|
||||
+ " (angularMomentumx angularMomentumy angularMomentumz)"
|
||||
+ " (torquex torquey torquez)"
|
||||
+ " rho"
|
||||
+ " age"
|
||||
+ " tTurb"
|
||||
+ " (UTurbx UTurby UTurbz)";
|
||||
Foam::string Foam::KinematicParcel<ParcelType>::propertyList_ =
|
||||
Foam::KinematicParcel<ParcelType>::propertyList();
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
|
||||
@ -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
|
||||
@ -239,12 +239,18 @@ public:
|
||||
|
||||
// Static data members
|
||||
|
||||
//- String representation of properties
|
||||
static string propHeader;
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("ReactingMultiphaseParcel");
|
||||
|
||||
//- String representation of properties
|
||||
AddToPropertyList
|
||||
(
|
||||
ParcelType,
|
||||
" nGas(Y1..YN)"
|
||||
+ " nLiquid(Y1..YN)"
|
||||
+ " nSolid(Y1..YN)"
|
||||
);
|
||||
|
||||
|
||||
// Constructors
|
||||
|
||||
|
||||
@ -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,11 +29,8 @@ License
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
template<class ParcelType>
|
||||
Foam::string Foam::ReactingMultiphaseParcel<ParcelType>::propHeader =
|
||||
ParcelType::propHeader
|
||||
+ " nGas(Y1..YN)"
|
||||
+ " nLiquid(Y1..YN)"
|
||||
+ " nSolid(Y1..YN)";
|
||||
Foam::string Foam::ReactingMultiphaseParcel<ParcelType>::propertyList_ =
|
||||
Foam::ReactingMultiphaseParcel<ParcelType>::propertyList();
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
@ -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
|
||||
@ -239,12 +239,17 @@ public:
|
||||
|
||||
// Static data members
|
||||
|
||||
//- String representation of properties
|
||||
static string propHeader;
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("ReactingParcel");
|
||||
|
||||
//- String representation of properties
|
||||
AddToPropertyList
|
||||
(
|
||||
ParcelType,
|
||||
" mass0"
|
||||
+ " nPhases(Y1..YN)"
|
||||
);
|
||||
|
||||
|
||||
// Constructors
|
||||
|
||||
|
||||
@ -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,10 +29,8 @@ License
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
template<class ParcelType>
|
||||
Foam::string Foam::ReactingParcel<ParcelType>::propHeader =
|
||||
ParcelType::propHeader
|
||||
+ " mass0"
|
||||
+ " nPhases(Y1..YN)";
|
||||
Foam::string Foam::ReactingParcel<ParcelType>::propertyList_ =
|
||||
Foam::ReactingParcel<ParcelType>::propertyList();
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
@ -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
|
||||
@ -264,12 +264,17 @@ public:
|
||||
|
||||
// Static data members
|
||||
|
||||
//- String representation of properties
|
||||
static string propHeader;
|
||||
|
||||
//- Runtime type information
|
||||
TypeName("ThermoParcel");
|
||||
|
||||
//- String representation of properties
|
||||
AddToPropertyList
|
||||
(
|
||||
ParcelType,
|
||||
" T"
|
||||
+ " Cp"
|
||||
);
|
||||
|
||||
|
||||
// Constructors
|
||||
|
||||
|
||||
@ -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,10 +29,8 @@ License
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
template<class ParcelType>
|
||||
Foam::string Foam::ThermoParcel<ParcelType>::propHeader =
|
||||
ParcelType::propHeader
|
||||
+ " T"
|
||||
+ " Cp";
|
||||
Foam::string Foam::ThermoParcel<ParcelType>::propertyList_ =
|
||||
Foam::ThermoParcel<ParcelType>::propertyList();
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||
|
||||
@ -115,7 +115,7 @@ void Foam::PatchPostProcessing<CloudType>::write()
|
||||
labelList indices;
|
||||
sortedOrder(globalTimes, indices);
|
||||
|
||||
string header("# Time currentProc " + parcelType::propHeader);
|
||||
string header("# Time currentProc " + parcelType::propertyList_);
|
||||
patchOutFile<< header.c_str() << nl;
|
||||
|
||||
forAll(globalTimes, i)
|
||||
|
||||
Reference in New Issue
Block a user