mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' into particleInteractions
Conflicts: src/parallel/decompositionMethods/Make/options
This commit is contained in:
@ -10,7 +10,7 @@ wmakeCheckPwd "$WM_PROJECT_DIR/applications" || {
|
|||||||
|
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
wmake all solvers
|
|
||||||
wmake all utilities
|
wmake all utilities
|
||||||
|
wmake all solvers
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
@ -11,7 +11,7 @@ forAll(patches, patchi)
|
|||||||
{
|
{
|
||||||
const fvPatch& currPatch = patches[patchi];
|
const fvPatch& currPatch = patches[patchi];
|
||||||
|
|
||||||
if (isType<wallFvPatch>(currPatch))
|
if (isA<wallFvPatch>(currPatch))
|
||||||
{
|
{
|
||||||
const vectorField nf = currPatch.nf();
|
const vectorField nf = currPatch.nf();
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -69,7 +69,7 @@ int main()
|
|||||||
word name;
|
word name;
|
||||||
|
|
||||||
fileName path(SubList<word>(wrdList, wrdList.size()-start, start));
|
fileName path(SubList<word>(wrdList, wrdList.size()-start, start));
|
||||||
fileName path2 = "." / path;
|
fileName path2 = "."/path;
|
||||||
|
|
||||||
IOobject::fileNameComponents
|
IOobject::fileNameComponents
|
||||||
(
|
(
|
||||||
|
|||||||
@ -91,23 +91,20 @@ cspace ","{space}
|
|||||||
|
|
||||||
alpha [_A-Za-z]
|
alpha [_A-Za-z]
|
||||||
digit [0-9]
|
digit [0-9]
|
||||||
dec_digit [0-9]
|
|
||||||
octal_digit [0-7]
|
|
||||||
hex_digit [0-9a-fA-F]
|
|
||||||
|
|
||||||
identifier {alpha}({alpha}|{digit})*
|
identifier {alpha}({alpha}|{digit})*
|
||||||
integer {dec_digit}+
|
integer {digit}+
|
||||||
label [1-9]{dec_digit}*
|
label [1-9]{digit}*
|
||||||
|
|
||||||
exponent_part [eE][-+]?{digit}+
|
exponent_part [eE][-+]?{digit}+
|
||||||
fractional_constant [-+]?(({digit}*"."{digit}+)|({digit}+"."?))
|
fractional_constant [-+]?(({digit}*"."{digit}+)|({digit}+"."?))
|
||||||
|
|
||||||
double (({fractional_constant}{exponent_part}?)|({digit}+{exponent_part}))
|
floatNum (({fractional_constant}{exponent_part}?)|({digit}+{exponent_part}))
|
||||||
|
|
||||||
x {double}
|
x {floatNum}
|
||||||
y {double}
|
y {floatNum}
|
||||||
z {double}
|
z {floatNum}
|
||||||
value {double}
|
value {floatNum}
|
||||||
|
|
||||||
node ^{space}"N"{cspace}
|
node ^{space}"N"{cspace}
|
||||||
element ^{space}"EN"{cspace}
|
element ^{space}"EN"{cspace}
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
EXE_INC = \
|
EXE_INC = \
|
||||||
-I$(LIB_SRC)/meshTools/lnInclude \
|
-I$(LIB_SRC)/meshTools/lnInclude \
|
||||||
-I$(LIB_SRC)/conversion/lnInclude
|
-I$(LIB_SRC)/conversion/lnInclude \
|
||||||
|
-I$(LIB_SRC)/fileFormats/lnInclude
|
||||||
|
|
||||||
EXE_LIBS = \
|
EXE_LIBS = \
|
||||||
-lconversion
|
-lconversion
|
||||||
|
|||||||
@ -95,24 +95,14 @@ int yyFlexLexer::yywrap()
|
|||||||
one_space [ \t\f\r]
|
one_space [ \t\f\r]
|
||||||
space {one_space}*
|
space {one_space}*
|
||||||
some_space {one_space}+
|
some_space {one_space}+
|
||||||
cspace ","{space}
|
|
||||||
spaceNl ({space}|\n)*
|
spaceNl ({space}|\n)*
|
||||||
|
|
||||||
alpha [_[:alpha:]]
|
alpha [_[:alpha:]]
|
||||||
digit [[:digit:]]
|
digit [[:digit:]]
|
||||||
dec_digit [[:digit:]]
|
|
||||||
octal_digit [0-7]
|
|
||||||
hex_digit [[:xdigit:]]
|
|
||||||
|
|
||||||
lbrac "("
|
dotColonDash [.:-]
|
||||||
rbrac ")"
|
|
||||||
quote \"
|
|
||||||
dash "-"
|
|
||||||
dotColonDash [.:-]
|
|
||||||
|
|
||||||
identifier {alpha}({alpha}|{digit})*
|
label [0-9]{digit}*
|
||||||
integer {dec_digit}+
|
|
||||||
label [0-9]{dec_digit}*
|
|
||||||
zeroLabel {digit}*
|
zeroLabel {digit}*
|
||||||
|
|
||||||
word ({alpha}|{digit}|{dotColonDash})*
|
word ({alpha}|{digit}|{dotColonDash})*
|
||||||
@ -120,14 +110,14 @@ word ({alpha}|{digit}|{dotColonDash})*
|
|||||||
exponent_part [eE][-+]?{digit}+
|
exponent_part [eE][-+]?{digit}+
|
||||||
fractional_constant [-+]?(({digit}*"."{digit}+)|({digit}+"."?))
|
fractional_constant [-+]?(({digit}*"."{digit}+)|({digit}+"."?))
|
||||||
|
|
||||||
double ((({fractional_constant}{exponent_part}?)|({digit}+{exponent_part}))|0)
|
floatNum ((({fractional_constant}{exponent_part}?)|({digit}+{exponent_part}))|0)
|
||||||
|
|
||||||
|
x {floatNum}
|
||||||
|
y {floatNum}
|
||||||
|
z {floatNum}
|
||||||
|
|
||||||
x {double}
|
|
||||||
y {double}
|
|
||||||
z {double}
|
|
||||||
scalar {double}
|
|
||||||
labelListElement {space}{zeroLabel}
|
labelListElement {space}{zeroLabel}
|
||||||
scalarListElement {space}{double}
|
scalarListElement {space}{floatNum}
|
||||||
labelList ({labelListElement}+{space})
|
labelList ({labelListElement}+{space})
|
||||||
scalarList ({scalarListElement}+{space})
|
scalarList ({scalarListElement}+{space})
|
||||||
|
|
||||||
|
|||||||
@ -358,9 +358,22 @@ int main(int argc, char *argv[])
|
|||||||
timeSelector::addOptions(true, false);
|
timeSelector::addOptions(true, false);
|
||||||
|
|
||||||
argList::validArgs.append("feature angle[0-180]");
|
argList::validArgs.append("feature angle[0-180]");
|
||||||
argList::addBoolOption("splitAllFaces");
|
argList::addBoolOption
|
||||||
argList::addBoolOption("concaveMultiCells");
|
(
|
||||||
argList::addBoolOption("doNotPreserveFaceZones");
|
"splitAllFaces",
|
||||||
|
"have multiple faces inbetween cells"
|
||||||
|
);
|
||||||
|
argList::addBoolOption
|
||||||
|
(
|
||||||
|
"concaveMultiCells",
|
||||||
|
"split cells on concave boundary edges into multiple cells"
|
||||||
|
);
|
||||||
|
argList::addBoolOption
|
||||||
|
(
|
||||||
|
"doNotPreserveFaceZones",
|
||||||
|
"disable the default behaviour of preserving faceZones by having"
|
||||||
|
" multiple faces inbetween cells"
|
||||||
|
);
|
||||||
|
|
||||||
# include "setRootCase.H"
|
# include "setRootCase.H"
|
||||||
# include "createTime.H"
|
# include "createTime.H"
|
||||||
|
|||||||
@ -884,7 +884,7 @@ void starMesh::createCoupleMatches()
|
|||||||
<< "newSlaveEdges: " << newSlaveEdges << endl;
|
<< "newSlaveEdges: " << newSlaveEdges << endl;
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
edge startEdge;
|
edge startEdge(-1, -1);
|
||||||
|
|
||||||
// Remember where the start edge was found:
|
// Remember where the start edge was found:
|
||||||
// 0 for not found
|
// 0 for not found
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
EXE_INC = \
|
EXE_INC = \
|
||||||
-I$(LIB_SRC)/meshTools/lnInclude \
|
-I$(LIB_SRC)/meshTools/lnInclude \
|
||||||
-I$(LIB_SRC)/conversion/lnInclude
|
-I$(LIB_SRC)/conversion/lnInclude \
|
||||||
|
-I$(LIB_SRC)/fileFormats/lnInclude
|
||||||
|
|
||||||
EXE_LIBS = \
|
EXE_LIBS = \
|
||||||
-lconversion
|
-lconversion
|
||||||
|
|||||||
@ -1,15 +1,17 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
cd ${0%/*} || exit 1 # run from this directory
|
cd ${0%/*} || exit 1 # run from this directory
|
||||||
|
|
||||||
READLINE=0
|
|
||||||
if [ -f /usr/include/readline/readline.h ]
|
if [ -f /usr/include/readline/readline.h ]
|
||||||
then
|
then
|
||||||
echo "Found readline/readline.h -- enabling readline support."
|
echo "Found readline/readline.h -- enabling readline support."
|
||||||
READLINE=1
|
export READLINE=1
|
||||||
export READLINELINK="-lreadline -lncurses"
|
export READLINELINK="-lreadline -lncurses"
|
||||||
break
|
else
|
||||||
|
# no readline/readline.h -- disabling readline support
|
||||||
|
export READLINE=0
|
||||||
|
unset READLINELINK
|
||||||
fi
|
fi
|
||||||
export READLINE
|
|
||||||
wmake
|
wmake
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
@ -1,5 +1,7 @@
|
|||||||
|
/* NB: trailing zero after define improves robustness */
|
||||||
|
|
||||||
EXE_INC = \
|
EXE_INC = \
|
||||||
-DREADLINE=$(READLINE) \
|
-DREADLINE=$(READLINE)0 \
|
||||||
-I$(LIB_SRC)/meshTools/lnInclude
|
-I$(LIB_SRC)/meshTools/lnInclude
|
||||||
|
|
||||||
EXE_LIBS = \
|
EXE_LIBS = \
|
||||||
|
|||||||
@ -440,7 +440,7 @@ int main(int argc, char *argv[])
|
|||||||
(
|
(
|
||||||
databases[procI].findInstance
|
databases[procI].findInstance
|
||||||
(
|
(
|
||||||
regionDir / polyMesh::meshSubDir,
|
regionDir/polyMesh::meshSubDir,
|
||||||
"points"
|
"points"
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
@ -469,10 +469,10 @@ int main(int argc, char *argv[])
|
|||||||
"points",
|
"points",
|
||||||
databases[procI].findInstance
|
databases[procI].findInstance
|
||||||
(
|
(
|
||||||
regionDir / polyMesh::meshSubDir,
|
regionDir/polyMesh::meshSubDir,
|
||||||
"points"
|
"points"
|
||||||
),
|
),
|
||||||
regionDir / polyMesh::meshSubDir,
|
regionDir/polyMesh::meshSubDir,
|
||||||
databases[procI],
|
databases[procI],
|
||||||
IOobject::MUST_READ,
|
IOobject::MUST_READ,
|
||||||
IOobject::NO_WRITE,
|
IOobject::NO_WRITE,
|
||||||
|
|||||||
@ -8,5 +8,4 @@ EXE_LIBS = \
|
|||||||
-lfiniteVolume \
|
-lfiniteVolume \
|
||||||
-ldecompositionMethods \
|
-ldecompositionMethods \
|
||||||
-lmeshTools \
|
-lmeshTools \
|
||||||
-ldynamicMesh \
|
-ldynamicMesh
|
||||||
-L$(FOAM_MPI_LIBBIN) -lparMetisDecompositionMethod
|
|
||||||
|
|||||||
@ -82,6 +82,19 @@
|
|||||||
</Documentation>
|
</Documentation>
|
||||||
</IntVectorProperty>
|
</IntVectorProperty>
|
||||||
|
|
||||||
|
<!-- Use VTK Polyhedron check-box -->
|
||||||
|
<IntVectorProperty
|
||||||
|
name="UseVTKPolyhedron"
|
||||||
|
command="SetUseVTKPolyhedron"
|
||||||
|
number_of_elements="1"
|
||||||
|
default_values="0"
|
||||||
|
animateable="0">
|
||||||
|
<BooleanDomain name="bool"/>
|
||||||
|
<Documentation>
|
||||||
|
Use vtkPolyhedron instead of decomposing polyhedra
|
||||||
|
</Documentation>
|
||||||
|
</IntVectorProperty>
|
||||||
|
|
||||||
<!-- Include Sets check-box -->
|
<!-- Include Sets check-box -->
|
||||||
<IntVectorProperty
|
<IntVectorProperty
|
||||||
name="UiIncludeSets"
|
name="UiIncludeSets"
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2009-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 2010-2009 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2009-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 2010-2009 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2008-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 2008-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -83,6 +83,7 @@ vtkPV3FoamReader::vtkPV3FoamReader()
|
|||||||
|
|
||||||
SkipZeroTime = 0;
|
SkipZeroTime = 0;
|
||||||
ExtrapolatePatches = 0;
|
ExtrapolatePatches = 0;
|
||||||
|
UseVTKPolyhedron = 0;
|
||||||
IncludeSets = 0;
|
IncludeSets = 0;
|
||||||
IncludeZones = 0;
|
IncludeZones = 0;
|
||||||
ShowPatchNames = 0;
|
ShowPatchNames = 0;
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2008-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 2008-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -102,6 +102,11 @@ public:
|
|||||||
vtkSetMacro(ExtrapolatePatches, int);
|
vtkSetMacro(ExtrapolatePatches, int);
|
||||||
vtkGetMacro(ExtrapolatePatches, int);
|
vtkGetMacro(ExtrapolatePatches, int);
|
||||||
|
|
||||||
|
// Description:
|
||||||
|
// FOAM use vtkPolyhedron instead of decomposing polyhedra
|
||||||
|
vtkSetMacro(UseVTKPolyhedron, int);
|
||||||
|
vtkGetMacro(UseVTKPolyhedron, int);
|
||||||
|
|
||||||
// Description:
|
// Description:
|
||||||
// FOAM read sets control
|
// FOAM read sets control
|
||||||
virtual void SetIncludeSets(int);
|
virtual void SetIncludeSets(int);
|
||||||
@ -217,6 +222,7 @@ private:
|
|||||||
int SkipZeroTime;
|
int SkipZeroTime;
|
||||||
|
|
||||||
int ExtrapolatePatches;
|
int ExtrapolatePatches;
|
||||||
|
int UseVTKPolyhedron;
|
||||||
int IncludeSets;
|
int IncludeSets;
|
||||||
int IncludeZones;
|
int IncludeZones;
|
||||||
int ShowPatchNames;
|
int ShowPatchNames;
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -0,0 +1,72 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ 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 2 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, write to the Free Software Foundation,
|
||||||
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
InClass
|
||||||
|
vtkPV3Foam
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#ifndef vtkOpenFOAMTupleRemap_H
|
||||||
|
#define vtkOpenFOAMTupleRemap_H
|
||||||
|
|
||||||
|
// OpenFOAM includes
|
||||||
|
#include "StaticAssert.H"
|
||||||
|
#include "Swap.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
template<class Type>
|
||||||
|
inline void vtkOpenFOAMTupleRemap(float vec[]);
|
||||||
|
|
||||||
|
|
||||||
|
// a symmTensor specialization to remap OpenFOAM -> ParaView naming order
|
||||||
|
// Qt/Core/pqScalarBarRepresentation.cxx defines this order
|
||||||
|
// { "XX", "YY", "ZZ", "XY", "YZ", "XZ" }
|
||||||
|
// in pqScalarBarRepresentation::getDefaultComponentLabel()
|
||||||
|
// whereas OpenFOAM uses this order
|
||||||
|
// { XX, XY, XZ, YY, YZ, ZZ }
|
||||||
|
//
|
||||||
|
// for extra safety, assert that symmTensor indeed has 6 components
|
||||||
|
StaticAssert(Foam::symmTensor::nComponents == 6);
|
||||||
|
|
||||||
|
|
||||||
|
// Template specialization for symmTensor
|
||||||
|
template<>
|
||||||
|
inline void vtkOpenFOAMTupleRemap<Foam::symmTensor>(float vec[])
|
||||||
|
{
|
||||||
|
Foam::Swap(vec[1], vec[3]); // swap XY <-> YY
|
||||||
|
Foam::Swap(vec[2], vec[5]); // swap XZ <-> ZZ
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
template<class Type>
|
||||||
|
inline void vtkOpenFOAMTupleRemap(float vec[])
|
||||||
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -36,6 +36,8 @@ InClass
|
|||||||
#include "vtkMultiBlockDataSet.h"
|
#include "vtkMultiBlockDataSet.h"
|
||||||
#include "vtkPolyData.h"
|
#include "vtkPolyData.h"
|
||||||
|
|
||||||
|
#include "vtkOpenFOAMTupleRemap.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
@ -80,7 +82,7 @@ void Foam::vtkPV3Foam::convertFaceField
|
|||||||
{
|
{
|
||||||
Type t = 0.5*(tf[faceOwner[faceNo]] + tf[faceNeigh[faceNo]]);
|
Type t = 0.5*(tf[faceOwner[faceNo]] + tf[faceNeigh[faceNo]]);
|
||||||
|
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
@ -88,11 +90,12 @@ void Foam::vtkPV3Foam::convertFaceField
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
const Type& t = tf[faceOwner[faceNo]];
|
const Type& t = tf[faceOwner[faceNo]];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
cellData->InsertTuple(faceI, vec);
|
cellData->InsertTuple(faceI, vec);
|
||||||
}
|
}
|
||||||
@ -152,7 +155,7 @@ void Foam::vtkPV3Foam::convertFaceField
|
|||||||
{
|
{
|
||||||
Type t = 0.5*(tf[faceOwner[faceNo]] + tf[faceNeigh[faceNo]]);
|
Type t = 0.5*(tf[faceOwner[faceNo]] + tf[faceNeigh[faceNo]]);
|
||||||
|
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
@ -160,11 +163,12 @@ void Foam::vtkPV3Foam::convertFaceField
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
const Type& t = tf[faceOwner[faceNo]];
|
const Type& t = tf[faceOwner[faceNo]];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
cellData->InsertTuple(faceI, vec);
|
cellData->InsertTuple(faceI, vec);
|
||||||
++faceI;
|
++faceI;
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -32,6 +32,8 @@ InClass
|
|||||||
|
|
||||||
#include "Cloud.H"
|
#include "Cloud.H"
|
||||||
|
|
||||||
|
#include "vtkOpenFOAMTupleRemap.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
@ -86,10 +88,11 @@ void Foam::vtkPV3Foam::convertLagrangianField
|
|||||||
forAll(tf, i)
|
forAll(tf, i)
|
||||||
{
|
{
|
||||||
const Type& t = tf[i];
|
const Type& t = tf[i];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
pointData->InsertTuple(i, vec);
|
pointData->InsertTuple(i, vec);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -25,6 +25,7 @@ License
|
|||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
#include "vtkPV3Foam.H"
|
#include "vtkPV3Foam.H"
|
||||||
|
#include "vtkPV3FoamReader.h"
|
||||||
|
|
||||||
// Foam includes
|
// Foam includes
|
||||||
#include "fvMesh.H"
|
#include "fvMesh.H"
|
||||||
@ -33,6 +34,7 @@ License
|
|||||||
|
|
||||||
// VTK includes
|
// VTK includes
|
||||||
#include "vtkCellArray.h"
|
#include "vtkCellArray.h"
|
||||||
|
#include "vtkIdTypeArray.h"
|
||||||
#include "vtkUnstructuredGrid.h"
|
#include "vtkUnstructuredGrid.h"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
@ -79,35 +81,40 @@ vtkUnstructuredGrid* Foam::vtkPV3Foam::volumeVTKMesh
|
|||||||
{
|
{
|
||||||
Info<< "... scanning" << endl;
|
Info<< "... scanning" << endl;
|
||||||
}
|
}
|
||||||
forAll(cellShapes, cellI)
|
|
||||||
|
// count number of cells to decompose
|
||||||
|
if (!reader_->GetUseVTKPolyhedron())
|
||||||
{
|
{
|
||||||
const cellModel& model = cellShapes[cellI].model();
|
forAll(cellShapes, cellI)
|
||||||
|
|
||||||
if
|
|
||||||
(
|
|
||||||
model != hex
|
|
||||||
&& model != wedge
|
|
||||||
&& model != prism
|
|
||||||
&& model != pyr
|
|
||||||
&& model != tet
|
|
||||||
&& model != tetWedge
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
const cell& cFaces = mesh.cells()[cellI];
|
const cellModel& model = cellShapes[cellI].model();
|
||||||
|
|
||||||
forAll(cFaces, cFaceI)
|
if
|
||||||
|
(
|
||||||
|
model != hex
|
||||||
|
&& model != wedge
|
||||||
|
&& model != prism
|
||||||
|
&& model != pyr
|
||||||
|
&& model != tet
|
||||||
|
&& model != tetWedge
|
||||||
|
)
|
||||||
{
|
{
|
||||||
const face& f = mesh.faces()[cFaces[cFaceI]];
|
const cell& cFaces = mesh.cells()[cellI];
|
||||||
|
|
||||||
label nFacePoints = f.size();
|
forAll(cFaces, cFaceI)
|
||||||
|
{
|
||||||
|
const face& f = mesh.faces()[cFaces[cFaceI]];
|
||||||
|
|
||||||
label nQuads = (nFacePoints - 2)/2;
|
label nFacePoints = f.size();
|
||||||
label nTris = (nFacePoints - 2)%2;
|
|
||||||
nAddCells += nQuads + nTris;
|
label nQuads = (nFacePoints - 2)/2;
|
||||||
|
label nTris = (nFacePoints - 2)%2;
|
||||||
|
nAddCells += nQuads + nTris;
|
||||||
|
}
|
||||||
|
|
||||||
|
nAddCells--;
|
||||||
|
nAddPoints++;
|
||||||
}
|
}
|
||||||
|
|
||||||
nAddCells--;
|
|
||||||
nAddPoints++;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -155,7 +162,7 @@ vtkUnstructuredGrid* Foam::vtkPV3Foam::volumeVTKMesh
|
|||||||
// Set counters for additional points and additional cells
|
// Set counters for additional points and additional cells
|
||||||
label addPointI = 0, addCellI = 0;
|
label addPointI = 0, addCellI = 0;
|
||||||
|
|
||||||
// Create storage for points - needed for mapping from Foam to VTK
|
// Create storage for points - needed for mapping from OpenFOAM to VTK
|
||||||
// data types - max 'order' = hex = 8 points
|
// data types - max 'order' = hex = 8 points
|
||||||
vtkIdType nodeIds[8];
|
vtkIdType nodeIds[8];
|
||||||
|
|
||||||
@ -194,10 +201,15 @@ vtkUnstructuredGrid* Foam::vtkPV3Foam::volumeVTKMesh
|
|||||||
}
|
}
|
||||||
else if (cellModel == prism)
|
else if (cellModel == prism)
|
||||||
{
|
{
|
||||||
for (int j = 0; j < 6; j++)
|
// VTK has a different node order - their triangles point outwards!
|
||||||
{
|
|
||||||
nodeIds[j] = cellShape[j];
|
nodeIds[0] = cellShape[0];
|
||||||
}
|
nodeIds[1] = cellShape[2];
|
||||||
|
nodeIds[2] = cellShape[1];
|
||||||
|
nodeIds[3] = cellShape[3];
|
||||||
|
nodeIds[4] = cellShape[5];
|
||||||
|
nodeIds[5] = cellShape[4];
|
||||||
|
|
||||||
vtkmesh->InsertNextCell
|
vtkmesh->InsertNextCell
|
||||||
(
|
(
|
||||||
VTK_WEDGE,
|
VTK_WEDGE,
|
||||||
@ -256,6 +268,80 @@ vtkUnstructuredGrid* Foam::vtkPV3Foam::volumeVTKMesh
|
|||||||
nodeIds
|
nodeIds
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
else if (reader_->GetUseVTKPolyhedron())
|
||||||
|
{
|
||||||
|
// Polyhedral cell - use VTK_POLYHEDRON
|
||||||
|
const labelList& cFaces = mesh.cells()[cellI];
|
||||||
|
|
||||||
|
vtkIdType nFaces = cFaces.size();
|
||||||
|
vtkIdType nodeCount = 0;
|
||||||
|
vtkIdType nLabels = nFaces;
|
||||||
|
|
||||||
|
// count size for face stream
|
||||||
|
forAll(cFaces, cFaceI)
|
||||||
|
{
|
||||||
|
const face& f = mesh.faces()[cFaces[cFaceI]];
|
||||||
|
nLabels += f.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
// unique node ids - approximately equal to the number of point ids
|
||||||
|
DynamicList<vtkIdType> uniqueNodeIds(nLabels-nFaces);
|
||||||
|
|
||||||
|
// zero-based index into uniqueNodeIds
|
||||||
|
DynamicList<vtkIdType> faceLabels(nLabels);
|
||||||
|
|
||||||
|
// localized point id within the cell
|
||||||
|
Map<label> mapLocalId(2*nLabels);
|
||||||
|
|
||||||
|
// establish the unique point ids,
|
||||||
|
// record the local mapping ids,
|
||||||
|
// create new face list
|
||||||
|
forAll(cFaces, cFaceI)
|
||||||
|
{
|
||||||
|
const face& f = mesh.faces()[cFaces[cFaceI]];
|
||||||
|
const label nFacePoints = f.size();
|
||||||
|
|
||||||
|
// number of labels for this face
|
||||||
|
faceLabels.append(nFacePoints);
|
||||||
|
|
||||||
|
forAll(f, fp)
|
||||||
|
{
|
||||||
|
const label nodeId = f[fp];
|
||||||
|
|
||||||
|
if (mapLocalId.insert(nodeId, nodeCount))
|
||||||
|
{
|
||||||
|
// insertion was successful (node Id was unique)
|
||||||
|
uniqueNodeIds.append(nodeId);
|
||||||
|
// map orig vertex id -> localized point label
|
||||||
|
faceLabels.append(nodeCount);
|
||||||
|
++nodeCount;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// map orig vertex id -> localized point label
|
||||||
|
faceLabels.append(mapLocalId[nodeId]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef HAS_VTK_POLYHEDRON
|
||||||
|
vtkmesh->InsertNextCell
|
||||||
|
(
|
||||||
|
VTK_POLYHEDRON,
|
||||||
|
nodeCount,
|
||||||
|
uniqueNodeIds.data(),
|
||||||
|
faceCount,
|
||||||
|
faceLabels.data()
|
||||||
|
);
|
||||||
|
#else
|
||||||
|
vtkmesh->InsertNextCell
|
||||||
|
(
|
||||||
|
VTK_CONVEX_POINT_SET,
|
||||||
|
nodeCount,
|
||||||
|
uniqueNodeIds.data()
|
||||||
|
);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// Polyhedral cell. Decompose into tets + prisms.
|
// Polyhedral cell. Decompose into tets + prisms.
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -37,6 +37,8 @@ InClass
|
|||||||
#include "vtkPointData.h"
|
#include "vtkPointData.h"
|
||||||
#include "vtkPolyData.h"
|
#include "vtkPolyData.h"
|
||||||
|
|
||||||
|
#include "vtkOpenFOAMTupleRemap.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
@ -61,10 +63,12 @@ void Foam::vtkPV3Foam::convertPatchField
|
|||||||
forAll(ptf, i)
|
forAll(ptf, i)
|
||||||
{
|
{
|
||||||
const Type& t = ptf[i];
|
const Type& t = ptf[i];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
cellData->InsertTuple(i, vec);
|
cellData->InsertTuple(i, vec);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -101,10 +105,11 @@ void Foam::vtkPV3Foam::convertPatchPointField
|
|||||||
forAll(pptf, i)
|
forAll(pptf, i)
|
||||||
{
|
{
|
||||||
const Type& t = pptf[i];
|
const Type& t = pptf[i];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
pointData->InsertTuple(i, vec);
|
pointData->InsertTuple(i, vec);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -33,6 +33,8 @@ InClass
|
|||||||
// Foam includes
|
// Foam includes
|
||||||
#include "interpolatePointToCell.H"
|
#include "interpolatePointToCell.H"
|
||||||
|
|
||||||
|
#include "vtkOpenFOAMTupleRemap.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
@ -210,10 +212,12 @@ void Foam::vtkPV3Foam::convertPointField
|
|||||||
forAll(pointMap, i)
|
forAll(pointMap, i)
|
||||||
{
|
{
|
||||||
const Type& t = ptf[pointMap[i]];
|
const Type& t = ptf[pointMap[i]];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
pointData->InsertTuple(i, vec);
|
pointData->InsertTuple(i, vec);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -222,10 +226,12 @@ void Foam::vtkPV3Foam::convertPointField
|
|||||||
forAll(ptf, i)
|
forAll(ptf, i)
|
||||||
{
|
{
|
||||||
const Type& t = ptf[i];
|
const Type& t = ptf[i];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
pointData->InsertTuple(i, vec);
|
pointData->InsertTuple(i, vec);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -238,10 +244,12 @@ void Foam::vtkPV3Foam::convertPointField
|
|||||||
forAll(addPointCellLabels, apI)
|
forAll(addPointCellLabels, apI)
|
||||||
{
|
{
|
||||||
const Type& t = tf[addPointCellLabels[apI]];
|
const Type& t = tf[addPointCellLabels[apI]];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
pointData->InsertTuple(i++, vec);
|
pointData->InsertTuple(i++, vec);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -250,10 +258,12 @@ void Foam::vtkPV3Foam::convertPointField
|
|||||||
forAll(addPointCellLabels, apI)
|
forAll(addPointCellLabels, apI)
|
||||||
{
|
{
|
||||||
Type t = interpolatePointToCell(ptf, addPointCellLabels[apI]);
|
Type t = interpolatePointToCell(ptf, addPointCellLabels[apI]);
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
pointData->InsertTuple(i++, vec);
|
pointData->InsertTuple(i++, vec);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -39,6 +39,8 @@ InClass
|
|||||||
#include "vtkPV3FoamFaceField.H"
|
#include "vtkPV3FoamFaceField.H"
|
||||||
#include "vtkPV3FoamPatchField.H"
|
#include "vtkPV3FoamPatchField.H"
|
||||||
|
|
||||||
|
#include "vtkOpenFOAMTupleRemap.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
@ -350,10 +352,12 @@ void Foam::vtkPV3Foam::convertVolField
|
|||||||
forAll(superCells, i)
|
forAll(superCells, i)
|
||||||
{
|
{
|
||||||
const Type& t = tf[superCells[i]];
|
const Type& t = tf[superCells[i]];
|
||||||
for (direction d=0; d<nComp; d++)
|
for (direction d=0; d<nComp; ++d)
|
||||||
{
|
{
|
||||||
vec[d] = component(t, d);
|
vec[d] = component(t, d);
|
||||||
}
|
}
|
||||||
|
vtkOpenFOAMTupleRemap<Type>(vec);
|
||||||
|
|
||||||
celldata->InsertTuple(i, vec);
|
celldata->InsertTuple(i, vec);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -114,6 +114,7 @@ fi
|
|||||||
|
|
||||||
#
|
#
|
||||||
# remove files (mesh itself, modifiers, snappyHexMesh ones) and subdirectories
|
# remove files (mesh itself, modifiers, snappyHexMesh ones) and subdirectories
|
||||||
|
# also remove .gz versions of the same files
|
||||||
#
|
#
|
||||||
echo "Clearing ${caseDir:-.}/$meshDir" 1>&2
|
echo "Clearing ${caseDir:-.}/$meshDir" 1>&2
|
||||||
|
|
||||||
@ -134,25 +135,9 @@ for i in \
|
|||||||
pointLevel \
|
pointLevel \
|
||||||
refinementHistory \
|
refinementHistory \
|
||||||
surfaceIndex \
|
surfaceIndex \
|
||||||
points.gz \
|
|
||||||
faces.gz \
|
|
||||||
owner.gz \
|
|
||||||
neighbour.gz \
|
|
||||||
cells.gz \
|
|
||||||
boundary.gz \
|
|
||||||
pointZones.gz \
|
|
||||||
faceZones.gz \
|
|
||||||
cellZones.gz \
|
|
||||||
meshModifiers.gz \
|
|
||||||
parallelData.gz \
|
|
||||||
sets.gz \
|
|
||||||
cellLevel.gz \
|
|
||||||
pointLevel.gz \
|
|
||||||
refinementHistory.gz \
|
|
||||||
surfaceIndex.gz \
|
|
||||||
;
|
;
|
||||||
do
|
do
|
||||||
rm -rf $meshDir/$i
|
rm -rf $meshDir/$i $meshDir/$i.gz
|
||||||
done
|
done
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
38
bin/paraFoam
38
bin/paraFoam
@ -44,6 +44,7 @@ options:
|
|||||||
-case <dir> specify alternative case directory, default is the cwd
|
-case <dir> specify alternative case directory, default is the cwd
|
||||||
-region <name> specify alternative mesh region
|
-region <name> specify alternative mesh region
|
||||||
-touch only create the file (eg, .blockMesh, .OpenFOAM, etc)
|
-touch only create the file (eg, .blockMesh, .OpenFOAM, etc)
|
||||||
|
-touchAll create .blockMesh, .OpenFOAM files (and for all regions)
|
||||||
-help print the usage
|
-help print the usage
|
||||||
|
|
||||||
* start paraview $ParaView_VERSION with the OpenFOAM libraries
|
* start paraview $ParaView_VERSION with the OpenFOAM libraries
|
||||||
@ -52,7 +53,7 @@ USAGE
|
|||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
unset regionName touchOnly
|
unset regionName touchOpt
|
||||||
|
|
||||||
# reader extension
|
# reader extension
|
||||||
extension=OpenFOAM
|
extension=OpenFOAM
|
||||||
@ -83,7 +84,11 @@ do
|
|||||||
shift 2
|
shift 2
|
||||||
;;
|
;;
|
||||||
-touch)
|
-touch)
|
||||||
touchOnly=true
|
touchOpt=true
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-touchAll)
|
||||||
|
touchOpt=all
|
||||||
shift
|
shift
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
@ -103,12 +108,35 @@ then
|
|||||||
fvControls="$fvControls/$regionName"
|
fvControls="$fvControls/$regionName"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -n "$touchOnly" ]
|
case "${touchOpt:-false}" in
|
||||||
then
|
all)
|
||||||
|
extension=OpenFOAM
|
||||||
|
if [ -f constant/polyMesh/blockMeshDict ]
|
||||||
|
then
|
||||||
|
touch "$caseName.blockMesh"
|
||||||
|
echo "created '$caseName.blockMesh'"
|
||||||
|
fi
|
||||||
|
touch "$caseName.$extension"
|
||||||
|
echo "created '$caseName.$extension'"
|
||||||
|
# discover probable regions
|
||||||
|
for region in constant/*
|
||||||
|
do
|
||||||
|
if [ -d $region -a -d $region/polyMesh ]
|
||||||
|
then
|
||||||
|
regionName=${region##*/}
|
||||||
|
touch "$caseName{$regionName}.$extension"
|
||||||
|
echo "created '$caseName{$regionName}.$extension'"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
exit 0
|
||||||
|
;;
|
||||||
|
true)
|
||||||
touch "$caseFile"
|
touch "$caseFile"
|
||||||
echo "created '$caseFile'"
|
echo "created '$caseFile'"
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
|
||||||
# parent directory for normal or parallel results
|
# parent directory for normal or parallel results
|
||||||
case "$caseName" in
|
case "$caseName" in
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
# ========= |
|
# ========= |
|
||||||
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
# \\ / O peration |
|
# \\ / O peration |
|
||||||
# \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
# \\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
# \\/ M anipulation |
|
# \\/ M anipulation |
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
# License
|
# License
|
||||||
@ -56,6 +56,11 @@ alias app 'cd $FOAM_APP'
|
|||||||
alias util 'cd $FOAM_UTILITIES'
|
alias util 'cd $FOAM_UTILITIES'
|
||||||
alias sol 'cd $FOAM_SOLVERS'
|
alias sol 'cd $FOAM_SOLVERS'
|
||||||
alias tut 'cd $FOAM_TUTORIALS'
|
alias tut 'cd $FOAM_TUTORIALS'
|
||||||
|
|
||||||
|
alias foamApps 'cd $FOAM_APP'
|
||||||
|
alias foamSol 'cd $FOAM_SOLVERS'
|
||||||
|
alias foamTuts 'cd $FOAM_TUTORIALS'
|
||||||
|
alias foamUtils 'cd $FOAM_UTILITIES'
|
||||||
alias foam3rdParty 'cd $WM_THIRD_PARTY_DIR'
|
alias foam3rdParty 'cd $WM_THIRD_PARTY_DIR'
|
||||||
|
|
||||||
# -----------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
# ========= |
|
# ========= |
|
||||||
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
# \\ / O peration |
|
# \\ / O peration |
|
||||||
# \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
# \\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
# \\/ M anipulation |
|
# \\/ M anipulation |
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
# License
|
# License
|
||||||
@ -56,6 +56,11 @@ alias app='cd $FOAM_APP'
|
|||||||
alias util='cd $FOAM_UTILITIES'
|
alias util='cd $FOAM_UTILITIES'
|
||||||
alias sol='cd $FOAM_SOLVERS'
|
alias sol='cd $FOAM_SOLVERS'
|
||||||
alias tut='cd $FOAM_TUTORIALS'
|
alias tut='cd $FOAM_TUTORIALS'
|
||||||
|
|
||||||
|
alias foamApps='cd $FOAM_APP'
|
||||||
|
alias foamSol='cd $FOAM_SOLVERS'
|
||||||
|
alias foamTuts='cd $FOAM_TUTORIALS'
|
||||||
|
alias foamUtils='cd $FOAM_UTILITIES'
|
||||||
alias foam3rdParty='cd $WM_THIRD_PARTY_DIR'
|
alias foam3rdParty='cd $WM_THIRD_PARTY_DIR'
|
||||||
|
|
||||||
# -----------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
# ========= |
|
# ========= |
|
||||||
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
# \\ / O peration |
|
# \\ / O peration |
|
||||||
# \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
# \\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
# \\/ M anipulation |
|
# \\/ M anipulation |
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
# License
|
# License
|
||||||
@ -26,7 +26,7 @@
|
|||||||
# ensight/bashrc
|
# ensight/bashrc
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# Setup file for Ensight 8.?
|
# Setup file for Ensight
|
||||||
# Sourced from OpenFOAM-*/etc/bashrc
|
# Sourced from OpenFOAM-*/etc/bashrc
|
||||||
#
|
#
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
@ -40,7 +40,7 @@ fi
|
|||||||
if [ -r $CEI_HOME ]
|
if [ -r $CEI_HOME ]
|
||||||
then
|
then
|
||||||
|
|
||||||
# special treatment for 32bit FOAM and 64bit Ensight
|
# special treatment for 32bit OpenFOAM and 64bit Ensight
|
||||||
if [ "$WM_ARCH" = linux -a `uname -m` = x86_64 ]
|
if [ "$WM_ARCH" = linux -a `uname -m` = x86_64 ]
|
||||||
then
|
then
|
||||||
export CEI_ARCH=linux_2.6_32
|
export CEI_ARCH=linux_2.6_32
|
||||||
@ -52,8 +52,8 @@ then
|
|||||||
export PATH=$CEI_HOME/bin:$PATH
|
export PATH=$CEI_HOME/bin:$PATH
|
||||||
fi
|
fi
|
||||||
|
|
||||||
export ENSIGHT8_INPUT=dummy
|
export ENSIGHT9_INPUT=dummy
|
||||||
export ENSIGHT8_READER=$FOAM_LIBBIN
|
export ENSIGHT9_READER=$FOAM_LIBBIN
|
||||||
else
|
else
|
||||||
unset CEI_HOME
|
unset CEI_HOME
|
||||||
fi
|
fi
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
# ========= |
|
# ========= |
|
||||||
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
# \\ / O peration |
|
# \\ / O peration |
|
||||||
# \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
# \\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
# \\/ M anipulation |
|
# \\/ M anipulation |
|
||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
# License
|
# License
|
||||||
@ -26,7 +26,7 @@
|
|||||||
# ensight/cshrc
|
# ensight/cshrc
|
||||||
#
|
#
|
||||||
# Description
|
# Description
|
||||||
# Setup file for Ensight 8.?
|
# Setup file for Ensight
|
||||||
# Sourced from OpenFOAM-*/etc/cshrc
|
# Sourced from OpenFOAM-*/etc/cshrc
|
||||||
#
|
#
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
@ -38,15 +38,16 @@ endif
|
|||||||
|
|
||||||
if ( -r $CEI_HOME ) then
|
if ( -r $CEI_HOME ) then
|
||||||
|
|
||||||
# special treatment for 32bit FOAM and 64bit Ensight
|
# special treatment for 32bit OpenFOAM and 64bit Ensight
|
||||||
if ($WM_ARCH == linux) then
|
if ($WM_ARCH == linux && `uname -m` == x86_64) then
|
||||||
setenv CEI_ARCH linux_linux_2.6_32
|
setenv CEI_ARCH linux_2.6_32
|
||||||
endif
|
endif
|
||||||
|
|
||||||
set path=($path $CEI_HOME/bin)
|
# add to path
|
||||||
|
set path=($CEI_HOME/bin $path)
|
||||||
|
|
||||||
setenv ENSIGHT8_INPUT dummy
|
setenv ENSIGHT9_INPUT dummy
|
||||||
setenv ENSIGHT8_READER $FOAM_LIBBIN
|
setenv ENSIGHT9_READER $FOAM_LIBBIN
|
||||||
else
|
else
|
||||||
unsetenv CEI_HOME
|
unsetenv CEI_HOME
|
||||||
endif
|
endif
|
||||||
|
|||||||
@ -147,6 +147,30 @@ case OPENMPI:
|
|||||||
unset mpi_version
|
unset mpi_version
|
||||||
breaksw
|
breaksw
|
||||||
|
|
||||||
|
case SYSTEMOPENMPI:
|
||||||
|
|
||||||
|
# This uses the installed openmpi. It needs mpicc installed!
|
||||||
|
|
||||||
|
set mpi_version=openmpi-system
|
||||||
|
|
||||||
|
# Set compilation flags here instead of in wmake/rules/../mplibSYSTEMOPENMPI
|
||||||
|
setenv PINC `mpicc --showme:compile`
|
||||||
|
setenv PLIBS `mpicc --showme:link`
|
||||||
|
set libDir=`echo "$PLIBS" | sed -e 's/.*-L\([^ ]*\).*/\1/'`
|
||||||
|
|
||||||
|
if ($?FOAM_VERBOSE && $?prompt) then
|
||||||
|
echo "Using system installed MPI:"
|
||||||
|
echo " compile flags : $PINC"
|
||||||
|
echo " link flags : $PLIBS"
|
||||||
|
echo " libmpi dir : $libDir"
|
||||||
|
endif
|
||||||
|
|
||||||
|
_foamAddLib $libDir
|
||||||
|
|
||||||
|
setenv FOAM_MPI_LIBBIN $FOAM_LIBBIN/$mpi_version
|
||||||
|
unset mpi_version libDir
|
||||||
|
breaksw
|
||||||
|
|
||||||
case MPICH:
|
case MPICH:
|
||||||
set mpi_version=mpich2-1.1.1p1
|
set mpi_version=mpich2-1.1.1p1
|
||||||
setenv MPI_HOME $WM_THIRD_PARTY_DIR/$mpi_version
|
setenv MPI_HOME $WM_THIRD_PARTY_DIR/$mpi_version
|
||||||
|
|||||||
@ -183,6 +183,28 @@ OPENMPI)
|
|||||||
unset mpi_version
|
unset mpi_version
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
SYSTEMOPENMPI)
|
||||||
|
mpi_version=openmpi-system
|
||||||
|
|
||||||
|
# Set compilation flags here instead of in wmake/rules/../mplibSYSTEMOPENMPI
|
||||||
|
export PINC=`mpicc --showme:compile`
|
||||||
|
export PLIBS=`mpicc --showme:link`
|
||||||
|
libDir=`echo "$PLIBS" | sed -e 's/.*-L\([^ ]*\).*/\1/'`
|
||||||
|
|
||||||
|
if [ "$FOAM_VERBOSE" -a "$PS1" ]
|
||||||
|
then
|
||||||
|
echo "Using system installed MPI:"
|
||||||
|
echo " compile flags : $PINC"
|
||||||
|
echo " link flags : $PLIBS"
|
||||||
|
echo " libmpi dir : $libDir"
|
||||||
|
fi
|
||||||
|
|
||||||
|
_foamAddLib $libDir
|
||||||
|
|
||||||
|
export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/$mpi_version
|
||||||
|
unset mpi_version libDir
|
||||||
|
;;
|
||||||
|
|
||||||
MPICH)
|
MPICH)
|
||||||
mpi_version=mpich2-1.1.1p1
|
mpi_version=mpich2-1.1.1p1
|
||||||
export MPI_HOME=$WM_THIRD_PARTY_DIR/$mpi_version
|
export MPI_HOME=$WM_THIRD_PARTY_DIR/$mpi_version
|
||||||
|
|||||||
10
src/Allwmake
10
src/Allwmake
@ -27,14 +27,18 @@ wmake libso edgeMesh
|
|||||||
wmake libso surfMesh
|
wmake libso surfMesh
|
||||||
wmake libso triSurface
|
wmake libso triSurface
|
||||||
|
|
||||||
# Decomposition methods needed by meshTools
|
# Decomposition methods needed by dummyThirdParty
|
||||||
wmake libso parallel/decompositionMethods
|
parallel/AllwmakeLnInclude
|
||||||
wmake libso parallel/metisDecomp
|
# dummyThirdParty (dummy metisDecomp, scotchDecomp etc) needed by e.g. meshTools
|
||||||
|
dummyThirdParty/Allwmake
|
||||||
|
|
||||||
wmake libso meshTools
|
wmake libso meshTools
|
||||||
wmake libso finiteVolume
|
wmake libso finiteVolume
|
||||||
wmake libso genericPatchFields
|
wmake libso genericPatchFields
|
||||||
|
|
||||||
|
# Build the proper scotchDecomp, metisDecomp etc.
|
||||||
|
parallel/Allwmake
|
||||||
|
|
||||||
wmake libso sampling
|
wmake libso sampling
|
||||||
|
|
||||||
wmake libso dynamicMesh
|
wmake libso dynamicMesh
|
||||||
|
|||||||
@ -466,40 +466,6 @@ void Foam::FaceCellWave<Type>::transform
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Send face info to neighbour.
|
|
||||||
template <class Type>
|
|
||||||
void Foam::FaceCellWave<Type>::sendPatchInfo
|
|
||||||
(
|
|
||||||
const label neighbour,
|
|
||||||
const label nFaces,
|
|
||||||
const labelList& faceLabels,
|
|
||||||
const List<Type>& faceInfo
|
|
||||||
) const
|
|
||||||
{
|
|
||||||
OPstream toNeighbour(Pstream::blocking, neighbour);
|
|
||||||
|
|
||||||
writeFaces(nFaces, faceLabels, faceInfo, toNeighbour);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// Receive face info from neighbour
|
|
||||||
template <class Type>
|
|
||||||
Foam::label Foam::FaceCellWave<Type>::receivePatchInfo
|
|
||||||
(
|
|
||||||
const label neighbour,
|
|
||||||
labelList& faceLabels,
|
|
||||||
List<Type>& faceInfo
|
|
||||||
) const
|
|
||||||
{
|
|
||||||
IPstream fromNeighbour(Pstream::blocking, neighbour);
|
|
||||||
|
|
||||||
label nFaces = 0;
|
|
||||||
readFaces(nFaces, faceLabels, faceInfo, fromNeighbour);
|
|
||||||
|
|
||||||
return nFaces;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// Offset mesh face. Used for transferring from one cyclic half to the other.
|
// Offset mesh face. Used for transferring from one cyclic half to the other.
|
||||||
template <class Type>
|
template <class Type>
|
||||||
void Foam::FaceCellWave<Type>::offset
|
void Foam::FaceCellWave<Type>::offset
|
||||||
@ -523,6 +489,8 @@ void Foam::FaceCellWave<Type>::handleProcPatches()
|
|||||||
{
|
{
|
||||||
// Send all
|
// Send all
|
||||||
|
|
||||||
|
PstreamBuffers pBufs(Pstream::nonBlocking);
|
||||||
|
|
||||||
forAll(mesh_.boundaryMesh(), patchI)
|
forAll(mesh_.boundaryMesh(), patchI)
|
||||||
{
|
{
|
||||||
const polyPatch& patch = mesh_.boundaryMesh()[patchI];
|
const polyPatch& patch = mesh_.boundaryMesh()[patchI];
|
||||||
@ -564,16 +532,13 @@ void Foam::FaceCellWave<Type>::handleProcPatches()
|
|||||||
<< endl;
|
<< endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
sendPatchInfo
|
UOPstream toNeighbour(procPatch.neighbProcNo(), pBufs);
|
||||||
(
|
writeFaces(nSendFaces, sendFaces, sendFacesInfo, toNeighbour);
|
||||||
procPatch.neighbProcNo(),
|
|
||||||
nSendFaces,
|
|
||||||
sendFaces,
|
|
||||||
sendFacesInfo
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pBufs.finishedSends();
|
||||||
|
|
||||||
// Receive all
|
// Receive all
|
||||||
|
|
||||||
forAll(mesh_.boundaryMesh(), patchI)
|
forAll(mesh_.boundaryMesh(), patchI)
|
||||||
@ -586,16 +551,20 @@ void Foam::FaceCellWave<Type>::handleProcPatches()
|
|||||||
refCast<const processorPolyPatch>(patch);
|
refCast<const processorPolyPatch>(patch);
|
||||||
|
|
||||||
// Allocate buffers
|
// Allocate buffers
|
||||||
label nReceiveFaces;
|
label nReceiveFaces = 0;
|
||||||
labelList receiveFaces(patch.size());
|
labelList receiveFaces(patch.size());
|
||||||
List<Type> receiveFacesInfo(patch.size());
|
List<Type> receiveFacesInfo(patch.size());
|
||||||
|
|
||||||
nReceiveFaces = receivePatchInfo
|
{
|
||||||
(
|
UIPstream fromNeighbour(procPatch.neighbProcNo(), pBufs);
|
||||||
procPatch.neighbProcNo(),
|
readFaces
|
||||||
receiveFaces,
|
(
|
||||||
receiveFacesInfo
|
nReceiveFaces,
|
||||||
);
|
receiveFaces,
|
||||||
|
receiveFacesInfo,
|
||||||
|
fromNeighbour
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
if (debug)
|
if (debug)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -225,23 +225,6 @@ class FaceCellWave
|
|||||||
List<Type>& faceInfo
|
List<Type>& faceInfo
|
||||||
) const;
|
) const;
|
||||||
|
|
||||||
//- Send info to neighbour
|
|
||||||
void sendPatchInfo
|
|
||||||
(
|
|
||||||
const label neighbour,
|
|
||||||
const label nFaces,
|
|
||||||
const labelList&,
|
|
||||||
const List<Type>&
|
|
||||||
) const;
|
|
||||||
|
|
||||||
//- Receive info from neighbour. Returns number of faces received.
|
|
||||||
label receivePatchInfo
|
|
||||||
(
|
|
||||||
const label neighbour,
|
|
||||||
labelList&,
|
|
||||||
List<Type>&
|
|
||||||
) const;
|
|
||||||
|
|
||||||
//- Offset face labels by constant value
|
//- Offset face labels by constant value
|
||||||
static void offset
|
static void offset
|
||||||
(
|
(
|
||||||
|
|||||||
58
src/OpenFOAM/global/foamDoc.H
Normal file
58
src/OpenFOAM/global/foamDoc.H
Normal file
@ -0,0 +1,58 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ 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 2 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, write to the Free Software Foundation,
|
||||||
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
@mainpage OpenFOAM®: open source CFD
|
||||||
|
|
||||||
|
@section about About OpenFOAM
|
||||||
|
|
||||||
|
OpenFOAM is a free, open source CFD software package produced by
|
||||||
|
a commercial company,
|
||||||
|
<a href="http://www.openfoam.com/about">OpenCFD Ltd</a>.
|
||||||
|
It has a
|
||||||
|
large user base across most areas of engineering and science,
|
||||||
|
from both commercial and academic organisations. OpenFOAM has an
|
||||||
|
extensive range of features to solve anything from complex fluid
|
||||||
|
flows involving chemical reactions, turbulence and heat transfer,
|
||||||
|
to solid dynamics and electromagnetics.
|
||||||
|
<a href="http://www.openfoam.com/features">More ...</a>
|
||||||
|
|
||||||
|
@section users Our commitment to the users
|
||||||
|
|
||||||
|
OpenFOAM comes with full commercial support from OpenCFD, including
|
||||||
|
<a href="http://www.openfoam.com/support/software.php">software support</a>,
|
||||||
|
<a href="http://www.openfoam.com/support/development.php">contracted developments</a>
|
||||||
|
and a programme of <a href="http://www.openfoam.com/training">training courses</a>.
|
||||||
|
These activities fund the development, maintenance and release of
|
||||||
|
OpenFOAM to make it an extremely viable commercial open source product.
|
||||||
|
|
||||||
|
@section opensource Our commitment to open source
|
||||||
|
|
||||||
|
OpenCFD is committed to open source software, continually developing and
|
||||||
|
maintaining OpenFOAM under the
|
||||||
|
<a href="http://www.gnu.org/copyleft/gpl.html">GNU General Public Licence</a>.
|
||||||
|
OpenFOAM will <strong>always</strong> be free of charge and open source.
|
||||||
|
In addition, we endeavour to support other viable open source initiatives
|
||||||
|
that will benefit science and engineering.
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -44,40 +44,6 @@ Description
|
|||||||
SourceFiles
|
SourceFiles
|
||||||
global.Cver
|
global.Cver
|
||||||
|
|
||||||
|
|
||||||
@mainpage OpenFOAM®: open source CFD
|
|
||||||
|
|
||||||
@section about About OpenFOAM
|
|
||||||
|
|
||||||
OpenFOAM is a free, open source CFD software package produced by
|
|
||||||
a commercial company,
|
|
||||||
<a href="http://www.openfoam.com/about">OpenCFD Ltd</a>.
|
|
||||||
It has a
|
|
||||||
large user base across most areas of engineering and science,
|
|
||||||
from both commercial and academic organisations. OpenFOAM has an
|
|
||||||
extensive range of features to solve anything from complex fluid
|
|
||||||
flows involving chemical reactions, turbulence and heat transfer,
|
|
||||||
to solid dynamics and electromagnetics.
|
|
||||||
<a href="http://www.openfoam.com/features">More ...</a>
|
|
||||||
|
|
||||||
@section users Our commitment to the users
|
|
||||||
|
|
||||||
OpenFOAM comes with full commercial support from OpenCFD, including
|
|
||||||
<a href="http://www.openfoam.com/support/software.php">software support</a>,
|
|
||||||
<a href="http://www.openfoam.com/support/development.php">contracted developments</a> and
|
|
||||||
a programme of <a href="http://www.openfoam.com/training">training courses</a>.
|
|
||||||
These activities fund the development, maintenance and release of
|
|
||||||
OpenFOAM to make it an extremely viable commercial open source product.
|
|
||||||
|
|
||||||
@section opensource Our commitment to open source
|
|
||||||
|
|
||||||
OpenCFD is committed to open source software, continually developing and
|
|
||||||
maintaining OpenFOAM under the
|
|
||||||
<a href="http://www.gnu.org/copyleft/gpl.html">GNU General Public Licence</a>.
|
|
||||||
OpenFOAM will <strong>always</strong> be free of charge and open source.
|
|
||||||
In addition, we endeavour to support other viable open source initiatives
|
|
||||||
that will benefit science and engineering.
|
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
#ifndef foamVersion_H
|
#ifndef foamVersion_H
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
// addOverwriteOption.H
|
// addOverwriteOption.H
|
||||||
// ~~~~~~~~~~~~~~~~~~~~
|
// ~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
Foam::argList::addOption
|
Foam::argList::addBoolOption
|
||||||
(
|
(
|
||||||
"overwrite",
|
"overwrite",
|
||||||
"overwrite existing mesh/results files"
|
"overwrite existing mesh/results files"
|
||||||
|
|||||||
@ -1,7 +1,9 @@
|
|||||||
EXE_INC = \
|
EXE_INC = \
|
||||||
|
-I$(LIB_SRC)/fileFormats/lnInclude \
|
||||||
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
||||||
-I$(LIB_SRC)/meshTools/lnInclude
|
-I$(LIB_SRC)/meshTools/lnInclude
|
||||||
|
|
||||||
LIB_LIBS = \
|
LIB_LIBS = \
|
||||||
|
-lfileFormats \
|
||||||
-lfiniteVolume \
|
-lfiniteVolume \
|
||||||
-lmeshTools
|
-lmeshTools
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -150,7 +150,7 @@ protected:
|
|||||||
virtual void writeConnectivity
|
virtual void writeConnectivity
|
||||||
(
|
(
|
||||||
ensightGeoFile& os,
|
ensightGeoFile& os,
|
||||||
const string& key,
|
const word& key,
|
||||||
const labelList& idList,
|
const labelList& idList,
|
||||||
const labelList& pointMap
|
const labelList& pointMap
|
||||||
) const
|
) const
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -345,7 +345,7 @@ Foam::ensightPart::localPoints Foam::ensightPartCells::calcLocalPoints() const
|
|||||||
void Foam::ensightPartCells::writeConnectivity
|
void Foam::ensightPartCells::writeConnectivity
|
||||||
(
|
(
|
||||||
ensightGeoFile& os,
|
ensightGeoFile& os,
|
||||||
const string& key,
|
const word& key,
|
||||||
const labelList& idList,
|
const labelList& idList,
|
||||||
const labelList& pointMap
|
const labelList& pointMap
|
||||||
) const
|
) const
|
||||||
@ -357,7 +357,7 @@ void Foam::ensightPartCells::writeConnectivity
|
|||||||
const polyMesh& mesh = *meshPtr_;
|
const polyMesh& mesh = *meshPtr_;
|
||||||
|
|
||||||
// write polyhedral
|
// write polyhedral
|
||||||
if (word(key) == "nfaced")
|
if (key == "nfaced")
|
||||||
{
|
{
|
||||||
const faceList& meshFaces = mesh.faces();
|
const faceList& meshFaces = mesh.faces();
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -70,7 +70,7 @@ class ensightPartCells
|
|||||||
virtual void writeConnectivity
|
virtual void writeConnectivity
|
||||||
(
|
(
|
||||||
ensightGeoFile& os,
|
ensightGeoFile& os,
|
||||||
const string& key,
|
const word& key,
|
||||||
const labelList& idList,
|
const labelList& idList,
|
||||||
const labelList& pointMap
|
const labelList& pointMap
|
||||||
) const;
|
) const;
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -206,7 +206,7 @@ Foam::ensightPart::localPoints Foam::ensightPartFaces::calcLocalPoints() const
|
|||||||
void Foam::ensightPartFaces::writeConnectivity
|
void Foam::ensightPartFaces::writeConnectivity
|
||||||
(
|
(
|
||||||
ensightGeoFile& os,
|
ensightGeoFile& os,
|
||||||
const string& key,
|
const word& key,
|
||||||
const labelList& idList,
|
const labelList& idList,
|
||||||
const labelList& pointMap
|
const labelList& pointMap
|
||||||
) const
|
) const
|
||||||
@ -218,7 +218,7 @@ void Foam::ensightPartFaces::writeConnectivity
|
|||||||
const faceList& meshFaces = meshPtr_->faces();
|
const faceList& meshFaces = meshPtr_->faces();
|
||||||
|
|
||||||
// write (polygon) face sizes
|
// write (polygon) face sizes
|
||||||
if (word(key) == "nsided")
|
if (key == "nsided")
|
||||||
{
|
{
|
||||||
// write the number of points per face
|
// write the number of points per face
|
||||||
forAll(idList, i)
|
forAll(idList, i)
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -63,7 +63,7 @@ class ensightPartFaces
|
|||||||
virtual void writeConnectivity
|
virtual void writeConnectivity
|
||||||
(
|
(
|
||||||
ensightGeoFile& os,
|
ensightGeoFile& os,
|
||||||
const string& key,
|
const word& key,
|
||||||
const labelList& idList,
|
const labelList& idList,
|
||||||
const labelList& pointMap
|
const labelList& pointMap
|
||||||
) const;
|
) const;
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -237,7 +237,7 @@ Body:
|
|||||||
|
|
||||||
For primitive cell shapes, the number of vertices will never exceed 8 (hexa)
|
For primitive cell shapes, the number of vertices will never exceed 8 (hexa)
|
||||||
and corresponds to <nLabels>.
|
and corresponds to <nLabels>.
|
||||||
For polyhedral, <nLabels> includess an index table comprising beg/end pairs
|
For polyhedral, <nLabels> includes an index table comprising beg/end pairs
|
||||||
for each cell face.
|
for each cell face.
|
||||||
|
|
||||||
Strictly speaking, we only need the cellModeller for adding boundaries.
|
Strictly speaking, we only need the cellModeller for adding boundaries.
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
|
|||||||
11
src/dummyThirdParty/Allwmake
vendored
Executable file
11
src/dummyThirdParty/Allwmake
vendored
Executable file
@ -0,0 +1,11 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
cd ${0%/*} || exit 1 # run from this directory
|
||||||
|
set -x
|
||||||
|
|
||||||
|
wmake libso scotchDecomp
|
||||||
|
wmake libso metisDecomp
|
||||||
|
wmake libso parMetisDecomp
|
||||||
|
wmake libso MGridGen
|
||||||
|
|
||||||
|
|
||||||
|
# ----------------------------------------------------------------- end-of-file
|
||||||
3
src/dummyThirdParty/MGridGen/Make/files
vendored
Normal file
3
src/dummyThirdParty/MGridGen/Make/files
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
dummyMGridGen.C
|
||||||
|
|
||||||
|
LIB = $(FOAM_LIBBIN)/dummy/libMGridGen
|
||||||
3
src/dummyThirdParty/MGridGen/Make/options
vendored
Normal file
3
src/dummyThirdParty/MGridGen/Make/options
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
EXE_INC =
|
||||||
|
|
||||||
|
EXE_LIBS =
|
||||||
59
src/dummyThirdParty/MGridGen/dummyMGridGen.C
vendored
Normal file
59
src/dummyThirdParty/MGridGen/dummyMGridGen.C
vendored
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ 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 2 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, write to the Free Software Foundation,
|
||||||
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
//extern "C"
|
||||||
|
//{
|
||||||
|
#include "mgridgen.h"
|
||||||
|
//}
|
||||||
|
|
||||||
|
#include "error.H"
|
||||||
|
|
||||||
|
using namespace Foam;
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
static const char* notImplementedMessage =
|
||||||
|
"You are trying to use MGridGen but do not have the MGridGen library loaded.\n"
|
||||||
|
"This message is from the dummy MGridGen stub library instead.\n"
|
||||||
|
"\n"
|
||||||
|
"Normally the MGridGen library will be loaded through the LD_LIBRARY_PATH\n"
|
||||||
|
"environment variable but you are picking up this dummy library from the\n"
|
||||||
|
"$FOAM_LIBBIN/dummy directory. Please install MGridGen and make sure the\n"
|
||||||
|
"libMGridGen.so is in your LD_LIBRARY_PATH.";
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C"
|
||||||
|
#endif
|
||||||
|
void MGridGen(int, idxtype *, realtype *, realtype *, idxtype *, realtype *,
|
||||||
|
int, int, int *, int *, int *, idxtype *)
|
||||||
|
{
|
||||||
|
FatalErrorIn("MGridGen(..)")
|
||||||
|
<< notImplementedMessage
|
||||||
|
<< Foam::exit(Foam::FatalError);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
64
src/dummyThirdParty/MGridGen/mgridgen.h
vendored
Normal file
64
src/dummyThirdParty/MGridGen/mgridgen.h
vendored
Normal file
@ -0,0 +1,64 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
||||||
|
\\/ 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 2 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, write to the Free Software Foundation,
|
||||||
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
Namespace
|
||||||
|
C linkage
|
||||||
|
|
||||||
|
Description
|
||||||
|
Dummy stub for mgridgen library functions.
|
||||||
|
Only implements the absolute minimum we are using.
|
||||||
|
|
||||||
|
SourceFiles
|
||||||
|
dummyMGridGen.C
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#ifndef mgridgen_H
|
||||||
|
#define mgridgen_H
|
||||||
|
|
||||||
|
#include "scalar.H"
|
||||||
|
|
||||||
|
#ifndef idxtype
|
||||||
|
#define idxtype int
|
||||||
|
#define realtype Foam::scalar
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
Class metis Declaration
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C"
|
||||||
|
#endif
|
||||||
|
void MGridGen(int, idxtype *, realtype *, realtype *, idxtype *, realtype *,
|
||||||
|
int, int, int *, int *, int *, idxtype *);
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
3
src/dummyThirdParty/metisDecomp/Make/files
vendored
Normal file
3
src/dummyThirdParty/metisDecomp/Make/files
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
dummyMetisDecomp.C
|
||||||
|
|
||||||
|
LIB = $(FOAM_LIBBIN)/dummy/libmetisDecomp
|
||||||
5
src/dummyThirdParty/metisDecomp/Make/options
vendored
Normal file
5
src/dummyThirdParty/metisDecomp/Make/options
vendored
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
EXE_INC = \
|
||||||
|
-I$(FOAM_SRC)/parallel/decompositionMethods/lnInclude \
|
||||||
|
-I$(FOAM_SRC)/parallel/metisDecomp/lnInclude
|
||||||
|
|
||||||
|
LIB_LIBS =
|
||||||
156
src/dummyThirdParty/metisDecomp/dummyMetisDecomp.C
vendored
Normal file
156
src/dummyThirdParty/metisDecomp/dummyMetisDecomp.C
vendored
Normal file
@ -0,0 +1,156 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ 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 2 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, write to the Free Software Foundation,
|
||||||
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#include "metisDecomp.H"
|
||||||
|
#include "addToRunTimeSelectionTable.H"
|
||||||
|
#include "Time.H"
|
||||||
|
|
||||||
|
static const char* notImplementedMessage =
|
||||||
|
"You are trying to use metis but do not have the metisDecomp library loaded."
|
||||||
|
"\nThis message is from the dummy metisDecomp stub library instead.\n"
|
||||||
|
"\n"
|
||||||
|
"Please install metis and make sure that libmetis.so is in your "
|
||||||
|
"LD_LIBRARY_PATH.\n"
|
||||||
|
"The metisDecomp library can then be built in $FOAM_SRC/decompositionMethods/"
|
||||||
|
"metisDecomp\n";
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
namespace Foam
|
||||||
|
{
|
||||||
|
defineTypeNameAndDebug(metisDecomp, 0);
|
||||||
|
|
||||||
|
addToRunTimeSelectionTable
|
||||||
|
(
|
||||||
|
decompositionMethod,
|
||||||
|
metisDecomp,
|
||||||
|
dictionaryMesh
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::label Foam::metisDecomp::decompose
|
||||||
|
(
|
||||||
|
const List<int>& adjncy,
|
||||||
|
const List<int>& xadj,
|
||||||
|
const scalarField& cellWeights,
|
||||||
|
List<int>& finalDecomp
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList metisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const List<int>&, "
|
||||||
|
"const List<int>&, "
|
||||||
|
"const scalarField&, "
|
||||||
|
"List<int>&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::metisDecomp::metisDecomp
|
||||||
|
(
|
||||||
|
const dictionary& decompositionDict,
|
||||||
|
const polyMesh& mesh
|
||||||
|
)
|
||||||
|
:
|
||||||
|
decompositionMethod(decompositionDict),
|
||||||
|
mesh_(mesh)
|
||||||
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::labelList Foam::metisDecomp::decompose
|
||||||
|
(
|
||||||
|
const pointField& points,
|
||||||
|
const scalarField& pointWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList metisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Foam::labelList Foam::metisDecomp::decompose
|
||||||
|
(
|
||||||
|
const labelList& agglom,
|
||||||
|
const pointField& agglomPoints,
|
||||||
|
const scalarField& agglomWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList metisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const labelList&, "
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Foam::labelList Foam::metisDecomp::decompose
|
||||||
|
(
|
||||||
|
const labelListList& globalCellCells,
|
||||||
|
const pointField& cellCentres,
|
||||||
|
const scalarField& cellWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList metisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const labelListList&, "
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
3
src/dummyThirdParty/parMetisDecomp/Make/files
vendored
Normal file
3
src/dummyThirdParty/parMetisDecomp/Make/files
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
dummyParMetisDecomp.C
|
||||||
|
|
||||||
|
LIB = $(FOAM_LIBBIN)/dummy/libparMetisDecomp
|
||||||
5
src/dummyThirdParty/parMetisDecomp/Make/options
vendored
Normal file
5
src/dummyThirdParty/parMetisDecomp/Make/options
vendored
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
EXE_INC = \
|
||||||
|
-I$(FOAM_SRC)/parallel/decompositionMethods/lnInclude \
|
||||||
|
-I$(FOAM_SRC)/parallel/parMetisDecomp/lnInclude
|
||||||
|
|
||||||
|
LIB_LIBS =
|
||||||
185
src/dummyThirdParty/parMetisDecomp/dummyParMetisDecomp.C
vendored
Normal file
185
src/dummyThirdParty/parMetisDecomp/dummyParMetisDecomp.C
vendored
Normal file
@ -0,0 +1,185 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ 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 2 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, write to the Free Software Foundation,
|
||||||
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#include "parMetisDecomp.H"
|
||||||
|
#include "addToRunTimeSelectionTable.H"
|
||||||
|
#include "polyMesh.H"
|
||||||
|
#include "Time.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
namespace Foam
|
||||||
|
{
|
||||||
|
defineTypeNameAndDebug(parMetisDecomp, 0);
|
||||||
|
|
||||||
|
addToRunTimeSelectionTable
|
||||||
|
(
|
||||||
|
decompositionMethod,
|
||||||
|
parMetisDecomp,
|
||||||
|
dictionaryMesh
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
static const char* notImplementedMessage =
|
||||||
|
"You are trying to use parMetis but do not have the parMetisDecomp library "
|
||||||
|
"loaded.\n"
|
||||||
|
"This message is from the dummy parMetisDecomp stub library instead.\n"
|
||||||
|
"\n"
|
||||||
|
"Please install parMetis and make sure that libparMetis.so is in your "
|
||||||
|
"LD_LIBRARY_PATH.\n"
|
||||||
|
"The parMetisDecomp library can then be built in $FOAM_SRC/decompositionMethods/"
|
||||||
|
"parMetisDecomp\n";
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
|
||||||
|
|
||||||
|
//- Does prevention of 0 cell domains and calls parmetis.
|
||||||
|
Foam::label Foam::parMetisDecomp::decompose
|
||||||
|
(
|
||||||
|
Field<int>& xadj,
|
||||||
|
Field<int>& adjncy,
|
||||||
|
const pointField& cellCentres,
|
||||||
|
Field<int>& cellWeights,
|
||||||
|
Field<int>& faceWeights,
|
||||||
|
const List<int>& options,
|
||||||
|
|
||||||
|
List<int>& finalDecomp
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"label parMetisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"Field<int>&, "
|
||||||
|
"Field<int>&, "
|
||||||
|
"const pointField&, "
|
||||||
|
"Field<int>&, "
|
||||||
|
"Field<int>&, "
|
||||||
|
"const List<int>&, "
|
||||||
|
"List<int>&"
|
||||||
|
")"
|
||||||
|
)<< notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::parMetisDecomp::parMetisDecomp
|
||||||
|
(
|
||||||
|
const dictionary& decompositionDict,
|
||||||
|
const polyMesh& mesh
|
||||||
|
)
|
||||||
|
:
|
||||||
|
decompositionMethod(decompositionDict),
|
||||||
|
mesh_(mesh)
|
||||||
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::labelList Foam::parMetisDecomp::decompose
|
||||||
|
(
|
||||||
|
const pointField& cc,
|
||||||
|
const scalarField& cWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList parMetisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Foam::labelList Foam::parMetisDecomp::decompose
|
||||||
|
(
|
||||||
|
const labelList& cellToRegion,
|
||||||
|
const pointField& regionPoints,
|
||||||
|
const scalarField& regionWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList parMetisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const labelList&, "
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Foam::labelList Foam::parMetisDecomp::decompose
|
||||||
|
(
|
||||||
|
const labelListList& globalCellCells,
|
||||||
|
const pointField& cellCentres,
|
||||||
|
const scalarField& cWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList parMetisDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const labelListList&, "
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void Foam::parMetisDecomp::calcMetisDistributedCSR
|
||||||
|
(
|
||||||
|
const polyMesh& mesh,
|
||||||
|
List<int>& adjncy,
|
||||||
|
List<int>& xadj
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"void parMetisDecomp::calcMetisDistributedCSR"
|
||||||
|
"("
|
||||||
|
"const polyMesh&, "
|
||||||
|
"List<int>&, "
|
||||||
|
"List<int>&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
3
src/dummyThirdParty/scotchDecomp/Make/files
vendored
Normal file
3
src/dummyThirdParty/scotchDecomp/Make/files
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
dummyScotchDecomp.C
|
||||||
|
|
||||||
|
LIB = $(FOAM_LIBBIN)/dummy/libscotchDecomp
|
||||||
6
src/dummyThirdParty/scotchDecomp/Make/options
vendored
Normal file
6
src/dummyThirdParty/scotchDecomp/Make/options
vendored
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
EXE_INC = \
|
||||||
|
-I$(FOAM_SRC)/parallel/decompositionMethods/lnInclude \
|
||||||
|
-I$(FOAM_SRC)/parallel/scotchDecomp/lnInclude
|
||||||
|
|
||||||
|
LIB_LIBS =
|
||||||
|
|
||||||
280
src/dummyThirdParty/scotchDecomp/dummyScotchDecomp.C
vendored
Normal file
280
src/dummyThirdParty/scotchDecomp/dummyScotchDecomp.C
vendored
Normal file
@ -0,0 +1,280 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ 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 2 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, write to the Free Software Foundation,
|
||||||
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
|
From scotch forum:
|
||||||
|
|
||||||
|
By: Francois PELLEGRINI RE: Graph mapping 'strategy' string [ reply ]
|
||||||
|
2008-08-22 10:09 Strategy handling in Scotch is a bit tricky. In order
|
||||||
|
not to be confused, you must have a clear view of how they are built.
|
||||||
|
Here are some rules:
|
||||||
|
|
||||||
|
1- Strategies are made up of "methods" which are combined by means of
|
||||||
|
"operators".
|
||||||
|
|
||||||
|
2- A method is of the form "m{param=value,param=value,...}", where "m"
|
||||||
|
is a single character (this is your first error: "f" is a method name,
|
||||||
|
not a parameter name).
|
||||||
|
|
||||||
|
3- There exist different sort of strategies : bipartitioning strategies,
|
||||||
|
mapping strategies, ordering strategies, which cannot be mixed. For
|
||||||
|
instance, you cannot build a bipartitioning strategy and feed it to a
|
||||||
|
mapping method (this is your second error).
|
||||||
|
|
||||||
|
To use the "mapCompute" routine, you must create a mapping strategy, not
|
||||||
|
a bipartitioning one, and so use stratGraphMap() and not
|
||||||
|
stratGraphBipart(). Your mapping strategy should however be based on the
|
||||||
|
"recursive bipartitioning" method ("b"). For instance, a simple (and
|
||||||
|
hence not very efficient) mapping strategy can be :
|
||||||
|
|
||||||
|
"b{sep=f}"
|
||||||
|
|
||||||
|
which computes mappings with the recursive bipartitioning method "b",
|
||||||
|
this latter using the Fiduccia-Mattheyses method "f" to compute its
|
||||||
|
separators.
|
||||||
|
|
||||||
|
If you want an exact partition (see your previous post), try
|
||||||
|
"b{sep=fx}".
|
||||||
|
|
||||||
|
However, these strategies are not the most efficient, as they do not
|
||||||
|
make use of the multi-level framework.
|
||||||
|
|
||||||
|
To use the multi-level framework, try for instance:
|
||||||
|
|
||||||
|
"b{sep=m{vert=100,low=h,asc=f}x}"
|
||||||
|
|
||||||
|
The current default mapping strategy in Scotch can be seen by using the
|
||||||
|
"-vs" option of program gmap. It is, to date:
|
||||||
|
|
||||||
|
b
|
||||||
|
{
|
||||||
|
job=t,
|
||||||
|
map=t,
|
||||||
|
poli=S,
|
||||||
|
sep=
|
||||||
|
(
|
||||||
|
m
|
||||||
|
{
|
||||||
|
asc=b
|
||||||
|
{
|
||||||
|
bnd=d{pass=40,dif=1,rem=1}f{move=80,pass=-1,bal=0.005},
|
||||||
|
org=f{move=80,pass=-1,bal=0.005},
|
||||||
|
width=3
|
||||||
|
},
|
||||||
|
low=h{pass=10}f{move=80,pass=-1,bal=0.0005},
|
||||||
|
type=h,
|
||||||
|
vert=80,
|
||||||
|
rat=0.8
|
||||||
|
}
|
||||||
|
| m
|
||||||
|
{
|
||||||
|
asc=b
|
||||||
|
{
|
||||||
|
bnd=d{pass=40,dif=1,rem=1}f{move=80,pass=-1,bal=0.005},
|
||||||
|
org=f{move=80,pass=-1,bal=0.005},
|
||||||
|
width=3
|
||||||
|
},
|
||||||
|
low=h{pass=10}f{move=80,pass=-1,bal=0.0005},
|
||||||
|
type=h,
|
||||||
|
vert=80,
|
||||||
|
rat=0.8
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#include "scotchDecomp.H"
|
||||||
|
#include "addToRunTimeSelectionTable.H"
|
||||||
|
#include "Time.H"
|
||||||
|
|
||||||
|
static const char* notImplementedMessage =
|
||||||
|
"You are trying to use scotch but do not have the scotchDecomp library loaded."
|
||||||
|
"\nThis message is from the dummy scotchDecomp stub library instead.\n"
|
||||||
|
"\n"
|
||||||
|
"Please install scotch and make sure that libscotch.so is in your "
|
||||||
|
"LD_LIBRARY_PATH.\n"
|
||||||
|
"The scotchDecomp library can then be built in $FOAM_SRC/decompositionMethods/"
|
||||||
|
"scotchDecomp\n";
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
namespace Foam
|
||||||
|
{
|
||||||
|
defineTypeNameAndDebug(scotchDecomp, 0);
|
||||||
|
|
||||||
|
addToRunTimeSelectionTable
|
||||||
|
(
|
||||||
|
decompositionMethod,
|
||||||
|
scotchDecomp,
|
||||||
|
dictionaryMesh
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
|
||||||
|
|
||||||
|
void Foam::scotchDecomp::check(const int retVal, const char* str)
|
||||||
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
Foam::label Foam::scotchDecomp::decompose
|
||||||
|
(
|
||||||
|
const List<int>& adjncy,
|
||||||
|
const List<int>& xadj,
|
||||||
|
const scalarField& cWeights,
|
||||||
|
|
||||||
|
List<int>& finalDecomp
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"label scotchDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const List<int>&, "
|
||||||
|
"const List<int>&, "
|
||||||
|
"const scalarField&, "
|
||||||
|
"List<int>&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::scotchDecomp::scotchDecomp
|
||||||
|
(
|
||||||
|
const dictionary& decompositionDict,
|
||||||
|
const polyMesh& mesh
|
||||||
|
)
|
||||||
|
:
|
||||||
|
decompositionMethod(decompositionDict),
|
||||||
|
mesh_(mesh)
|
||||||
|
{}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Foam::labelList Foam::scotchDecomp::decompose
|
||||||
|
(
|
||||||
|
const pointField& points,
|
||||||
|
const scalarField& pointWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList scotchDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList::null();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Foam::labelList Foam::scotchDecomp::decompose
|
||||||
|
(
|
||||||
|
const labelList& agglom,
|
||||||
|
const pointField& agglomPoints,
|
||||||
|
const scalarField& pointWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList scotchDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const labelList&, "
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList::null();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Foam::labelList Foam::scotchDecomp::decompose
|
||||||
|
(
|
||||||
|
const labelListList& globalCellCells,
|
||||||
|
const pointField& cellCentres,
|
||||||
|
const scalarField& cWeights
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList scotchDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const labelListList&, "
|
||||||
|
"const pointField&, "
|
||||||
|
"const scalarField&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
|
||||||
|
return labelList::null();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void Foam::scotchDecomp::calcCSR
|
||||||
|
(
|
||||||
|
const polyMesh& mesh,
|
||||||
|
List<int>& adjncy,
|
||||||
|
List<int>& xadj
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList scotchDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const polyMesh&, "
|
||||||
|
"const List<int>&, "
|
||||||
|
"const List<int>&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void Foam::scotchDecomp::calcCSR
|
||||||
|
(
|
||||||
|
const labelListList& cellCells,
|
||||||
|
List<int>& adjncy,
|
||||||
|
List<int>& xadj
|
||||||
|
)
|
||||||
|
{
|
||||||
|
FatalErrorIn
|
||||||
|
(
|
||||||
|
"labelList scotchDecomp::decompose"
|
||||||
|
"("
|
||||||
|
"const labelListList&, "
|
||||||
|
"const List<int>&, "
|
||||||
|
"const List<int>&"
|
||||||
|
")"
|
||||||
|
) << notImplementedMessage << exit(FatalError);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -39,11 +39,6 @@ SourceFiles
|
|||||||
#ifndef ReactingParcel_H
|
#ifndef ReactingParcel_H
|
||||||
#define ReactingParcel_H
|
#define ReactingParcel_H
|
||||||
|
|
||||||
#include "IOstream.H"
|
|
||||||
#include "autoPtr.H"
|
|
||||||
#include "interpolationCellPoint.H"
|
|
||||||
#include "contiguous.H"
|
|
||||||
|
|
||||||
#include "ThermoParcel.H"
|
#include "ThermoParcel.H"
|
||||||
#include "ReactingCloud.H"
|
#include "ReactingCloud.H"
|
||||||
#include "reactingParcel.H"
|
#include "reactingParcel.H"
|
||||||
|
|||||||
@ -40,11 +40,6 @@ SourceFiles
|
|||||||
#ifndef ThermoParcel_H
|
#ifndef ThermoParcel_H
|
||||||
#define ThermoParcel_H
|
#define ThermoParcel_H
|
||||||
|
|
||||||
#include "IOstream.H"
|
|
||||||
#include "autoPtr.H"
|
|
||||||
#include "interpolationCellPoint.H"
|
|
||||||
#include "contiguous.H"
|
|
||||||
|
|
||||||
#include "KinematicParcel.H"
|
#include "KinematicParcel.H"
|
||||||
#include "ThermoCloud.H"
|
#include "ThermoCloud.H"
|
||||||
|
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user