Merge remote-tracking branch 'origin/nr/HenrikRusche' into nextRelease

This commit is contained in:
Hrvoje Jasak 2013-12-02 10:52:32 +00:00
commit 298bf9d822
22 changed files with 56 additions and 93 deletions

View file

@ -76,9 +76,6 @@ int main(int argc, char *argv[])
// Read required accuracy
scalar eps = readScalar(PODsolverDict.lookup("eps"));
// Interpolation coefficients
scalarField& PODcoeffs = equation->coeffs();
Info<< "\nStarting time loop\n" << endl;
for (runTime++; !runTime.end(); runTime++)

View file

@ -30,6 +30,10 @@
const volScalarField& T = thermo.T();
// dummy statement to quench compiler warning
// Note: T is used in engineFoam
T.size();
Info<< "\nReading field U\n" << endl;
volVectorField U
(

View file

@ -1,12 +1,6 @@
# include "readTimeControls.H"
# include "readPISOControls.H"
bool correctPhi = false;
if (piso.found("correctPhi"))
{
correctPhi = Switch(piso.lookup("correctPhi"));
}
bool checkMeshCourantNo = false;
if (piso.found("checkMeshCourantNo"))
{

View file

@ -80,8 +80,6 @@ int main(int argc, char *argv[])
// Store divU from the previous mesh for the correctPhi
volScalarField divU = fvc::div(phi);
scalar timeBeforeMeshUpdate = runTime.elapsedCpuTime();
bool meshChanged = mesh.update();
reduce(meshChanged, orOp<bool>());

View file

@ -1,11 +1,6 @@
#include "readPISOControls.H"
#include "readTimeControls.H"
label nAlphaCorr
(
readLabel(piso.lookup("nAlphaCorr"))
);
label nAlphaSubCycles
(
readLabel(piso.lookup("nAlphaSubCycles"))

View file

@ -1,11 +1,6 @@
#include "readPISOControls.H"
#include "readTimeControls.H"
label nAlphaCorr
(
readLabel(piso.lookup("nAlphaCorr"))
);
label nAlphaSubCycles
(
readLabel(piso.lookup("nAlphaSubCycles"))

View file

@ -78,8 +78,8 @@ int main(int argc, char *argv[])
scalar initialResidual = 1.0;
scalar residual = 1.0;
surfaceSymmTensorField DSigmaCorrf = fvc::interpolate(DSigmaCorr);
label nCrackedFaces = 0;
//label nCrackedFaces = 0;
// cracking loop if you use cohesive boundaries
//do
//{

View file

@ -212,17 +212,14 @@ bool Foam::bubbleHistory::start()
vector F = fs.totalViscousForce() + fs.totalPressureForce();
vector dragDir;
scalar Uref;
if(mag(U.value()) > SMALL)
{
dragDir = -U.value()/mag(U.value());
Uref = mag(U.value());
}
else
{
dragDir = fs.g().value()/(mag(fs.g().value()) + SMALL);
Uref = SMALL;
}
scalar dragForce = (dragDir&F);
@ -331,17 +328,14 @@ bool Foam::bubbleHistory::execute()
vector F = fs.totalViscousForce() + fs.totalPressureForce();
vector dragDir;
scalar Uref;
if(mag(U.value()) > SMALL)
{
dragDir = -U.value()/mag(U.value());
Uref = mag(U.value());
}
else
{
dragDir = fs.g().value()/(mag(fs.g().value()) + SMALL);
Uref = SMALL;
}
scalar dragForce = (dragDir&F);

View file

@ -87,7 +87,6 @@ void starMesh::readPoints(const scalar scaleFactor)
if (pointsFile.good())
{
label pointLabel;
scalar x, y, z;
maxLabel = -1;
while (pointsFile)
@ -98,9 +97,9 @@ void starMesh::readPoints(const scalar scaleFactor)
maxLabel = max(maxLabel, pointLabel);
x = readVtxCmpt(pointsFile);
y = readVtxCmpt(pointsFile);
z = readVtxCmpt(pointsFile);
readVtxCmpt(pointsFile);
readVtxCmpt(pointsFile);
readVtxCmpt(pointsFile);
readToNl(pointsFile);

View file

@ -199,9 +199,6 @@ Foam::labelList Foam::blockMesh::createMergeList()
<< exit(FatalError);
}
bool found = false;
// N-squared point search over all points of all faces of
// master block over all point of all faces of slave block
forAll(blockPfaceFaces, blockPfaceFaceLabel)
@ -215,7 +212,7 @@ Foam::labelList Foam::blockMesh::createMergeList()
forAll(blockPfaceFacePoints, blockPfaceFacePointLabel)
{
found = false;
bool found = false;
forAll(blockNfaceFaces, blockNfaceFaceLabel)
{
@ -307,7 +304,6 @@ Foam::labelList Foam::blockMesh::createMergeList()
const labelListList& curPairs = glueMergePairs[blockFaceLabel];
bool foundFace = false;
label blockPfaceLabel;
for
(
@ -322,12 +318,10 @@ Foam::labelList Foam::blockMesh::createMergeList()
== blockInternalFaces[blockFaceLabel]
)
{
foundFace = true;
break;
}
}
foundFace = false;
label blockNfaceLabel;
for
(
@ -342,7 +336,6 @@ Foam::labelList Foam::blockMesh::createMergeList()
== blockInternalFaces[blockFaceLabel]
)
{
foundFace = true;
break;
}
}

View file

@ -396,11 +396,6 @@ void Foam::ensightMesh::writePrimsBinary
{
label po = pointOffset + 1;
// Create a temp int array
int numElem;
numElem = cellShapes.size();
if (cellShapes.size())
{
// All the cellShapes have the same number of elements!

View file

@ -136,7 +136,7 @@ bool merge
const bool literalRE
)
{
auto bool wildCardInMergeDict = false;
bool wildCardInMergeDict = false;
bool changed = false;

View file

@ -188,10 +188,6 @@ endOfSection {space}")"{space}
// Data index
label curNEntriesPerObject = 0;
// Dummy, not used
label nTimeLevels;
label nPhases;
label curFirstID = 0;
label curLastID = 0;
label objI = 0;
@ -320,8 +316,10 @@ endOfSection {space}")"{space}
nEntriesPerObject.append(curNEntriesPerObject);
// Dummy, not used
nTimeLevels = readLabel(fieldDataStream);
nPhases = readLabel(fieldDataStream);
//nTimeLevels =
readLabel(fieldDataStream);
//nPhases =
readLabel(fieldDataStream);
// Start and end of list
curFirstID = readLabel(fieldDataStream);

View file

@ -70,7 +70,8 @@ Foam::label Foam::metisDecomp::decompose
int numCells = xadj.size()-1;
// decomposition options. 0 = use defaults
List<int> options(5, 0);
idx_t options[METIS_NOPTIONS];
METIS_SetDefaultOptions(options);
// processor weights initialised with no size, only used if specified in
// a file
@ -139,18 +140,24 @@ Foam::label Foam::metisDecomp::decompose
<< nl << endl;
}
if (metisCoeffs.readIfPresent("options", options))
List<int> mOptions;
if (metisCoeffs.readIfPresent("options", mOptions))
{
if (options.size() != 5)
if (mOptions.size() != METIS_NOPTIONS)
{
FatalErrorIn("metisDecomp::decompose()")
<< "Number of options in metisCoeffs in dictionary : "
<< decompositionDict_.name()
<< " should be 5"
<< " should be " << METIS_NOPTIONS
<< exit(FatalError);
}
Info<< "metisDecomp : Using Metis options " << options
forAll(mOptions, i)
{
options[i] = mOptions[i];
}
Info<< "metisDecomp : Using Metis options " << mOptions
<< nl << endl;
}
@ -232,7 +239,7 @@ Foam::label Foam::metisDecomp::decompose
&nProcs,
processorWeights.begin(),
NULL,
options.begin(),
options,
&edgeCut,
finalDecomp.begin()
);
@ -251,7 +258,7 @@ Foam::label Foam::metisDecomp::decompose
&nProcs,
processorWeights.begin(),
NULL,
options.begin(),
options,
&edgeCut,
finalDecomp.begin()
);

View file

@ -5433,6 +5433,10 @@ void dynamicTopoFvMesh::buildProcessorPatchMesh
// Check if this is a direct neighbour
const polyBoundaryMesh& boundary = boundaryMesh();
/*
// unused code section - to be removed
// HR: 30/11/2013
label patchIndex = -1;
forAll(boundary, patchI)
@ -5447,11 +5451,11 @@ void dynamicTopoFvMesh::buildProcessorPatchMesh
if (pp.neighbProcNo() == proc)
{
patchIndex = patchI;
break;
}
}
}
*/
// Add sub-mesh points first.
// Additional halo points will be added later.

View file

@ -233,8 +233,7 @@ void eMesh::calcEdgePoints() const
// Counter-clockwise. Pick the owner.
cellIndex = owner[faceIndex];
}
else
if (mesh_.isInternalFace(faceIndex))
else if (mesh_.isInternalFace(faceIndex))
{
// Clockwise. Pick the neighbour.
cellIndex = neighbour[faceIndex];
@ -260,7 +259,8 @@ void eMesh::calcEdgePoints() const
)
{
faceIndex = cellToCheck[0];
found = true; break;
found = true;
break;
}
if
@ -270,7 +270,8 @@ void eMesh::calcEdgePoints() const
)
{
faceIndex = cellToCheck[1];
found = true; break;
found = true;
break;
}
if
@ -280,7 +281,8 @@ void eMesh::calcEdgePoints() const
)
{
faceIndex = cellToCheck[2];
found = true; break;
found = true;
break;
}
if
@ -290,7 +292,8 @@ void eMesh::calcEdgePoints() const
)
{
faceIndex = cellToCheck[3];
found = true; break;
found = true;
break;
}
}
@ -308,6 +311,9 @@ void eMesh::calcEdgePoints() const
<< "edgeFaces: " << eFace
<< abort(FatalError);
}
# else
// dummy statement to quech compiler warning
found = found;
# endif
}
}

View file

@ -190,7 +190,7 @@ void Foam::multiSolver::synchronizeParallel() const
// Recieve go signal
{
IPstream fromMaster(Pstream::blocking, Pstream::masterNo());
bool okayToGo(readBool(fromMaster));
readBool(fromMaster);
}
}
}

View file

@ -309,8 +309,8 @@ List<specieElement> currentSpecieComposition(5);
scalar currentLowT = 0;
scalar currentHighT = 0;
scalar currentCommonT = 0;
gasThermoPhysics::coeffArray highCpCoeffs;
gasThermoPhysics::coeffArray lowCpCoeffs;
gasThermoPhysics::coeffArray highCpCoeffs(scalarList(7));
gasThermoPhysics::coeffArray lowCpCoeffs(scalarList(7));
gasReaction::specieCoeffs currentSpecieCoeff;

View file

@ -209,7 +209,7 @@ endsolid {space}("endsolid"|"ENDSOLID")({some_space}{word})*
%{
// End of read character pointer returned by strtof
char* endPtr;
//char* endPtr;
STLpoint normal;
STLpoint vertex;

View file

@ -15,15 +15,7 @@ FoamFile
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
writeFormat ascii;
writePrecision 6;
writeCompression uncompressed;
runTimeModifiable yes;
application icoFoam;
application multiSolverDemo;
deltaT 0.01;
@ -33,9 +25,9 @@ writeInterval 1;
startFrom startTime;
startTime 0.1;
startTime 0;
stopAt endTime;
stopAt noWriteNow;
endTime 0.1;

View file

@ -15,15 +15,7 @@ FoamFile
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
writeFormat ascii;
writePrecision 6;
writeCompression uncompressed;
runTimeModifiable yes;
application icoFoam;
application multiSolverDemo;
deltaT 0.01;
@ -33,9 +25,9 @@ writeInterval 1;
startFrom startTime;
startTime 0.1;
startTime 0;
stopAt endTime;
stopAt noWriteNow;
endTime 0.1;