Merge branch 'master' into cvm

This commit is contained in:
graham
2009-01-27 16:52:43 +00:00
345 changed files with 4071 additions and 2195 deletions

View File

@ -48,7 +48,7 @@ Description
#include "polyMesh.H"
#include "mapPolyMesh.H"
#include "mathematicalConstants.H"
#include "PackedList.H"
#include "PackedBoolList.H"
#include "SortableList.H"
using namespace Foam;
@ -177,7 +177,7 @@ label mergeEdges
// Return master point edge needs to be collapsed to (or -1)
label edgeMaster(const PackedList<1>& boundaryPoint, const edge& e)
label edgeMaster(const PackedBoolList& boundaryPoint, const edge& e)
{
label masterPoint = -1;
@ -215,7 +215,7 @@ label edgeMaster(const PackedList<1>& boundaryPoint, const edge& e)
label collapseSmallEdges
(
const polyMesh& mesh,
const PackedList<1>& boundaryPoint,
const PackedBoolList& boundaryPoint,
const scalar minLen,
edgeCollapser& collapser
)
@ -254,7 +254,7 @@ label collapseSmallEdges
label collapseHighAspectFaces
(
const polyMesh& mesh,
const PackedList<1>& boundaryPoint,
const PackedBoolList& boundaryPoint,
const scalar areaFac,
const scalar edgeRatio,
edgeCollapser& collapser
@ -346,7 +346,7 @@ void set(const labelList& elems, const bool val, boolList& status)
label simplifyFaces
(
const polyMesh& mesh,
const PackedList<1>& boundaryPoint,
const PackedBoolList& boundaryPoint,
const label minSize,
const scalar lenGap,
edgeCollapser& collapser
@ -485,7 +485,7 @@ int main(int argc, char *argv[])
const faceList& faces = mesh.faces();
// Get all points on the boundary
PackedList<1> boundaryPoint(mesh.nPoints(), false);
PackedBoolList boundaryPoint(mesh.nPoints());
label nIntFaces = mesh.nInternalFaces();
for (label faceI = nIntFaces; faceI < mesh.nFaces(); faceI++)

View File

@ -51,7 +51,7 @@ cellShape create3DCellShape
static List<const cellModel*> fluentCellModelLookup
(
7,
reinterpret_cast<const cellModel*>(NULL)
reinterpret_cast<const cellModel*>(0)
);
fluentCellModelLookup[2] = cellModeller::lookup("tet");

View File

@ -49,7 +49,7 @@ Description
#include "mathematicalConstants.H"
#include "polyTopoChange.H"
#include "mapPolyMesh.H"
#include "PackedList.H"
#include "PackedBoolList.H"
#include "meshTools.H"
#include "OFstream.H"
#include "meshDualiser.H"
@ -67,7 +67,7 @@ using namespace Foam;
void simpleMarkFeatures
(
const polyMesh& mesh,
const PackedList<1>& isBoundaryEdge,
const PackedBoolList& isBoundaryEdge,
const scalar featureAngle,
const bool doNotPreserveFaceZones,
@ -358,7 +358,7 @@ int main(int argc, char *argv[])
// Mark boundary edges and points.
// (Note: in 1.4.2 we can use the built-in mesh point ordering
// facility instead)
PackedList<1> isBoundaryEdge(mesh.nEdges());
PackedBoolList isBoundaryEdge(mesh.nEdges());
for (label faceI = mesh.nInternalFaces(); faceI < mesh.nFaces(); faceI++)
{
const labelList& fEdges = mesh.faceEdges()[faceI];

View File

@ -155,7 +155,7 @@ Foam::label Foam::meshDualiser::findDualCell
// from (boundary & feature) point
void Foam::meshDualiser::generateDualBoundaryEdges
(
const PackedList<1>& isBoundaryEdge,
const PackedBoolList& isBoundaryEdge,
const label pointI,
polyTopoChange& meshMod
)
@ -388,7 +388,7 @@ Foam::label Foam::meshDualiser::addBoundaryFace
void Foam::meshDualiser::createFacesAroundEdge
(
const bool splitFace,
const PackedList<1>& isBoundaryEdge,
const PackedBoolList& isBoundaryEdge,
const label edgeI,
const label startFaceI,
polyTopoChange& meshMod,
@ -907,7 +907,7 @@ void Foam::meshDualiser::setRefinement
// Mark boundary edges and points.
// (Note: in 1.4.2 we can use the built-in mesh point ordering
// facility instead)
PackedList<1> isBoundaryEdge(mesh_.nEdges());
PackedBoolList isBoundaryEdge(mesh_.nEdges());
for (label faceI = mesh_.nInternalFaces(); faceI < mesh_.nFaces(); faceI++)
{
const labelList& fEdges = mesh_.faceEdges()[faceI];

View File

@ -49,7 +49,7 @@ SourceFiles
#define meshDualiser_H
#include "DynamicList.H"
#include "PackedList.H"
#include "PackedBoolList.H"
#include "boolList.H"
#include "typeInfo.H"
@ -101,7 +101,7 @@ class meshDualiser
// emanating from (boundary & feature) point
void generateDualBoundaryEdges
(
const PackedList<1>&,
const PackedBoolList&,
const label pointI,
polyTopoChange&
);
@ -144,7 +144,7 @@ class meshDualiser
void createFacesAroundEdge
(
const bool splitFace,
const PackedList<1>&,
const PackedBoolList&,
const label edgeI,
const label startFaceI,
polyTopoChange&,

View File

@ -90,13 +90,13 @@ const label sammMesh::shapeFaceLookup[19][9] =
List<const cellModel*> sammMesh::sammShapeLookup
(
256,
reinterpret_cast<cellModel*>(NULL)
reinterpret_cast<cellModel*>(0)
);
List<const label*> sammMesh::sammAddressingTable
(
256,
reinterpret_cast<label*>(NULL)
reinterpret_cast<label*>(0)
);
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //

View File

@ -48,7 +48,7 @@ void starMesh::addRegularCell
label regularTypeFlag = -1;
// grab the shape from the table
const cellModel* curModelPtr = reinterpret_cast<cellModel*>(NULL);
const cellModel* curModelPtr = reinterpret_cast<cellModel*>(0);
if // Tetrahedron
(
@ -130,7 +130,7 @@ void starMesh::addSAMMcell
// grab the shape from the table
label sammTypeFlag = -1;
const cellModel* curModelPtr = reinterpret_cast<cellModel*>(NULL);
const cellModel* curModelPtr = reinterpret_cast<cellModel*>(0);
switch (typeFlag)
{

View File

@ -82,7 +82,7 @@ topoSetSources
// Cells in cell zone
zoneToCell
{
name ".*Zone"; // name of cellZone, wildcards allowed.
name ".*Zone"; // Name of cellZone, regular expressions allowed
}
// values of field within certain range
@ -102,16 +102,16 @@ topoSetSources
// Select based on surface
surfaceToCell
{
file "www.avl.com-geometry.stl";
outsidePoints ((-99 -99 -59)); // definition of outside
includeCut false; // cells cut by surface
includeInside false; // cells not on outside of surf
includeOutside false; // cells on outside of surf
nearDistance -1; // cells with centre near surf
// (set to -1 if not used)
curvature 0.9; // cells within nearDistance
// and near surf curvature
// (set to -100 if not used)
file "www.avl.com-geometry.stl";
outsidePoints ((-99 -99 -59)); // definition of outside
includeCut false; // cells cut by surface
includeInside false; // cells not on outside of surf
includeOutside false; // cells on outside of surf
nearDistance -1; // cells with centre near surf
// (set to -1 if not used)
curvature 0.9; // cells within nearDistance
// and near surf curvature
// (set to -100 if not used)
}
);

View File

@ -60,18 +60,18 @@ topoSetSources
// All points in pointzone
zoneToPoint
{
name ".*Zone"; // name of pointZone, wildcards allowed.
name ".*Zone"; // name of pointZone, regular expressions allowed
}
// Select based on surface
surfaceToPoint
{
file "www.avl.com-geometry.stl";
nearDistance 0.1; // points near to surface
includeInside false; // points on inside of surface
// (requires closed surface with consistent
// normals)
includeOutside false; // ,, outside ,,
file "www.avl.com-geometry.stl";
nearDistance 0.1; // points near to surface
includeInside false; // points on inside of surface
// (requires closed surface with consistent
// normals)
includeOutside false; // ,, outside ,,
}
);

View File

@ -613,7 +613,7 @@ autoPtr<mapPolyMesh> createRegionMesh
"fvSchemes",
mesh.time().system(),
regionName,
mesh.db(),
mesh,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
@ -642,7 +642,7 @@ autoPtr<mapPolyMesh> createRegionMesh
"fvSolution",
mesh.time().system(),
regionName,
mesh.db(),
mesh,
IOobject::NO_READ,
IOobject::NO_WRITE,
false

View File

@ -299,7 +299,7 @@ bool domainDecomposition::writeDecomposition()
(
curPatchSizes.size()
+ curProcessorPatchSizes.size(),
reinterpret_cast<polyPatch*>(NULL)
reinterpret_cast<polyPatch*>(0)
);
label nPatches = 0;

View File

@ -3,7 +3,7 @@ int nFields = volScalarNames.size() + 3*volVectorNames.size();
List<volScalarField*> volFieldPtrs
(
nFields,
reinterpret_cast<volScalarField*>(NULL)
reinterpret_cast<volScalarField*>(0)
);
stringList volFieldNames(nFields);
@ -27,12 +27,11 @@ nFields = 0;
if (ioHeader.headerOk())
{
volFieldPtrs[nFields] =
new volScalarField
(
ioHeader,
mesh
);
volFieldPtrs[nFields] = new volScalarField
(
ioHeader,
mesh
);
}
fieldName = getFieldViewName(fieldName);
@ -106,7 +105,7 @@ int nSurfFields = surfScalarNames.size() + 3*surfVectorNames.size();
List<surfaceScalarField*> surfFieldPtrs
(
nSurfFields,
reinterpret_cast<surfaceScalarField*>(NULL)
reinterpret_cast<surfaceScalarField*>(0)
);
stringList surfFieldNames(nSurfFields);

View File

@ -2,13 +2,13 @@
List<IOField<scalar>* > sprayScalarFieldPtrs
(
sprayScalarNames.size(),
reinterpret_cast<IOField<scalar>*>(NULL)
reinterpret_cast<IOField<scalar>*>(0)
);
List<IOField<vector>* > sprayVectorFieldPtrs
(
sprayVectorNames.size(),
reinterpret_cast<IOField<vector>*>(NULL)
reinterpret_cast<IOField<vector>*>(0)
);
{

View File

@ -24,7 +24,7 @@ License
Description
Translates a STAR-CD SMAP data file into FOAM field format.
\*---------------------------------------------------------------------------*/
#include "fvCFD.H"
@ -108,15 +108,15 @@ int main(int argc, char *argv[])
List<volScalarField*> sFields
(
nCols,
reinterpret_cast<volScalarField*>(NULL)
reinterpret_cast<volScalarField*>(0)
);
List<volVectorField*> vFields
(
nCols,
reinterpret_cast<volVectorField*>(NULL)
reinterpret_cast<volVectorField*>(0)
);
label i=0;
while (i < nCols)
{

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License

View File

@ -34,6 +34,9 @@ Usage
@param -clean \n
Perform some surface checking/cleanup on the input surface
@param -orient \n
Check face orientation on the input surface
@param -scale \<scale\> \n
Specify a scaling factor for writing the files
@ -68,6 +71,7 @@ int main(int argc, char *argv[])
argList::validArgs.append("inputFile");
argList::validArgs.append("outputFile");
argList::validOptions.insert("clean", "");
argList::validOptions.insert("orient", "");
argList::validOptions.insert("scale", "scale");
argList::validOptions.insert("triSurface", "");
argList::validOptions.insert("unsorted", "");
@ -108,6 +112,13 @@ int main(int argc, char *argv[])
surf.writeStats(Info);
Info<< endl;
if (args.options().found("orient"))
{
Info<< "Checking surface orientation" << endl;
surf.checkOrientation(true);
Info<< endl;
}
if (args.options().found("clean"))
{
Info<< "Cleaning up surface" << endl;
@ -140,6 +151,13 @@ int main(int argc, char *argv[])
surf.writeStats(Info);
Info<< endl;
if (args.options().found("orient"))
{
Info<< "Checking surface orientation" << endl;
surf.checkOrientation(true);
Info<< endl;
}
if (args.options().found("clean"))
{
Info<< "Cleaning up surface" << endl;
@ -171,6 +189,13 @@ int main(int argc, char *argv[])
surf.writeStats(Info);
Info<< endl;
if (args.options().found("orient"))
{
Info<< "Checking surface orientation" << endl;
surf.checkOrientation(true);
Info<< endl;
}
if (args.options().found("clean"))
{
Info<< "Cleaning up surface" << endl;
@ -202,6 +227,13 @@ int main(int argc, char *argv[])
surf.writeStats(Info);
Info<< endl;
if (args.options().found("orient"))
{
Info<< "Checking surface orientation" << endl;
surf.checkOrientation(true);
Info<< endl;
}
if (args.options().found("clean"))
{
Info<< "Cleaning up surface" << endl;