Merge branch 'master' into testLoop/MartinBeaudoin
Conflicts: CMakeLists.txt testHarness/OpenFOAM/1.6-ext/CMakeFiles/CMakeLists.txt
This commit is contained in:
commit
43799e411b
64 changed files with 789 additions and 252 deletions
|
@ -1,10 +1,10 @@
|
||||||
#/*---------------------------------------------------------------------------*\
|
# /*-------------------------------------------------------------------------*\
|
||||||
# ========= |
|
# ========= |
|
||||||
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
# \\ / O peration |
|
# \\ / O peration |
|
||||||
# \\ / A nd | Copyright held by original author
|
# \\ / A nd | Copyright held by original author
|
||||||
# \\/ M anipulation |
|
# \\/ M anipulation |
|
||||||
# -------------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
# License
|
# License
|
||||||
# This file is part of OpenFOAM.
|
# This file is part of OpenFOAM.
|
||||||
#
|
#
|
||||||
|
@ -23,17 +23,17 @@
|
||||||
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# CMakeLists.txt file for implementing a test harness for the compilation
|
# CMakeLists.txt file for implementing a test harness for the compilation
|
||||||
# and test of OpenFOAM-1.5-dev using Kitware CTest./CMake/CDash
|
# and test of OpenFOAM-1.5-dev using Kitware CTest./CMake/CDash
|
||||||
#
|
#
|
||||||
# The results will be submitted to the CDash server identified by the file
|
# The results will be submitted to the CDash server identified by the file
|
||||||
# CTestConfig.cmake
|
# CTestConfig.cmake
|
||||||
#
|
#
|
||||||
# Author
|
# Author
|
||||||
# Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved
|
# Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
# \*---------------------------------------------------------------------------*/
|
# \*-------------------------------------------------------------------------*/
|
||||||
|
|
||||||
cmake_minimum_required (VERSION 2.8)
|
cmake_minimum_required (VERSION 2.8)
|
||||||
|
|
||||||
|
|
|
@ -71,13 +71,12 @@ fi
|
||||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
export WM_PROJECT_INST_DIR=$FOAM_INST_DIR
|
export WM_PROJECT_INST_DIR=$FOAM_INST_DIR
|
||||||
export WM_PROJECT_DIR=$WM_PROJECT_INST_DIR/$WM_PROJECT-$WM_PROJECT_VERSION
|
export WM_PROJECT_DIR=$WM_PROJECT_INST_DIR/$WM_PROJECT-$WM_PROJECT_VERSION
|
||||||
export WM_PROJECT_USER_DIR=$HOME/$WM_PROJECT/$USER-$WM_PROJECT_VERSION
|
: ${WM_PROJECT_USER_DIR:=$HOME/$WM_PROJECT/$USER-$WM_PROJECT_VERSION}; export WM_PROJECT_USER_DIR
|
||||||
|
|
||||||
|
|
||||||
# Location of third-party software
|
# Location of third-party software
|
||||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
export WM_THIRD_PARTY_DIR=$WM_PROJECT_INST_DIR/ThirdParty-$WM_PROJECT_VERSION
|
: ${WM_THIRD_PARTY_DIR=$WM_PROJECT_INST_DIR/ThirdParty-$WM_PROJECT_VERSION}; export WM_THIRD_PARTY_DIR
|
||||||
|
|
||||||
|
|
||||||
# Operating System/Platform
|
# Operating System/Platform
|
||||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
@ -95,7 +94,7 @@ export WM_COMPILER_LIB_ARCH=
|
||||||
|
|
||||||
# Compilation options (architecture, precision, optimised, debug or profiling)
|
# Compilation options (architecture, precision, optimised, debug or profiling)
|
||||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
export WM_NCOMPPROCS=2
|
: ${WM_NCOMPPROCS:=2}; export WM_NCOMPPROCS
|
||||||
|
|
||||||
# WM_ARCH_OPTION = 32 | 64
|
# WM_ARCH_OPTION = 32 | 64
|
||||||
: ${WM_ARCH_OPTION:=64}; export WM_ARCH_OPTION
|
: ${WM_ARCH_OPTION:=64}; export WM_ARCH_OPTION
|
||||||
|
|
|
@ -32,11 +32,18 @@ License
|
||||||
Foam::tensor Foam::RodriguesRotation
|
Foam::tensor Foam::RodriguesRotation
|
||||||
(
|
(
|
||||||
const vector& rotationAxis,
|
const vector& rotationAxis,
|
||||||
const scalar& rotationAngle
|
const scalar& rotationAngle,
|
||||||
|
const bool inDegrees
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
tensor rotTensor;
|
tensor rotTensor;
|
||||||
scalar theta = rotationAngle*mathematicalConstant::pi/180.0;
|
scalar theta = rotationAngle;
|
||||||
|
|
||||||
|
if (inDegrees)
|
||||||
|
{
|
||||||
|
theta *= mathematicalConstant::pi/180.0;
|
||||||
|
}
|
||||||
|
|
||||||
scalar sinTheta = sin(theta);
|
scalar sinTheta = sin(theta);
|
||||||
scalar cosTheta = cos(theta);
|
scalar cosTheta = cos(theta);
|
||||||
scalar oneMinusCosTheta = 1.0 - cosTheta;
|
scalar oneMinusCosTheta = 1.0 - cosTheta;
|
||||||
|
|
|
@ -53,7 +53,8 @@ namespace Foam
|
||||||
tensor RodriguesRotation
|
tensor RodriguesRotation
|
||||||
(
|
(
|
||||||
const vector& rotationAxis,
|
const vector& rotationAxis,
|
||||||
const scalar& rotationAngle
|
const scalar& rotationAngle,
|
||||||
|
const bool inDegrees = true
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -65,10 +65,10 @@ template<class T, class Key, class Hash> Ostream& operator<<
|
||||||
|
|
||||||
|
|
||||||
/*---------------------------------------------------------------------------*\
|
/*---------------------------------------------------------------------------*\
|
||||||
Class HashPtrTable Declaration
|
Class HashPtrTable Declaration
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
template<class T, class Key=word, class Hash=string::hash>
|
template<class T, class Key = word, class Hash = string::hash>
|
||||||
class HashPtrTable
|
class HashPtrTable
|
||||||
:
|
:
|
||||||
public HashTable<T*, Key, Hash>
|
public HashTable<T*, Key, Hash>
|
||||||
|
@ -89,7 +89,7 @@ public:
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
//- Construct given initial table size
|
//- Construct given initial table size
|
||||||
HashPtrTable(label size = 100);
|
HashPtrTable(const label size = 128);
|
||||||
|
|
||||||
//- Construct from Istream using given Istream constructor class
|
//- Construct from Istream using given Istream constructor class
|
||||||
template<class INew>
|
template<class INew>
|
||||||
|
@ -128,23 +128,19 @@ public:
|
||||||
|
|
||||||
// IOstream Operators
|
// IOstream Operators
|
||||||
|
|
||||||
friend Istream& operator>>
|
#ifndef SWIG
|
||||||
#ifndef __CINT__
|
friend Istream& operator>> <T, Key, Hash>
|
||||||
<T, Key, Hash>
|
|
||||||
#endif
|
|
||||||
(
|
(
|
||||||
Istream&,
|
Istream&,
|
||||||
HashPtrTable<T, Key, Hash>&
|
HashPtrTable<T, Key, Hash>&
|
||||||
);
|
);
|
||||||
|
|
||||||
friend Ostream& operator<<
|
friend Ostream& operator<< <T, Key, Hash>
|
||||||
#ifndef __CINT__
|
|
||||||
<T, Key, Hash>
|
|
||||||
#endif
|
|
||||||
(
|
(
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const HashPtrTable<T, Key, Hash>&
|
const HashPtrTable<T, Key, Hash>&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -417,6 +417,7 @@ public:
|
||||||
|
|
||||||
// IOstream Operator
|
// IOstream Operator
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Istream& operator>> <T, Key, Hash>
|
friend Istream& operator>> <T, Key, Hash>
|
||||||
(
|
(
|
||||||
Istream&,
|
Istream&,
|
||||||
|
@ -428,6 +429,7 @@ public:
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const HashTable<T, Key, Hash>&
|
const HashTable<T, Key, Hash>&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -208,6 +208,7 @@ public:
|
||||||
|
|
||||||
// IOstream operators
|
// IOstream operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
// Write DynamicList to Ostream.
|
// Write DynamicList to Ostream.
|
||||||
friend Ostream& operator<< <T, SizeInc, SizeMult, SizeDiv>
|
friend Ostream& operator<< <T, SizeInc, SizeMult, SizeDiv>
|
||||||
(
|
(
|
||||||
|
@ -221,6 +222,7 @@ public:
|
||||||
Istream&,
|
Istream&,
|
||||||
DynamicList<T, SizeInc, SizeMult, SizeDiv>&
|
DynamicList<T, SizeInc, SizeMult, SizeDiv>&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -71,8 +71,11 @@ template<class T> class SLList;
|
||||||
template<class T, unsigned Size>
|
template<class T, unsigned Size>
|
||||||
class FixedList
|
class FixedList
|
||||||
{
|
{
|
||||||
|
#ifndef SWIG
|
||||||
//- Size must be positive (non-zero) and also fit as a signed value
|
//- Size must be positive (non-zero) and also fit as a signed value
|
||||||
StaticAssert(Size && Size <= INT_MAX);
|
StaticAssert(Size && Size <= INT_MAX);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Private data
|
// Private data
|
||||||
|
|
||||||
|
@ -331,6 +334,8 @@ public:
|
||||||
// IOstream operators
|
// IOstream operators
|
||||||
|
|
||||||
//- Read List from Istream, discarding contents of existing List.
|
//- Read List from Istream, discarding contents of existing List.
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Istream& operator>> <T, Size>
|
friend Istream& operator>> <T, Size>
|
||||||
(Istream&, FixedList<T, Size>&);
|
(Istream&, FixedList<T, Size>&);
|
||||||
|
|
||||||
|
@ -340,6 +345,7 @@ public:
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const FixedList<T, Size>&
|
const FixedList<T, Size>&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -232,9 +232,10 @@ public:
|
||||||
|
|
||||||
// Istream operator
|
// Istream operator
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
//- Read List from Istream, discarding contents of existing List.
|
//- Read List from Istream, discarding contents of existing List.
|
||||||
friend Istream& operator>> <T>
|
friend Istream& operator>> <T>(Istream&, List<T>&);
|
||||||
(Istream&, List<T>&);
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -295,11 +295,13 @@ public:
|
||||||
|
|
||||||
// IOstream operator
|
// IOstream operator
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
//- Read List from Istream, discarding contents of existing List.
|
//- Read List from Istream, discarding contents of existing List.
|
||||||
friend Istream& operator>> <T>(Istream&, PtrList<T>&);
|
friend Istream& operator>> <T>(Istream&, PtrList<T>&);
|
||||||
|
|
||||||
// Write List to Ostream.
|
// Write List to Ostream.
|
||||||
friend Ostream& operator<< <T>(Ostream&, const PtrList<T>&);
|
friend Ostream& operator<< <T>(Ostream&, const PtrList<T>&);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -321,13 +321,16 @@ public:
|
||||||
// Ostream operator
|
// Ostream operator
|
||||||
|
|
||||||
// Write UList to Ostream.
|
// Write UList to Ostream.
|
||||||
|
#ifndef SWIG
|
||||||
friend Ostream& operator<< <T>
|
friend Ostream& operator<< <T>
|
||||||
(
|
(
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const UList<T>&
|
const UList<T>&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
void sort(UList<T>&);
|
void sort(UList<T>&);
|
||||||
|
|
||||||
|
|
|
@ -53,8 +53,11 @@ class NamedEnum
|
||||||
:
|
:
|
||||||
public HashTable<int>
|
public HashTable<int>
|
||||||
{
|
{
|
||||||
|
#ifndef SWIG
|
||||||
//- nEnum must be positive (non-zero)
|
//- nEnum must be positive (non-zero)
|
||||||
StaticAssert(nEnum > 0);
|
StaticAssert(nEnum > 0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Private Member Functions
|
// Private Member Functions
|
||||||
|
|
||||||
|
|
|
@ -139,9 +139,15 @@ public:
|
||||||
//- Construct from dictionary
|
//- Construct from dictionary
|
||||||
coordinateRotation(const dictionary&);
|
coordinateRotation(const dictionary&);
|
||||||
|
|
||||||
|
//- Return clone
|
||||||
|
autoPtr<coordinateRotation> clone() const
|
||||||
|
{
|
||||||
|
return autoPtr<coordinateRotation>(new coordinateRotation(*this));
|
||||||
|
}
|
||||||
|
|
||||||
// Declare run-time constructor selection table
|
// Declare run-time constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -152,6 +158,7 @@ public:
|
||||||
),
|
),
|
||||||
(dict)
|
(dict)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
|
@ -166,6 +166,7 @@ class coordinateSystem
|
||||||
//- Global-to-Local transformation tensor
|
//- Global-to-Local transformation tensor
|
||||||
tensor Rtr_;
|
tensor Rtr_;
|
||||||
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
// Protected Member Functions
|
// Protected Member Functions
|
||||||
|
@ -249,8 +250,10 @@ public:
|
||||||
return autoPtr<coordinateSystem>(new coordinateSystem(*this));
|
return autoPtr<coordinateSystem>(new coordinateSystem(*this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Declare run-time constructor selection table
|
// Declare run-time constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -275,6 +278,8 @@ public:
|
||||||
),
|
),
|
||||||
(name, origin, cr)
|
(name, origin, cr)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
||||||
|
|
|
@ -50,7 +50,11 @@ namespace Foam
|
||||||
|
|
||||||
class IOobjectList
|
class IOobjectList
|
||||||
:
|
:
|
||||||
|
#ifndef SWIG
|
||||||
public HashPtrTable<IOobject>
|
public HashPtrTable<IOobject>
|
||||||
|
#else
|
||||||
|
public HashPtrTable<IOobject, word, string_hash>
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
// Private Member Functions
|
// Private Member Functions
|
||||||
|
|
||||||
|
|
|
@ -209,6 +209,8 @@ public:
|
||||||
|
|
||||||
|
|
||||||
//- A templated class for holding compound tokens
|
//- A templated class for holding compound tokens
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
template<class T>
|
template<class T>
|
||||||
class Compound
|
class Compound
|
||||||
:
|
:
|
||||||
|
@ -235,7 +237,7 @@ public:
|
||||||
operator<<(os, static_cast<const T&>(*this));
|
operator<<(os, static_cast<const T&>(*this));
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
//- Static undefined token
|
//- Static undefined token
|
||||||
static token undefinedToken;
|
static token undefinedToken;
|
||||||
|
|
|
@ -51,7 +51,11 @@ namespace Foam
|
||||||
class objectRegistry
|
class objectRegistry
|
||||||
:
|
:
|
||||||
public regIOobject,
|
public regIOobject,
|
||||||
|
#ifndef SWIG
|
||||||
public HashTable<regIOobject*>
|
public HashTable<regIOobject*>
|
||||||
|
#else
|
||||||
|
public HashTable<regIOobject*, word, string_hash>
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
// Private Data
|
// Private Data
|
||||||
|
|
||||||
|
|
|
@ -174,11 +174,13 @@ public:
|
||||||
|
|
||||||
// IOstream operators
|
// IOstream operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Istream& operator>> <Type>
|
friend Istream& operator>> <Type>
|
||||||
(Istream&, dimensioned<Type>&);
|
(Istream&, dimensioned<Type>&);
|
||||||
|
|
||||||
friend Ostream& operator<< <Type>
|
friend Ostream& operator<< <Type>
|
||||||
(Ostream&, const dimensioned<Type>&);
|
(Ostream&, const dimensioned<Type>&);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -162,10 +162,13 @@ public:
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Construct by transferring the DimensionedField
|
//- Construct by transferring the DimensionedField
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
DimensionedField
|
DimensionedField
|
||||||
(
|
(
|
||||||
const Xfer<DimensionedField<Type, GeoMesh> >&
|
const Xfer<DimensionedField<Type, GeoMesh> >&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
//- Construct as copy of tmp<DimensionedField> deleting argument
|
//- Construct as copy of tmp<DimensionedField> deleting argument
|
||||||
# ifdef ConstructFromTmp
|
# ifdef ConstructFromTmp
|
||||||
|
@ -198,11 +201,13 @@ public:
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Construct by transferring the DimensionedField with a new name
|
//- Construct by transferring the DimensionedField with a new name
|
||||||
|
#ifndef SWIG
|
||||||
DimensionedField
|
DimensionedField
|
||||||
(
|
(
|
||||||
const word& newName,
|
const word& newName,
|
||||||
const Xfer<DimensionedField<Type, GeoMesh> >&
|
const Xfer<DimensionedField<Type, GeoMesh> >&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
//- Construct as copy resetting name
|
//- Construct as copy resetting name
|
||||||
# ifdef ConstructFromTmp
|
# ifdef ConstructFromTmp
|
||||||
|
@ -309,6 +314,7 @@ public:
|
||||||
|
|
||||||
// Ostream Operators
|
// Ostream Operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Ostream& operator<< <Type, GeoMesh>
|
friend Ostream& operator<< <Type, GeoMesh>
|
||||||
(
|
(
|
||||||
Ostream&,
|
Ostream&,
|
||||||
|
@ -320,6 +326,7 @@ public:
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const tmp<DimensionedField<Type, GeoMesh> >&
|
const tmp<DimensionedField<Type, GeoMesh> >&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -189,6 +189,7 @@ public:
|
||||||
|
|
||||||
// IOstream operators
|
// IOstream operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Ostream& operator<< <Field, Type>
|
friend Ostream& operator<< <Field, Type>
|
||||||
(
|
(
|
||||||
Ostream&,
|
Ostream&,
|
||||||
|
@ -200,6 +201,7 @@ public:
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const tmp<FieldField<Field, Type> >&
|
const tmp<FieldField<Field, Type> >&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -339,11 +339,13 @@ public:
|
||||||
|
|
||||||
// IOstream operators
|
// IOstream operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Ostream& operator<< <Type>
|
friend Ostream& operator<< <Type>
|
||||||
(Ostream&, const Field<Type>&);
|
(Ostream&, const Field<Type>&);
|
||||||
|
|
||||||
friend Ostream& operator<< <Type>
|
friend Ostream& operator<< <Type>
|
||||||
(Ostream&, const tmp<Field<Type> >&);
|
(Ostream&, const tmp<Field<Type> >&);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -296,7 +296,8 @@ public:
|
||||||
const word& patchFieldType=PatchField<Type>::calculatedType()
|
const word& patchFieldType=PatchField<Type>::calculatedType()
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Constructor given IOobject, mesh, dimensioned<Type> and patch types.
|
//- Constructor given IOobject, mesh, dimensioned<Type>
|
||||||
|
// and patch types.
|
||||||
GeometricField
|
GeometricField
|
||||||
(
|
(
|
||||||
const IOobject&,
|
const IOobject&,
|
||||||
|
@ -306,6 +307,8 @@ public:
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Constructor from components
|
//- Constructor from components
|
||||||
|
|
||||||
|
#if ( !defined(SWIG) || (SWIG_VERSION > 0x010340) )
|
||||||
GeometricField
|
GeometricField
|
||||||
(
|
(
|
||||||
const IOobject&,
|
const IOobject&,
|
||||||
|
@ -314,6 +317,7 @@ public:
|
||||||
const Field<Type>&,
|
const Field<Type>&,
|
||||||
const PtrList<PatchField<Type> >&
|
const PtrList<PatchField<Type> >&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
//- Construct and read given IOobject
|
//- Construct and read given IOobject
|
||||||
GeometricField
|
GeometricField
|
||||||
|
@ -345,12 +349,12 @@ public:
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Construct as copy of tmp<GeometricField> deleting argument
|
//- Construct as copy of tmp<GeometricField> deleting argument
|
||||||
#ifdef ConstructFromTmp
|
# ifdef ConstructFromTmp
|
||||||
GeometricField
|
GeometricField
|
||||||
(
|
(
|
||||||
const tmp<GeometricField<Type, PatchField, GeoMesh> >&
|
const tmp<GeometricField<Type, PatchField, GeoMesh> >&
|
||||||
);
|
);
|
||||||
#endif
|
# endif
|
||||||
|
|
||||||
//- Construct as copy resetting IO parameters
|
//- Construct as copy resetting IO parameters
|
||||||
GeometricField
|
GeometricField
|
||||||
|
@ -367,13 +371,13 @@ public:
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Construct as copy resetting name
|
//- Construct as copy resetting name
|
||||||
#ifdef ConstructFromTmp
|
# ifdef ConstructFromTmp
|
||||||
GeometricField
|
GeometricField
|
||||||
(
|
(
|
||||||
const word& newName,
|
const word& newName,
|
||||||
const tmp<GeometricField<Type, PatchField, GeoMesh> >&
|
const tmp<GeometricField<Type, PatchField, GeoMesh> >&
|
||||||
);
|
);
|
||||||
#endif
|
# endif
|
||||||
|
|
||||||
//- Construct as copy resetting IO parameters and patch type
|
//- Construct as copy resetting IO parameters and patch type
|
||||||
GeometricField
|
GeometricField
|
||||||
|
@ -547,6 +551,7 @@ public:
|
||||||
|
|
||||||
// Ostream operators
|
// Ostream operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Ostream& operator<< <Type, PatchField, GeoMesh>
|
friend Ostream& operator<< <Type, PatchField, GeoMesh>
|
||||||
(
|
(
|
||||||
Ostream&,
|
Ostream&,
|
||||||
|
@ -558,6 +563,7 @@ public:
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const tmp<GeometricField<Type, PatchField, GeoMesh> >&
|
const tmp<GeometricField<Type, PatchField, GeoMesh> >&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -85,7 +85,10 @@ void GGIInterpolation<MasterPatch, SlavePatch>::calcAddressing() const
|
||||||
<< abort(FatalError);
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << "Evaluation of GGI weighting factors:" << endl;
|
if (debug)
|
||||||
|
{
|
||||||
|
Info << "Evaluation of GGI weighting factors:" << endl;
|
||||||
|
}
|
||||||
|
|
||||||
// Create the dynamic lists to hold the addressing
|
// Create the dynamic lists to hold the addressing
|
||||||
|
|
||||||
|
@ -475,8 +478,6 @@ void GGIInterpolation<MasterPatch, SlavePatch>::calcAddressing() const
|
||||||
{
|
{
|
||||||
rescaleWeightingFactors();
|
rescaleWeightingFactors();
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << endl;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -569,12 +570,17 @@ void GGIInterpolation<MasterPatch, SlavePatch>::rescaleWeightingFactors() const
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (saW.size() > 0 && maW.size() > 0)
|
if (debug)
|
||||||
{
|
{
|
||||||
Info<< " Largest slave weighting factor correction : " << largestSWC
|
if (saW.size() > 0 && maW.size() > 0)
|
||||||
<< " average: " << sumSWC/saW.size() << nl
|
{
|
||||||
<< " Largest master weighting factor correction: " << largestMWC
|
Info<< " Largest slave weighting factor correction : "
|
||||||
<< " average: " << sumMWC/maW.size() << endl;
|
<< largestSWC
|
||||||
|
<< " average: " << sumSWC/saW.size() << nl
|
||||||
|
<< " Largest master weighting factor correction: "
|
||||||
|
<< largestMWC
|
||||||
|
<< " average: " << sumMWC/maW.size() << endl;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ namespace Foam
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
// Interpolate field to cell center.
|
// Interpolate field to cell center
|
||||||
template<class Type>
|
template<class Type>
|
||||||
Type interpolatePointToCell
|
Type interpolatePointToCell
|
||||||
(
|
(
|
||||||
|
|
|
@ -27,7 +27,7 @@ Class
|
||||||
|
|
||||||
Author
|
Author
|
||||||
Hrvoje Jasak, Wikki Ltd. All rights reserved
|
Hrvoje Jasak, Wikki Ltd. All rights reserved
|
||||||
Fethi Tekin, All rights reserved,
|
Fethi Tekin, All rights reserved
|
||||||
|
|
||||||
Description
|
Description
|
||||||
Mass-conservative face interpolation: typedef for stand-alone patch to
|
Mass-conservative face interpolation: typedef for stand-alone patch to
|
||||||
|
|
|
@ -54,8 +54,6 @@ void Foam::overlapGgiPolyPatch::calcExpandedMaster() const
|
||||||
// Create expanded master patch
|
// Create expanded master patch
|
||||||
const label ncpm = nCopies();
|
const label ncpm = nCopies();
|
||||||
|
|
||||||
Info << "Number of master copies: " << ncpm << endl;
|
|
||||||
|
|
||||||
// Create expanded master points and faces
|
// Create expanded master points and faces
|
||||||
const polyPatch& master = boundaryMesh()[index()];
|
const polyPatch& master = boundaryMesh()[index()];
|
||||||
const pointField& masterLocalPoints = master.localPoints();
|
const pointField& masterLocalPoints = master.localPoints();
|
||||||
|
@ -64,8 +62,6 @@ void Foam::overlapGgiPolyPatch::calcExpandedMaster() const
|
||||||
|
|
||||||
const scalar masterAngle = angle();
|
const scalar masterAngle = angle();
|
||||||
|
|
||||||
Info << "Master Angle is: " << masterAngle << endl;
|
|
||||||
|
|
||||||
// Transform points
|
// Transform points
|
||||||
label nPoints_master = 0;
|
label nPoints_master = 0;
|
||||||
|
|
||||||
|
@ -156,8 +152,6 @@ void Foam::overlapGgiPolyPatch::calcExpandedSlave() const
|
||||||
// Create expanded patch
|
// Create expanded patch
|
||||||
const label ncp = shadow().nCopies();
|
const label ncp = shadow().nCopies();
|
||||||
|
|
||||||
Info << "Number of slave copies: " << ncp << endl;
|
|
||||||
|
|
||||||
// Create expanded points and faces
|
// Create expanded points and faces
|
||||||
const polyPatch& slave = boundaryMesh()[shadowIndex()];
|
const polyPatch& slave = boundaryMesh()[shadowIndex()];
|
||||||
const pointField& slaveLocalPoints = slave.localPoints();
|
const pointField& slaveLocalPoints = slave.localPoints();
|
||||||
|
|
|
@ -24,7 +24,7 @@ License
|
||||||
|
|
||||||
Author
|
Author
|
||||||
Hrvoje Jasak, Wikki Ltd. All rights reserved.
|
Hrvoje Jasak, Wikki Ltd. All rights reserved.
|
||||||
Fethi Tekin, All rights reserved.
|
Fethi Tekin, All rights reserved. fethitekin@gmail.com
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
@ -37,12 +37,12 @@ template<class Type>
|
||||||
Foam::tmp<Foam::Field<Type> >
|
Foam::tmp<Foam::Field<Type> >
|
||||||
Foam::overlapGgiPolyPatch::expandSlaveData(const Field<Type>& spf) const
|
Foam::overlapGgiPolyPatch::expandSlaveData(const Field<Type>& spf) const
|
||||||
{
|
{
|
||||||
|
|
||||||
const scalar slaveAngle = shadow().angle();
|
const scalar slaveAngle = shadow().angle();
|
||||||
|
|
||||||
const label ncp = shadow().nCopies();
|
const label ncp = shadow().nCopies();
|
||||||
|
|
||||||
tmp<Field<Type> > tef(new Field<Type>(ncp*spf.size()));
|
tmp<Field<Type> > tef(new Field<Type>(ncp*spf.size()));
|
||||||
|
|
||||||
Field<Type>& ef = tef();
|
Field<Type>& ef = tef();
|
||||||
|
|
||||||
label nFaces = 0;
|
label nFaces = 0;
|
||||||
|
@ -63,15 +63,17 @@ Foam::overlapGgiPolyPatch::expandSlaveData(const Field<Type>& spf) const
|
||||||
return tef;
|
return tef;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
Foam::tmp<Foam::Field<Type> >
|
Foam::tmp<Foam::Field<Type> >
|
||||||
Foam::overlapGgiPolyPatch::expandMasterData(const Field<Type>& spf) const
|
Foam::overlapGgiPolyPatch::expandMasterData(const Field<Type>& spf) const
|
||||||
{
|
{
|
||||||
const scalar masterAngle = angle();
|
const scalar masterAngle = shadow().angle();
|
||||||
|
|
||||||
const label ncpm = nCopies();
|
const label ncpm = shadow().nCopies();
|
||||||
|
|
||||||
tmp<Field<Type> > tef(new Field<Type>(ncpm*spf.size()));
|
tmp<Field<Type> > tef(new Field<Type>(ncpm*spf.size()));
|
||||||
|
|
||||||
Field<Type>& ef = tef();
|
Field<Type>& ef = tef();
|
||||||
|
|
||||||
label nFaces = 0;
|
label nFaces = 0;
|
||||||
|
@ -91,8 +93,6 @@ Foam::overlapGgiPolyPatch::expandMasterData(const Field<Type>& spf) const
|
||||||
|
|
||||||
return tef;
|
return tef;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
|
@ -155,5 +155,4 @@ Foam::overlapGgiPolyPatch::interpolate(const tmp<Field<Type> >& tpf) const
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|
|
@ -228,6 +228,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection tables
|
// Declare run-time constructor selection tables
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -256,6 +257,7 @@ public:
|
||||||
),
|
),
|
||||||
(name, dict, index, bm)
|
(name, dict, index, bm)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
|
@ -48,11 +48,12 @@ namespace Foam
|
||||||
|
|
||||||
typedef SphericalTensor<scalar> sphericalTensor;
|
typedef SphericalTensor<scalar> sphericalTensor;
|
||||||
|
|
||||||
// Identity tensor
|
|
||||||
static const sphericalTensor I(1);
|
|
||||||
|
|
||||||
static const sphericalTensor oneThirdI(1.0/3.0);
|
// Identity tensor
|
||||||
static const sphericalTensor twoThirdsI(2.0/3.0);
|
static const sphericalTensor I;
|
||||||
|
|
||||||
|
static const sphericalTensor oneThirdI;
|
||||||
|
static const sphericalTensor twoThirdsI;
|
||||||
|
|
||||||
|
|
||||||
//- Specify data associated with sphericalTensor type are contiguous
|
//- Specify data associated with sphericalTensor type are contiguous
|
||||||
|
|
|
@ -136,6 +136,7 @@ public:
|
||||||
|
|
||||||
// IOstream Operators
|
// IOstream Operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Istream& operator>> <Form, Cmpt, nCmpt>
|
friend Istream& operator>> <Form, Cmpt, nCmpt>
|
||||||
(
|
(
|
||||||
Istream&,
|
Istream&,
|
||||||
|
@ -147,6 +148,7 @@ public:
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const VectorSpace<Form, Cmpt, nCmpt>&
|
const VectorSpace<Form, Cmpt, nCmpt>&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -48,6 +48,20 @@ public:
|
||||||
vs.v_[I] = o(vs1.v_[I], vs2.v_[I]);
|
vs.v_[I] = o(vs1.v_[I], vs2.v_[I]);
|
||||||
VectorSpaceOps<endLoop*N, endLoop*(I+1)>::op(vs, vs1, vs2, o);
|
VectorSpaceOps<endLoop*N, endLoop*(I+1)>::op(vs, vs1, vs2, o);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template<class V, class V1, class V2, class Op>
|
||||||
|
static inline void opVV(V& vs, const V1& vs1, const V2& vs2, Op o)
|
||||||
|
{
|
||||||
|
vs.v_[I] = o(vs1.v_[I], vs2.v_[I]);
|
||||||
|
VectorSpaceOps<endLoop*N, endLoop*(I+1)>::opVV(vs, vs1, vs2, o);
|
||||||
|
}
|
||||||
|
|
||||||
|
template<class S, class V1, class V2, class EqOp, class Op>
|
||||||
|
static inline void SopEqOpVV(S& s, const V1& vs1, const V2& vs2, EqOp eo, Op o)
|
||||||
|
{
|
||||||
|
eo(s, o(vs1.v_[I], vs2.v_[I]));
|
||||||
|
VectorSpaceOps<endLoop*N, endLoop*(I+1)>::SopEqOpVV(s, vs1, vs2, eo, o);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -80,4 +94,13 @@ public:
|
||||||
template<class V, class V1, class Op>
|
template<class V, class V1, class Op>
|
||||||
static inline void op(V& vs, const V1&, const V1&, Op)
|
static inline void op(V& vs, const V1&, const V1&, Op)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
template<class V, class V1, class V2, class Op>
|
||||||
|
static inline void opVV(V& vs, const V1& vs1, const V2& vs2, Op o)
|
||||||
|
{}
|
||||||
|
|
||||||
|
template<class S, class V1, class V2, class EqOp, class Op>
|
||||||
|
static inline void SopEqOpVV(S& s, const V1& vs1, const V2& vs2, EqOp eo, Op o)
|
||||||
|
{}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -32,6 +32,11 @@ Description
|
||||||
combined using the given combination function and the result is
|
combined using the given combination function and the result is
|
||||||
broadcast to all nodes
|
broadcast to all nodes
|
||||||
|
|
||||||
|
Note:
|
||||||
|
Format of this file has considerably changed to remove cpp pre-processor
|
||||||
|
definition in order to help Swig with parsing in. Implemented by
|
||||||
|
Alexey Petrov; merged by HJ, 14/Oct/2010
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
#ifndef ops_H
|
#ifndef ops_H
|
||||||
|
@ -42,103 +47,272 @@ Description
|
||||||
namespace Foam
|
namespace Foam
|
||||||
{
|
{
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
template<class T1, class T2>
|
||||||
|
class eqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x = y; } };
|
||||||
|
|
||||||
#define EqOp(opName, op) \
|
template<class T>
|
||||||
\
|
class eqOp
|
||||||
template<class T1, class T2> \
|
{ public: void operator()(T& x, const T& y) const { x = y; } };
|
||||||
class opName##Op2 \
|
|
||||||
{ \
|
|
||||||
public: \
|
|
||||||
\
|
|
||||||
void operator()(T1& x, const T2& y) const \
|
|
||||||
{ \
|
|
||||||
op; \
|
|
||||||
} \
|
|
||||||
}; \
|
|
||||||
\
|
|
||||||
template<class T> \
|
|
||||||
class opName##Op \
|
|
||||||
{ \
|
|
||||||
public: \
|
|
||||||
\
|
|
||||||
void operator()(T& x, const T& y) const \
|
|
||||||
{ \
|
|
||||||
op; \
|
|
||||||
} \
|
|
||||||
};
|
|
||||||
|
|
||||||
EqOp(eq, x = y)
|
template<class T1, class T2>
|
||||||
EqOp(plusEq, x += y)
|
class plusEqOp2
|
||||||
EqOp(minusEq, x -= y)
|
{ public: void operator()(T1& x, const T2& y) const { x += y; } };
|
||||||
EqOp(multiplyEq, x *= y)
|
|
||||||
EqOp(divideEq, x /= y)
|
|
||||||
EqOp(eqMag, x = mag(y))
|
|
||||||
EqOp(plusEqMagSqr, x += magSqr(y))
|
|
||||||
EqOp(maxEq, x = max(x, y))
|
|
||||||
EqOp(minEq, x = min(x, y))
|
|
||||||
EqOp(andEq, x = (x && y))
|
|
||||||
EqOp(orEq, x = (x || y))
|
|
||||||
|
|
||||||
EqOp(eqMinus, x = -y)
|
template<class T>
|
||||||
|
class plusEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x += y; } };
|
||||||
|
|
||||||
#undef EqOp
|
template<class T1, class T2>
|
||||||
|
class minusEqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x -= y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class minusEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x -= y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class multiplyEqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x *= y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class multiplyEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x *= y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class divideEqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x /= y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class divideEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x /= y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class eqMagOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x = mag(y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class eqMagOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x = mag(y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class plusEqMagSqrOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x += magSqr(y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class plusEqMagSqrOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x += magSqr(y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class maxEqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x = max(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class maxEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x = max(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class minEqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x = min(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class minEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x = min(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class andEqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x = (x && y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class andEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x = (x && y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class orEqOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x = (x || y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class orEqOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x = (x || y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class eqMinusOp2
|
||||||
|
{ public: void operator()(T1& x, const T2& y) const { x = -y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class eqMinusOp
|
||||||
|
{ public: void operator()(T& x, const T& y) const { x = -y; } };
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
#define Op(opName, op) \
|
template<class T, class T1, class T2>
|
||||||
\
|
class sumOp3
|
||||||
template<class T, class T1, class T2> \
|
{ public: T operator()(const T1& x, const T2& y) const { return x + y; } };
|
||||||
class opName##Op3 \
|
|
||||||
{ \
|
|
||||||
public: \
|
|
||||||
\
|
|
||||||
T operator()(const T1& x, const T2& y) const \
|
|
||||||
{ \
|
|
||||||
return op; \
|
|
||||||
} \
|
|
||||||
}; \
|
|
||||||
\
|
|
||||||
template<class T1, class T2> \
|
|
||||||
class opName##Op2 \
|
|
||||||
{ \
|
|
||||||
public: \
|
|
||||||
\
|
|
||||||
T1 operator()(const T1& x, const T2& y) const \
|
|
||||||
{ \
|
|
||||||
return op; \
|
|
||||||
} \
|
|
||||||
}; \
|
|
||||||
\
|
|
||||||
template<class T> \
|
|
||||||
class opName##Op \
|
|
||||||
{ \
|
|
||||||
public: \
|
|
||||||
\
|
|
||||||
T operator()(const T& x, const T& y) const \
|
|
||||||
{ \
|
|
||||||
return op; \
|
|
||||||
} \
|
|
||||||
};
|
|
||||||
|
|
||||||
Op(sum, x + y)
|
template<class T1, class T2>
|
||||||
|
class sumOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x + y; } };
|
||||||
|
|
||||||
Op(plus, x + y)
|
template<class T>
|
||||||
Op(minus, x - y)
|
class sumOp
|
||||||
Op(multiply, x * y)
|
{ public: T operator()(const T& x, const T& y) const { return x + y; } };
|
||||||
Op(divide, x / y)
|
|
||||||
Op(cmptMultiply, cmptMultiply(x, y))
|
|
||||||
Op(cmptDivide, cmptDivide(x, y))
|
|
||||||
Op(stabilise, stabilise(x, y))
|
|
||||||
Op(max, max(x, y))
|
|
||||||
Op(min, min(x, y))
|
|
||||||
Op(minMod, minMod(x, y))
|
|
||||||
Op(and, x && y)
|
|
||||||
Op(or, x || y)
|
|
||||||
Op(eqEq, x == y)
|
|
||||||
|
|
||||||
#undef Op
|
template<class T, class T1, class T2>
|
||||||
|
class plusOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return x + y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class plusOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x + y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class plusOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return x + y; } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class minusOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return x - y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class minusOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x - y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class minusOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return x - y; } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class multiplyOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return x * y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class multiplyOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x * y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class multiplyOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return x * y; } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class divideOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return x / y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class divideOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x / y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class divideOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return x / y; } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class cmptMultiplyOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return cmptMultiply(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class cmptMultiplyOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return cmptMultiply(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class cmptMultiplyOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return cmptMultiply(x, y); } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class cmptDivideOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return cmptDivide(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class cmptDivideOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return cmptDivide(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class cmptDivideOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return cmptDivide(x, y); } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class stabiliseOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return stabilise(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class stabiliseOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return stabilise(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class stabiliseOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return stabilise(x, y); } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class maxOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return max(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class maxOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return max(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class maxOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return max(x, y); } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class minOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return min(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class minOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return min(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class minOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return min(x, y); } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class minModOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return minMod(x, y); } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class minModOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return minMod(x, y); } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class minModOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return minMod(x, y); } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class andOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return x && y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class andOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x && y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class andOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return x && y; } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class orOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return x || y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class orOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x || y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class orOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return x || y; } };
|
||||||
|
|
||||||
|
template<class T, class T1, class T2>
|
||||||
|
class eqEqOp3
|
||||||
|
{ public: T operator()(const T1& x, const T2& y) const { return x == y; } };
|
||||||
|
|
||||||
|
template<class T1, class T2>
|
||||||
|
class eqEqOp2
|
||||||
|
{ public: T1 operator()(const T1& x, const T2& y) const { return x == y; } };
|
||||||
|
|
||||||
|
template<class T>
|
||||||
|
class eqEqOp
|
||||||
|
{ public: T operator()(const T& x, const T& y) const { return x == y; } };
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
|
@ -71,6 +71,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection table
|
// Declare run-time constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -79,6 +80,7 @@ public:
|
||||||
(const IOobject& io),
|
(const IOobject& io),
|
||||||
(io)
|
(io)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
|
@ -131,11 +131,14 @@ void Foam::turboFvMesh::calcMovingPoints() const
|
||||||
|
|
||||||
forAll (curFace, pointI)
|
forAll (curFace, pointI)
|
||||||
{
|
{
|
||||||
//The rotation data is saved within the cell data. For
|
// The rotation data is saved within the cell data. For
|
||||||
//non-rotating regions rpm is zero,so mesh movement is
|
// non-rotating regions rpm is zero, so mesh movement is
|
||||||
//also zero. The conversion of rotational speed
|
// also zero. The conversion of rotational speed
|
||||||
|
|
||||||
|
// Note: deltaT changes during the run: moved to
|
||||||
|
// turboFvMesh::update(). HJ, 14/Oct/2010
|
||||||
movingPoints[curFace[pointI]] =
|
movingPoints[curFace[pointI]] =
|
||||||
vector(0,rpm_*360.0*time().deltaT().value()/60.0, 0);
|
vector(0, rpm_/60.0*360.0, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -213,7 +216,8 @@ bool Foam::turboFvMesh::update()
|
||||||
(
|
(
|
||||||
csPtr_->globalPosition
|
csPtr_->globalPosition
|
||||||
(
|
(
|
||||||
csPtr_->localPosition(allPoints()) + movingPoints()
|
csPtr_->localPosition(allPoints())
|
||||||
|
+ movingPoints()*time().deltaT().value()
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
@ -129,6 +129,18 @@ void surfaceNormalFixedValueFvPatchVectorField::rmap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void surfaceNormalFixedValueFvPatchVectorField::updateCoeffs()
|
||||||
|
{
|
||||||
|
if (updated())
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Bug fix: update for moving mesh. HJ, 15/Oct/2010
|
||||||
|
operator==(refValue_*patch().nf());
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void surfaceNormalFixedValueFvPatchVectorField::write(Ostream& os) const
|
void surfaceNormalFixedValueFvPatchVectorField::write(Ostream& os) const
|
||||||
{
|
{
|
||||||
fvPatchVectorField::write(os);
|
fvPatchVectorField::write(os);
|
||||||
|
|
|
@ -151,6 +151,11 @@ public:
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
// Member functions
|
||||||
|
|
||||||
|
//- Update the coefficients associated with the patch field
|
||||||
|
virtual void updateCoeffs();
|
||||||
|
|
||||||
//- Write
|
//- Write
|
||||||
virtual void write(Ostream&) const;
|
virtual void write(Ostream&) const;
|
||||||
};
|
};
|
||||||
|
|
|
@ -114,6 +114,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection tables
|
// Declare run-time constructor selection tables
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
tmp,
|
tmp,
|
||||||
|
@ -152,7 +153,7 @@ public:
|
||||||
),
|
),
|
||||||
(p, iF, dict)
|
(p, iF, dict)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
|
@ -469,7 +470,9 @@ public:
|
||||||
|
|
||||||
// Ostream operator
|
// Ostream operator
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend Ostream& operator<< <Type>(Ostream&, const fvPatchField<Type>&);
|
friend Ostream& operator<< <Type>(Ostream&, const fvPatchField<Type>&);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -102,6 +102,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection tables
|
// Declare run-time constructor selection tables
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
tmp,
|
tmp,
|
||||||
|
@ -140,7 +141,7 @@ public:
|
||||||
),
|
),
|
||||||
(p, iF, dict)
|
(p, iF, dict)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
|
@ -354,7 +355,13 @@ public:
|
||||||
|
|
||||||
// Ostream operator
|
// Ostream operator
|
||||||
|
|
||||||
friend Ostream& operator<< <Type>(Ostream&, const fvsPatchField<Type>&);
|
#ifndef SWIG
|
||||||
|
friend Ostream& operator<< <Type>
|
||||||
|
(
|
||||||
|
Ostream&,
|
||||||
|
const fvsPatchField<Type>&
|
||||||
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -447,6 +447,7 @@ public:
|
||||||
|
|
||||||
// Friend operators
|
// Friend operators
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
friend tmp<GeometricField<Type, fvPatchField, volMesh> >
|
friend tmp<GeometricField<Type, fvPatchField, volMesh> >
|
||||||
operator& <Type>
|
operator& <Type>
|
||||||
(
|
(
|
||||||
|
@ -483,6 +484,7 @@ public:
|
||||||
Ostream&,
|
Ostream&,
|
||||||
const fvMatrix<Type>&
|
const fvMatrix<Type>&
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -113,6 +113,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection tables
|
// Declare run-time constructor selection tables
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -121,6 +122,7 @@ public:
|
||||||
(const polyPatch& patch, const fvBoundaryMesh& bm),
|
(const polyPatch& patch, const fvBoundaryMesh& bm),
|
||||||
(patch, bm)
|
(patch, bm)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
|
@ -69,6 +69,8 @@ public:
|
||||||
|
|
||||||
|
|
||||||
//- Declare run-time constructor selection table
|
//- Declare run-time constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -77,6 +79,8 @@ public:
|
||||||
(const fvMesh& mesh),
|
(const fvMesh& mesh),
|
||||||
(mesh)
|
(mesh)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
|
|
|
@ -121,6 +121,7 @@ public:
|
||||||
|
|
||||||
// Declare runtime constructor selection table
|
// Declare runtime constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -131,7 +132,7 @@ public:
|
||||||
),
|
),
|
||||||
(T)
|
(T)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
|
|
|
@ -135,7 +135,7 @@ tmp<volScalarField> twoPhaseMixture::rho() const
|
||||||
(
|
(
|
||||||
new volScalarField
|
new volScalarField
|
||||||
(
|
(
|
||||||
"rho",
|
"rho_twoPhaseMixture",
|
||||||
limitedAlpha1*rho1_
|
limitedAlpha1*rho1_
|
||||||
+ (scalar(1) - limitedAlpha1)*rho2_
|
+ (scalar(1) - limitedAlpha1)*rho2_
|
||||||
)
|
)
|
||||||
|
@ -151,7 +151,7 @@ tmp<volScalarField> twoPhaseMixture::mu() const
|
||||||
(
|
(
|
||||||
new volScalarField
|
new volScalarField
|
||||||
(
|
(
|
||||||
"mu",
|
"mu_twoPhaseMixture",
|
||||||
limitedAlpha1*rho1_*nuModel1_->nu()
|
limitedAlpha1*rho1_*nuModel1_->nu()
|
||||||
+ (scalar(1) - limitedAlpha1)*rho2_*nuModel2_->nu()
|
+ (scalar(1) - limitedAlpha1)*rho2_*nuModel2_->nu()
|
||||||
)
|
)
|
||||||
|
@ -168,7 +168,7 @@ tmp<surfaceScalarField> twoPhaseMixture::muf() const
|
||||||
(
|
(
|
||||||
new surfaceScalarField
|
new surfaceScalarField
|
||||||
(
|
(
|
||||||
"muf",
|
"muf_twoPhaseMixture",
|
||||||
alpha1f*rho1_*fvc::interpolate(nuModel1_->nu())
|
alpha1f*rho1_*fvc::interpolate(nuModel1_->nu())
|
||||||
+ (scalar(1) - alpha1f)*rho2_*fvc::interpolate(nuModel2_->nu())
|
+ (scalar(1) - alpha1f)*rho2_*fvc::interpolate(nuModel2_->nu())
|
||||||
)
|
)
|
||||||
|
@ -185,7 +185,7 @@ tmp<surfaceScalarField> twoPhaseMixture::nuf() const
|
||||||
(
|
(
|
||||||
new surfaceScalarField
|
new surfaceScalarField
|
||||||
(
|
(
|
||||||
"nuf",
|
"nuf_twoPhaseMixture",
|
||||||
(
|
(
|
||||||
alpha1f*rho1_*fvc::interpolate(nuModel1_->nu())
|
alpha1f*rho1_*fvc::interpolate(nuModel1_->nu())
|
||||||
+ (scalar(1) - alpha1f)*rho2_*fvc::interpolate(nuModel2_->nu())
|
+ (scalar(1) - alpha1f)*rho2_*fvc::interpolate(nuModel2_->nu())
|
||||||
|
|
|
@ -92,6 +92,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection table
|
// Declare run-time constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -105,6 +106,7 @@ public:
|
||||||
),
|
),
|
||||||
(name, viscosityProperties, U, phi)
|
(name, viscosityProperties, U, phi)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
|
@ -144,7 +144,7 @@ public:
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
||||||
//- Return a reference to the selected LES model
|
//- Return a reference to the selected LES model
|
||||||
static autoPtr<LESModel> New
|
static autoPtr<compressible::LESModel> New
|
||||||
(
|
(
|
||||||
const volScalarField& rho,
|
const volScalarField& rho,
|
||||||
const volVectorField& U,
|
const volVectorField& U,
|
||||||
|
|
|
@ -136,6 +136,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection table
|
// Declare run-time constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeSelectionTable
|
declareRunTimeSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -149,7 +150,7 @@ public:
|
||||||
),
|
),
|
||||||
(rho, U, phi, thermoPhysicalModel)
|
(rho, U, phi, thermoPhysicalModel)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
|
@ -167,7 +168,7 @@ public:
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
||||||
//- Return a reference to the selected turbulence model
|
//- Return a reference to the selected turbulence model
|
||||||
static autoPtr<RASModel> New
|
static autoPtr<compressible::RASModel> New
|
||||||
(
|
(
|
||||||
const volScalarField& rho,
|
const volScalarField& rho,
|
||||||
const volVectorField& U,
|
const volVectorField& U,
|
||||||
|
@ -176,8 +177,7 @@ public:
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
// Destructor
|
//- Destructor
|
||||||
|
|
||||||
virtual ~RASModel()
|
virtual ~RASModel()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
|
@ -104,6 +104,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time constructor selection table
|
// Declare run-time constructor selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeNewSelectionTable
|
declareRunTimeNewSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -117,6 +118,7 @@ public:
|
||||||
),
|
),
|
||||||
(rho, U, phi, thermoPhysicalModel)
|
(rho, U, phi, thermoPhysicalModel)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
@ -134,7 +136,7 @@ public:
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
||||||
//- Return a reference to the selected turbulence model
|
//- Return a reference to the selected turbulence model
|
||||||
static autoPtr<turbulenceModel> New
|
static autoPtr<compressible::turbulenceModel> New
|
||||||
(
|
(
|
||||||
const volScalarField& rho,
|
const volScalarField& rho,
|
||||||
const volVectorField& U,
|
const volVectorField& U,
|
||||||
|
|
|
@ -142,7 +142,7 @@ public:
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
||||||
//- Return a reference to the selected LES model
|
//- Return a reference to the selected LES model
|
||||||
static autoPtr<LESModel> New
|
static autoPtr<incompressible::LESModel> New
|
||||||
(
|
(
|
||||||
const volVectorField& U,
|
const volVectorField& U,
|
||||||
const surfaceScalarField& phi,
|
const surfaceScalarField& phi,
|
||||||
|
|
|
@ -159,7 +159,7 @@ public:
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
||||||
//- Return a reference to the selected RAS model
|
//- Return a reference to the selected RAS model
|
||||||
static autoPtr<RASModel> New
|
static autoPtr<incompressible::RASModel> New
|
||||||
(
|
(
|
||||||
const volVectorField& U,
|
const volVectorField& U,
|
||||||
const surfaceScalarField& phi,
|
const surfaceScalarField& phi,
|
||||||
|
|
|
@ -102,6 +102,7 @@ public:
|
||||||
|
|
||||||
// Declare run-time New selection table
|
// Declare run-time New selection table
|
||||||
|
|
||||||
|
#ifndef SWIG
|
||||||
declareRunTimeNewSelectionTable
|
declareRunTimeNewSelectionTable
|
||||||
(
|
(
|
||||||
autoPtr,
|
autoPtr,
|
||||||
|
@ -114,6 +115,7 @@ public:
|
||||||
),
|
),
|
||||||
(U, phi, lamTransportModel)
|
(U, phi, lamTransportModel)
|
||||||
);
|
);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
@ -130,7 +132,7 @@ public:
|
||||||
// Selectors
|
// Selectors
|
||||||
|
|
||||||
//- Return a reference to the selected turbulence model
|
//- Return a reference to the selected turbulence model
|
||||||
static autoPtr<turbulenceModel> New
|
static autoPtr<incompressible::turbulenceModel> New
|
||||||
(
|
(
|
||||||
const volVectorField& U,
|
const volVectorField& U,
|
||||||
const surfaceScalarField& phi,
|
const surfaceScalarField& phi,
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
#/*---------------------------------------------------------------------------*\
|
# /*-------------------------------------------------------------------------*\
|
||||||
# ========= |
|
# ========= |
|
||||||
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
# \\ / O peration |
|
# \\ / O peration |
|
||||||
# \\ / A nd | Copyright held by original author
|
# \\ / A nd | Copyright held by original author
|
||||||
# \\/ M anipulation |
|
# \\/ M anipulation |
|
||||||
# -------------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
# License
|
# License
|
||||||
# This file is part of OpenFOAM.
|
# This file is part of OpenFOAM.
|
||||||
#
|
#
|
||||||
|
@ -23,17 +23,17 @@
|
||||||
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# CMakeLists.txt file for implementing a test harness for the compilation
|
# CMakeLists.txt file for implementing a test harness for the compilation
|
||||||
# and test of OpenFOAM-1.5-dev using Kitware CTest./CMake/CDash
|
# and test of OpenFOAM-1.5-dev using Kitware CTest./CMake/CDash
|
||||||
#
|
#
|
||||||
# The results will be submitted to the CDash server identified by the file
|
# The results will be submitted to the CDash server identified by the file
|
||||||
# CTestConfig.cmake
|
# CTestConfig.cmake
|
||||||
#
|
#
|
||||||
# Author
|
# Author
|
||||||
# Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved
|
# Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
# \*---------------------------------------------------------------------------*/
|
# \*-------------------------------------------------------------------------*/
|
||||||
|
|
||||||
cmake_minimum_required (VERSION 2.8)
|
cmake_minimum_required (VERSION 2.8)
|
||||||
|
|
||||||
|
|
|
@ -14,3 +14,72 @@ OSIG/TurboMachinery : Test harness for the TurboMachinery OSIG. See the file OSI
|
||||||
|
|
||||||
|
|
||||||
Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved.
|
Martin Beaudoin, Hydro-Quebec, 2010. All rights reserved.
|
||||||
|
|
||||||
|
|
||||||
|
1: Select your git branch of choice: ie:
|
||||||
|
|
||||||
|
git checkout master # For Hrv master branch
|
||||||
|
|
||||||
|
|
||||||
|
2: Make sure your OpenFOAM environment is properly configured to run OpenFOAM.
|
||||||
|
|
||||||
|
|
||||||
|
3: The minimal cmake version number for running the test loop is 2.8.0. Make sure you are there.
|
||||||
|
|
||||||
|
|
||||||
|
4: Make sure you have the test harness scripts available under your git branch;
|
||||||
|
otherwise, you will need to fetch this from Hrv's master branch, and merge it into yours
|
||||||
|
|
||||||
|
ls $WM_PROJECT_DIR/testHarness # Checking availability of testHarness under this branch
|
||||||
|
|
||||||
|
|
||||||
|
5: move to the runDir directory for the OpenFOAM test harness
|
||||||
|
|
||||||
|
cd $WM_PROJECT_DIR/testHarness/OpenFOAM/1.6-ext/runDir
|
||||||
|
|
||||||
|
|
||||||
|
6: Normally, if using the master branch, everything should already be setup for you to run the test harness.
|
||||||
|
Still, I recommand always checking that these two important files are up-to-date:
|
||||||
|
|
||||||
|
cp ../CMakeFiles/CMakeLists.txt $WM_PROJECT_DIR
|
||||||
|
cp ../CMakeFiles/CTestConfig.cmake.openfoam-extend_of-1.6-ext-testing $WM_PROJECT_DIR/CTestConfig.cmake
|
||||||
|
|
||||||
|
|
||||||
|
7: Next, running the test loop is pretty simple:
|
||||||
|
|
||||||
|
cd $WM_PROJECT_DIR/testHarness/OpenFOAM/1.6-ext/runDir # you should already be there...
|
||||||
|
./Allclean
|
||||||
|
./Allrun_Experimental
|
||||||
|
|
||||||
|
|
||||||
|
8: The results will be published on the CDash dashboard on openfoam-extend.
|
||||||
|
|
||||||
|
To see your results:
|
||||||
|
URL : http://openfoam-extend.sourceforge.net/CDash/index.php?project=OpenFOAM-1.6-ext_testing
|
||||||
|
Username : of-1.6-ext@of-extend.cdash
|
||||||
|
Password : onepasswd4all
|
||||||
|
|
||||||
|
|
||||||
|
9: You can customize your system identifier on the dashboard using the environment variable $CDASH_SUBMIT_LOCAL_HOST_ID.
|
||||||
|
Otherwise, the fully qualified name of your system will be used.
|
||||||
|
|
||||||
|
A good customization idea would be to add the name of your git branch in your system ID.
|
||||||
|
I will probably modify my scripts to add this information automagically.
|
||||||
|
|
||||||
|
NB: Please no "forward slash" or "/" in the system ID; it looks like CDash will choke on this.
|
||||||
|
|
||||||
|
|
||||||
|
10: In general, see the file $WM_PROJECT_DIR/testHarness/OpenFOAM/1.6-ext/README.txt for the necessary information about running the
|
||||||
|
test loop.
|
||||||
|
(NB: I just found out a couple of mistakes in that file, so please use this message for now as per instructions for running the test loop.
|
||||||
|
I will fix this shortly. Sorry.)
|
||||||
|
|
||||||
|
|
||||||
|
11: As more people will start using these basic steps, I will supply more information about some other features that are available with
|
||||||
|
the test loop.
|
||||||
|
|
||||||
|
But I need to see those baby steps first... :)
|
||||||
|
|
||||||
|
|
||||||
|
12: Please do not hesitate to report any problems, comments, suggestions about the test loop.
|
||||||
|
This stuff runs great on my systems, but it needs to run even better on yours.
|
||||||
|
|
0
tutorials/combustion/XiFoam/les/pitzDaily/Allrun
Normal file → Executable file
0
tutorials/combustion/XiFoam/les/pitzDaily/Allrun
Normal file → Executable file
|
@ -1,8 +1,8 @@
|
||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM Extend Project: Open source CFD |
|
||||||
| \\ / O peration | Version: 1.6.x |
|
| \\ / O peration | Version: 1.6-ext |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.extend-project.de |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
|
|
0
tutorials/combustion/XiFoam/les/pitzDaily3D/Allrun
Normal file → Executable file
0
tutorials/combustion/XiFoam/les/pitzDaily3D/Allrun
Normal file → Executable file
|
@ -18,11 +18,12 @@ FoamFile
|
||||||
|
|
||||||
twoDMotion yes;
|
twoDMotion yes;
|
||||||
|
|
||||||
dynamicFvMesh dynamicMotionSolverFvMesh;
|
dynamicFvMesh dynamicMotionSolverFvMesh;
|
||||||
|
|
||||||
solver laplaceFaceDecomposition;
|
solver laplaceFaceDecomposition;
|
||||||
|
|
||||||
diffusivity file;
|
diffusivity file;
|
||||||
|
// diffusivity uniform;
|
||||||
|
|
||||||
frozenDiffusion off;
|
frozenDiffusion off;
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/*---------------------------------------------------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 1.4 |
|
| \\ / O peration | Version: 1.4 |
|
||||||
|
@ -10,12 +10,6 @@ FoamFile
|
||||||
{
|
{
|
||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
|
|
||||||
root "";
|
|
||||||
case "";
|
|
||||||
instance "";
|
|
||||||
local "";
|
|
||||||
|
|
||||||
class dictionary;
|
class dictionary;
|
||||||
object blockMeshDict;
|
object blockMeshDict;
|
||||||
}
|
}
|
||||||
|
@ -50,11 +44,11 @@ vertices
|
||||||
|
|
||||||
blocks
|
blocks
|
||||||
(
|
(
|
||||||
hex (0 1 5 4 0 1 13 12) (15 15 1) simpleGrading (1 1 1)
|
hex (0 1 5 4 0 1 13 12) (5 5 1) simpleGrading (1 1 1)
|
||||||
hex (2 3 7 6 2 3 15 14) (20 20 1) simpleGrading (2 0.25 1)
|
hex (2 3 7 6 2 3 15 14) (7 7 1) simpleGrading (2 0.25 1)
|
||||||
hex (4 5 9 8 12 13 17 16) (15 15 1) simpleGrading (1 1 1)
|
hex (4 5 9 8 12 13 17 16) (5 5 1) simpleGrading (1 1 1)
|
||||||
hex (5 6 10 9 13 14 18 17) (50 15 1) simpleGrading (1 1 1)
|
hex (5 6 10 9 13 14 18 17) (15 5 1) simpleGrading (1 1 1)
|
||||||
hex (6 7 11 10 14 15 19 18) (20 15 1) simpleGrading (2 1 1)
|
hex (6 7 11 10 14 15 19 18) (7 5 1) simpleGrading (2 1 1)
|
||||||
);
|
);
|
||||||
|
|
||||||
edges
|
edges
|
||||||
|
|
|
@ -0,0 +1,112 @@
|
||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 1.4 |
|
||||||
|
| \\ / A nd | Web: http://www.openfoam.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class dictionary;
|
||||||
|
object blockMeshDict;
|
||||||
|
}
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
convertToMeters 0.001;
|
||||||
|
|
||||||
|
vertices
|
||||||
|
(
|
||||||
|
(-7.5 0 0)
|
||||||
|
(-7 0 0)
|
||||||
|
(-3.5 0 0)
|
||||||
|
(0 0 0)
|
||||||
|
(-7.5 0.75 -0.0327457)
|
||||||
|
(-7 0.75 -0.0327457)
|
||||||
|
(-3.5 2 -0.0873219)
|
||||||
|
(0 2 -0.0873219)
|
||||||
|
(-7.5 2.5 -0.109152)
|
||||||
|
(-7 2.5 -0.109152)
|
||||||
|
(-3.5 2.5 -0.109152)
|
||||||
|
(0 2.5 -0.109152)
|
||||||
|
(-7.5 0.75 0.0327457)
|
||||||
|
(-7 0.75 0.0327457)
|
||||||
|
(-3.5 2 0.0873219)
|
||||||
|
(0 2 0.0873219)
|
||||||
|
(-7.5 2.5 0.109152)
|
||||||
|
(-7 2.5 0.109152)
|
||||||
|
(-3.5 2.5 0.109152)
|
||||||
|
(0 2.5 0.109152)
|
||||||
|
);
|
||||||
|
|
||||||
|
blocks
|
||||||
|
(
|
||||||
|
hex (0 1 5 4 0 1 13 12) (15 15 1) simpleGrading (1 1 1)
|
||||||
|
hex (2 3 7 6 2 3 15 14) (20 20 1) simpleGrading (2 0.25 1)
|
||||||
|
hex (4 5 9 8 12 13 17 16) (15 15 1) simpleGrading (1 1 1)
|
||||||
|
hex (5 6 10 9 13 14 18 17) (50 15 1) simpleGrading (1 1 1)
|
||||||
|
hex (6 7 11 10 14 15 19 18) (20 15 1) simpleGrading (2 1 1)
|
||||||
|
);
|
||||||
|
|
||||||
|
edges
|
||||||
|
(
|
||||||
|
);
|
||||||
|
|
||||||
|
patches
|
||||||
|
(
|
||||||
|
wall movingWall
|
||||||
|
(
|
||||||
|
(1 5 13 1)
|
||||||
|
(5 6 14 13)
|
||||||
|
(2 2 14 6)
|
||||||
|
)
|
||||||
|
patch farFieldMoving
|
||||||
|
(
|
||||||
|
(9 17 18 10)
|
||||||
|
)
|
||||||
|
wall fixedWall
|
||||||
|
(
|
||||||
|
(3 7 15 3)
|
||||||
|
(7 11 19 15)
|
||||||
|
)
|
||||||
|
empty axis
|
||||||
|
(
|
||||||
|
(0 1 1 0)
|
||||||
|
(2 3 3 2)
|
||||||
|
)
|
||||||
|
patch left
|
||||||
|
(
|
||||||
|
(0 0 12 4)
|
||||||
|
(4 12 16 8)
|
||||||
|
)
|
||||||
|
patch farField
|
||||||
|
(
|
||||||
|
(8 16 17 9)
|
||||||
|
(10 18 19 11)
|
||||||
|
)
|
||||||
|
wedge back
|
||||||
|
(
|
||||||
|
(0 4 5 1)
|
||||||
|
(2 6 7 3)
|
||||||
|
(4 8 9 5)
|
||||||
|
(5 9 10 6)
|
||||||
|
(6 10 11 7)
|
||||||
|
)
|
||||||
|
wedge front
|
||||||
|
(
|
||||||
|
(0 1 13 12)
|
||||||
|
(2 3 15 14)
|
||||||
|
(12 13 17 16)
|
||||||
|
(13 14 18 17)
|
||||||
|
(14 15 19 18)
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
|
mergePatchPairs
|
||||||
|
(
|
||||||
|
);
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
|
@ -20,50 +20,50 @@ FoamFile
|
||||||
movingWall
|
movingWall
|
||||||
{
|
{
|
||||||
type wall;
|
type wall;
|
||||||
nFaces 85;
|
nFaces 27;
|
||||||
startFace 3665;
|
startFace 374;
|
||||||
}
|
}
|
||||||
farFieldMoving
|
farFieldMoving
|
||||||
{
|
{
|
||||||
type patch;
|
type patch;
|
||||||
nFaces 50;
|
nFaces 15;
|
||||||
startFace 3750;
|
startFace 401;
|
||||||
}
|
}
|
||||||
fixedWall
|
fixedWall
|
||||||
{
|
{
|
||||||
type wall;
|
type wall;
|
||||||
nFaces 35;
|
nFaces 12;
|
||||||
startFace 3800;
|
startFace 416;
|
||||||
}
|
}
|
||||||
axis
|
axis
|
||||||
{
|
{
|
||||||
type empty;
|
type empty;
|
||||||
nFaces 0;
|
nFaces 0;
|
||||||
startFace 3835;
|
startFace 428;
|
||||||
}
|
}
|
||||||
left
|
left
|
||||||
{
|
{
|
||||||
type patch;
|
type patch;
|
||||||
nFaces 30;
|
nFaces 10;
|
||||||
startFace 3835;
|
startFace 428;
|
||||||
}
|
}
|
||||||
farField
|
farField
|
||||||
{
|
{
|
||||||
type patch;
|
type patch;
|
||||||
nFaces 35;
|
nFaces 12;
|
||||||
startFace 3865;
|
startFace 438;
|
||||||
}
|
}
|
||||||
back
|
back
|
||||||
{
|
{
|
||||||
type wedge;
|
type wedge;
|
||||||
nFaces 1900;
|
nFaces 209;
|
||||||
startFace 3900;
|
startFace 450;
|
||||||
}
|
}
|
||||||
front
|
front
|
||||||
{
|
{
|
||||||
type wedge;
|
type wedge;
|
||||||
nFaces 1900;
|
nFaces 209;
|
||||||
startFace 5800;
|
startFace 659;
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/*---------------------------------------------------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 1.4 |
|
| \\ / O peration | Version: 1.4 |
|
||||||
|
@ -10,12 +10,6 @@ FoamFile
|
||||||
{
|
{
|
||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
|
|
||||||
root "";
|
|
||||||
case "";
|
|
||||||
instance "";
|
|
||||||
local "";
|
|
||||||
|
|
||||||
class dictionary;
|
class dictionary;
|
||||||
object transportProperties;
|
object transportProperties;
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,11 +26,11 @@ stopAt endTime;
|
||||||
|
|
||||||
endTime 0.003;
|
endTime 0.003;
|
||||||
|
|
||||||
deltaT 5e-06;
|
deltaT 2e-05;
|
||||||
|
|
||||||
writeControl timeStep;
|
writeControl timeStep;
|
||||||
|
|
||||||
writeInterval 40;
|
writeInterval 10;
|
||||||
|
|
||||||
purgeWrite 0;
|
purgeWrite 0;
|
||||||
|
|
||||||
|
@ -38,7 +38,7 @@ writeFormat ascii;
|
||||||
|
|
||||||
writePrecision 6;
|
writePrecision 6;
|
||||||
|
|
||||||
writeCompression uncompressed;
|
writeCompression compressed;
|
||||||
|
|
||||||
timeFormat general;
|
timeFormat general;
|
||||||
|
|
||||||
|
@ -50,4 +50,5 @@ adjustTimeStep no;
|
||||||
|
|
||||||
maxCo 0.2;
|
maxCo 0.2;
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|
|
@ -0,0 +1,50 @@
|
||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 1.5 |
|
||||||
|
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class dictionary;
|
||||||
|
object decomposeParDict;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
numberOfSubdomains 4;
|
||||||
|
|
||||||
|
method simple;
|
||||||
|
|
||||||
|
simpleCoeffs
|
||||||
|
{
|
||||||
|
n (2 2 1);
|
||||||
|
delta 0.001;
|
||||||
|
}
|
||||||
|
|
||||||
|
hierarchicalCoeffs
|
||||||
|
{
|
||||||
|
n (1 1 1);
|
||||||
|
delta 0.001;
|
||||||
|
order xyz;
|
||||||
|
}
|
||||||
|
|
||||||
|
metisCoeffs
|
||||||
|
{
|
||||||
|
processorWeights 4{1};
|
||||||
|
}
|
||||||
|
|
||||||
|
manualCoeffs
|
||||||
|
{
|
||||||
|
dataFile "";
|
||||||
|
}
|
||||||
|
|
||||||
|
distributed no;
|
||||||
|
|
||||||
|
roots
|
||||||
|
(
|
||||||
|
);
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
|
@ -10,12 +10,6 @@ FoamFile
|
||||||
{
|
{
|
||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
|
|
||||||
root "";
|
|
||||||
case "";
|
|
||||||
instance "";
|
|
||||||
local "";
|
|
||||||
|
|
||||||
class dictionary;
|
class dictionary;
|
||||||
object fvSchemes;
|
object fvSchemes;
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,22 +20,32 @@ solvers
|
||||||
{
|
{
|
||||||
motionU
|
motionU
|
||||||
{
|
{
|
||||||
solver amgSolver;
|
solver PCG;
|
||||||
cycle W-cycle;
|
preconditioner DIC;
|
||||||
policy AAMG;
|
|
||||||
nPreSweeps 0;
|
|
||||||
nPostSweeps 2;
|
|
||||||
groupSize 4;
|
|
||||||
minCoarseEqns 30;
|
|
||||||
nMaxLevels 100;
|
|
||||||
scale on;
|
|
||||||
smoother GaussSeidel;
|
|
||||||
|
|
||||||
minIter 0;
|
minIter 0;
|
||||||
maxIter 500;
|
maxIter 1000;
|
||||||
tolerance 1e-8;
|
tolerance 1e-6;
|
||||||
relTol 0.0;
|
relTol 0.01;
|
||||||
};
|
};
|
||||||
|
// motionU
|
||||||
|
// {
|
||||||
|
// solver amgSolver;
|
||||||
|
// cycle W-cycle;
|
||||||
|
// policy AAMG;
|
||||||
|
// nPreSweeps 0;
|
||||||
|
// nPostSweeps 2;
|
||||||
|
// groupSize 4;
|
||||||
|
// minCoarseEqns 30;
|
||||||
|
// nMaxLevels 100;
|
||||||
|
// scale on;
|
||||||
|
// smoother GaussSeidel;
|
||||||
|
|
||||||
|
// minIter 0;
|
||||||
|
// maxIter 500;
|
||||||
|
// tolerance 1e-8;
|
||||||
|
// relTol 0.0;
|
||||||
|
// };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Reference in a new issue