diff --git a/applications/utilities/mesh/conversion/plot3dToFoam/plot3dToFoam.C b/applications/utilities/mesh/conversion/plot3dToFoam/plot3dToFoam.C index f686180195..6e81ff9f0b 100644 --- a/applications/utilities/mesh/conversion/plot3dToFoam/plot3dToFoam.C +++ b/applications/utilities/mesh/conversion/plot3dToFoam/plot3dToFoam.C @@ -28,7 +28,8 @@ Description Work in progress! Handles ascii multiblock (and optionally singleBlock) format. By default expects blanking. Use -noBlank if none. - Use -2D if 2D. + Use -2D @a thickness if 2D. + Niklas Nordin has experienced a problem with lefthandedness of the blocks. The code should detect this automatically - see hexBlock::readPoints but if this goes wrong just set the blockHandedness_ variable to 'right' diff --git a/applications/utilities/mesh/generation/blockMesh/Make/files b/applications/utilities/mesh/generation/blockMesh/Make/files index af92bf759c..81f5f36749 100644 --- a/applications/utilities/mesh/generation/blockMesh/Make/files +++ b/applications/utilities/mesh/generation/blockMesh/Make/files @@ -26,6 +26,6 @@ blockPoints.C blockCells.C blockBoundary.C -genBlockMesh.C +blockMeshApp.C EXE = $(FOAM_APPBIN)/blockMesh diff --git a/applications/utilities/mesh/generation/blockMesh/addOptions.H b/applications/utilities/mesh/generation/blockMesh/addOptions.H index a0f494e483..c9e07df5a6 100644 --- a/applications/utilities/mesh/generation/blockMesh/addOptions.H +++ b/applications/utilities/mesh/generation/blockMesh/addOptions.H @@ -1,3 +1,4 @@ argList::noParallel(); argList::validOptions.insert("blockTopology", ""); + argList::validOptions.insert("dict", "dictionary"); # include "addRegionOption.H" diff --git a/applications/utilities/mesh/generation/blockMesh/genBlockMesh.C b/applications/utilities/mesh/generation/blockMesh/blockMeshApp.C similarity index 95% rename from applications/utilities/mesh/generation/blockMesh/genBlockMesh.C rename to applications/utilities/mesh/generation/blockMesh/blockMeshApp.C index c13d906392..e337b0d167 100644 --- a/applications/utilities/mesh/generation/blockMesh/genBlockMesh.C +++ b/applications/utilities/mesh/generation/blockMesh/blockMeshApp.C @@ -77,11 +77,21 @@ int main(int argc, char *argv[]) Info<< nl << "Reading block mesh description dictionary" << endl; + word dictName("blockMeshDict"); + fileName dictPath(runTime.constant()/polyMeshDir); + + if (args.options().found("dict")) + { + fileName userDict(args.options()["dict"]); + + dictName = userDict.name(); + dictPath = userDict.path(); + } + IOobject meshDescriptionIOobject ( - "blockMeshDict", - runTime.constant(), - polyMeshDir, + dictName, + dictPath, runTime, IOobject::MUST_READ, IOobject::NO_WRITE, @@ -91,13 +101,14 @@ int main(int argc, char *argv[]) if (!meshDescriptionIOobject.headerOk()) { FatalErrorIn(args.executable()) - << "Cannot open mesh description file " << nl - << runTime.constant()/polyMeshDir/"blockMeshDict" << nl + << "Cannot open mesh description file: " << nl + << dictPath/dictName << nl << exit(FatalError); } IOdictionary meshDescription(meshDescriptionIOobject); + Info<< nl << "Creating block mesh" << endl; blockMesh blocks(meshDescription); diff --git a/applications/utilities/miscellaneous/foamDebugSwitches/Make/options b/applications/utilities/miscellaneous/foamDebugSwitches/Make/options index 9d962c8efa..de8242a89f 100644 --- a/applications/utilities/miscellaneous/foamDebugSwitches/Make/options +++ b/applications/utilities/miscellaneous/foamDebugSwitches/Make/options @@ -1,10 +1,8 @@ EXE_LIBS = \ - -lautoMesh \ -lbasicThermophysicalModels \ -lchemistryModel \ -lcombustionThermophysicalModels \ -lcompressibleLESModels \ - -lcompressibleRASModels \ -ldecompositionMethods \ -ldieselSpray \ -ldynamicFvMesh \ @@ -17,6 +15,7 @@ EXE_LIBS = \ -lfvMotionSolvers \ -lincompressibleLESModels \ -lincompressibleTransportModels \ + -lcompressibleRASModels \ -lincompressibleRASModels \ -linterfaceProperties \ -llagrangianIntermediate \ @@ -39,5 +38,5 @@ EXE_LIBS = \ -lspecie \ -lthermophysicalFunctions \ -ltopoChangerFvMesh \ - -ltriSurface - + -ltriSurface \ + -lautoMesh diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/PV3FoamReader/PV3FoamReader_SM.xml b/applications/utilities/postProcessing/graphics/PV3FoamReader/PV3FoamReader/PV3FoamReader_SM.xml index c54cc2d45d..c097562a53 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/PV3FoamReader/PV3FoamReader_SM.xml +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/PV3FoamReader/PV3FoamReader_SM.xml @@ -90,52 +90,6 @@ - - - - - - - diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options index b40ecb51d7..2cebe55112 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/Make/options @@ -1,4 +1,5 @@ EXE_INC = \ + /* -DPV3FOAM_TIMESELECTION */ \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(LIB_SRC)/lagrangian/basic/lnInclude \ -I$(LIB_SRC)/meshTools/lnInclude \ diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3Foam.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3Foam.C index 678ae8e958..7699e94cf2 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3Foam.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3Foam.C @@ -27,8 +27,6 @@ License #include "vtkPV3Foam.H" // Foam includes -#include "argList.H" -#include "JobInfo.H" #include "Time.H" #include "fvMesh.H" #include "IOobjectList.H" @@ -176,11 +174,7 @@ void Foam::vtkPV3Foam::resetCounters() void Foam::vtkPV3Foam::initializeTime() { - if (debug) - { - Info<< "entered Foam::vtkPV3Foam::initializeTime" << endl; - } - +#ifdef PV3FOAM_TIMESELECTION Time& runTime = dbPtr_(); // Get times list @@ -206,6 +200,7 @@ void Foam::vtkPV3Foam::initializeTime() times[timeI].name().c_str() ); } +#endif /* PV3FOAM_TIMESELECTION */ } @@ -213,8 +208,8 @@ bool Foam::vtkPV3Foam::setTime(const double& requestedTime) { if (debug) { - Info<< "entered Foam::vtkPV3Foam::setTime(" - << requestedTime << ")" << endl; + Info<< " Foam::vtkPV3Foam::setTime(" << requestedTime << ")" + << endl; } Time& runTime = dbPtr_(); @@ -249,12 +244,14 @@ bool Foam::vtkPV3Foam::setTime(const double& requestedTime) found = true; } + runTime.setTime(times[nearestIndex], nearestIndex); + if (debug) { - Info<< "Selecting time " << times[nearestIndex].name() << endl; + Info<< " Foam::vtkPV3Foam::setTime() - selected time " + << times[nearestIndex].name() << endl; } - runTime.setTime(times[nearestIndex], nearestIndex); return found; } @@ -263,7 +260,7 @@ void Foam::vtkPV3Foam::updateSelectedRegions() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateSelectedRegions" << endl; + Info<< " Foam::vtkPV3Foam::updateSelectedRegions" << endl; } vtkDataArraySelection* arraySelection = reader_->GetRegionSelection(); @@ -281,10 +278,15 @@ void Foam::vtkPV3Foam::updateSelectedRegions() if (debug) { - Info<< "region " << regionId - << " = " << selectedRegions_[regionId] << endl; + Info<< " region[" << regionId << "] = " + << selectedRegions_[regionId] + << " : " << arraySelection->GetArrayName(regionId) << endl; } } + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateSelectedRegions" << endl; + } } @@ -294,13 +296,14 @@ Foam::stringList Foam::vtkPV3Foam::getSelectedArrayEntries const bool firstWord ) { - if (debug) - { - Info<< "entered Foam::vtkPV3Foam::getSelectedArrayEntries" << endl; - } - stringList selections(arraySelection->GetNumberOfArrays()); label nElem = 0; + + if (debug) + { + Info << "selections("; + } + forAll (selections, elemI) { if (arraySelection->GetArraySetting(elemI)) @@ -316,16 +319,22 @@ Foam::stringList Foam::vtkPV3Foam::getSelectedArrayEntries { selections[nElem] = arraySelection->GetArrayName(elemI); } + + if (debug) + { + Info << " " << selections[nElem]; + } + ++nElem; } } - selections.setSize(nElem); if (debug) { - Info<< "Active array: " << selections << endl; + Info << " )" << endl; } + selections.setSize(nElem); return selections; } @@ -337,14 +346,14 @@ Foam::stringList Foam::vtkPV3Foam::getSelectedArrayEntries const bool firstWord ) { - if (debug) - { - Info<< "entered Foam::vtkPV3Foam::getSelectedArrayEntries" << endl; - } - stringList selections(selector.size()); label nElem = 0; + if (debug) + { + Info << "selections("; + } + for ( int regionId = selector.start(); @@ -366,16 +375,22 @@ Foam::stringList Foam::vtkPV3Foam::getSelectedArrayEntries selections[nElem] = arraySelection->GetArrayName(regionId); } + if (debug) + { + Info << " " << selections[nElem]; + } + ++nElem; } } - selections.setSize(nElem); if (debug) { - Info<< "Active array: " << selections << endl; + Info << " )" << endl; } + + selections.setSize(nElem); return selections; } @@ -386,9 +401,9 @@ void Foam::vtkPV3Foam::setSelectedArrayEntries const stringList& selections ) { - if (debug) + if (debug > 1) { - Info<< "entered Foam::vtkPV3Foam::setSelectedArrayEntries" << endl; + Info<< " Foam::vtkPV3Foam::setSelectedArrayEntries" << endl; } const label nEntries = arraySelection->GetNumberOfArrays(); @@ -398,7 +413,7 @@ void Foam::vtkPV3Foam::setSelectedArrayEntries // Loop through entries, setting values from selectedEntries forAll (selections, elemI) { - if (debug) + if (debug > 1) { Info<< "selections[" << elemI << "] = " << selections[elemI] << endl; @@ -410,7 +425,7 @@ void Foam::vtkPV3Foam::setSelectedArrayEntries if (arrayName == selections[elemI]) { - if (debug) + if (debug > 1) { Info<< "enabling array: " << arrayName << " Index = " << i @@ -425,6 +440,10 @@ void Foam::vtkPV3Foam::setSelectedArrayEntries } } } + if (debug > 1) + { + Info<< " Foam::vtkPV3Foam::setSelectedArrayEntries" << endl; + } } @@ -455,8 +474,7 @@ Foam::vtkPV3Foam::vtkPV3Foam { if (debug) { - Info<< "entered Foam::vtkPV3Foam::vtkPV3Foam with " - << FileName << endl; + Info<< "Foam::vtkPV3Foam::vtkPV3Foam - " << FileName << endl; } // avoid argList and get rootPath/caseName directly from the file @@ -471,6 +489,22 @@ Foam::vtkPV3Foam::vtkPV3Foam fullCasePath = cwd(); } + // Set the case as an environment variable - some BCs might use this + if (fullCasePath.name().find("processor", 0) == 0) + { + setEnv("FOAM_CASE", fullCasePath.path(), true); + } + else + { + setEnv("FOAM_CASE", fullCasePath, true); + } + + if (debug) + { + Info<< "fullCasePath=" << fullCasePath << nl + << "FOAM_CASE=" << getEnv("FOAM_CASE") << endl; + } + // Create time object dbPtr_.reset ( @@ -504,7 +538,7 @@ Foam::vtkPV3Foam::~vtkPV3Foam() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::~vtkPV3Foam" << endl; + Info<< " Foam::vtkPV3Foam::~vtkPV3Foam" << endl; } if (meshPtr_) @@ -521,7 +555,7 @@ void Foam::vtkPV3Foam::UpdateInformation() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::UpdateInformation" << nl + Info<< " Foam::vtkPV3Foam::UpdateInformation - " << "TimeStep = " << reader_->GetTimeStep() << endl; } @@ -575,6 +609,12 @@ void Foam::vtkPV3Foam::UpdateInformation() // Update lagrangian field array updateInformationLagrangianFields(); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::UpdateInformation" << endl; + } + } @@ -585,8 +625,8 @@ void Foam::vtkPV3Foam::Update { if (debug) { - cout<< "entered Foam::vtkPV3Foam::Update" << nl - <<"Update\n"; + cout<< " Foam::vtkPV3Foam::Update" << nl + <<"Update\n"; output->Print(cout); cout<<"Internally:\n"; @@ -596,7 +636,6 @@ void Foam::vtkPV3Foam::Update } - // Set up region selection(s) updateSelectedRegions(); @@ -673,15 +712,16 @@ double* Foam::vtkPV3Foam::timeSteps(int& nTimeSteps) int nTimes = 0; double* ts = NULL; - vtkDataArraySelection* arraySelection = reader_->GetTimeSelection(); - if (dbPtr_.valid()) { Time& runTime = dbPtr_(); instantList times = runTime.times(); + +#ifdef PV3FOAM_TIMESELECTION List selected = List(times.size(), false); + vtkDataArraySelection* arraySelection = reader_->GetTimeSelection(); const label nSelectedTimes = arraySelection->GetNumberOfArrays(); for (int i = 0; i < nSelectedTimes; ++i) @@ -694,20 +734,21 @@ double* Foam::vtkPV3Foam::timeSteps(int& nTimeSteps) && timeI < times.size() ) { -#if 0 - Info<<"timeSelection[" - << i - <<"] = " - << arraySelection->GetArraySetting(i) - << " is " - << arraySelection->GetArrayName(i) << endl; -#endif + if (debug > 1) + { + Info<<"timeSelection[" + << i + <<"] = " + << arraySelection->GetArraySetting(i) + << " is " + << arraySelection->GetArrayName(i) << endl; + } selected[timeI] = true; ++nTimes; } } - if (debug) + if (debug > 1) { Info<< "selected " << nTimes << " times "; Info<< "found " << times.size() << " times: ("; @@ -732,6 +773,27 @@ double* Foam::vtkPV3Foam::timeSteps(int& nTimeSteps) } } } + +#else /* PV3FOAM_TIMESELECTION */ + // always skip "constant" time, unless there are no other times + nTimes = times.size(); + label timeI = 0; + + if (nTimes > 1) + { + timeI = 1; + --nTimes; + } + + if (nTimes) + { + ts = new double[nTimes]; + for (label stepI = 0; stepI < nTimes; ++stepI, ++timeI) + { + ts[stepI] = times[timeI].value(); + } + } +#endif /* PV3FOAM_TIMESELECTION */ } else { @@ -741,7 +803,7 @@ double* Foam::vtkPV3Foam::timeSteps(int& nTimeSteps) } } - // return length via the parameter + // return vector length via the parameter nTimeSteps = nTimes; return ts; @@ -755,7 +817,7 @@ void Foam::vtkPV3Foam::addPatchNames(vtkRenderer* renderer) if (debug) { - Info<< "addPatchNames()" << endl; + Info<< " Foam::vtkPV3Foam::addPatchNames" << endl; } const fvMesh& mesh = *meshPtr_; @@ -773,7 +835,7 @@ void Foam::vtkPV3Foam::addPatchNames(vtkRenderer* renderer) if (debug) { - Info<<"patches: " << selectedPatches < Foam::vtkPV3Foam::addPatchNames)" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceSetMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceSetMesh.C index 3de4b9c5d1..116f503a4d 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceSetMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceSetMesh.C @@ -48,7 +48,7 @@ void Foam::vtkPV3Foam::addFaceSetMesh { if (debug) { - Info<< "entered add face set internal mesh" << endl; + Info<< " Foam::vtkPV3Foam::addFaceSetMesh" << endl; } // Construct primitivePatch of faces in fSet. @@ -96,6 +96,11 @@ void Foam::vtkPV3Foam::addFaceSetMesh vtkmesh->SetPolys(vtkcells); vtkcells->Delete(); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::addFaceSetMesh" << endl; + } } // ************************************************************************* // diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceZoneMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceZoneMesh.C index 008caece7c..044d4cedaf 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceZoneMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFaceZoneMesh.C @@ -47,7 +47,7 @@ void Foam::vtkPV3Foam::addFaceZoneMesh { if (debug) { - Info<< "entered addFaceZoneMesh" << endl; + Info<< " Foam::vtkPV3Foam::addFaceZoneMesh" << endl; } // Construct primitivePatch of faces in fSet. @@ -94,6 +94,11 @@ void Foam::vtkPV3Foam::addFaceZoneMesh vtkmesh->SetPolys(vtkcells); vtkcells->Delete(); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::addFaceZoneMesh" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFields.H b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFields.H index 3c6580d1d3..ff6c48bfe5 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFields.H +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddFields.H @@ -64,7 +64,7 @@ Foam::label Foam::vtkPV3Foam::addFields { if (debug) { - Info<<"add region " << GeoField::typeName + Info<<" addField to GUI " << GeoField::typeName << ":" << fields[fieldI] << endl; } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddLagrangianMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddLagrangianMesh.C index b1f3099acd..d4d31aa3cc 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddLagrangianMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddLagrangianMesh.C @@ -50,7 +50,7 @@ void Foam::vtkPV3Foam::addLagrangianMesh { if (debug) { - Info<< "entered add Lagrangian mesh with timePath " + Info<< " Foam::vtkPV3Foam::addLagrangianMesh - timePath " << mesh.time().timePath()/"lagrangian" << endl; } @@ -61,7 +61,7 @@ void Foam::vtkPV3Foam::addLagrangianMesh if (debug && cloudDirs.size()) { - Info<< "check cloudDirs: " << cloudDirs << endl; + Info<< "... check cloudDirs: " << cloudDirs << endl; } bool foundCloud = false; @@ -99,6 +99,11 @@ void Foam::vtkPV3Foam::addLagrangianMesh vtkpoints->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::addLagrangianMesh" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPatchMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPatchMesh.C index e23ff92415..37392c905f 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPatchMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPatchMesh.C @@ -48,7 +48,7 @@ void Foam::vtkPV3Foam::addPatchMesh { if (debug) { - Info<< "Adding patch: " << p.name() << endl; + Info<< " Foam::vtkPV3Foam::addPatchMesh - " << p.name() << endl; } // Convert Foam mesh vertices to VTK @@ -84,6 +84,11 @@ void Foam::vtkPV3Foam::addPatchMesh vtkmesh->SetPolys(vtkcells); vtkcells->Delete(); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::addPatchMesh - " << p.name() << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointSetMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointSetMesh.C index 3567b6827f..4a19fab3d4 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointSetMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointSetMesh.C @@ -47,7 +47,7 @@ void Foam::vtkPV3Foam::addPointSetMesh { if (debug) { - Info<< "entered add point set mesh" << endl; + Info<< " Foam::vtkPV3Foam::addPointSetMesh" << endl; } const pointField& meshPoints = mesh.points(); @@ -62,6 +62,11 @@ void Foam::vtkPV3Foam::addPointSetMesh vtkmesh->SetPoints(vtkpoints); vtkpoints->Delete(); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::addPointSetMesh" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointZoneMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointZoneMesh.C index 51d735a79b..f6369bfa23 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointZoneMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddPointZoneMesh.C @@ -46,7 +46,7 @@ void Foam::vtkPV3Foam::addPointZoneMesh { if (debug) { - Info<< "entered add point zone mesh" << endl; + Info<< " Foam::vtkPV3Foam::addPointZoneMesh" << endl; } const pointField& meshPoints = mesh.points(); @@ -61,6 +61,11 @@ void Foam::vtkPV3Foam::addPointZoneMesh vtkmesh->SetPoints(vtkpoints); vtkpoints->Delete(); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::addPointZoneMesh" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddVolumeMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddVolumeMesh.C index c86dbec1da..5de9114eef 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddVolumeMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamAddVolumeMesh.C @@ -54,7 +54,7 @@ void Foam::vtkPV3Foam::addVolumeMesh { if (debug) { - Info<< "entered add volume mesh" << endl; + Info<< " Foam::vtkPV3Foam::addVolumeMesh" << endl; } // Number of additional points needed by the decomposition of polyhedra @@ -74,13 +74,13 @@ void Foam::vtkPV3Foam::addVolumeMesh // and cells if (debug) { - Info<< "building cell-shapes" << endl; + Info<< "... building cell-shapes" << endl; } const cellShapeList& cellShapes = mesh.cellShapes(); if (debug) { - Info<< "scanning" << endl; + Info<< "... scanning" << endl; } forAll(cellShapes, cellI) { @@ -133,7 +133,7 @@ void Foam::vtkPV3Foam::addVolumeMesh if (debug) { - Info<< "converting points" << endl; + Info<< "... converting points" << endl; } // Convert Foam mesh vertices to VTK @@ -150,7 +150,7 @@ void Foam::vtkPV3Foam::addVolumeMesh if (debug) { - Info<< "converting cells" << endl; + Info<< "... converting cells" << endl; } vtkmesh->Allocate(mesh.nCells() + nAddCells); @@ -350,6 +350,11 @@ void Foam::vtkPV3Foam::addVolumeMesh vtkmesh->SetPoints(vtkpoints); vtkpoints->Delete(); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::addVolumeMesh" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertMesh.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertMesh.C index 4c5f1a10ea..47239f02d7 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertMesh.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertMesh.C @@ -50,7 +50,7 @@ void Foam::vtkPV3Foam::convertMeshVolume { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshVolume" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshVolume" << endl; } const selectionInfo& selector = selectInfoVolume_; @@ -88,6 +88,11 @@ void Foam::vtkPV3Foam::convertMeshVolume selectedRegionDatasetIds_[regionId] = datasetId; vtkmesh->Delete(); } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshVolume" << endl; + } } @@ -98,7 +103,7 @@ void Foam::vtkPV3Foam::convertMeshLagrangian { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshLagrangian" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshLagrangian" << endl; } const selectionInfo& selector = selectInfoLagrangian_; @@ -131,6 +136,10 @@ void Foam::vtkPV3Foam::convertMeshLagrangian selectedRegionDatasetIds_[regionId] = datasetId; vtkmesh->Delete(); } + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshLagrangian" << endl; + } } @@ -141,7 +150,7 @@ void Foam::vtkPV3Foam::convertMeshPatches { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshPatches" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshPatches" << endl; } const selectionInfo& selector = selectInfoPatches_; @@ -196,6 +205,11 @@ void Foam::vtkPV3Foam::convertMeshPatches vtkmesh->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshPatches" << endl; + } } @@ -206,7 +220,7 @@ void Foam::vtkPV3Foam::convertMeshCellZones { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshCellZones" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshCellZones" << endl; } const selectionInfo& selector = selectInfoCellZones_; @@ -263,6 +277,11 @@ void Foam::vtkPV3Foam::convertMeshCellZones vtkmesh->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshCellZones" << endl; + } } @@ -273,7 +292,7 @@ void Foam::vtkPV3Foam::convertMeshCellSet { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshCellSet" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshCellSet" << endl; } const selectionInfo& selector = selectInfoCellSets_; @@ -337,6 +356,11 @@ void Foam::vtkPV3Foam::convertMeshCellSet vtkmesh->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshCellSet" << endl; + } } void Foam::vtkPV3Foam::convertMeshFaceZones @@ -346,7 +370,7 @@ void Foam::vtkPV3Foam::convertMeshFaceZones { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshFaceZones" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshFaceZones" << endl; } const selectionInfo& selector = selectInfoFaceZones_; @@ -393,6 +417,11 @@ void Foam::vtkPV3Foam::convertMeshFaceZones vtkmesh->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshFaceZones" << endl; + } } @@ -403,7 +432,7 @@ void Foam::vtkPV3Foam::convertMeshFaceSet { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshFaceSet" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshFaceSet" << endl; } const selectionInfo& selector = selectInfoFaceSets_; @@ -458,6 +487,11 @@ void Foam::vtkPV3Foam::convertMeshFaceSet vtkmesh->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshFaceSet" << endl; + } } @@ -468,7 +502,7 @@ void Foam::vtkPV3Foam::convertMeshPointZones { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshPointZones" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshPointZones" << endl; } const selectionInfo& selector = selectInfoPointZones_; @@ -498,7 +532,7 @@ void Foam::vtkPV3Foam::convertMeshPointZones const label datasetId = GetNumberOfDataSets(output, selector); vtkPolyData* vtkmesh = vtkPolyData::New(); - + addPointZoneMesh ( mesh, @@ -515,6 +549,11 @@ void Foam::vtkPV3Foam::convertMeshPointZones vtkmesh->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshPointZones" << endl; + } } @@ -526,7 +565,7 @@ void Foam::vtkPV3Foam::convertMeshPointSet { if (debug) { - Info<< "entered Foam::vtkPV3Foam::convertMeshPointSet" << endl; + Info<< " Foam::vtkPV3Foam::convertMeshPointSet" << endl; } const selectionInfo& selector = selectInfoPointSets_; @@ -581,7 +620,11 @@ void Foam::vtkPV3Foam::convertMeshPointSet vtkmesh->Delete(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::convertMeshPointSet" << endl; + } } - // ************************************************************************* // diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertPointFields.H b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertPointFields.H index 28d7fdfe5d..d26a0eb365 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertPointFields.H +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamConvertPointFields.H @@ -66,7 +66,7 @@ void Foam::vtkPV3Foam::convertPointFields if (debug) { - Info<< "converting Foam point field: " << fieldName + Info<< "Foam::vtkPV3Foam::convertPointFields : " << fieldName << endl; } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdate.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdate.C index 861a8573ac..85493b933e 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdate.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdate.C @@ -47,13 +47,16 @@ void Foam::vtkPV3Foam::updateFoamMesh() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateFoamMesh" << endl; + Info<< " Foam::vtkPV3Foam::updateFoamMesh" << endl; } if ( !reader_->GetCacheMesh() +#ifdef PV3FOAM_TIMESELECTION + // This is only useful if the times are individually selectable || reader_->GetTimeSelection()->GetArraySetting(0) +#endif ) { delete meshPtr_; @@ -84,6 +87,11 @@ void Foam::vtkPV3Foam::updateFoamMesh() Info<< "Using existing Foam mesh" << endl; } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateFoamMesh" << endl; + } } @@ -94,7 +102,7 @@ void Foam::vtkPV3Foam::updateVolFields { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateVolFields" << endl; + Info<< " Foam::vtkPV3Foam::updateVolFields" << endl; } const fvMesh& mesh = *meshPtr_; @@ -155,6 +163,11 @@ void Foam::vtkPV3Foam::updateVolFields ( mesh, pInterp, ppInterpList, objects, arraySelection, output ); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateVolFields" << endl; + } } @@ -165,7 +178,7 @@ void Foam::vtkPV3Foam::updatePointFields { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updatePointFields" << endl; + Info<< " Foam::vtkPV3Foam::updatePointFields" << endl; } const fvMesh& mesh = *meshPtr_; @@ -175,11 +188,6 @@ void Foam::vtkPV3Foam::updatePointFields vtkDataArraySelection* arraySelection = reader_->GetPointFieldSelection(); - // Convert point fields - if (debug) - { - Info<< "converting Foam point fields" << endl; - } /* convertPointFields ( @@ -206,6 +214,11 @@ void Foam::vtkPV3Foam::updatePointFields ( mesh, objects, arraySelection, output ); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updatePointFields" << endl; + } } @@ -216,7 +229,7 @@ void Foam::vtkPV3Foam::updateLagrangianFields { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateLagrangianFields" << endl; + Info<< " Foam::vtkPV3Foam::updateLagrangianFields" << endl; } const fvMesh& mesh = *meshPtr_; @@ -264,6 +277,11 @@ void Foam::vtkPV3Foam::updateLagrangianFields ( mesh, objects, arraySelection, output ); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateLagrangianFields" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformation.C b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformation.C index d86a8a90dc..9c2d144dea 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformation.C +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformation.C @@ -86,8 +86,7 @@ void Foam::vtkPV3Foam::updateInformationInternalMesh() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateInformationInternalMesh" - << endl; + Info<< " Foam::vtkPV3Foam::updateInformationInternalMesh" << endl; } vtkDataArraySelection* arraySelection = reader_->GetRegionSelection(); @@ -101,6 +100,12 @@ void Foam::vtkPV3Foam::updateInformationInternalMesh() selectInfoVolume_ = arraySelection->GetNumberOfArrays(); arraySelection->AddArray("internalMesh"); selectInfoVolume_ += 1; + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateInformationInternalMesh" << endl; + } + } @@ -108,8 +113,8 @@ void Foam::vtkPV3Foam::updateInformationLagrangian() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateInformationLagrangian " - << "at timePath " << dbPtr_->timePath()/"lagrangian" << endl; + Info<< " Foam::vtkPV3Foam::updateInformationLagrangian" << nl + << " " << dbPtr_->timePath()/"lagrangian" << endl; } vtkDataArraySelection* arraySelection = reader_->GetRegionSelection(); @@ -144,11 +149,15 @@ void Foam::vtkPV3Foam::updateInformationLagrangian() { if (debug) { - Info<<"no clouds identified in " - << dbPtr_->timePath()/"lagrangian" << endl; + Info<<"no clouds identified in " <timePath()/"lagrangian" << endl; } } + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateInformationLagrangian" << endl; + } } @@ -156,7 +165,7 @@ void Foam::vtkPV3Foam::updateInformationPatches() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateInformationPatches" << endl; + Info<< " Foam::vtkPV3Foam::updateInformationPatches" << endl; } vtkDataArraySelection *arraySelection = reader_->GetRegionSelection(); @@ -198,6 +207,10 @@ void Foam::vtkPV3Foam::updateInformationPatches() } selectInfoPatches_ += nPatches; + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateInformationPatches" << endl; + } } @@ -205,7 +218,7 @@ void Foam::vtkPV3Foam::updateInformationZones() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateInformationZones" << endl; + Info<< " Foam::vtkPV3Foam::updateInformationZones" << endl; } vtkDataArraySelection *arraySelection = reader_->GetRegionSelection(); @@ -301,6 +314,12 @@ void Foam::vtkPV3Foam::updateInformationZones() selectInfoPointZones_ += zones.size(); } } + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateInformationZones" << endl; + } + } @@ -308,7 +327,7 @@ void Foam::vtkPV3Foam::updateInformationSets() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateInformationSets" << endl; + Info<< " Foam::vtkPV3Foam::updateInformationSets" << endl; } vtkDataArraySelection *arraySelection = reader_->GetRegionSelection(); @@ -346,6 +365,11 @@ void Foam::vtkPV3Foam::updateInformationSets() objects, " - pointSet" ); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateInformationSets" << endl; + } } @@ -353,7 +377,7 @@ void Foam::vtkPV3Foam::updateInformationLagrangianFields() { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateInformationLagrangianFields" + Info<< " Foam::vtkPV3Foam::updateInformationLagrangianFields" << endl; } @@ -415,8 +439,8 @@ void Foam::vtkPV3Foam::updateInformationLagrangianFields() if (debug) { - Info<< "lagrangian objects.size() = " << objects.size() - << endl; + Info<< " Foam::vtkPV3Foam::updateInformationLagrangianFields - " + << "lagrangian objects.size() = " << objects.size() << endl; } } diff --git a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformationFields.H b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformationFields.H index 91571ca5f4..170ad74ed1 100644 --- a/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformationFields.H +++ b/applications/utilities/postProcessing/graphics/PV3FoamReader/vtkPV3Foam/vtkPV3FoamUpdateInformationFields.H @@ -40,7 +40,7 @@ void Foam::vtkPV3Foam::updateInformationFields { if (debug) { - Info<< "entered Foam::vtkPV3Foam::updateInformationFields" << endl; + Info<< " Foam::vtkPV3Foam::updateInformationFields" << endl; } // preserve the currently selected values @@ -94,6 +94,11 @@ void Foam::vtkPV3Foam::updateInformationFields arraySelection, selectedEntries ); + + if (debug) + { + Info<< " Foam::vtkPV3Foam::updateInformationFields" << endl; + } } diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/Allwmake b/applications/utilities/postProcessing/graphics/ensightFoamReader/Allwmake similarity index 54% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/Allwmake rename to applications/utilities/postProcessing/graphics/ensightFoamReader/Allwmake index f5d718f041..aca3e014c9 100755 --- a/applications/utilities/postProcessing/graphics/ensight76FoamExec/Allwmake +++ b/applications/utilities/postProcessing/graphics/ensightFoamReader/Allwmake @@ -1 +1,2 @@ +#!/bin/sh wmake libso diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/Make/files b/applications/utilities/postProcessing/graphics/ensightFoamReader/Make/files similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/Make/files rename to applications/utilities/postProcessing/graphics/ensightFoamReader/Make/files diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/Make/options b/applications/utilities/postProcessing/graphics/ensightFoamReader/Make/options similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/Make/options rename to applications/utilities/postProcessing/graphics/ensightFoamReader/Make/options diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README b/applications/utilities/postProcessing/graphics/ensightFoamReader/README similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README7 b/applications/utilities/postProcessing/graphics/ensightFoamReader/README7 similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README7 rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README7 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README_1.0_to_2.0 b/applications/utilities/postProcessing/graphics/ensightFoamReader/README_1.0_to_2.0 similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README_1.0_to_2.0 rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README_1.0_to_2.0 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README_2.01_to_2.03 b/applications/utilities/postProcessing/graphics/ensightFoamReader/README_2.01_to_2.03 similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README_2.01_to_2.03 rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README_2.01_to_2.03 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_1.0 b/applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_1.0 similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_1.0 rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_1.0 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.0 b/applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.0 similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.0 rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.0 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.01 b/applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.01 similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.01 rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.01 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.03 b/applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.03 similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.03 rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.03 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.03_CHANGES b/applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.03_CHANGES similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/README_USERD_2.03_CHANGES rename to applications/utilities/postProcessing/graphics/ensightFoamReader/README_USERD_2.03_CHANGES diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_bkup.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_bkup.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_bkup.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_bkup.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_exit_routine.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_exit_routine.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_exit_routine.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_exit_routine.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_border_availability.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_border_availability.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_border_availability.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_border_availability.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_border_elements_by_type.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_border_elements_by_type.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_border_elements_by_type.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_border_elements_by_type.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_changing_geometry_status.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_changing_geometry_status.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_changing_geometry_status.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_changing_geometry_status.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_constant_val.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_constant_val.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_constant_val.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_constant_val.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_dataset_query_file_info.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_dataset_query_file_info.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_dataset_query_file_info.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_dataset_query_file_info.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_descrip_lines.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_descrip_lines.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_descrip_lines.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_descrip_lines.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_element_label_status.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_element_label_status.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_element_label_status.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_element_label_status.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_geom_timeset_number.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_geom_timeset_number.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_geom_timeset_number.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_geom_timeset_number.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_gold_part_build_info.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_gold_part_build_info.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_gold_part_build_info.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_gold_part_build_info.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_gold_variable_info.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_gold_variable_info.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_gold_variable_info.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_gold_variable_info.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_matf_set_info.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_matf_set_info.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_matf_set_info.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_matf_set_info.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_matf_var_info.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_matf_var_info.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_matf_var_info.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_matf_var_info.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_maxsize_info.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_maxsize_info.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_maxsize_info.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_maxsize_info.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_model_extents.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_model_extents.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_model_extents.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_model_extents.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_name_of_reader.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_name_of_reader.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_name_of_reader.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_name_of_reader.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_nfaced_conn.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_nfaced_conn.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_nfaced_conn.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_nfaced_conn.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_nfaced_nodes_per_face.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_nfaced_nodes_per_face.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_nfaced_nodes_per_face.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_nfaced_nodes_per_face.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_node_label_status.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_node_label_status.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_node_label_status.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_node_label_status.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_nsided_conn.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_nsided_conn.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_nsided_conn.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_nsided_conn.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_num_of_time_steps.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_num_of_time_steps.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_num_of_time_steps.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_num_of_time_steps.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_files_in_dataset.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_files_in_dataset.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_files_in_dataset.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_files_in_dataset.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_material_sets.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_material_sets.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_material_sets.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_material_sets.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_materials.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_materials.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_materials.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_materials.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_model_parts.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_model_parts.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_model_parts.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_model_parts.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_variables.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_variables.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_of_variables.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_of_variables.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_timesets.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_timesets.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_number_timesets.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_number_timesets.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_coords.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_coords.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_coords.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_coords.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_element_ids_by_type.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_element_ids_by_type.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_element_ids_by_type.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_element_ids_by_type.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_elements_by_type.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_elements_by_type.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_elements_by_type.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_elements_by_type.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_node_ids.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_node_ids.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_part_node_ids.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_part_node_ids.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_reader_version.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_reader_version.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_reader_version.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_reader_version.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_sol_times.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_sol_times.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_sol_times.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_sol_times.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_timeset_description.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_timeset_description.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_timeset_description.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_timeset_description.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_var_by_component.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_var_by_component.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_var_by_component.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_var_by_component.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_var_value_at_specific.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_var_value_at_specific.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_get_var_value_at_specific.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_get_var_value_at_specific.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_load_matf_data.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_load_matf_data.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_load_matf_data.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_load_matf_data.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_set_filenames.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_set_filenames.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_set_filenames.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_set_filenames.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_set_server_number.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_set_server_number.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_set_server_number.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_set_server_number.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_set_time_set_and_step.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_set_time_set_and_step.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_set_time_set_and_step.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_set_time_set_and_step.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_size_matf_data.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_size_matf_data.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_size_matf_data.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_size_matf_data.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_stop_part_building.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_stop_part_building.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_stop_part_building.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_stop_part_building.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_structured_data.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_structured_data.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/USERD_structured_data.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/USERD_structured_data.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getFieldScalar.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getFieldScalar.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getFieldScalar.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getFieldScalar.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getFieldTensor.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getFieldTensor.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getFieldTensor.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getFieldTensor.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getFieldVector.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getFieldVector.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getFieldVector.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getFieldVector.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getLagrangianScalar.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getLagrangianScalar.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getLagrangianScalar.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getLagrangianScalar.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getLagrangianVector.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getLagrangianVector.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getLagrangianVector.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getLagrangianVector.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getPatchFieldScalar.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getPatchFieldScalar.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getPatchFieldScalar.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getPatchFieldScalar.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getPatchFieldTensor.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getPatchFieldTensor.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getPatchFieldTensor.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getPatchFieldTensor.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/getPatchFieldVector.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/getPatchFieldVector.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/getPatchFieldVector.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/getPatchFieldVector.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/globalFoam.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/globalFoam.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/globalFoam.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/globalFoam.H diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/global_extern.h b/applications/utilities/postProcessing/graphics/ensightFoamReader/global_extern.h similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/global_extern.h rename to applications/utilities/postProcessing/graphics/ensightFoamReader/global_extern.h diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/global_extern_proto.h b/applications/utilities/postProcessing/graphics/ensightFoamReader/global_extern_proto.h similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/global_extern_proto.h rename to applications/utilities/postProcessing/graphics/ensightFoamReader/global_extern_proto.h diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/libuserd.C b/applications/utilities/postProcessing/graphics/ensightFoamReader/libuserd.C similarity index 96% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/libuserd.C rename to applications/utilities/postProcessing/graphics/ensightFoamReader/libuserd.C index 44d3087638..9057461ea9 100644 --- a/applications/utilities/postProcessing/graphics/ensight76FoamExec/libuserd.C +++ b/applications/utilities/postProcessing/graphics/ensightFoamReader/libuserd.C @@ -26,10 +26,9 @@ Application libuserd-foam Description - Module for EnSight 7.6 to read FOAM data directly without translation + EnSight library module to read OpenFOAM data directly without translation - It can currently handle cells of type: - Z_HEX08, Z_PEN06, Z_TET04, Z_PUR05 + It can currently handle most cell types. See also: README_USERD_2.0 24 Sep 2001: NN - Added support for Ensight API 2.0 diff --git a/applications/utilities/postProcessing/graphics/ensight76FoamExec/tensorConversion.H b/applications/utilities/postProcessing/graphics/ensightFoamReader/tensorConversion.H similarity index 100% rename from applications/utilities/postProcessing/graphics/ensight76FoamExec/tensorConversion.H rename to applications/utilities/postProcessing/graphics/ensightFoamReader/tensorConversion.H diff --git a/applications/utilities/postProcessing/sampling/probeLocations/probeLocations.C b/applications/utilities/postProcessing/sampling/probeLocations/probeLocations.C index 920f251656..4e960a7415 100644 --- a/applications/utilities/postProcessing/sampling/probeLocations/probeLocations.C +++ b/applications/utilities/postProcessing/sampling/probeLocations/probeLocations.C @@ -44,7 +44,7 @@ int main(int argc, char *argv[]) instantList timeDirs = timeSelector::select0(runTime, args); # include "createMesh.H" - IOprobes sniff(mesh, "probesDict", true); + IOprobes sniff(mesh, "probesDict", IOobject::MUST_READ, true); forAll(timeDirs, timeI) { diff --git a/applications/utilities/postProcessing/sampling/sample/sample.C b/applications/utilities/postProcessing/sampling/sample/sample.C index 1cc9115dba..f2b27de8ea 100644 --- a/applications/utilities/postProcessing/sampling/sample/sample.C +++ b/applications/utilities/postProcessing/sampling/sample/sample.C @@ -28,39 +28,39 @@ Description Keywords: - setFormat: set output format, choice of - xmgr - jplot - gnuplot - raw + @param setFormat : set output format, choice of \n + - xmgr + - jplot + - gnuplot + - raw - surfaceFormat: surface output format, choice of - null : suppress output - foamFile : separate points, faces and values file - dx : DX scalar or vector format - vtk : VTK ascii format - raw : x y z value format for use with e.g. gnuplot 'splot'. - stl : ascii stl. Does not contain values! + @param surfaceFormat : surface output format, choice of \n + - null : suppress output + - foamFile : separate points, faces and values file + - dx : DX scalar or vector format + - vtk : VTK ascii format + - raw : x y z value format for use with e.g. gnuplot 'splot'. + - stl : ascii stl. Does not contain values! - interpolationScheme: interpolation scheme, choice of - cell : use cell-centre value; constant over cells (default) - cellPoint : use cell-centre and vertex values - cellPointFace : use cell-centre, vertex and face values. - 1] vertex values determined from neighbouring cell-centre values - 2] face values determined using the current face interpolation scheme - for the field (linear, limitedLinear, etc.) + @param interpolationScheme : interpolation scheme, choice of \n + - cell : use cell-centre value; constant over cells (default) + - cellPoint : use cell-centre and vertex values + - cellPointFace : use cell-centre, vertex and face values. \n + -# vertex values determined from neighbouring cell-centre values + -# face values determined using the current face interpolation scheme + for the field (linear, limitedLinear, etc.) - fields: list of fields to sample + @param fields : list of fields to sample - sets: list of sets to sample, choice of - uniform evenly distributed points on line - face one point per face intersection - midPoint one point per cell, inbetween two face intersections - midPointAndFace combination of face and midPoint + @param sets : list of sets to sample, choice of \n + - uniform evenly distributed points on line + - face one point per face intersection + - midPoint one point per cell, inbetween two face intersections + - midPointAndFace combination of face and midPoint - curve specified points, not nessecary on line, uses + - curve specified points, not nessecary on line, uses tracking - cloud specified points, uses findCell + - cloud specified points, uses findCell Option axis: how to write point coordinate. Choice of - x/y/z: x/y/z coordinate only @@ -74,11 +74,12 @@ Description uniform: extra number of sampling points curve, cloud: list of coordinates - surfaces: list of surfaces to sample, choice of - plane : values on plane defined by point, normal. - patch : values on patch. + @param surfaces : list of surfaces to sample, choice of \n + - plane : values on plane defined by point, normal. + - patch : values on patch. - Runs in parallel. +Notes + Runs in parallel \*---------------------------------------------------------------------------*/ @@ -100,8 +101,8 @@ int main(int argc, char *argv[]) instantList timeDirs = timeSelector::select0(runTime, args); # include "createMesh.H" - IOsampledSets sSets(mesh, "sampleDict", true); - IOsampledSurfaces sSurfaces(mesh, "sampleDict", true); + IOsampledSets sSets(mesh, "sampleDict", IOobject::MUST_READ, true); + IOsampledSurfaces sSurfs(mesh, "sampleDict", IOobject::MUST_READ, true); forAll(timeDirs, timeI) { @@ -112,10 +113,10 @@ int main(int argc, char *argv[]) polyMesh::readUpdateState state = mesh.readUpdate(); sSets.readUpdate(state); - sSurfaces.readUpdate(state); + sSurfs.readUpdate(state); sSets.write(); - sSurfaces.write(); + sSurfs.write(); Info<< endl; } diff --git a/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C b/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C index e2a8a9c5ab..06b9e6c884 100644 --- a/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C +++ b/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C @@ -95,8 +95,8 @@ int main(int argc, char *argv[]) << exit(FatalError); } - Info<< "\nCreating boundary-layer for U of thickness" << ybl.value() << " m" - << nl << endl; + Info<< "\nCreating boundary-layer for U of thickness " + << ybl.value() << " m" << nl << endl; // Modify velocity by applying a 1/7th power law boundary-layer // u/U0 = (y/ybl)^(1/7) diff --git a/bin/foamClearPolyMesh b/bin/foamClearPolyMesh index 07531f68bf..c354ca0dd3 100755 --- a/bin/foamClearPolyMesh +++ b/bin/foamClearPolyMesh @@ -35,7 +35,7 @@ usage() { while [ "$#" -ge 1 ]; do echo "$1" 1>&2; shift; done cat <&2 -usage: ${0##*/} [-case dir] +usage: ${0##*/} [-case dir] [-region name] Remove the contents of the constant/polyMesh directory as per the Foam::polyMesh::removeFiles() method. @@ -44,46 +44,60 @@ USAGE exit 1 } -unset caseDir -unset meshDir +unset caseDir regionName -# parse options -if [ "$#" -gt 0 ]; then +# parse a single option +while [ "$#" -gt 0 ] +do case "$1" in -h | -help) usage ;; -case) - shift - caseDir=$1 - [ "$#" -ge 1 ] || usage "'-case' option requires an argument" + [ "$#" -ge 2 ] || usage "'-case' option requires an argument" + caseDir=$2 + shift 2 cd "$caseDir" 2>/dev/null || usage "directory does not exist: '$caseDir'" - meshDir="constant/polyMesh" + ;; + -region) + [ "$#" -ge 2 ] || usage "'-region' option requires an argument" + regionName=$2 + shift 2 ;; *) usage "unknown option/argument: '$*'" ;; esac +done + +if [ -n "$regionName" ] +then + meshDir=$regionName/polyMesh +else + meshDir=polyMesh fi -# meshDir is only set if -case was specified: insist upon 'constant/polyMesh' -if [ -n "$meshDir" ] +# if -case was specified: insist upon 'constant/polyMesh' +if [ -n "$caseDir" ] then - if [ ! -d "$meshDir" ] + if [ -d constant/$meshDir ] then - echo "Error: no '$meshDir' in $caseDir" 1>&2 + # use constant/polyMesh + meshDir=constant/$meshDir + else + echo "Error: no 'constant/$meshDir' in $caseDir" 1>&2 exit 1 fi else - if [ -d constant/polyMesh ] + if [ -d constant/$meshDir ] then # use constant/polyMesh - meshDir=constant/polyMesh - elif [ -d polyMesh ] + meshDir=constant/$meshDir + elif [ -d $meshDir ] then - # likely already in constant/ - meshDir=polyMesh - elif [ "${PWD##*/}" = polyMesh ] + # likely already in constant/ - do not adjust anything + : + elif [ "${PWD##*/}" = polyMesh -a -z "$regionName" ] then # apparently already within polyMesh/ meshDir=. diff --git a/bin/foamCopySettings b/bin/foamCopySettings index 22c7a6b32a..bad2904aea 100755 --- a/bin/foamCopySettings +++ b/bin/foamCopySettings @@ -84,9 +84,9 @@ for i in $fileList do name="${i##*/}" # skip numerical (results) directories (except 0) - # and things that look like queuing system output + # and things that look like queuing system output or log files case "$name" in - [1-9] | [0-9]?* | foam.[eo][1-9]*) + [1-9] | [0-9]?* | foam.[eo][1-9]* | log | *.log ) echo "$i [skipped]" continue ;; diff --git a/bin/foamDiffSourceList b/bin/foamDiffSourceList deleted file mode 100755 index 560d965032..0000000000 --- a/bin/foamDiffSourceList +++ /dev/null @@ -1,135 +0,0 @@ -#!/bin/sh -#------------------------------------------------------------------------------ -# ========= | -# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox -# \\ / O peration | -# \\ / A nd | Copyright (C) 1991-2008 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 -# -# Script -# foamDiffSourceList -# -# Description -# Packs and compresses files that have changed (diff -uw) between -# oldDir newDir -# -#------------------------------------------------------------------------------ -tmpFile=${TMPDIR:-/tmp}/foamDiffList.$$ - -if [ $# -ne 3 ]; then - echo "Usage : ${0##*/} oldDir newDir tarFile" - echo "" - echo "Find the files that changed (diff -uw) between and " - echo "and pack them into " - echo "" - exit 1 -fi - -# canonical form (no double and no trailing dashes) -oldDir=$(echo "$1" | sed -e 's@//*@/@g' -e 's@/$@@') -newDir=$(echo "$2" | sed -e 's@//*@/@g' -e 's@/$@@') -packFile=$3 - -if [ ! -d $oldDir ]; then - echo "Error: directory $oldDir does not exist" - exit 1 -fi - -if [ ! -d $newDir ]; then - echo "Error: directory $newDir does not exist" - exit 1 -fi - -if [ -f $packFile ]; then - echo "Error: $packFile already exists" - exit 1 -fi - -# Clean up on termination and on Ctrl-C -trap 'rm -f $tmpFile 2>/dev/null; exit 0' EXIT TERM INT - -fileCount=0 -cat /dev/null > $tmpFile - -find -H $newDir \ - ! -type d -type f \ - ! -name "*~" \ - -a ! -name ".*~" \ - -a ! -name ".#*" \ - -a ! -name "*.orig" \ - -a ! -name "*.dep" \ - -a ! -name "*.o" \ - -a ! -name "*.so" \ - -a ! -name "*.a" \ - -a ! -name "*.tgz" \ - -a ! -name "core" \ - -a ! -name "core.[1-9]*" \ - -a ! -name "log[0-9]*" \ -| sed \ - -e "\@$newDir/.git/@d" \ - -e "\@$newDir/lib/@d" \ - -e '\@applications/bin/@d' \ - -e '\@/t/@d' \ - -e '\@Make[.A-Za-z]*/[^/]*/@d' \ - -e '\@[Dd]oxygen/html@d' \ - -e '\@[Dd]oxygen/latex@d' \ - -e '\@[Dd]oxygen/man@d' \ - -e "s@$newDir/*@@" \ - | \ - ( - while read file - do - (( fileCount=$fileCount + 1)) - - if [ -f "$oldDir/$file" ] - then - diff -uw $oldDir/$file $newDir/$file >/dev/null 2>&1 - if [ $? = 1 ] - then - echo "[DIFF]" $file - echo $newDir/$file >> $tmpFile - continue - fi - else - echo "[NEW]" $file - echo $newDir/$file >> $tmpFile - continue - fi - echo $fileCount $file - done - ) - -# file fileCount -fileCount=$(cat $tmpFile | wc -l) -echo "----------------------------------------------------------------------" -echo "pack $fileCount changed/new files" - -tar -czpf $packFile --files-from $tmpFile - -if [ $? = 0 ] -then - echo "Finished packing changed files from $newDir into $packFile" -else - echo "Error: failure packing changed files from $newDir into $packFile" - rm -f $packFile 2>/dev/null -fi -echo "----------------------------------------------------------------------" - -# ---------------------------------------------------------------------------- diff --git a/bin/foamExec b/bin/foamExec index b4ec646637..dea3c664f8 100755 --- a/bin/foamExec +++ b/bin/foamExec @@ -37,13 +37,11 @@ # foamExec -v ... -parallel # #------------------------------------------------------------------------------ -Script=${0##*/} - usage() { while [ "$#" -ge 1 ]; do echo "$1"; shift; done cat< ... +usage: ${0##*/} [OPTION] ... options: -v ver specify OpenFOAM version diff --git a/bin/foamJob b/bin/foamJob index 39d32db801..1aad5fca99 100755 --- a/bin/foamJob +++ b/bin/foamJob @@ -29,13 +29,11 @@ # Description # #------------------------------------------------------------------------------ -Script=${0##*/} - usage() { while [ "$#" -ge 1 ]; do echo "$1"; shift; done cat< ... +usage: ${0##*/} [OPTION] ... options: -case dir specify case directory @@ -108,9 +106,9 @@ do usage ;; -case) - shift - caseDir=$1 - [ "$#" -ge 1 ] || usage "'-case' option requires an argument" + [ "$#" -ge 2 ] || usage "'-case' option requires an argument" + caseDir=$2 + shift 2 cd "$caseDir" 2>/dev/null || usage "directory does not exist: '$caseDir'" ;; -s) diff --git a/bin/foamNew b/bin/foamNew index 3900c3c74c..15005c5c83 100755 --- a/bin/foamNew +++ b/bin/foamNew @@ -30,13 +30,11 @@ # Create a new standard OpenFOAM source file # #------------------------------------------------------------------------------ -Script=${0##*/} - usage() { while [ "$#" -ge 1 ]; do echo "$1"; shift; done cat< {args} +usage: ${0##*/} {args} * create a new standard OpenFOAM source file diff --git a/bin/foamPack b/bin/foamPack index 6541e10c4a..8166714c6b 100755 --- a/bin/foamPack +++ b/bin/foamPack @@ -43,7 +43,8 @@ then fi # add optional output directory -if [ -d "$1" ]; then +if [ -d "$1" ] +then packFile="$1/$packFile" fi diff --git a/bin/foamPackBin b/bin/foamPackBin index 99ceabb402..4c0d673e27 100755 --- a/bin/foamPackBin +++ b/bin/foamPackBin @@ -31,7 +31,7 @@ # #------------------------------------------------------------------------------ -if [ $# = 0 ] +if [ $# -eq 0 ] then echo "Error: architecture type expected, exiting" echo diff --git a/bin/foamPackBinAll b/bin/foamPackBinAll index 76ad4ffb81..45708b17c3 100755 --- a/bin/foamPackBinAll +++ b/bin/foamPackBinAll @@ -27,7 +27,7 @@ # foamPackBinAll [outputDir] # # Description -# Packs and compresses all binary version of foam for release +# Packs and compresses all binary versions of foam for release # #------------------------------------------------------------------------------ packDir=$WM_PROJECT-$WM_PROJECT_VERSION @@ -38,6 +38,7 @@ then exit 1 fi +# obtain arch types from lib/ for bin in $packDir/lib/* do foamPackBin ${bin##*/} $@ diff --git a/bin/foamPackChanged b/bin/foamPackChanged deleted file mode 100755 index 93fac19060..0000000000 --- a/bin/foamPackChanged +++ /dev/null @@ -1,105 +0,0 @@ -#!/bin/sh -#------------------------------------------------------------------------------ -# ========= | -# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox -# \\ / O peration | -# \\ / A nd | Copyright (C) 1991-2008 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 -# -# Script -# foamPackChanged -# -# Description -# Packs and compresses files that have a corresponding .orig file -# -#------------------------------------------------------------------------------ -tmpFile=${TMPDIR:-/tmp}/foamPackChanged.$$ - -if [ $# -ne 2 ]; then - echo "Usage : ${0##*/} directory tarFile" - echo "" - echo "Packs and compresses files that have a corresponding .orig file" - echo "" - exit 1 -fi - -# canonical form (no double and no trailing dashes) -packDir=$(echo "$1" | sed -e 's@//*@/@g' -e 's@/$@@') -packFile=$2 - -if [ ! -d $packDir ]; then - echo "Error: directory $packDir does not exist" - exit 1 -fi - -# Clean up on termination and on Ctrl-C -trap 'rm -f $tmpFile 2>/dev/null; exit 0' EXIT TERM INT - -fileCount=0 -cat /dev/null > $tmpFile - -find -H $packDir \ - ! -type d \ - -type f \ - -name "*.orig" \ -| sed \ - -e "\@$packDir/lib/@d" \ - -e '\@applications/bin/@d' \ - -e '\@/t/@d' \ - -e '\@Make[.A-Za-z]*/[^/]*/@d' \ - -e '\@[Dd]oxygen/html@d' \ - -e '\@[Dd]oxygen/latex@d' \ - -e '\@[Dd]oxygen/man@d' \ - -e "s@$packDir/*@@" \ - | \ - ( - while read file - do - (( fileCount=$fileCount + 1 )) - - file=${file%%.orig} - - if [ -f "$packDir/$file" ] - then - echo $fileCount $file - echo $packDir/$file >> $tmpFile - else - echo "[MISSING]" $file - fi - done - ) - -# file fileCount -fileCount=$(cat $tmpFile | wc -l) -echo "----------------------------------------------------------------------" -echo "pack $fileCount updated (non-.orig) files" - -tar -czpf $packFile --files-from $tmpFile - -if [ $? = 0 ] -then - echo "Finished packing changed files from $packDir into $packFile" -else - echo "Error: failure packing changed files from $packDir into $packFile" - rm -f $packFile 2>/dev/null -fi -echo "----------------------------------------------------------------------" - -# ---------------------------------------------------------------------------- diff --git a/bin/foamPackDoxygen b/bin/foamPackDoxygen new file mode 100755 index 0000000000..239c87c740 --- /dev/null +++ b/bin/foamPackDoxygen @@ -0,0 +1,121 @@ +#!/bin/sh +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright (C) 1991-2008 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 +# +# Script +# foamPackDoxygen [-prefix DIR] [-o outputDir] +# +# Description +# Packs and compresses the OpenFOAM doxygen html for release +# +#------------------------------------------------------------------------------ +packDir=$WM_PROJECT-$WM_PROJECT_VERSION +packTag=_Doxygen.gtgz + +usage() { +cat <&2 +Usage: ${0##*/} [-prefix DIR] [-o outputDir] + + Packs and compresses the OpenFOAM doxygen html for release + +USAGE + exit 1 +} + +unset prefix outputDir + +while [ "$#" -gt 0 ] +do + case $1 in + -prefix | --prefix ) + prefix=${2%%/} + shift 2 + ;; + -o | -output ) + outputDir=${2%%/} + shift 2 + ;; + -h | -help ) + usage + ;; + -*) + usage "unknown option: '$*'" + ;; + esac +done + +# if packing from within the directory, use -prefix form +if [ "${PWD##*/}" = "$packDir" ] +then + : ${prefix:=$packDir} +fi + +# pack the directories directly and add prefix afterwards +if [ -n "$prefix" ] +then + packDir="$prefix" +elif [ ! -d $packDir ] +then + echo "Error: directory $packDir does not exist" + exit 1 +fi + +# +# add optional output directory +# +if [ -d "$outputDir" ] +then + packFile="$outputDir/$packDir$packTag" +else + packFile="$packDir$packTag" +fi + + +if [ -f $packFile ] +then + echo "Error: $packFile already exists" + exit 1 +fi + +# Pack and compress the packFile using GNU tar +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +echo +echo "Packing doxygen html into $packFile" +echo + +if [ -n "$prefix" ] +then + tar czpf $packFile --transform="s@^@$prefix/@" doc/Doxygen/html +else + tar czpf $packFile $packDir/doc/Doxygen/html +fi + +if [ $? = 0 ] +then + echo "Finished packing doxygen html into file $packFile" +else + echo "Error: failure packing doxygen html file $packFile" +fi + +#------------------------------------------------------------------------------ diff --git a/bin/foamPackSource b/bin/foamPackSource index 7db55ed86b..2bdee4916d 100755 --- a/bin/foamPackSource +++ b/bin/foamPackSource @@ -33,7 +33,8 @@ #------------------------------------------------------------------------------ tmpFile=${TMPDIR:-/tmp}/foamPackFiles.$$ -if [ $# -ne 2 ]; then +if [ $# -ne 2 ] +then echo "Usage : ${0##*/} directory tarFile" echo "" echo "Packs all .C and .H files and Make/options and Make/files into" @@ -46,12 +47,14 @@ fi packDir=$(echo "$1" | sed -e 's@//*@/@g' -e 's@/$@@') packFile=$2 -if [ ! -d $packDir ]; then +if [ ! -d $packDir ] +then echo "Error: directory $packDir does not exist" exit 1 fi -if [ -f $packFile ]; then +if [ -f $packFile ] +then echo "Error: $packFile already exists" exit 1 fi diff --git a/bin/foamPackThirdPartyBin b/bin/foamPackThirdPartyBin index a229ebea9c..ad0a2a14d0 100755 --- a/bin/foamPackThirdPartyBin +++ b/bin/foamPackThirdPartyBin @@ -33,14 +33,14 @@ if [ $# = 0 ] then - echo "Error: archOptionsitecture type expected, exiting" + echo "Error: archOptions type expected, exiting" echo echo "Usage : ${0##*/} [outputDir]" echo exit 1 fi archOptions=$1 -arch=${archOptions%%G*} +arch=${archOptions%%G*} # TODO: works for Gcc only arch3264=$(echo "$arch" | sed 's@64@-64@') echo "archOptions=$archOptions" diff --git a/bin/foamUpdateCaseFileHeader b/bin/foamUpdateCaseFileHeader index dad6dfc355..6b7aa8439f 100755 --- a/bin/foamUpdateCaseFileHeader +++ b/bin/foamUpdateCaseFileHeader @@ -33,85 +33,108 @@ # Also removes consecutive blank lines from file. # #------------------------------------------------------------------------------ +foamVersion=$WM_PROJECT_VERSION -# -# FUNCTIONS -# -printUsage () { -cat < - Updates the header of application files - By default, writes current version in the header - Alternatively version can be specified with -v option - Also removes consecutive blank lines from file +usage() { + cat<" specifies the version to be written in the header --h help -EOF +usage: ${0##*/} [OPTION] ... + +options: + -v "" specifies the version to be written in the header + -h help + + Updates the header of application files. + By default, writes current version in the header. + Alternatively version can be specified with -v option. + Also removes consecutive blank lines from file. + +USAGE + exit 1 } -printOpenFOAMheader () { -cat< FoamFile - CLASS=`FoamFileAttribute class FoamFile` - OBJECT=`FoamFileAttribute object FoamFile` - FORMAT=`FoamFileAttribute format FoamFile` - printOpenFOAMheader $VERSION $FORMAT $CLASS $OBJECT > temp - sed '1,/}/d' $CASE_FILE | sed '/./,/^$/!d' >> temp - mv temp $1 - rm FoamFile -else - echo "The following file does not appear to be a case file:" - echo " " $CASE_FILE -fi +for caseFile +do + if grep FoamFile $caseFile >/dev/null 2>&1 + then + echo "Updating case file: $caseFile" + sed -n '/FoamFile/,/}/p' $caseFile > FoamFile + CLASS=`FoamFileAttribute class FoamFile` + OBJECT=`FoamFileAttribute object FoamFile` + FORMAT=`FoamFileAttribute format FoamFile` + + printHeader $FORMAT $CLASS $OBJECT $NOTE > FoamFile.tmp + sed '1,/}/d' $caseFile | sed '/./,/^$/!d' >> FoamFile.tmp + + mv FoamFile.tmp $caseFile + rm FoamFile + else + echo " Invalid case file: $caseFile" + fi +done #------------------------------------------------------------------------------ diff --git a/bin/foamUpgradeTurbulenceProperties b/bin/foamUpgradeTurbulenceProperties index 1f10d8551a..8c1437aca6 100755 --- a/bin/foamUpgradeTurbulenceProperties +++ b/bin/foamUpgradeTurbulenceProperties @@ -30,59 +30,64 @@ # Upgrade the turbulenceProperties dictionary to the new format employed # in OpenFOAM version 1.5 # - RAS turbulence models now defined by the RASProperties dictionary, -# and RASModel keyword, and +# and RASModel keyword. # - LES turbulence models now defined by the LESProperties dictionary, # and LESModel keyword. # #------------------------------------------------------------------------------ -printUsage() -{ - echo "Usage: `basename $0` " - echo " Where is the full path to the" - echo " turbulenceProperties dictionary" +usage() { + cat< + + Where is the full path to the + turbulenceProperties dictionary + + Note: can upgrade several files at once + +USAGE + exit 1 } +# +# $1: turbulence model +# $2: new properties type +# $3: original dictionary +# convertDict() { - echo " Identified $1 turbulence model" + echo "Identified $1 turbulence model in '$3'" + outputPath=`dirname $3` sed -e "s/turbulenceProperties/$1Properties/" \ -e "s/$2/$1Model/" \ -e "s/[a-zA-Z0-9]* [ ]*\[[0-9 ]*\]//" \ $3 > "$outputPath/$1Properties" - echo " written $1Properties to $outputPath/" + echo " wrote $outputPath/$1Properties" } -outputPath=`dirname $1` - -if [ $# -ne 1 ]; then - printUsage - exit 1 -elif [ ! -e $1 ]; then - echo " Error: file $1 does not exist" - echo "" - printUsage - exit 1 -fi - -# Identify type of turbulence model -RAS=`grep turbulenceModel $1` -LES=`grep LESmodel $1` - -if [ -n "$RAS" ]; then - convertDict "RAS" "turbulenceModel" $1 -elif [ -n "$LES" ]; then - convertDict "LES" "LESmodel" $1 -else - echo "Unable to determine turbulence model type - nothing changed" - exit 1 -fi - -echo "done." - -exit 0 +[ $# -ge 1 ] || usage +for turbDict +do + # Identify type of turbulence model and convert + if [ -f $turbDict ] + then + if grep turbulenceModel $turbDict >/dev/null 2>&1 + then + convertDict RAS turbulenceModel $turbDict + elif grep LESmodel $turbDict >/dev/null 2>&1 + then + convertDict LES LESmodel $turbDict + else + echo "Unable to determine turbulence model type in '$turbDict'" + echo " - nothing changed" + fi + else + echo "Error: file '$turbDict' does not exist" + fi +done #------------------------------------------------------------------------------ diff --git a/bin/paraFoam b/bin/paraFoam index 93fb4cf03b..217596343a 100755 --- a/bin/paraFoam +++ b/bin/paraFoam @@ -30,13 +30,11 @@ # start paraview with the OpenFOAM libraries # #------------------------------------------------------------------------------ -Script=${0##*/} - usage() { while [ "$#" -ge 1 ]; do echo "$1"; shift; done cat</dev/null || usage "directory does not exist: '$caseDir'" ;; *) usage "unknown option/argument: '$*'" ;; esac -fi +done # get a sensible caseName caseName=${PWD##*/} +caseFile="$caseName.OpenFOAM" # parent directory for normal or parallel results case "$caseName" in @@ -77,8 +77,6 @@ do [ -s "$parentDir/$check" ] || usage "file does not exist: '$parentDir/$check'" done -#caseFile="$caseName.foam" -caseFile="$caseName.OpenFOAM" case "$ParaView_VERSION" in 2*) diff --git a/bin/rmcore b/bin/rmcore index 6014adc414..1245878ff3 100755 --- a/bin/rmcore +++ b/bin/rmcore @@ -1,3 +1,3 @@ #!/bin/sh -#find . \( -name 'core' \) -exec ls -l {} \; -exec rm {} \; +# find . \( -name 'core' \) -exec ls -l {} \; -exec rm {} \; find . \( -type f -name 'core' -o -name 'core.[1-9]*' -o -name 'vgcore.*' \) -print | xargs -t rm diff --git a/bin/rmdepall b/bin/rmdepall index 89e6e4c566..84e6526741 100755 --- a/bin/rmdepall +++ b/bin/rmdepall @@ -1,12 +1,15 @@ #!/bin/sh -if [ $# -eq 0 ]; then - find . \( -name '*.dep' \) -print | xargs -t rm -elif [ $# -eq 1 ]; then - echo "Removing all dep files containing $1..." - find . -name '*.dep' -exec grep "$1" '{}' \; -exec rm '{}' \; +if [ $# -eq 0 ] +then + find . \( -name '*.dep' \) -print | xargs -t rm +elif [ $# -eq 1 ] +then + echo "Removing all dep files containing $1..." + find . -name '*.dep' -exec grep "$1" '{}' \; -exec rm '{}' \; else - echo "Usage: `basename $0` to remove all .dep files" - echo " `basename $0` to remove all .dep files referring to " - exit 1 + echo "Usage: ${0##/} to remove all .dep files" + echo " ${0##/} to remove all .dep files referring to " + exit 1 fi + diff --git a/bin/rm~all b/bin/rm~all index 73ea1d5569..6ee2bad370 100755 --- a/bin/rm~all +++ b/bin/rm~all @@ -1,3 +1,3 @@ #!/bin/sh -#find . \( -name '*~' -o -name '.*~' \) -exec ls -l {} \; -exec rm {} \; +# find . \( -name '*~' -o -name '.*~' \) -exec ls -l {} \; -exec rm {} \; find . \( -name '*~' -o -name '.*~' \) -print | xargs -t rm diff --git a/src/OpenFOAM/db/IOobject/IOobjectReadHeader.C b/src/OpenFOAM/db/IOobject/IOobjectReadHeader.C index 3564ae9ab1..966ef84136 100644 --- a/src/OpenFOAM/db/IOobject/IOobjectReadHeader.C +++ b/src/OpenFOAM/db/IOobject/IOobjectReadHeader.C @@ -83,10 +83,7 @@ bool Foam::IOobject::readHeader(Istream& is) } // The note entry is optional - if (headerDict.found("note")) - { - note_ = string(headerDict.lookup("note")); - } + headerDict.readIfPresent("note", note_); } else { diff --git a/src/OpenFOAM/db/IOobject/IOobjectWriteHeader.C b/src/OpenFOAM/db/IOobject/IOobjectWriteHeader.C index cbf7800606..20030c2ea5 100644 --- a/src/OpenFOAM/db/IOobject/IOobjectWriteHeader.C +++ b/src/OpenFOAM/db/IOobject/IOobjectWriteHeader.C @@ -49,7 +49,6 @@ bool Foam::IOobject::writeHeader(Ostream& os) const << " format " << os.format() << ";\n" << " class " << type() << ";\n"; - // outdent for visibility and more space if (note().size()) { os << " note " << note() << ";\n"; diff --git a/src/OpenFOAM/db/IOstreams/Fstreams/zfIFstream.C b/src/OpenFOAM/db/IOstreams/Fstreams/zfIFstream.C deleted file mode 100644 index da862fdf99..0000000000 --- a/src/OpenFOAM/db/IOstreams/Fstreams/zfIFstream.C +++ /dev/null @@ -1,179 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | - \\ / A nd | Copyright (C) 1991-2008 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 "IFstream.H" -#include "OSspecific.H" -#include "zfstream.H" - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - -// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // - -defineTypeNameAndDebug(IFstream, 0); - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -IFstreamAllocator::IFstreamAllocator(const fileName& pathname) -: - ifPtr_(NULL), - compression_(IOstream::UNCOMPRESSED) -{ - if (!pathname.size()) - { - if (IFstream::debug) - { - Info<< "IFstreamAllocator::IFstreamAllocator" - "(const fileName& pathname) : " - "can't open null file " - << endl; - } - } - - ifPtr_ = new ifstream(pathname.c_str()); - - // If the file is compressed, decompress it before reading. - if (!ifPtr_->good() && file(pathname + ".gz")) - { - if (IFstream::debug) - { - Info<< "IFstreamAllocator::IFstreamAllocator" - "(const fileName& pathname) : " - "decompressing " << pathname + ".gz" - << endl; - } - - delete ifPtr_; - - ifPtr_ = new gzifstream((pathname + ".gz").c_str()); - - if (ifPtr_->good()) - { - compression_ = IOstream::COMPRESSED; - } - } -} - - -IFstreamAllocator::~IFstreamAllocator() -{ - delete ifPtr_; -} - - -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - -IFstream::IFstream -( - const fileName& pathname, - streamFormat format, - versionNumber version -) -: - IFstreamAllocator(pathname), - ISstream - ( - *ifPtr_, - "IFstream.sourceFile_", - format, - version, - IFstreamAllocator::compression_ - ), - pathname_(pathname) -{ - setClosed(); - - setState(ifPtr_->rdstate()); - - if (!good()) - { - if (debug) - { - Info<< "IFstream::IFstream(const fileName& pathname," - "streamFormat format=ASCII," - "versionNumber version=currentVersion) : " - "couldn't open File for input" - << endl << info() << endl; - } - - setBad(); - } - else - { - setOpened(); - } - - lineNumber_ = 1; -} - - -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - -IFstream::~IFstream() -{} - - -// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // - -void IFstream::print(Ostream& os) const -{ - // Print File data - os << "IFstream: "; - ISstream::print(os); -} - - -//- Return a non-const reference to const Istream -// Needed for read-constructors where the stream argument is temporary: -// e.g. thing thisThing(IFstream("thingFileName")()); -IFstream& IFstream::operator()() const -{ - if (!good()) - { - if (!file(pathname_) && !file(pathname_ + ".gz")) - { - FatalIOErrorIn("IFstream::operator()", *this) - << "file " << pathname_ << " does not exist" - << exit(FatalIOError); - } - else - { - check("IFstream::operator()"); - FatalIOError.exit(); - } - } - - return const_cast(*this); -} - - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - -// ************************************************************************* // diff --git a/src/OpenFOAM/db/IOstreams/Fstreams/zfOFstream.C b/src/OpenFOAM/db/IOstreams/Fstreams/zfOFstream.C deleted file mode 100644 index e2cc170627..0000000000 --- a/src/OpenFOAM/db/IOstreams/Fstreams/zfOFstream.C +++ /dev/null @@ -1,151 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | - \\ / A nd | Copyright (C) 1991-2008 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 "OFstream.H" -#include "OSspecific.H" -#include "zfstream.H" - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - -// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // - -defineTypeNameAndDebug(OFstream, 0); - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -OFstreamAllocator::OFstreamAllocator -( - const fileName& pathname, - IOstream::compressionType compression -) -: - ofPtr_(NULL) -{ - if (!pathname.size()) - { - if (OFstream::debug) - { - Info - << "OFstreamAllocator::OFstreamAllocator" - "(const fileName& pathname) : " - "can't open null file " - << endl; - } - } - - if (compression == IOstream::COMPRESSED) - { - if (file(pathname)) - { - rm(pathname); - } - - gzofstream* gzofPtr = new gzofstream((pathname + ".gz").c_str()); - gzofPtr->buffer_.setcompressionlevel(Z_BEST_SPEED); - ofPtr_ = gzofPtr; - } - else - { - if (file(pathname + ".gz")) - { - rm(pathname + ".gz"); - } - - ofPtr_ = new ofstream(pathname.c_str()); - } -} - - -OFstreamAllocator::~OFstreamAllocator() -{ - delete ofPtr_; -} - - -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - -OFstream::OFstream -( - const fileName& pathname, - streamFormat format, - versionNumber version, - compressionType compression -) -: - OFstreamAllocator(pathname, compression), - OSstream(*ofPtr_, "OFstream.sinkFile_", format, version, compression), - pathname_(pathname) -{ - setClosed(); - - setState(ofPtr_->rdstate()); - - if (!good()) - { - if (debug) - { - Info<< "IFstream::IFstream(const fileName& pathname," - "streamFormat format=ASCII," - "versionNumber version=currentVersion) : " - "couldn't open File for input\n" - "in stream " << info() << Foam::endl; - } - - setBad(); - } - else - { - setOpened(); - } - - lineNumber_ = 1; -} - - -// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * * // - -OFstream::~OFstream() -{} - - -// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // - -void OFstream::print(Ostream& os) const -{ - // Print File data - os << " OFstream: "; - OSstream::print(os); -} - - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - -// ************************************************************************* // diff --git a/src/OpenFOAM/db/Time/Time.C b/src/OpenFOAM/db/Time/Time.C index f0948b77de..dd1e944067 100644 --- a/src/OpenFOAM/db/Time/Time.C +++ b/src/OpenFOAM/db/Time/Time.C @@ -101,14 +101,12 @@ void Foam::Time::setControls() { // default is to resume calculation from "latestTime" word startFrom("latestTime"); - if (controlDict_.found("startFrom")) - { - controlDict_.lookup("startFrom") >> startFrom; - } + + controlDict_.readIfPresent("startFrom", startFrom); if (startFrom == "startTime") { - startTime_ = readScalar(controlDict_.lookup("startTime")); + controlDict_.lookup("startTime") >> startTime_; } else { @@ -158,7 +156,7 @@ void Foam::Time::setControls() FatalErrorIn("Time::setControls()") << "Start time is not the same for all processors" << nl << "processor " << Pstream::myProcNo() << " has startTime " - << startTime_ << exit(FatalError); + << startTime_ << exit(FatalError); } } @@ -176,15 +174,13 @@ void Foam::Time::setControls() ) ); - if (timeDict.found("deltaT")) + if (timeDict.readIfPresent("deltaT", deltaTSave_)) { - deltaTSave_ = readScalar(timeDict.lookup("deltaT")); deltaT0_ = deltaTSave_; } - if (timeDict.found("index")) + if (timeDict.readIfPresent("index", startTimeIndex_)) { - timeDict.lookup("index") >> startTimeIndex_; timeIndex_ = startTimeIndex_; } } @@ -503,20 +499,9 @@ void Foam::Time::setTime(const instant& inst, const label newIndex) ) ); - if (timeDict.found("deltaT")) - { - deltaT_ = readScalar(timeDict.lookup("deltaT")); - } - - if (timeDict.found("deltaT0")) - { - deltaT0_ = readScalar(timeDict.lookup("deltaT0")); - } - - if (timeDict.found("index")) - { - timeIndex_ = readLabel(timeDict.lookup("index")); - } + timeDict.readIfPresent("deltaT", deltaT_); + timeDict.readIfPresent("deltaT0", deltaT0_); + timeDict.readIfPresent("index", timeIndex_); } @@ -647,7 +632,7 @@ Foam::Time& Foam::Time::operator++() case wcRunTime: case wcAdjustableRunTime: { - label outputTimeIndex = + label outputTimeIndex = label(((value() - startTime_) + 0.5*deltaT_)/writeInterval_); if (outputTimeIndex > outputTimeIndex_) diff --git a/src/OpenFOAM/db/Time/TimeIO.C b/src/OpenFOAM/db/Time/TimeIO.C index 45eaefed64..fc3ad8857c 100644 --- a/src/OpenFOAM/db/Time/TimeIO.C +++ b/src/OpenFOAM/db/Time/TimeIO.C @@ -44,10 +44,8 @@ void Foam::Time::readDict() ); } - if (controlDict_.found("writeInterval")) + if (controlDict_.readIfPresent("writeInterval", writeInterval_)) { - controlDict_.lookup("writeInterval") >> writeInterval_; - if (writeControl_ == wcTimeStep && label(writeInterval_) < 1) { FatalIOErrorIn("Time::readDict()", controlDict_) @@ -60,10 +58,8 @@ void Foam::Time::readDict() controlDict_.lookup("writeFrequency") >> writeInterval_; } - if (controlDict_.found("purgeWrite")) + if (controlDict_.readIfPresent("purgeWrite", purgeWrite_)) { - purgeWrite_ = readInt(controlDict_.lookup("purgeWrite")); - if (purgeWrite_ < 0) { WarningIn("Time::readDict()") @@ -106,10 +102,7 @@ void Foam::Time::readDict() } } - if (controlDict_.found("timePrecision")) - { - precision_ = readLabel(controlDict_.lookup("timePrecision")); - } + controlDict_.readIfPresent("timePrecision", precision_); // stopAt at 'endTime' or a specified value // if nothing is specified, the endTime is zero @@ -119,18 +112,14 @@ void Foam::Time::readDict() if (stopAt_ == saEndTime) { - endTime_ = readScalar(controlDict_.lookup("endTime")); + controlDict_.lookup("endTime") >> endTime_; } else { endTime_ = GREAT; } } - else if (controlDict_.found("endTime")) - { - endTime_ = readScalar(controlDict_.lookup("endTime")); - } - else + else if (!controlDict_.readIfPresent("endTime", endTime_)) { endTime_ = 0; } @@ -175,10 +164,7 @@ void Foam::Time::readDict() ); } - if (controlDict_.found("graphFormat")) - { - graphFormat_ = word(controlDict_.lookup("graphFormat")); - } + controlDict_.readIfPresent("graphFormat", graphFormat_); if (controlDict_.found("runTimeModifiable")) { diff --git a/src/OpenFOAM/db/functionObject/functionObject.H b/src/OpenFOAM/db/functionObject/functionObject.H index d729c1c8cb..4761636613 100644 --- a/src/OpenFOAM/db/functionObject/functionObject.H +++ b/src/OpenFOAM/db/functionObject/functionObject.H @@ -28,6 +28,9 @@ Class Description Abstract base-class for Time/database function objects. +See Also + Foam::OutputFilterFunctionObject + SourceFiles functionObject.C diff --git a/src/OpenFOAM/db/functionObjectList/functionObjectList.H b/src/OpenFOAM/db/functionObjectList/functionObjectList.H index 752c6d8a0d..bd71c1578c 100644 --- a/src/OpenFOAM/db/functionObjectList/functionObjectList.H +++ b/src/OpenFOAM/db/functionObjectList/functionObjectList.H @@ -29,6 +29,9 @@ Description List of function objects with execute function which is called for each object. +See Also + Foam::functionObject and Foam::OutputFilterFunctionObject + SourceFiles functionObjectList.C diff --git a/src/OpenFOAM/db/memberFunctionSelection/addToMemberFunctionSelectionTable.H b/src/OpenFOAM/db/memberFunctionSelection/addToMemberFunctionSelectionTable.H index 5d6b78db47..7bfd089dc3 100644 --- a/src/OpenFOAM/db/memberFunctionSelection/addToMemberFunctionSelectionTable.H +++ b/src/OpenFOAM/db/memberFunctionSelection/addToMemberFunctionSelectionTable.H @@ -26,7 +26,7 @@ InClass Foam::memberFunctionSelectionTables Description - Macros to enable the easy insertion into member function selection tables. + Macros for easy insertion into member function selection tables \*---------------------------------------------------------------------------*/ @@ -47,14 +47,13 @@ Description \ /* Add the thisType constructor function to the table */ \ baseType::add##memberFunction##argNames##MemberFunctionToTable \ - add##thisType##memberFunction##argNames##MemberFunctionTo##baseType##Table_(#lookup) + add_##lookup##_##thisType##memberFunction##argNames##MemberFunctionTo##baseType##Table_(#lookup) #define addTemplateToMemberFunctionSelectionTable\ (baseType,thisType,Targ,memberFunction,argNames) \ \ /* Add the thisType constructor function to the table */ \ - baseType::add##memberFunction##argNames##MemberFunctionToTable \ - > \ + baseType::add##memberFunction##argNames##MemberFunctionToTable > \ add##thisType##Targ##memberFunction##argNames##MemberFunctionTo##baseType##Table_ diff --git a/src/OpenFOAM/db/runTimeSelection/addToRunTimeSelectionTable.H b/src/OpenFOAM/db/runTimeSelection/addToRunTimeSelectionTable.H index b3bbf50cb7..3a1d74e28a 100644 --- a/src/OpenFOAM/db/runTimeSelection/addToRunTimeSelectionTable.H +++ b/src/OpenFOAM/db/runTimeSelection/addToRunTimeSelectionTable.H @@ -26,7 +26,7 @@ InClass Foam::runTimeSelectionTables Description - Macros to enable the easy insertion into run-time selection tables. + Macros for easy insertion into run-time selection tables \*---------------------------------------------------------------------------*/ @@ -45,7 +45,7 @@ Description \ /* Add the thisType constructor function to the table */ \ baseType::add##argNames##ConstructorToTable \ - add##thisType##argNames##ConstructorTo##baseType##Table_(#lookup) + add_##lookup##_##thisType##argNames##ConstructorTo##baseType##Table_(#lookup) #define addTemplateToRunTimeSelectionTable(baseType,thisType,Targ,argNames) \ \ diff --git a/src/OpenFOAM/fields/FieldFields/FieldField/FieldField.H b/src/OpenFOAM/fields/FieldFields/FieldField/FieldField.H index 20b41f17b8..958e2f259b 100644 --- a/src/OpenFOAM/fields/FieldFields/FieldField/FieldField.H +++ b/src/OpenFOAM/fields/FieldFields/FieldField/FieldField.H @@ -23,7 +23,7 @@ License Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Class - Foam::FieldField\ + Foam::FieldField Description Generic field type. @@ -134,7 +134,7 @@ public: ); forAll(*nffPtr, i) - { + { nffPtr->set(i, Field::NewCalculatedType(ff[i]).ptr()); } diff --git a/src/OpenFOAM/global/argList/argList.C b/src/OpenFOAM/global/argList/argList.C index 59ee6e57b5..d8b90d013b 100644 --- a/src/OpenFOAM/global/argList/argList.C +++ b/src/OpenFOAM/global/argList/argList.C @@ -168,7 +168,6 @@ Foam::argList::argList { // Check if this run is a parallel run by searching for any parallel option // If found call runPar (might filter argv) - for (int argi=0; argi args_ and capture ( ... ) lists // for normal arguments and for options regroupArgv(argc, argv); @@ -291,8 +284,10 @@ Foam::argList::argList string dateString = clock::date(); string timeString = clock::clockTime(); + // Print the banner once only for parallel runs if (Pstream::master()) { + IOobject::writeBanner(Info, true); Info<< "Exec : " << argListString.c_str() << nl << "Date : " << dateString.c_str() << nl << "Time : " << timeString.c_str() << nl @@ -609,9 +604,9 @@ void Foam::argList::printUsage() const Info<< ']'; } - // place help/doc options of the way at the end, + // place help/doc/srcDoc options of the way at the end, // but with an extra space to separate it a little - Info<< " [-help] [-doc] [-srcDoc]" << endl; + Info<< " [-help] [-doc] [-srcDoc]\n" << endl; } @@ -663,7 +658,9 @@ void Foam::argList::displayDoc(bool source) const } else { - Info<< "No documentation found" << endl; + Info<< nl + << "No documentation found for " << executable_ + << ", but you can use -help to display the usage\n" << endl; } } diff --git a/src/OpenFOAM/include/addRegionOption.H b/src/OpenFOAM/include/addRegionOption.H index a67d1e0fbd..382836d329 100644 --- a/src/OpenFOAM/include/addRegionOption.H +++ b/src/OpenFOAM/include/addRegionOption.H @@ -1 +1 @@ - argList::validOptions.insert("region", "region name"); + argList::validOptions.insert("region", "name"); diff --git a/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrix.H b/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrix.H index 2d89ac4e79..33fcda639d 100644 --- a/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrix.H +++ b/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrix.H @@ -87,8 +87,7 @@ class lduMatrix public: - //- Class returned by the solver - // containing performance statistics + //- Class returned by the solver, containing performance statistics class solverPerformance { word solverName_; @@ -237,16 +236,6 @@ public: // Protected Member Functions - //- Read a control parameter from controlDict - template - inline void readControl - ( - const dictionary& controlDict, - T& control, - const word& controlName - ); - - //- Read the control parameters from the controlDict_ virtual void readControls(); @@ -318,7 +307,6 @@ public: Istream& solverData ); - // Selectors //- Return a new solver @@ -333,6 +321,7 @@ public: ); + // Destructor virtual ~solver() @@ -749,7 +738,7 @@ public: const lduInterfaceFieldPtrsList&, const direction cmpt ) const; - + //- Matrix transpose multiplication with updated interfaces. void Tmul ( @@ -800,7 +789,7 @@ public: scalarField& result, const direction cmpt ) const; - + //- Update interfaced interfaces for matrix operations void updateMatrixInterfaces ( @@ -810,7 +799,7 @@ public: scalarField& result, const direction cmpt ) const; - + template tmp > H(const Field&) const; diff --git a/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixSolver.C b/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixSolver.C index 4db27fde04..19fd2435a0 100644 --- a/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixSolver.C +++ b/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixSolver.C @@ -171,9 +171,9 @@ Foam::lduMatrix::solver::solver void Foam::lduMatrix::solver::readControls() { - readControl(controlDict_, maxIter_, "maxIter"); - readControl(controlDict_, tolerance_, "tolerance"); - readControl(controlDict_, relTol_, "relTol"); + controlDict_.readIfPresent("maxIter", maxIter_); + controlDict_.readIfPresent("tolerance", tolerance_); + controlDict_.readIfPresent("relTol", relTol_); } diff --git a/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixTemplates.C b/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixTemplates.C index 50767e741e..6209d81c86 100644 --- a/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixTemplates.C +++ b/src/OpenFOAM/matrices/lduMatrix/lduMatrix/lduMatrixTemplates.C @@ -31,21 +31,6 @@ Description // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -template -inline void Foam::lduMatrix::solver::readControl -( - const dictionary& controlDict, - T& control, - const word& controlName -) -{ - if (controlDict.found(controlName)) - { - controlDict.lookup(controlName) >> control; - } -} - - template Foam::tmp > Foam::lduMatrix::H(const Field& psi) const { diff --git a/src/OpenFOAM/matrices/lduMatrix/preconditioners/GAMGPreconditioner/GAMGPreconditioner.C b/src/OpenFOAM/matrices/lduMatrix/preconditioners/GAMGPreconditioner/GAMGPreconditioner.C index 2042ac6ac3..cfd2f4513e 100644 --- a/src/OpenFOAM/matrices/lduMatrix/preconditioners/GAMGPreconditioner/GAMGPreconditioner.C +++ b/src/OpenFOAM/matrices/lduMatrix/preconditioners/GAMGPreconditioner/GAMGPreconditioner.C @@ -75,7 +75,7 @@ Foam::GAMGPreconditioner::~GAMGPreconditioner() void Foam::GAMGPreconditioner::readControls() { GAMGSolver::readControls(); - readControl(controlDict_, nVcycles_, "nVcycles"); + controlDict_.readIfPresent("nVcycles", nVcycles_); } diff --git a/src/OpenFOAM/matrices/lduMatrix/solvers/GAMG/GAMGSolver.C b/src/OpenFOAM/matrices/lduMatrix/solvers/GAMG/GAMGSolver.C index fa13572601..f8a29ba241 100644 --- a/src/OpenFOAM/matrices/lduMatrix/solvers/GAMG/GAMGSolver.C +++ b/src/OpenFOAM/matrices/lduMatrix/solvers/GAMG/GAMGSolver.C @@ -154,13 +154,12 @@ void Foam::GAMGSolver::readControls() { lduMatrix::solver::readControls(); - readControl(controlDict_, cacheAgglomeration_, "cacheAgglomeration"); - - readControl(controlDict_, nPreSweeps_, "nPreSweeps"); - readControl(controlDict_, nPostSweeps_, "nPostSweeps"); - readControl(controlDict_, nFinestSweeps_, "nFinestSweeps"); - readControl(controlDict_, scaleCorrection_, "scaleCorrection"); - readControl(controlDict_, directSolveCoarsest_, "directSolveCoarsest"); + controlDict_.readIfPresent("cacheAgglomeration", cacheAgglomeration_); + controlDict_.readIfPresent("nPreSweeps", nPreSweeps_); + controlDict_.readIfPresent("nPostSweeps", nPostSweeps_); + controlDict_.readIfPresent("nFinestSweeps", nFinestSweeps_); + controlDict_.readIfPresent("scaleCorrection", scaleCorrection_); + controlDict_.readIfPresent("directSolveCoarsest", directSolveCoarsest_); } diff --git a/src/OpenFOAM/matrices/lduMatrix/solvers/smoothSolver/smoothSolver.C b/src/OpenFOAM/matrices/lduMatrix/solvers/smoothSolver/smoothSolver.C index c07a626ec3..6b7c1cbcc3 100644 --- a/src/OpenFOAM/matrices/lduMatrix/solvers/smoothSolver/smoothSolver.C +++ b/src/OpenFOAM/matrices/lduMatrix/solvers/smoothSolver/smoothSolver.C @@ -72,7 +72,7 @@ Foam::smoothSolver::smoothSolver void Foam::smoothSolver::readControls() { lduMatrix::solver::readControls(); - readControl(controlDict_, nSweeps_, "nSweeps"); + controlDict_.readIfPresent("nSweeps", nSweeps_); } diff --git a/src/OpenFOAM/matrices/solution/solution.H b/src/OpenFOAM/matrices/solution/solution.H index 7b295cc18a..3d455fdecc 100644 --- a/src/OpenFOAM/matrices/solution/solution.H +++ b/src/OpenFOAM/matrices/solution/solution.H @@ -97,7 +97,7 @@ public: const dictionary& solverDict(const word& name) const; //- Return the stream of solver parameters for the given field - // (Provided for backward compatibility only) + // @deprecated Backward compatibility only - should use solverDict ITstream& solver(const word& name) const; diff --git a/src/OpenFOAM/meshes/patchIdentifier/patchIdentifier.C b/src/OpenFOAM/meshes/patchIdentifier/patchIdentifier.C index bdbde0c06f..c0d90270df 100644 --- a/src/OpenFOAM/meshes/patchIdentifier/patchIdentifier.C +++ b/src/OpenFOAM/meshes/patchIdentifier/patchIdentifier.C @@ -52,10 +52,7 @@ Foam::patchIdentifier::patchIdentifier name_(name), boundaryIndex_(index) { - if (dict.found("physicalType")) - { - dict.lookup("physicalType") >> physicalType_; - } + dict.readIfPresent("physicalType", physicalType_); } diff --git a/src/OpenFOAM/meshes/polyMesh/polyPatches/basic/generic/genericPolyPatch.H b/src/OpenFOAM/meshes/polyMesh/polyPatches/basic/generic/genericPolyPatch.H index a5a0614b99..6ab6354a08 100644 --- a/src/OpenFOAM/meshes/polyMesh/polyPatches/basic/generic/genericPolyPatch.H +++ b/src/OpenFOAM/meshes/polyMesh/polyPatches/basic/generic/genericPolyPatch.H @@ -23,14 +23,15 @@ License Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Class - Foam::genericPolyPatch.C + Foam::genericPolyPatch Description Determines a mapping between patch face centres and mesh cell centres and processors they're on. - Note: storage is not optimal. It stores all face centres and cells on - all processors to keep the addressing calculation simple. +Note + Storage is not optimal. It stores all face centres and cells on all + processors to keep the addressing calculation simple. SourceFiles genericPolyPatch.C diff --git a/src/OpenFOAM/meshes/polyMesh/polyPatches/constraint/cyclic/cyclicPolyPatch.C b/src/OpenFOAM/meshes/polyMesh/polyPatches/constraint/cyclic/cyclicPolyPatch.C index b1cd7a02f6..31faea5669 100644 --- a/src/OpenFOAM/meshes/polyMesh/polyPatches/constraint/cyclic/cyclicPolyPatch.C +++ b/src/OpenFOAM/meshes/polyMesh/polyPatches/constraint/cyclic/cyclicPolyPatch.C @@ -637,10 +637,8 @@ Foam::cyclicPolyPatch::cyclicPolyPatch rotationAxis_(vector::zero), rotationCentre_(point::zero) { - if (dict.found("featureCos")) - { - dict.lookup("featureCos") >> featureCos_; - } + dict.readIfPresent("featureCos", featureCos_); + if (dict.found("transform")) { transform_ = transformTypeNames.read(dict.lookup("transform")); diff --git a/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/newPolyPatch.C b/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/newPolyPatch.C index 67a3e2886b..fde52b3e75 100644 --- a/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/newPolyPatch.C +++ b/src/OpenFOAM/meshes/polyMesh/polyPatches/polyPatch/newPolyPatch.C @@ -27,14 +27,9 @@ License #include "polyPatch.H" #include "dictionary.H" -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ - // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // -autoPtr polyPatch::New +Foam::autoPtr Foam::polyPatch::New ( const word& patchType, const word& name, @@ -72,7 +67,7 @@ autoPtr polyPatch::New } -autoPtr polyPatch::New +Foam::autoPtr Foam::polyPatch::New ( const word& name, const dictionary& dict, @@ -89,10 +84,7 @@ autoPtr polyPatch::New word patchType(dict.lookup("type")); - if (dict.found("geometricType")) - { - dict.lookup("geometricType") >> patchType; - } + dict.readIfPresent("geometricType", patchType); dictionaryConstructorTable::iterator cstrIter = dictionaryConstructorTablePtr_->find(patchType); @@ -124,8 +116,4 @@ autoPtr polyPatch::New } -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - // ************************************************************************* // diff --git a/src/OpenFOAM/meshes/preservePatchTypes/preservePatchTypes.C b/src/OpenFOAM/meshes/preservePatchTypes/preservePatchTypes.C index 2f46854f6f..7c6aecf8f4 100644 --- a/src/OpenFOAM/meshes/preservePatchTypes/preservePatchTypes.C +++ b/src/OpenFOAM/meshes/preservePatchTypes/preservePatchTypes.C @@ -77,19 +77,14 @@ void Foam::preservePatchTypes const dictionary& patchDict = patchDictionary.subDict(patchNames[patchi]); - patchTypes[patchi] = word(patchDict.lookup("type")); + patchDict.lookup("type") >> patchTypes[patchi]; - if (patchDict.found("geometricType")) - { - patchTypes[patchi] = - word(patchDict.lookup("geometricType")); - } - - if (patchDict.found("physicalType")) - { - patchPhysicalTypes[patchi] = - word(patchDict.lookup("physicalType")); - } + patchDict.readIfPresent("geometricType", patchTypes[patchi]); + patchDict.readIfPresent + ( + "physicalType", + patchPhysicalTypes[patchi] + ); } } @@ -98,10 +93,7 @@ void Foam::preservePatchTypes const dictionary& patchDict = patchDictionary.subDict(defaultFacesName); - if (patchDict.found("geometricType")) - { - defaultFacesType = word(patchDict.lookup("geometricType")); - } + patchDict.readIfPresent("geometricType", defaultFacesType); } } diff --git a/src/OpenFOAM/primitives/Scalar/doubleFloat.H b/src/OpenFOAM/primitives/Scalar/doubleFloat.H index 58e8f65002..40ccb27279 100644 --- a/src/OpenFOAM/primitives/Scalar/doubleFloat.H +++ b/src/OpenFOAM/primitives/Scalar/doubleFloat.H @@ -22,9 +22,6 @@ License along with OpenFOAM; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -Typedef - Foam::double and float - \*---------------------------------------------------------------------------*/ #ifndef doubleFloat_H diff --git a/src/OpenFOAM/primitives/strings/fileName/fileName.H b/src/OpenFOAM/primitives/strings/fileName/fileName.H index 71cdfbdb46..1ef3839ea5 100644 --- a/src/OpenFOAM/primitives/strings/fileName/fileName.H +++ b/src/OpenFOAM/primitives/strings/fileName/fileName.H @@ -147,7 +147,7 @@ public: wordList components(const char delimiter='/') const; //- Return a component of the path - word component(const size_t, const char delimiter='/') const; + word component(const size_type, const char delimiter='/') const; // Interogation diff --git a/src/autoMesh/Make/options b/src/autoMesh/Make/options index bf2ad0c4d0..4589b7ac3f 100644 --- a/src/autoMesh/Make/options +++ b/src/autoMesh/Make/options @@ -1,11 +1,8 @@ -/* include /home/pinky2/mattijs/pub/Delaunay/CGAL-3.1/make/makefile_i686_Linux-2.6.4-52-default_g++-3.4.3 */ - EXE_INC = \ - /* -g -DFULLDEBUG -O0 $(CGAL_CXXFLAGS) */ \ -I$(LIB_SRC)/decompositionAgglomeration/decompositionMethods/lnInclude \ -I$(LIB_SRC)/dynamicMesh/lnInclude \ -I$(LIB_SRC)/finiteVolume/lnInclude \ - -I$(FOAM_SRC)/lagrangian/basic/lnInclude \ + -I$(LIB_SRC)/lagrangian/basic/lnInclude \ -I$(LIB_SRC)/meshTools/lnInclude \ -I$(LIB_SRC)/edgeMesh/lnInclude \ -I$(LIB_SRC)/triSurface/lnInclude @@ -17,5 +14,4 @@ LIB_LIBS = \ -llagrangian \ -lmeshTools \ -ledgeMesh \ - -ltriSurface \ - /* $(CGAL_LDFLAGS) */ + -ltriSurface diff --git a/src/autoMesh/autoHexMesh/autoHexMeshDriver/layerParameters/layerParameters.C b/src/autoMesh/autoHexMesh/autoHexMeshDriver/layerParameters/layerParameters.C index a2fd5ca976..17ad2db042 100644 --- a/src/autoMesh/autoHexMesh/autoHexMeshDriver/layerParameters/layerParameters.C +++ b/src/autoMesh/autoHexMesh/autoHexMeshDriver/layerParameters/layerParameters.C @@ -175,9 +175,7 @@ Foam::layerParameters::layerParameters featureAngle_(readScalar(dict.lookup("featureAngle"))), concaveAngle_ ( - dict.found("concaveAngle") - ? readScalar(dict.lookup("concaveAngle")) - : defaultConcaveAngle + dict.lookupOrDefault("concaveAngle", defaultConcaveAngle) ), nGrow_(readLabel(dict.lookup("nGrow"))), nSmoothSurfaceNormals_ @@ -242,9 +240,7 @@ Foam::layerParameters::layerParameters featureAngle_(readScalar(dict.lookup("featureAngle"))), concaveAngle_ ( - dict.found("concaveAngle") - ? readScalar(dict.lookup("concaveAngle")) - : defaultConcaveAngle + dict.lookupOrDefault("concaveAngle", defaultConcaveAngle) ), nGrow_(readLabel(dict.lookup("nGrow"))), nSmoothSurfaceNormals_ diff --git a/src/autoMesh/autoHexMesh/shellSurfaces/shellSurfaces.H b/src/autoMesh/autoHexMesh/shellSurfaces/shellSurfaces.H index b996e98e89..0ec93cbeb1 100644 --- a/src/autoMesh/autoHexMesh/shellSurfaces/shellSurfaces.H +++ b/src/autoMesh/autoHexMesh/shellSurfaces/shellSurfaces.H @@ -23,7 +23,7 @@ License Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Class - shellSurfaces + Foam::shellSurfaces Description Encapsulates queries for volume refinement ('refine all cells within diff --git a/src/conversion/ensight/part/ensightPart.C b/src/conversion/ensight/part/ensightPart.C index 5ccb17e820..ff870658f6 100644 --- a/src/conversion/ensight/part/ensightPart.C +++ b/src/conversion/ensight/part/ensightPart.C @@ -171,14 +171,10 @@ void Foam::ensightPart::reconstruct(Istream& is) forAll(elementTypes(), elemI) { word key(elementTypes()[elemI]); - if (dict.found(key)) - { - dict.lookup(key) >> elemLists_[elemI]; - } - else - { - elemLists_[elemI].clear(); - } + + elemLists_[elemI].clear(); + dict.readIfPresent(key, elemLists_[elemI]); + size_ += elemLists_[elemI].size(); } diff --git a/src/conversion/ensight/part/ensightPart.H b/src/conversion/ensight/part/ensightPart.H index b511c6d095..5df840ea01 100644 --- a/src/conversion/ensight/part/ensightPart.H +++ b/src/conversion/ensight/part/ensightPart.H @@ -137,7 +137,7 @@ protected: ( ensightFile& os, const List& field, - const labelList& idList + const List