mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' of ssh://opencfd:8007/home/dm4/OpenFOAM/OpenFOAM-dev
This commit is contained in:
@ -5,7 +5,7 @@ tmp<fvVectorMatrix> UEqn
|
||||
fvm::ddt(U)
|
||||
+ fvm::div(phi, U)
|
||||
+ turbulence->divDevReff(U)
|
||||
==
|
||||
==
|
||||
fvOptions(U)
|
||||
);
|
||||
|
||||
@ -17,7 +17,7 @@ rAU = 1.0/UEqn().A();
|
||||
|
||||
if (pimple.momentumPredictor())
|
||||
{
|
||||
solve(UEqn() == -fvc::grad(p) + fvOptions(U));
|
||||
solve(UEqn() == -fvc::grad(p));
|
||||
|
||||
fvOptions.correct(U);
|
||||
}
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -47,6 +47,8 @@ Description
|
||||
#include "snapParameters.H"
|
||||
#include "layerParameters.H"
|
||||
#include "vtkSetWriter.H"
|
||||
#include "faceSet.H"
|
||||
#include "motionSmoother.H"
|
||||
|
||||
using namespace Foam;
|
||||
|
||||
@ -675,6 +677,31 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
|
||||
{
|
||||
// Check final mesh
|
||||
Info<< "Checking final mesh ..." << endl;
|
||||
faceSet wrongFaces(mesh, "wrongFaces", mesh.nFaces()/100);
|
||||
motionSmoother::checkMesh(false, mesh, motionDict, wrongFaces);
|
||||
const label nErrors = returnReduce
|
||||
(
|
||||
wrongFaces.size(),
|
||||
sumOp<label>()
|
||||
);
|
||||
|
||||
if (nErrors > 0)
|
||||
{
|
||||
Info<< "Finished meshing with " << nErrors << " illegal faces"
|
||||
<< " (concave, zero area or negative cell pyramid volume)"
|
||||
<< endl;
|
||||
wrongFaces.write();
|
||||
}
|
||||
else
|
||||
{
|
||||
Info<< "Finished meshing without any errors" << endl;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Info<< "Finished meshing in = "
|
||||
<< runTime.elapsedCpuTime() << " s." << endl;
|
||||
|
||||
|
||||
@ -832,5 +832,39 @@ Foam::label Foam::checkGeometry(const polyMesh& mesh, const bool allGeometry)
|
||||
}
|
||||
}
|
||||
|
||||
if (allGeometry)
|
||||
{
|
||||
faceSet faces(mesh, "lowWeightFaces", mesh.nFaces()/100);
|
||||
if (mesh.checkFaceWeight(true, 0.05, &faces))
|
||||
{
|
||||
noFailedChecks++;
|
||||
|
||||
label nFaces = returnReduce(faces.size(), sumOp<label>());
|
||||
|
||||
Info<< " <<Writing " << nFaces
|
||||
<< " faces with low interpolation weights to set "
|
||||
<< faces.name() << endl;
|
||||
faces.instance() = mesh.pointsInstance();
|
||||
faces.write();
|
||||
}
|
||||
}
|
||||
|
||||
if (allGeometry)
|
||||
{
|
||||
faceSet faces(mesh, "lowVolRatioFaces", mesh.nFaces()/100);
|
||||
if (mesh.checkVolRatio(true, 0.05, &faces))
|
||||
{
|
||||
noFailedChecks++;
|
||||
|
||||
label nFaces = returnReduce(faces.size(), sumOp<label>());
|
||||
|
||||
Info<< " <<Writing " << nFaces
|
||||
<< " faces with low volume ratio cells to set "
|
||||
<< faces.name() << endl;
|
||||
faces.instance() = mesh.pointsInstance();
|
||||
faces.write();
|
||||
}
|
||||
}
|
||||
|
||||
return noFailedChecks;
|
||||
}
|
||||
|
||||
@ -138,6 +138,8 @@ baffles
|
||||
//- Select faces and orientation through a searchableSurface
|
||||
type searchableSurface;
|
||||
surface searchablePlate;
|
||||
//name sphere.stl; // name if surface=triSurfaceMesh
|
||||
|
||||
origin (0.099 -0.006 0.004);
|
||||
span (0 0.012 0.012);
|
||||
|
||||
|
||||
@ -28,6 +28,7 @@ License
|
||||
#include "syncTools.H"
|
||||
#include "searchableSurface.H"
|
||||
#include "fvMesh.H"
|
||||
#include "Time.H"
|
||||
|
||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||
|
||||
@ -61,7 +62,15 @@ Foam::faceSelections::searchableSurfaceSelection::searchableSurfaceSelection
|
||||
searchableSurface::New
|
||||
(
|
||||
word(dict.lookup("surface")),
|
||||
mesh.objectRegistry::db(),
|
||||
IOobject
|
||||
(
|
||||
dict.lookupOrDefault("name", mesh.objectRegistry::db().name()),
|
||||
mesh.time().constant(),
|
||||
"triSurface",
|
||||
mesh.objectRegistry::db(),
|
||||
IOobject::MUST_READ,
|
||||
IOobject::NO_WRITE
|
||||
),
|
||||
dict
|
||||
)
|
||||
)
|
||||
|
||||
@ -378,6 +378,7 @@ FoamFile
|
||||
// surface searchableSphere;
|
||||
// centre (0.05 0.05 0.005);
|
||||
// radius 0.025;
|
||||
// //name sphere.stl; // Optional name if surface triSurfaceMesh
|
||||
// }
|
||||
// }
|
||||
//
|
||||
|
||||
@ -2,21 +2,26 @@
|
||||
cd ${0%/*} || exit 1 # run from this directory
|
||||
#set -x
|
||||
|
||||
if [ -d "$ParaView_DIR" -a -r "$ParaView_DIR" ]
|
||||
then
|
||||
[ -n "$PV_PLUGIN_PATH" ] || {
|
||||
echo "$0 : PV_PLUGIN_PATH not valid - it is unset"
|
||||
exit 1
|
||||
}
|
||||
if [ "$ParaView_VERSION" == "3.98.1" ]
|
||||
then
|
||||
if [ -d "$ParaView_DIR" -a -r "$ParaView_DIR" ]
|
||||
then
|
||||
[ -n "$PV_PLUGIN_PATH" ] || {
|
||||
echo "$0 : PV_PLUGIN_PATH not valid - it is unset"
|
||||
exit 1
|
||||
}
|
||||
|
||||
# ensure CMake gets the correct C++ compiler
|
||||
[ -n "$WM_CXX" ] && export CXX="$WM_CXX"
|
||||
# ensure CMake gets the correct C++ compiler
|
||||
[ -n "$WM_CXX" ] && export CXX="$WM_CXX"
|
||||
|
||||
wmake libso vtkPV398Readers
|
||||
PV398blockMeshReader/Allwmake
|
||||
PV398FoamReader/Allwmake
|
||||
wmake libso vtkPV398Readers
|
||||
PV398blockMeshReader/Allwmake
|
||||
PV398FoamReader/Allwmake
|
||||
else
|
||||
echo "ERROR: ParaView not found in $ParaView_DIR"
|
||||
fi
|
||||
else
|
||||
echo "ERROR: ParaView not found in $ParaView_DIR"
|
||||
echo "WARN: PV398 readers not building: ParaView_VERSION=$ParaView_VERSION"
|
||||
fi
|
||||
|
||||
# ----------------------------------------------------------------- end-of-file
|
||||
|
||||
@ -2,21 +2,26 @@
|
||||
cd ${0%/*} || exit 1 # run from this directory
|
||||
#set -x
|
||||
|
||||
if [ -d "$ParaView_DIR" -a -r "$ParaView_DIR" ]
|
||||
then
|
||||
[ -n "$PV_PLUGIN_PATH" ] || {
|
||||
echo "$0 : PV_PLUGIN_PATH not valid - it is unset"
|
||||
exit 1
|
||||
}
|
||||
if [ "$ParaView_VERSION" != "3.98.1" ]
|
||||
then
|
||||
if [ -d "$ParaView_DIR" -a -r "$ParaView_DIR" ]
|
||||
then
|
||||
[ -n "$PV_PLUGIN_PATH" ] || {
|
||||
echo "$0 : PV_PLUGIN_PATH not valid - it is unset"
|
||||
exit 1
|
||||
}
|
||||
|
||||
# ensure CMake gets the correct C++ compiler
|
||||
[ -n "$WM_CXX" ] && export CXX="$WM_CXX"
|
||||
# ensure CMake gets the correct C++ compiler
|
||||
[ -n "$WM_CXX" ] && export CXX="$WM_CXX"
|
||||
|
||||
wmake libso vtkPV3Readers
|
||||
PV3blockMeshReader/Allwmake
|
||||
PV3FoamReader/Allwmake
|
||||
wmake libso vtkPV3Readers
|
||||
PV3blockMeshReader/Allwmake
|
||||
PV3FoamReader/Allwmake
|
||||
else
|
||||
echo "ERROR: ParaView not found in $ParaView_DIR"
|
||||
fi
|
||||
else
|
||||
echo "ERROR: ParaView not found in $ParaView_DIR"
|
||||
echo "WARN: PV3 readers not building: ParaView_VERSION=$ParaView_VERSION"
|
||||
fi
|
||||
|
||||
# ----------------------------------------------------------------- end-of-file
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -179,7 +179,10 @@ void Foam::vtkPV3Foam::convertMeshPatches
|
||||
|
||||
const word patchName = getPartName(partId);
|
||||
|
||||
labelHashSet patchIds(patches.patchSet(List<wordRe>(1, patchName)));
|
||||
labelHashSet patchIds
|
||||
(
|
||||
patches.patchSet(List<wordRe>(1, wordRe(patchName)))
|
||||
);
|
||||
|
||||
if (debug)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user