mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: Updating utilities based on internal development line
This commit is contained in:
@ -34,7 +34,8 @@ Description
|
|||||||
NOTE: To avoid exposing wrong fields values faceSets should include
|
NOTE: To avoid exposing wrong fields values faceSets should include
|
||||||
faces contained in the blockedCells cellset.
|
faces contained in the blockedCells cellset.
|
||||||
|
|
||||||
- coupledFaces reads coupledFacesSet to introduces mixe-coupled baffles
|
- coupledFaces reads coupledFacesSet to introduces mixed-coupled
|
||||||
|
duplicate baffles
|
||||||
|
|
||||||
Subsets out the blocked cells and splits the blockedFaces and updates
|
Subsets out the blocked cells and splits the blockedFaces and updates
|
||||||
fields.
|
fields.
|
||||||
|
|||||||
@ -17,7 +17,8 @@ FoamFile
|
|||||||
//- Per faceSet the patch the faces should go into blocked baffles
|
//- Per faceSet the patch the faces should go into blocked baffles
|
||||||
blockedFaces ((blockedFacesSet blockedFaces));
|
blockedFaces ((blockedFacesSet blockedFaces));
|
||||||
|
|
||||||
//- Per faceSet the patch the faces should go into coupled baffles
|
//- Per faceSet the duplicate baffles to generate (one 'normal', wall baffle,
|
||||||
|
// one cyclic baffle). For use with active baffle boundary conditions.
|
||||||
coupledFaces
|
coupledFaces
|
||||||
{
|
{
|
||||||
coupledFacesSet
|
coupledFacesSet
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -525,7 +525,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
Info<< "Created zone " << name
|
Info<< "Created zone " << name
|
||||||
<< " at index " << zoneID
|
<< " at index " << zoneID
|
||||||
<< " with " << n << " faces" << endl;
|
<< " with " << returnReduce(n, sumOp<label>()) << " faces" << endl;
|
||||||
|
|
||||||
mesh.faceZones().set
|
mesh.faceZones().set
|
||||||
(
|
(
|
||||||
|
|||||||
@ -512,6 +512,11 @@ int main(int argc, char *argv[])
|
|||||||
#include "addOverwriteOption.H"
|
#include "addOverwriteOption.H"
|
||||||
#include "addRegionOption.H"
|
#include "addRegionOption.H"
|
||||||
#include "addDictOption.H"
|
#include "addDictOption.H"
|
||||||
|
Foam::argList::addBoolOption
|
||||||
|
(
|
||||||
|
"writeObj",
|
||||||
|
"write obj files showing the cyclic matching process"
|
||||||
|
);
|
||||||
#include "setRootCase.H"
|
#include "setRootCase.H"
|
||||||
#include "createTime.H"
|
#include "createTime.H"
|
||||||
runTime.functionObjects().off();
|
runTime.functionObjects().off();
|
||||||
@ -523,12 +528,13 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
#include "createNamedPolyMesh.H"
|
#include "createNamedPolyMesh.H"
|
||||||
|
|
||||||
|
const bool writeObj = args.optionFound("writeObj");
|
||||||
|
|
||||||
const word oldInstance = mesh.pointsInstance();
|
const word oldInstance = mesh.pointsInstance();
|
||||||
|
|
||||||
const word dictName("createPatchDict");
|
const word dictName("createPatchDict");
|
||||||
#include "setSystemMeshDictionaryIO.H"
|
#include "setSystemMeshDictionaryIO.H"
|
||||||
|
Info<< "Reading " << dictIO.instance()/dictIO.name() << nl << endl;
|
||||||
Info<< "Reading " << dictName << nl << endl;
|
|
||||||
|
|
||||||
IOdictionary dict(dictIO);
|
IOdictionary dict(dictIO);
|
||||||
|
|
||||||
@ -542,7 +548,10 @@ int main(int argc, char *argv[])
|
|||||||
patches.checkParallelSync(true);
|
patches.checkParallelSync(true);
|
||||||
|
|
||||||
|
|
||||||
|
if (writeObj)
|
||||||
|
{
|
||||||
dumpCyclicMatch("initial_", mesh);
|
dumpCyclicMatch("initial_", mesh);
|
||||||
|
}
|
||||||
|
|
||||||
// Read patch construct info from dictionary
|
// Read patch construct info from dictionary
|
||||||
PtrList<dictionary> patchSources(dict.lookup("patches"));
|
PtrList<dictionary> patchSources(dict.lookup("patches"));
|
||||||
@ -761,7 +770,10 @@ int main(int argc, char *argv[])
|
|||||||
autoPtr<mapPolyMesh> map = meshMod.changeMesh(mesh, true);
|
autoPtr<mapPolyMesh> map = meshMod.changeMesh(mesh, true);
|
||||||
mesh.movePoints(map().preMotionPoints());
|
mesh.movePoints(map().preMotionPoints());
|
||||||
|
|
||||||
|
if (writeObj)
|
||||||
|
{
|
||||||
dumpCyclicMatch("coupled_", mesh);
|
dumpCyclicMatch("coupled_", mesh);
|
||||||
|
}
|
||||||
|
|
||||||
// Synchronise points.
|
// Synchronise points.
|
||||||
if (!pointSync)
|
if (!pointSync)
|
||||||
@ -872,7 +884,10 @@ int main(int argc, char *argv[])
|
|||||||
filterPatches(mesh, addedPatchNames);
|
filterPatches(mesh, addedPatchNames);
|
||||||
|
|
||||||
|
|
||||||
|
if (writeObj)
|
||||||
|
{
|
||||||
dumpCyclicMatch("final_", mesh);
|
dumpCyclicMatch("final_", mesh);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// Set the precision of the points data to 10
|
// Set the precision of the points data to 10
|
||||||
|
|||||||
@ -96,6 +96,8 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Writing points into directory " << points.path() << nl << endl;
|
Info<< "Writing points into directory " << points.path() << nl << endl;
|
||||||
points.write();
|
points.write();
|
||||||
|
|
||||||
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -62,7 +62,6 @@ int main(int argc, char *argv[])
|
|||||||
"merge two meshes"
|
"merge two meshes"
|
||||||
);
|
);
|
||||||
|
|
||||||
argList::noParallel();
|
|
||||||
#include "addOverwriteOption.H"
|
#include "addOverwriteOption.H"
|
||||||
|
|
||||||
argList::validArgs.append("masterCase");
|
argList::validArgs.append("masterCase");
|
||||||
@ -97,6 +96,18 @@ int main(int argc, char *argv[])
|
|||||||
word addRegion = polyMesh::defaultRegion;
|
word addRegion = polyMesh::defaultRegion;
|
||||||
args.optionReadIfPresent("addRegion", addRegion);
|
args.optionReadIfPresent("addRegion", addRegion);
|
||||||
|
|
||||||
|
// Since we don't use argList processor directory detection, add it to
|
||||||
|
// the casename ourselves so it triggers the logic inside TimePath.
|
||||||
|
const fileName& cName = args.caseName();
|
||||||
|
std::string::size_type pos = cName.find("processor");
|
||||||
|
if (pos != string::npos && pos != 0)
|
||||||
|
{
|
||||||
|
fileName processorName = cName.substr(pos, cName.size()-pos);
|
||||||
|
masterCase += '/' + processorName;
|
||||||
|
addCase += '/' + processorName;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
getRootCase(masterCase);
|
getRootCase(masterCase);
|
||||||
getRootCase(addCase);
|
getRootCase(addCase);
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -243,8 +243,9 @@ Foam::mirrorFvMesh::mirrorFvMesh(const IOobject& io)
|
|||||||
|
|
||||||
// Mirror boundary faces patch by patch
|
// Mirror boundary faces patch by patch
|
||||||
|
|
||||||
wordList newPatchTypes(boundary().size());
|
|
||||||
wordList newPatchNames(boundary().size());
|
labelList newToOldPatch(boundary().size(), -1);
|
||||||
|
|
||||||
labelList newPatchSizes(boundary().size(), -1);
|
labelList newPatchSizes(boundary().size(), -1);
|
||||||
labelList newPatchStarts(boundary().size(), -1);
|
labelList newPatchStarts(boundary().size(), -1);
|
||||||
label nNewPatches = 0;
|
label nNewPatches = 0;
|
||||||
@ -303,8 +304,8 @@ Foam::mirrorFvMesh::mirrorFvMesh(const IOobject& io)
|
|||||||
// If patch exists, grab the name and type of the original patch
|
// If patch exists, grab the name and type of the original patch
|
||||||
if (nNewFaces > newPatchStarts[nNewPatches])
|
if (nNewFaces > newPatchStarts[nNewPatches])
|
||||||
{
|
{
|
||||||
newPatchTypes[nNewPatches] = boundaryMesh()[patchI].type();
|
newToOldPatch[nNewPatches] = patchI;
|
||||||
newPatchNames[nNewPatches] = boundaryMesh()[patchI].name();
|
|
||||||
newPatchSizes[nNewPatches] =
|
newPatchSizes[nNewPatches] =
|
||||||
nNewFaces - newPatchStarts[nNewPatches];
|
nNewFaces - newPatchStarts[nNewPatches];
|
||||||
|
|
||||||
@ -316,8 +317,7 @@ Foam::mirrorFvMesh::mirrorFvMesh(const IOobject& io)
|
|||||||
newFaces.setSize(nNewFaces);
|
newFaces.setSize(nNewFaces);
|
||||||
Info<< " New faces: " << nNewFaces << endl;
|
Info<< " New faces: " << nNewFaces << endl;
|
||||||
|
|
||||||
newPatchTypes.setSize(nNewPatches);
|
newToOldPatch.setSize(nNewPatches);
|
||||||
newPatchNames.setSize(nNewPatches);
|
|
||||||
newPatchSizes.setSize(nNewPatches);
|
newPatchSizes.setSize(nNewPatches);
|
||||||
newPatchStarts.setSize(nNewPatches);
|
newPatchStarts.setSize(nNewPatches);
|
||||||
|
|
||||||
@ -377,18 +377,16 @@ Foam::mirrorFvMesh::mirrorFvMesh(const IOobject& io)
|
|||||||
fvMesh& pMesh = *mirrorMeshPtr_;
|
fvMesh& pMesh = *mirrorMeshPtr_;
|
||||||
|
|
||||||
// Add the boundary patches
|
// Add the boundary patches
|
||||||
List<polyPatch*> p(newPatchTypes.size());
|
List<polyPatch*> p(newPatchSizes.size());
|
||||||
|
|
||||||
forAll(p, patchI)
|
forAll(p, patchI)
|
||||||
{
|
{
|
||||||
p[patchI] = polyPatch::New
|
p[patchI] = boundaryMesh()[newToOldPatch[patchI]].clone
|
||||||
(
|
(
|
||||||
newPatchTypes[patchI],
|
pMesh.boundaryMesh(),
|
||||||
newPatchNames[patchI],
|
|
||||||
newPatchSizes[patchI],
|
|
||||||
newPatchStarts[patchI],
|
|
||||||
patchI,
|
patchI,
|
||||||
pMesh.boundaryMesh()
|
newPatchSizes[patchI],
|
||||||
|
newPatchStarts[patchI]
|
||||||
).ptr();
|
).ptr();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -67,7 +67,7 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Writing mirrored mesh" << endl;
|
Info<< "Writing mirrored mesh" << endl;
|
||||||
mesh.mirrorMesh().write();
|
mesh.mirrorMesh().write();
|
||||||
|
|
||||||
Info<< "End" << endl;
|
Info<< "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||||
\\/ M anispulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
@ -46,6 +46,9 @@ Description
|
|||||||
#include "zeroGradientFvPatchFields.H"
|
#include "zeroGradientFvPatchFields.H"
|
||||||
#include "CuthillMcKeeRenumber.H"
|
#include "CuthillMcKeeRenumber.H"
|
||||||
#include "fvMeshSubset.H"
|
#include "fvMeshSubset.H"
|
||||||
|
#include "cellSet.H"
|
||||||
|
#include "faceSet.H"
|
||||||
|
#include "pointSet.H"
|
||||||
|
|
||||||
#ifdef FOAM_USE_ZOLTAN
|
#ifdef FOAM_USE_ZOLTAN
|
||||||
#include "zoltanRenumber.H"
|
#include "zoltanRenumber.H"
|
||||||
@ -634,6 +637,12 @@ int main(int argc, char *argv[])
|
|||||||
"calculate the rms of the frontwidth"
|
"calculate the rms of the frontwidth"
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
#include "setRootCase.H"
|
||||||
|
#include "createTime.H"
|
||||||
|
runTime.functionObjects().off();
|
||||||
|
|
||||||
|
|
||||||
// Force linker to include zoltan symbols. This section is only needed since
|
// Force linker to include zoltan symbols. This section is only needed since
|
||||||
// Zoltan is a static library
|
// Zoltan is a static library
|
||||||
#ifdef FOAM_USE_ZOLTAN
|
#ifdef FOAM_USE_ZOLTAN
|
||||||
@ -641,9 +650,6 @@ int main(int argc, char *argv[])
|
|||||||
(void)zoltanRenumber::typeName;
|
(void)zoltanRenumber::typeName;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "setRootCase.H"
|
|
||||||
#include "createTime.H"
|
|
||||||
runTime.functionObjects().off();
|
|
||||||
|
|
||||||
// Get times list
|
// Get times list
|
||||||
instantList Times = runTime.times();
|
instantList Times = runTime.times();
|
||||||
@ -700,6 +706,7 @@ int main(int argc, char *argv[])
|
|||||||
bool writeMaps = false;
|
bool writeMaps = false;
|
||||||
bool orderPoints = false;
|
bool orderPoints = false;
|
||||||
label blockSize = 0;
|
label blockSize = 0;
|
||||||
|
bool renumberSets = true;
|
||||||
|
|
||||||
// Construct renumberMethod
|
// Construct renumberMethod
|
||||||
autoPtr<IOdictionary> renumberDictPtr;
|
autoPtr<IOdictionary> renumberDictPtr;
|
||||||
@ -760,6 +767,8 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Writing renumber maps (new to old) to polyMesh." << nl
|
Info<< "Writing renumber maps (new to old) to polyMesh." << nl
|
||||||
<< endl;
|
<< endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
renumberSets = renumberDict.lookupOrDefault("renumberSets", true);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -861,6 +870,71 @@ int main(int argc, char *argv[])
|
|||||||
PtrList<surfaceTensorField> stFlds;
|
PtrList<surfaceTensorField> stFlds;
|
||||||
ReadFields(mesh, objects, stFlds);
|
ReadFields(mesh, objects, stFlds);
|
||||||
|
|
||||||
|
// Read point fields.
|
||||||
|
|
||||||
|
PtrList<pointScalarField> psFlds;
|
||||||
|
ReadFields(pointMesh::New(mesh), objects, psFlds);
|
||||||
|
|
||||||
|
PtrList<pointVectorField> pvFlds;
|
||||||
|
ReadFields(pointMesh::New(mesh), objects, pvFlds);
|
||||||
|
|
||||||
|
PtrList<pointSphericalTensorField> pstFlds;
|
||||||
|
ReadFields(pointMesh::New(mesh), objects, pstFlds);
|
||||||
|
|
||||||
|
PtrList<pointSymmTensorField> psymtFlds;
|
||||||
|
ReadFields(pointMesh::New(mesh), objects, psymtFlds);
|
||||||
|
|
||||||
|
PtrList<pointTensorField> ptFlds;
|
||||||
|
ReadFields(pointMesh::New(mesh), objects, ptFlds);
|
||||||
|
|
||||||
|
// Read sets
|
||||||
|
PtrList<cellSet> cellSets;
|
||||||
|
PtrList<faceSet> faceSets;
|
||||||
|
PtrList<pointSet> pointSets;
|
||||||
|
if (renumberSets)
|
||||||
|
{
|
||||||
|
// Read sets
|
||||||
|
IOobjectList objects(mesh, mesh.facesInstance(), "polyMesh/sets");
|
||||||
|
{
|
||||||
|
IOobjectList cSets(objects.lookupClass(cellSet::typeName));
|
||||||
|
if (cSets.size())
|
||||||
|
{
|
||||||
|
Info<< "Reading cellSets:" << endl;
|
||||||
|
forAllConstIter(IOobjectList, cSets, iter)
|
||||||
|
{
|
||||||
|
cellSets.append(new cellSet(*iter()));
|
||||||
|
Info<< " " << cellSets.last().name() << endl;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
IOobjectList fSets(objects.lookupClass(faceSet::typeName));
|
||||||
|
if (fSets.size())
|
||||||
|
{
|
||||||
|
Info<< "Reading faceSets:" << endl;
|
||||||
|
forAllConstIter(IOobjectList, fSets, iter)
|
||||||
|
{
|
||||||
|
faceSets.append(new faceSet(*iter()));
|
||||||
|
Info<< " " << faceSets.last().name() << endl;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
IOobjectList pSets(objects.lookupClass(pointSet::typeName));
|
||||||
|
if (pSets.size())
|
||||||
|
{
|
||||||
|
Info<< "Reading pointSets:" << endl;
|
||||||
|
forAllConstIter(IOobjectList, pSets, iter)
|
||||||
|
{
|
||||||
|
pointSets.append(new pointSet(*iter()));
|
||||||
|
Info<< " " << pointSets.last().name() << endl;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Info<< endl;
|
Info<< endl;
|
||||||
|
|
||||||
// From renumbering:
|
// From renumbering:
|
||||||
@ -1055,7 +1129,6 @@ int main(int argc, char *argv[])
|
|||||||
mesh.updateMesh(map);
|
mesh.updateMesh(map);
|
||||||
|
|
||||||
// Update proc maps
|
// Update proc maps
|
||||||
if (cellProcAddressing.headerOk())
|
|
||||||
if
|
if
|
||||||
(
|
(
|
||||||
cellProcAddressing.headerOk()
|
cellProcAddressing.headerOk()
|
||||||
@ -1070,7 +1143,6 @@ int main(int argc, char *argv[])
|
|||||||
UIndirectList<label>(cellProcAddressing, map().cellMap())
|
UIndirectList<label>(cellProcAddressing, map().cellMap())
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if (faceProcAddressing.headerOk())
|
|
||||||
if
|
if
|
||||||
(
|
(
|
||||||
faceProcAddressing.headerOk()
|
faceProcAddressing.headerOk()
|
||||||
@ -1101,7 +1173,6 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (pointProcAddressing.headerOk())
|
|
||||||
if
|
if
|
||||||
(
|
(
|
||||||
pointProcAddressing.headerOk()
|
pointProcAddressing.headerOk()
|
||||||
@ -1226,46 +1297,79 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
mesh.write();
|
mesh.write();
|
||||||
if (cellProcAddressing.headerOk())
|
if (cellProcAddressing.headerOk())
|
||||||
if
|
|
||||||
(
|
|
||||||
cellProcAddressing.headerOk()
|
|
||||||
&& cellProcAddressing.size() == mesh.nCells()
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
cellProcAddressing.instance() = mesh.facesInstance();
|
cellProcAddressing.instance() = mesh.facesInstance();
|
||||||
|
if (cellProcAddressing.size() == mesh.nCells())
|
||||||
|
{
|
||||||
cellProcAddressing.write();
|
cellProcAddressing.write();
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// procAddressing no longer valid. Delete it.
|
||||||
|
const fileName fName(cellProcAddressing.filePath());
|
||||||
|
if (fName.size())
|
||||||
|
{
|
||||||
|
Info<< "Deleting inconsistent processor cell decomposition"
|
||||||
|
<< " map " << fName << endl;
|
||||||
|
rm(fName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
if (faceProcAddressing.headerOk())
|
if (faceProcAddressing.headerOk())
|
||||||
if
|
|
||||||
(
|
|
||||||
faceProcAddressing.headerOk()
|
|
||||||
&& faceProcAddressing.size() == mesh.nFaces()
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
faceProcAddressing.instance() = mesh.facesInstance();
|
faceProcAddressing.instance() = mesh.facesInstance();
|
||||||
|
if (faceProcAddressing.size() == mesh.nFaces())
|
||||||
|
{
|
||||||
faceProcAddressing.write();
|
faceProcAddressing.write();
|
||||||
}
|
}
|
||||||
if (pointProcAddressing.headerOk())
|
else
|
||||||
if
|
|
||||||
(
|
|
||||||
pointProcAddressing.headerOk()
|
|
||||||
&& pointProcAddressing.size() == mesh.nPoints()
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
pointProcAddressing.instance() = mesh.facesInstance();
|
const fileName fName(faceProcAddressing.filePath());
|
||||||
pointProcAddressing.write();
|
if (fName.size())
|
||||||
|
{
|
||||||
|
Info<< "Deleting inconsistent processor face decomposition"
|
||||||
|
<< " map " << fName << endl;
|
||||||
|
rm(fName);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (boundaryProcAddressing.headerOk())
|
|
||||||
if
|
|
||||||
(
|
|
||||||
boundaryProcAddressing.headerOk()
|
|
||||||
&& boundaryProcAddressing.size() == mesh.boundaryMesh().size()
|
|
||||||
)
|
|
||||||
{
|
|
||||||
boundaryProcAddressing.instance() = mesh.facesInstance();
|
|
||||||
boundaryProcAddressing.write();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (pointProcAddressing.headerOk())
|
||||||
|
{
|
||||||
|
pointProcAddressing.instance() = mesh.facesInstance();
|
||||||
|
if (pointProcAddressing.size() == mesh.nPoints())
|
||||||
|
{
|
||||||
|
pointProcAddressing.write();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
const fileName fName(pointProcAddressing.filePath());
|
||||||
|
if (fName.size())
|
||||||
|
{
|
||||||
|
Info<< "Deleting inconsistent processor point decomposition"
|
||||||
|
<< " map " << fName << endl;
|
||||||
|
rm(fName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (boundaryProcAddressing.headerOk())
|
||||||
|
{
|
||||||
|
boundaryProcAddressing.instance() = mesh.facesInstance();
|
||||||
|
if (boundaryProcAddressing.size() == mesh.boundaryMesh().size())
|
||||||
|
{
|
||||||
|
boundaryProcAddressing.write();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
const fileName fName(boundaryProcAddressing.filePath());
|
||||||
|
if (fName.size())
|
||||||
|
{
|
||||||
|
Info<< "Deleting inconsistent processor patch decomposition"
|
||||||
|
<< " map " << fName << endl;
|
||||||
|
rm(fName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (writeMaps)
|
if (writeMaps)
|
||||||
{
|
{
|
||||||
@ -1331,6 +1435,28 @@ int main(int argc, char *argv[])
|
|||||||
).write();
|
).write();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (renumberSets)
|
||||||
|
{
|
||||||
|
forAll(cellSets, i)
|
||||||
|
{
|
||||||
|
cellSets[i].updateMesh(map());
|
||||||
|
cellSets[i].instance() = mesh.facesInstance();
|
||||||
|
cellSets[i].write();
|
||||||
|
}
|
||||||
|
forAll(faceSets, i)
|
||||||
|
{
|
||||||
|
faceSets[i].updateMesh(map());
|
||||||
|
faceSets[i].instance() = mesh.facesInstance();
|
||||||
|
faceSets[i].write();
|
||||||
|
}
|
||||||
|
forAll(pointSets, i)
|
||||||
|
{
|
||||||
|
pointSets[i].updateMesh(map());
|
||||||
|
pointSets[i].instance() = mesh.facesInstance();
|
||||||
|
pointSets[i].write();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Info<< "\nEnd\n" << endl;
|
Info<< "\nEnd\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
@ -34,6 +34,8 @@ sortCoupledFaceCells false;
|
|||||||
// Optional entry: sort points into internal and boundary points
|
// Optional entry: sort points into internal and boundary points
|
||||||
//orderPoints false;
|
//orderPoints false;
|
||||||
|
|
||||||
|
// Optional: suppress renumbering cellSets,faceSets,pointSets
|
||||||
|
//renumberSets false;
|
||||||
|
|
||||||
|
|
||||||
method CuthillMcKee;
|
method CuthillMcKee;
|
||||||
|
|||||||
@ -287,7 +287,8 @@ int main(int argc, char *argv[])
|
|||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
Info<< nl << "end" << endl;
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -499,7 +499,7 @@ int main(int argc, char *argv[])
|
|||||||
// Write fields
|
// Write fields
|
||||||
runTime.write();
|
runTime.write();
|
||||||
|
|
||||||
Info<< nl << "end" << endl;
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -41,11 +41,86 @@ Description
|
|||||||
#include "cellSet.H"
|
#include "cellSet.H"
|
||||||
#include "IOobjectList.H"
|
#include "IOobjectList.H"
|
||||||
#include "volFields.H"
|
#include "volFields.H"
|
||||||
|
#include "topoDistanceData.H"
|
||||||
|
#include "FaceCellWave.H"
|
||||||
|
|
||||||
using namespace Foam;
|
using namespace Foam;
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
labelList nearestPatch(const polyMesh& mesh, const labelList& patchIDs)
|
||||||
|
{
|
||||||
|
const polyBoundaryMesh& pbm = mesh.boundaryMesh();
|
||||||
|
|
||||||
|
// Count number of faces in exposedPatchIDs
|
||||||
|
label nFaces = 0;
|
||||||
|
forAll(patchIDs, i)
|
||||||
|
{
|
||||||
|
const polyPatch& pp = pbm[patchIDs[i]];
|
||||||
|
nFaces += pp.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Field on cells and faces.
|
||||||
|
List<topoDistanceData> cellData(mesh.nCells());
|
||||||
|
List<topoDistanceData> faceData(mesh.nFaces());
|
||||||
|
|
||||||
|
// Start of changes
|
||||||
|
labelList patchFaces(nFaces);
|
||||||
|
List<topoDistanceData> patchData(nFaces);
|
||||||
|
nFaces = 0;
|
||||||
|
forAll(patchIDs, i)
|
||||||
|
{
|
||||||
|
label patchI = patchIDs[i];
|
||||||
|
const polyPatch& pp = pbm[patchI];
|
||||||
|
|
||||||
|
forAll(pp, i)
|
||||||
|
{
|
||||||
|
patchFaces[nFaces] = pp.start()+i;
|
||||||
|
patchData[nFaces] = topoDistanceData(patchI, 0);
|
||||||
|
nFaces++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Propagate information inwards
|
||||||
|
FaceCellWave<topoDistanceData> deltaCalc
|
||||||
|
(
|
||||||
|
mesh,
|
||||||
|
patchFaces,
|
||||||
|
patchData,
|
||||||
|
faceData,
|
||||||
|
cellData,
|
||||||
|
mesh.globalData().nTotalCells()+1
|
||||||
|
);
|
||||||
|
|
||||||
|
// And extract
|
||||||
|
|
||||||
|
labelList nearest(mesh.nFaces());
|
||||||
|
|
||||||
|
bool haveWarned = false;
|
||||||
|
forAll(faceData, faceI)
|
||||||
|
{
|
||||||
|
if (!faceData[faceI].valid(deltaCalc.data()))
|
||||||
|
{
|
||||||
|
if (!haveWarned)
|
||||||
|
{
|
||||||
|
WarningIn("meshRefinement::nearestPatch(..)")
|
||||||
|
<< "Did not visit some faces, e.g. face " << faceI
|
||||||
|
<< " at " << mesh.faceCentres()[faceI] << endl
|
||||||
|
<< "Using patch " << patchIDs[0] << " as nearest"
|
||||||
|
<< endl;
|
||||||
|
haveWarned = true;
|
||||||
|
}
|
||||||
|
nearest[faceI] = patchIDs[0];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
nearest[faceI] = faceData[faceI].data();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return nearest;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void subsetVolFields
|
void subsetVolFields
|
||||||
@ -150,6 +225,40 @@ void subsetPointFields
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
template<class Type>
|
||||||
|
void subsetDimensionedFields
|
||||||
|
(
|
||||||
|
const fvMeshSubset& subsetter,
|
||||||
|
const wordList& fieldNames,
|
||||||
|
PtrList<DimensionedField<Type, volMesh> >& subFields
|
||||||
|
)
|
||||||
|
{
|
||||||
|
const fvMesh& baseMesh = subsetter.baseMesh();
|
||||||
|
|
||||||
|
forAll(fieldNames, i)
|
||||||
|
{
|
||||||
|
const word& fieldName = fieldNames[i];
|
||||||
|
|
||||||
|
Info<< "Subsetting field " << fieldName << endl;
|
||||||
|
|
||||||
|
DimensionedField<Type, volMesh> fld
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
fieldName,
|
||||||
|
baseMesh.time().timeName(),
|
||||||
|
baseMesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::NO_WRITE
|
||||||
|
),
|
||||||
|
baseMesh
|
||||||
|
);
|
||||||
|
|
||||||
|
subFields.set(i, subsetter.interpolate(fld));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
@ -169,6 +278,13 @@ int main(int argc, char *argv[])
|
|||||||
"'oldInternalFaces'"
|
"'oldInternalFaces'"
|
||||||
);
|
);
|
||||||
argList::addOption
|
argList::addOption
|
||||||
|
(
|
||||||
|
"patches",
|
||||||
|
"names",
|
||||||
|
"add exposed internal faces to nearest of specified patches"
|
||||||
|
" instead of to 'oldInternalFaces'"
|
||||||
|
);
|
||||||
|
argList::addOption
|
||||||
(
|
(
|
||||||
"resultTime",
|
"resultTime",
|
||||||
"time",
|
"time",
|
||||||
@ -207,15 +323,19 @@ int main(int argc, char *argv[])
|
|||||||
// Create mesh subsetting engine
|
// Create mesh subsetting engine
|
||||||
fvMeshSubset subsetter(mesh);
|
fvMeshSubset subsetter(mesh);
|
||||||
|
|
||||||
label patchI = -1;
|
labelList exposedPatchIDs;
|
||||||
|
|
||||||
if (args.optionFound("patch"))
|
if (args.optionFound("patch"))
|
||||||
{
|
{
|
||||||
const word patchName = args["patch"];
|
const word patchName = args["patch"];
|
||||||
|
|
||||||
patchI = mesh.boundaryMesh().findPatchID(patchName);
|
exposedPatchIDs = labelList
|
||||||
|
(
|
||||||
|
1,
|
||||||
|
mesh.boundaryMesh().findPatchID(patchName)
|
||||||
|
);
|
||||||
|
|
||||||
if (patchI == -1)
|
if (exposedPatchIDs[0] == -1)
|
||||||
{
|
{
|
||||||
FatalErrorIn(args.executable()) << "Illegal patch " << patchName
|
FatalErrorIn(args.executable()) << "Illegal patch " << patchName
|
||||||
<< nl << "Valid patches are " << mesh.boundaryMesh().names()
|
<< nl << "Valid patches are " << mesh.boundaryMesh().names()
|
||||||
@ -225,17 +345,53 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Adding exposed internal faces to patch " << patchName << endl
|
Info<< "Adding exposed internal faces to patch " << patchName << endl
|
||||||
<< endl;
|
<< endl;
|
||||||
}
|
}
|
||||||
|
else if (args.optionFound("patches"))
|
||||||
|
{
|
||||||
|
const wordReList patchNames(args.optionRead<wordReList>("patches"));
|
||||||
|
|
||||||
|
exposedPatchIDs = mesh.boundaryMesh().patchSet(patchNames).sortedToc();
|
||||||
|
|
||||||
|
Info<< "Adding exposed internal faces to nearest of patches "
|
||||||
|
<< patchNames << endl << endl;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Info<< "Adding exposed internal faces to a patch called"
|
Info<< "Adding exposed internal faces to a patch called"
|
||||||
<< " \"oldInternalFaces\" (created if necessary)" << endl
|
<< " \"oldInternalFaces\" (created if necessary)" << endl
|
||||||
<< endl;
|
<< endl;
|
||||||
|
exposedPatchIDs = labelList(1, label(-1));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
cellSet currentSet(mesh, setName);
|
cellSet currentSet(mesh, setName);
|
||||||
|
|
||||||
subsetter.setLargeCellSubset(currentSet, patchI, true);
|
if (exposedPatchIDs.size() == 1)
|
||||||
|
{
|
||||||
|
subsetter.setLargeCellSubset(currentSet, exposedPatchIDs[0], true);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
// Find per face the nearest patch
|
||||||
|
labelList nearestExposedPatch(nearestPatch(mesh, exposedPatchIDs));
|
||||||
|
|
||||||
|
labelList region(mesh.nCells(), 0);
|
||||||
|
forAllConstIter(cellSet, currentSet, iter)
|
||||||
|
{
|
||||||
|
region[iter.key()] = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
labelList exposedFaces(subsetter.getExposedFaces(region, 1, true));
|
||||||
|
subsetter.setLargeCellSubset
|
||||||
|
(
|
||||||
|
region,
|
||||||
|
1,
|
||||||
|
exposedFaces,
|
||||||
|
UIndirectList<label>(nearestExposedPatch, exposedFaces)(),
|
||||||
|
true
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
IOobjectList objects(mesh, runTime.timeName());
|
IOobjectList objects(mesh, runTime.timeName());
|
||||||
|
|
||||||
@ -361,6 +517,42 @@ int main(int argc, char *argv[])
|
|||||||
subsetPointFields(subsetter, pMesh, pointTensorNames, pointTensorFlds);
|
subsetPointFields(subsetter, pMesh, pointTensorNames, pointTensorFlds);
|
||||||
|
|
||||||
|
|
||||||
|
// Read dimensioned fields and subset
|
||||||
|
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
typedef volScalarField::DimensionedInternalField dimScalType;
|
||||||
|
wordList scalarDimNames(objects.names(dimScalType::typeName));
|
||||||
|
PtrList<dimScalType> scalarDimFlds(scalarDimNames.size());
|
||||||
|
subsetDimensionedFields(subsetter, scalarDimNames, scalarDimFlds);
|
||||||
|
|
||||||
|
typedef volVectorField::DimensionedInternalField dimVecType;
|
||||||
|
wordList vectorDimNames(objects.names(dimVecType::typeName));
|
||||||
|
PtrList<dimVecType> vectorDimFlds(vectorDimNames.size());
|
||||||
|
subsetDimensionedFields(subsetter, vectorDimNames, vectorDimFlds);
|
||||||
|
|
||||||
|
typedef volSphericalTensorField::DimensionedInternalField dimSphereType;
|
||||||
|
wordList sphericalTensorDimNames(objects.names(dimSphereType::typeName));
|
||||||
|
PtrList<dimSphereType> sphericalTensorDimFlds
|
||||||
|
(
|
||||||
|
sphericalTensorDimNames.size()
|
||||||
|
);
|
||||||
|
subsetDimensionedFields
|
||||||
|
(
|
||||||
|
subsetter,
|
||||||
|
sphericalTensorDimNames,
|
||||||
|
sphericalTensorDimFlds
|
||||||
|
);
|
||||||
|
|
||||||
|
typedef volSymmTensorField::DimensionedInternalField dimSymmTensorType;
|
||||||
|
wordList symmTensorDimNames(objects.names(dimSymmTensorType::typeName));
|
||||||
|
PtrList<dimSymmTensorType> symmTensorDimFlds(symmTensorDimNames.size());
|
||||||
|
subsetDimensionedFields(subsetter, symmTensorDimNames, symmTensorDimFlds);
|
||||||
|
|
||||||
|
typedef volTensorField::DimensionedInternalField dimTensorType;
|
||||||
|
wordList tensorDimNames(objects.names(dimTensorType::typeName));
|
||||||
|
PtrList<dimTensorType> tensorDimFlds(tensorDimNames.size());
|
||||||
|
subsetDimensionedFields(subsetter, tensorDimNames, tensorDimFlds);
|
||||||
|
|
||||||
|
|
||||||
// Write mesh and fields to new time
|
// Write mesh and fields to new time
|
||||||
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
@ -461,6 +653,33 @@ int main(int argc, char *argv[])
|
|||||||
pointTensorFlds[i].write();
|
pointTensorFlds[i].write();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DimensionedFields
|
||||||
|
forAll(scalarDimFlds, i)
|
||||||
|
{
|
||||||
|
scalarDimFlds[i].rename(scalarDimNames[i]);
|
||||||
|
scalarDimFlds[i].write();
|
||||||
|
}
|
||||||
|
forAll(vectorDimFlds, i)
|
||||||
|
{
|
||||||
|
vectorDimFlds[i].rename(vectorDimNames[i]);
|
||||||
|
vectorDimFlds[i].write();
|
||||||
|
}
|
||||||
|
forAll(sphericalTensorDimFlds, i)
|
||||||
|
{
|
||||||
|
sphericalTensorDimFlds[i].rename(sphericalTensorDimNames[i]);
|
||||||
|
sphericalTensorDimFlds[i].write();
|
||||||
|
}
|
||||||
|
forAll(symmTensorDimFlds, i)
|
||||||
|
{
|
||||||
|
symmTensorDimFlds[i].rename(symmTensorDimNames[i]);
|
||||||
|
symmTensorDimFlds[i].write();
|
||||||
|
}
|
||||||
|
forAll(tensorDimFlds, i)
|
||||||
|
{
|
||||||
|
tensorDimFlds[i].rename(tensorDimNames[i]);
|
||||||
|
tensorDimFlds[i].write();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
Info<< "\nEnd\n" << endl;
|
Info<< "\nEnd\n" << endl;
|
||||||
|
|
||||||
|
|||||||
@ -372,11 +372,15 @@ FoamFile
|
|||||||
// // is the master side)
|
// // is the master side)
|
||||||
// }
|
// }
|
||||||
//
|
//
|
||||||
// // Select based on surface. Orientation from normals on surface
|
// // Select based on faceSet, using supplied normal to determine orientation
|
||||||
|
// source setAndNormalToFaceZone;
|
||||||
|
// sourceInfo
|
||||||
// {
|
// {
|
||||||
// name fz0;
|
// faceSet f0; // name of faceSet
|
||||||
// type faceZoneSet;
|
// normal (1 0 0); // normal orientation
|
||||||
// action new;
|
// }
|
||||||
|
//
|
||||||
|
// // Select based on surface. Orientation from normals on surface
|
||||||
// source searchableSurfaceToFaceZone;
|
// source searchableSurfaceToFaceZone;
|
||||||
// sourceInfo
|
// sourceInfo
|
||||||
// {
|
// {
|
||||||
@ -385,7 +389,6 @@ FoamFile
|
|||||||
// radius 0.025;
|
// radius 0.025;
|
||||||
// //name sphere.stl; // Optional name if surface triSurfaceMesh
|
// //name sphere.stl; // Optional name if surface triSurfaceMesh
|
||||||
// }
|
// }
|
||||||
// }
|
|
||||||
//
|
//
|
||||||
//
|
//
|
||||||
//
|
//
|
||||||
|
|||||||
@ -308,6 +308,8 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Writing points into directory " << points.path() << nl << endl;
|
Info<< "Writing points into directory " << points.path() << nl << endl;
|
||||||
points.write();
|
points.write();
|
||||||
|
|
||||||
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -158,9 +158,7 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "OptimisationSwitches: " << currOpt << endl;
|
Info<< "OptimisationSwitches: " << currOpt << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
Info<< "done" << endl;
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -601,6 +601,53 @@ int main(int argc, char *argv[])
|
|||||||
+ vtf.size();
|
+ vtf.size();
|
||||||
|
|
||||||
|
|
||||||
|
// Construct dimensioned fields
|
||||||
|
PtrList<volScalarField::DimensionedInternalField> dsf;
|
||||||
|
PtrList<volVectorField::DimensionedInternalField> dvf;
|
||||||
|
PtrList<volSphericalTensorField::DimensionedInternalField> dSpheretf;
|
||||||
|
PtrList<volSymmTensorField::DimensionedInternalField> dSymmtf;
|
||||||
|
PtrList<volTensorField::DimensionedInternalField> dtf;
|
||||||
|
|
||||||
|
if (!specifiedFields || selectedFields.size())
|
||||||
|
{
|
||||||
|
readFields(vMesh, vMesh.baseMesh(), objects, selectedFields, dsf);
|
||||||
|
print(" volScalarFields::Internal :", Info, dsf);
|
||||||
|
|
||||||
|
readFields(vMesh, vMesh.baseMesh(), objects, selectedFields, dvf);
|
||||||
|
print(" volVectorFields::Internal :", Info, dvf);
|
||||||
|
|
||||||
|
readFields
|
||||||
|
(
|
||||||
|
vMesh,
|
||||||
|
vMesh.baseMesh(),
|
||||||
|
objects,
|
||||||
|
selectedFields,
|
||||||
|
dSpheretf
|
||||||
|
);
|
||||||
|
print(" volSphericalTensorFields::Internal :", Info, dSpheretf);
|
||||||
|
|
||||||
|
readFields
|
||||||
|
(
|
||||||
|
vMesh,
|
||||||
|
vMesh.baseMesh(),
|
||||||
|
objects,
|
||||||
|
selectedFields,
|
||||||
|
dSymmtf
|
||||||
|
);
|
||||||
|
print(" volSymmTensorFields::Internal :", Info, dSymmtf);
|
||||||
|
|
||||||
|
readFields(vMesh, vMesh.baseMesh(), objects, selectedFields, dtf);
|
||||||
|
print(" volTensorFields::Internal :", Info, dtf);
|
||||||
|
}
|
||||||
|
|
||||||
|
label nDimFields =
|
||||||
|
dsf.size()
|
||||||
|
+ dvf.size()
|
||||||
|
+ dSpheretf.size()
|
||||||
|
+ dSymmtf.size()
|
||||||
|
+ dtf.size();
|
||||||
|
|
||||||
|
|
||||||
// Construct pointMesh only if nessecary since constructs edge
|
// Construct pointMesh only if nessecary since constructs edge
|
||||||
// addressing (expensive on polyhedral meshes)
|
// addressing (expensive on polyhedral meshes)
|
||||||
if (noPointValues)
|
if (noPointValues)
|
||||||
@ -701,7 +748,7 @@ int main(int argc, char *argv[])
|
|||||||
(
|
(
|
||||||
writer.os(),
|
writer.os(),
|
||||||
vMesh.nFieldCells(),
|
vMesh.nFieldCells(),
|
||||||
1+nVolFields
|
1 + nVolFields + nDimFields
|
||||||
);
|
);
|
||||||
|
|
||||||
// Write cellID field
|
// Write cellID field
|
||||||
@ -714,13 +761,20 @@ int main(int argc, char *argv[])
|
|||||||
writer.write(vSymmtf);
|
writer.write(vSymmtf);
|
||||||
writer.write(vtf);
|
writer.write(vtf);
|
||||||
|
|
||||||
|
// Write dimensionedFields
|
||||||
|
writer.write<scalar, volMesh>(dsf);
|
||||||
|
writer.write<vector, volMesh>(dvf);
|
||||||
|
writer.write<sphericalTensor, volMesh>(dSpheretf);
|
||||||
|
writer.write<symmTensor, volMesh>(dSymmtf);
|
||||||
|
writer.write<tensor, volMesh>(dtf);
|
||||||
|
|
||||||
if (!noPointValues)
|
if (!noPointValues)
|
||||||
{
|
{
|
||||||
writeFuns::writePointDataHeader
|
writeFuns::writePointDataHeader
|
||||||
(
|
(
|
||||||
writer.os(),
|
writer.os(),
|
||||||
vMesh.nFieldPoints(),
|
vMesh.nFieldPoints(),
|
||||||
nVolFields+nPointFields
|
nVolFields + nDimFields + nPointFields
|
||||||
);
|
);
|
||||||
|
|
||||||
// pointFields
|
// pointFields
|
||||||
@ -737,6 +791,12 @@ int main(int argc, char *argv[])
|
|||||||
writer.write(pInterp, vSpheretf);
|
writer.write(pInterp, vSpheretf);
|
||||||
writer.write(pInterp, vSymmtf);
|
writer.write(pInterp, vSymmtf);
|
||||||
writer.write(pInterp, vtf);
|
writer.write(pInterp, vtf);
|
||||||
|
|
||||||
|
writer.write<scalar, volMesh>(pInterp, dsf);
|
||||||
|
writer.write<vector, volMesh>(pInterp, dvf);
|
||||||
|
writer.write<sphericalTensor, volMesh>(pInterp, dSpheretf);
|
||||||
|
writer.write<symmTensor, volMesh>(pInterp, dSymmtf);
|
||||||
|
writer.write<tensor, volMesh>(pInterp, dtf);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -94,6 +94,13 @@ public:
|
|||||||
const PtrList<GeometricField<Type, PatchField, GeoMesh> >&
|
const PtrList<GeometricField<Type, PatchField, GeoMesh> >&
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//- Write generic internal fields
|
||||||
|
template<class Type, class GeoMesh>
|
||||||
|
void write
|
||||||
|
(
|
||||||
|
const PtrList<DimensionedField<Type, volMesh> >& flds
|
||||||
|
);
|
||||||
|
|
||||||
//- Interpolate and write volFields
|
//- Interpolate and write volFields
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void write
|
void write
|
||||||
@ -101,6 +108,14 @@ public:
|
|||||||
const volPointInterpolation&,
|
const volPointInterpolation&,
|
||||||
const PtrList<GeometricField<Type, fvPatchField, volMesh> >&
|
const PtrList<GeometricField<Type, fvPatchField, volMesh> >&
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//- Interpolate and internal fields
|
||||||
|
template<class Type, class GeoMesh>
|
||||||
|
void write
|
||||||
|
(
|
||||||
|
const volPointInterpolation&,
|
||||||
|
const PtrList<DimensionedField<Type, volMesh> >&
|
||||||
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -41,6 +41,19 @@ void Foam::internalWriter::write
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
template<class Type, class GeoMesh>
|
||||||
|
void Foam::internalWriter::write
|
||||||
|
(
|
||||||
|
const PtrList<DimensionedField<Type, volMesh> >& flds
|
||||||
|
)
|
||||||
|
{
|
||||||
|
forAll(flds, i)
|
||||||
|
{
|
||||||
|
writeFuns::write(os_, binary_, flds[i], vMesh_);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void Foam::internalWriter::write
|
void Foam::internalWriter::write
|
||||||
(
|
(
|
||||||
@ -62,4 +75,25 @@ void Foam::internalWriter::write
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
template<class Type, class GeoMesh>
|
||||||
|
void Foam::internalWriter::write
|
||||||
|
(
|
||||||
|
const volPointInterpolation& pInterp,
|
||||||
|
const PtrList<DimensionedField<Type, volMesh> >& flds
|
||||||
|
)
|
||||||
|
{
|
||||||
|
forAll(flds, i)
|
||||||
|
{
|
||||||
|
writeFuns::write
|
||||||
|
(
|
||||||
|
os_,
|
||||||
|
binary_,
|
||||||
|
flds[i],
|
||||||
|
pInterp.interpolate(flds[i])(),
|
||||||
|
vMesh_
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|||||||
@ -113,7 +113,7 @@ public:
|
|||||||
(
|
(
|
||||||
std::ostream&,
|
std::ostream&,
|
||||||
const bool binary,
|
const bool binary,
|
||||||
const GeometricField<Type, fvPatchField, volMesh>&,
|
const DimensionedField<Type, volMesh>&,
|
||||||
const vtkMesh&
|
const vtkMesh&
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -135,8 +135,8 @@ public:
|
|||||||
(
|
(
|
||||||
std::ostream&,
|
std::ostream&,
|
||||||
const bool binary,
|
const bool binary,
|
||||||
const GeometricField<Type, fvPatchField, volMesh>&,
|
const DimensionedField<Type, volMesh>&,
|
||||||
const GeometricField<Type, pointPatchField, pointMesh>&,
|
const DimensionedField<Type, pointMesh>&,
|
||||||
const vtkMesh&
|
const vtkMesh&
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -150,6 +150,16 @@ public:
|
|||||||
const vtkMesh&
|
const vtkMesh&
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//- Write generic dimensioned internal fields
|
||||||
|
template<class Type>
|
||||||
|
static void write
|
||||||
|
(
|
||||||
|
std::ostream&,
|
||||||
|
const bool binary,
|
||||||
|
const PtrList<DimensionedField<Type, volMesh> >&,
|
||||||
|
const vtkMesh&
|
||||||
|
);
|
||||||
|
|
||||||
//- Interpolate and write volFields
|
//- Interpolate and write volFields
|
||||||
template<class Type>
|
template<class Type>
|
||||||
static void write
|
static void write
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -64,7 +64,7 @@ void Foam::writeFuns::write
|
|||||||
(
|
(
|
||||||
std::ostream& os,
|
std::ostream& os,
|
||||||
const bool binary,
|
const bool binary,
|
||||||
const GeometricField<Type, fvPatchField, volMesh>& vvf,
|
const DimensionedField<Type, volMesh>& vvf,
|
||||||
const vtkMesh& vMesh
|
const vtkMesh& vMesh
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
@ -79,7 +79,7 @@ void Foam::writeFuns::write
|
|||||||
|
|
||||||
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nValues);
|
DynamicList<floatScalar> fField(pTraits<Type>::nComponents*nValues);
|
||||||
|
|
||||||
insert(vvf.internalField(), fField);
|
insert(vvf, fField);
|
||||||
|
|
||||||
forAll(superCells, superCellI)
|
forAll(superCells, superCellI)
|
||||||
{
|
{
|
||||||
@ -128,8 +128,8 @@ void Foam::writeFuns::write
|
|||||||
(
|
(
|
||||||
std::ostream& os,
|
std::ostream& os,
|
||||||
const bool binary,
|
const bool binary,
|
||||||
const GeometricField<Type, fvPatchField, volMesh>& vvf,
|
const DimensionedField<Type, volMesh>& vvf,
|
||||||
const GeometricField<Type, pointPatchField, pointMesh>& pvf,
|
const DimensionedField<Type, pointMesh>& pvf,
|
||||||
const vtkMesh& vMesh
|
const vtkMesh& vMesh
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
@ -164,6 +164,22 @@ void Foam::writeFuns::write
|
|||||||
const PtrList<GeometricField<Type, PatchField, GeoMesh> >& flds,
|
const PtrList<GeometricField<Type, PatchField, GeoMesh> >& flds,
|
||||||
const vtkMesh& vMesh
|
const vtkMesh& vMesh
|
||||||
)
|
)
|
||||||
|
{
|
||||||
|
forAll(flds, i)
|
||||||
|
{
|
||||||
|
write(os, binary, flds[i].dimensionedInternalField(), vMesh);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
template<class Type>
|
||||||
|
void Foam::writeFuns::write
|
||||||
|
(
|
||||||
|
std::ostream& os,
|
||||||
|
const bool binary,
|
||||||
|
const PtrList<DimensionedField<Type, volMesh> >& flds,
|
||||||
|
const vtkMesh& vMesh
|
||||||
|
)
|
||||||
{
|
{
|
||||||
forAll(flds, i)
|
forAll(flds, i)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -390,15 +390,6 @@ class vtkPV4Foam
|
|||||||
//- Reduce memory footprint after conversion
|
//- Reduce memory footprint after conversion
|
||||||
void reduceMemory();
|
void reduceMemory();
|
||||||
|
|
||||||
//- Volume fields
|
|
||||||
void updateVolFields(vtkMultiBlockDataSet*);
|
|
||||||
|
|
||||||
//- Point fields
|
|
||||||
void updatePointFields(vtkMultiBlockDataSet*);
|
|
||||||
|
|
||||||
//- Lagrangian fields
|
|
||||||
void updateLagrangianFields(vtkMultiBlockDataSet*);
|
|
||||||
|
|
||||||
|
|
||||||
// Mesh conversion functions
|
// Mesh conversion functions
|
||||||
|
|
||||||
@ -492,6 +483,16 @@ class vtkPV4Foam
|
|||||||
|
|
||||||
// Convert OpenFOAM fields
|
// Convert OpenFOAM fields
|
||||||
|
|
||||||
|
//- Volume field - all types
|
||||||
|
template<class Type>
|
||||||
|
void convertVolField
|
||||||
|
(
|
||||||
|
const PtrList<PrimitivePatchInterpolation<primitivePatch> >&,
|
||||||
|
const GeometricField<Type, fvPatchField, volMesh>&,
|
||||||
|
const bool interpFields,
|
||||||
|
vtkMultiBlockDataSet* output
|
||||||
|
);
|
||||||
|
|
||||||
//- Volume fields - all types
|
//- Volume fields - all types
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void convertVolFields
|
void convertVolFields
|
||||||
@ -503,6 +504,17 @@ class vtkPV4Foam
|
|||||||
vtkMultiBlockDataSet* output
|
vtkMultiBlockDataSet* output
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//- Volume internal fields (DimensionedField)- all types
|
||||||
|
template<class Type>
|
||||||
|
void convertDimFields
|
||||||
|
(
|
||||||
|
const fvMesh&,
|
||||||
|
const PtrList<PrimitivePatchInterpolation<primitivePatch> >&,
|
||||||
|
const IOobjectList&,
|
||||||
|
const bool interpFields,
|
||||||
|
vtkMultiBlockDataSet* output
|
||||||
|
);
|
||||||
|
|
||||||
//- Volume field - all selected parts
|
//- Volume field - all selected parts
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void convertVolFieldBlock
|
void convertVolFieldBlock
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -143,6 +143,27 @@ void Foam::vtkPV4Foam::convertVolFields
|
|||||||
mesh, ppInterpList, objects, interpFields, output
|
mesh, ppInterpList, objects, interpFields, output
|
||||||
);
|
);
|
||||||
|
|
||||||
|
convertDimFields<scalar>
|
||||||
|
(
|
||||||
|
mesh, ppInterpList, objects, interpFields, output
|
||||||
|
);
|
||||||
|
convertDimFields<vector>
|
||||||
|
(
|
||||||
|
mesh, ppInterpList, objects, interpFields, output
|
||||||
|
);
|
||||||
|
convertDimFields<sphericalTensor>
|
||||||
|
(
|
||||||
|
mesh, ppInterpList, objects, interpFields, output
|
||||||
|
);
|
||||||
|
convertDimFields<symmTensor>
|
||||||
|
(
|
||||||
|
mesh, ppInterpList, objects, interpFields, output
|
||||||
|
);
|
||||||
|
convertDimFields<tensor>
|
||||||
|
(
|
||||||
|
mesh, ppInterpList, objects, interpFields, output
|
||||||
|
);
|
||||||
|
|
||||||
if (debug)
|
if (debug)
|
||||||
{
|
{
|
||||||
Info<< "<end> Foam::vtkPV4Foam::convertVolFields" << endl;
|
Info<< "<end> Foam::vtkPV4Foam::convertVolFields" << endl;
|
||||||
|
|||||||
@ -99,6 +99,34 @@ void Foam::vtkPV4Foam::updateInfoFields
|
|||||||
objects
|
objects
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//- Add dimensioned fields to GUI
|
||||||
|
addToSelection<DimensionedField<scalar, meshType> >
|
||||||
|
(
|
||||||
|
select,
|
||||||
|
objects
|
||||||
|
);
|
||||||
|
addToSelection<DimensionedField<vector, meshType> >
|
||||||
|
(
|
||||||
|
select,
|
||||||
|
objects
|
||||||
|
);
|
||||||
|
addToSelection<DimensionedField<sphericalTensor, meshType> >
|
||||||
|
(
|
||||||
|
select,
|
||||||
|
objects
|
||||||
|
);
|
||||||
|
addToSelection<DimensionedField<symmTensor, meshType> >
|
||||||
|
(
|
||||||
|
select,
|
||||||
|
objects
|
||||||
|
);
|
||||||
|
addToSelection<DimensionedField<tensor, meshType> >
|
||||||
|
(
|
||||||
|
select,
|
||||||
|
objects
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
// restore the enabled selections
|
// restore the enabled selections
|
||||||
setSelectedArrayEntries(select, enabledEntries);
|
setSelectedArrayEntries(select, enabledEntries);
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -34,6 +34,7 @@ InClass
|
|||||||
#include "wallPolyPatch.H"
|
#include "wallPolyPatch.H"
|
||||||
#include "faceSet.H"
|
#include "faceSet.H"
|
||||||
#include "volPointInterpolation.H"
|
#include "volPointInterpolation.H"
|
||||||
|
#include "zeroGradientFvPatchField.H"
|
||||||
|
|
||||||
#include "vtkPV4FoamFaceField.H"
|
#include "vtkPV4FoamFaceField.H"
|
||||||
#include "vtkPV4FoamPatchField.H"
|
#include "vtkPV4FoamPatchField.H"
|
||||||
@ -43,36 +44,17 @@ InClass
|
|||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class Type>
|
template<class Type>
|
||||||
void Foam::vtkPV4Foam::convertVolFields
|
void Foam::vtkPV4Foam::convertVolField
|
||||||
(
|
(
|
||||||
const fvMesh& mesh,
|
|
||||||
const PtrList<PrimitivePatchInterpolation<primitivePatch> >& ppInterpList,
|
const PtrList<PrimitivePatchInterpolation<primitivePatch> >& ppInterpList,
|
||||||
const IOobjectList& objects,
|
const GeometricField<Type, fvPatchField, volMesh>& tf,
|
||||||
const bool interpFields,
|
const bool interpFields,
|
||||||
vtkMultiBlockDataSet* output
|
vtkMultiBlockDataSet* output
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
const fvMesh& mesh = tf.mesh();
|
||||||
const polyBoundaryMesh& patches = mesh.boundaryMesh();
|
const polyBoundaryMesh& patches = mesh.boundaryMesh();
|
||||||
|
|
||||||
forAllConstIter(IOobjectList, objects, iter)
|
|
||||||
{
|
|
||||||
// restrict to GeometricField<Type, ...>
|
|
||||||
if
|
|
||||||
(
|
|
||||||
iter()->headerClassName()
|
|
||||||
!= GeometricField<Type, fvPatchField, volMesh>::typeName
|
|
||||||
)
|
|
||||||
{
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Load field
|
|
||||||
GeometricField<Type, fvPatchField, volMesh> tf
|
|
||||||
(
|
|
||||||
*iter(),
|
|
||||||
mesh
|
|
||||||
);
|
|
||||||
|
|
||||||
// Interpolated field (demand driven)
|
// Interpolated field (demand driven)
|
||||||
autoPtr<GeometricField<Type, pointPatchField, pointMesh> > ptfPtr;
|
autoPtr<GeometricField<Type, pointPatchField, pointMesh> > ptfPtr;
|
||||||
if (interpFields)
|
if (interpFields)
|
||||||
@ -85,7 +67,7 @@ void Foam::vtkPV4Foam::convertVolFields
|
|||||||
|
|
||||||
ptfPtr.reset
|
ptfPtr.reset
|
||||||
(
|
(
|
||||||
volPointInterpolation::New(tf.mesh()).interpolate(tf).ptr()
|
volPointInterpolation::New(mesh).interpolate(tf).ptr()
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -152,7 +134,7 @@ void Foam::vtkPV4Foam::convertVolFields
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
fvPatch p(ptf.patch().patch(), tf.mesh().boundary());
|
fvPatch p(ptf.patch().patch(), mesh.boundary());
|
||||||
|
|
||||||
tmp<Field<Type> > tpptf
|
tmp<Field<Type> > tpptf
|
||||||
(
|
(
|
||||||
@ -276,6 +258,101 @@ void Foam::vtkPV4Foam::convertVolFields
|
|||||||
|
|
||||||
// TODO: points
|
// TODO: points
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
template<class Type>
|
||||||
|
void Foam::vtkPV4Foam::convertVolFields
|
||||||
|
(
|
||||||
|
const fvMesh& mesh,
|
||||||
|
const PtrList<PrimitivePatchInterpolation<primitivePatch> >& ppInterpList,
|
||||||
|
const IOobjectList& objects,
|
||||||
|
const bool interpFields,
|
||||||
|
vtkMultiBlockDataSet* output
|
||||||
|
)
|
||||||
|
{
|
||||||
|
forAllConstIter(IOobjectList, objects, iter)
|
||||||
|
{
|
||||||
|
// restrict to GeometricField<Type, ...>
|
||||||
|
if
|
||||||
|
(
|
||||||
|
iter()->headerClassName()
|
||||||
|
!= GeometricField<Type, fvPatchField, volMesh>::typeName
|
||||||
|
)
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Load field
|
||||||
|
GeometricField<Type, fvPatchField, volMesh> tf
|
||||||
|
(
|
||||||
|
*iter(),
|
||||||
|
mesh
|
||||||
|
);
|
||||||
|
|
||||||
|
// Convert
|
||||||
|
convertVolField(ppInterpList, tf, interpFields, output);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
template<class Type>
|
||||||
|
void Foam::vtkPV4Foam::convertDimFields
|
||||||
|
(
|
||||||
|
const fvMesh& mesh,
|
||||||
|
const PtrList<PrimitivePatchInterpolation<primitivePatch> >& ppInterpList,
|
||||||
|
const IOobjectList& objects,
|
||||||
|
const bool interpFields,
|
||||||
|
vtkMultiBlockDataSet* output
|
||||||
|
)
|
||||||
|
{
|
||||||
|
forAllConstIter(IOobjectList, objects, iter)
|
||||||
|
{
|
||||||
|
// restrict to DimensionedField<Type, ...>
|
||||||
|
if
|
||||||
|
(
|
||||||
|
iter()->headerClassName()
|
||||||
|
!= DimensionedField<Type, volMesh>::typeName
|
||||||
|
)
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Load field
|
||||||
|
DimensionedField<Type, volMesh> dimFld(*iter(), mesh);
|
||||||
|
|
||||||
|
|
||||||
|
// Construct volField with zero-gradient patch fields
|
||||||
|
|
||||||
|
IOobject io(dimFld);
|
||||||
|
io.readOpt() = IOobject::NO_READ;
|
||||||
|
|
||||||
|
PtrList<fvPatchField<Type> > patchFields(mesh.boundary().size());
|
||||||
|
forAll(patchFields, patchI)
|
||||||
|
{
|
||||||
|
patchFields.set
|
||||||
|
(
|
||||||
|
patchI,
|
||||||
|
fvPatchField<Type>::New
|
||||||
|
(
|
||||||
|
zeroGradientFvPatchField<scalar>::typeName,
|
||||||
|
mesh.boundary()[patchI],
|
||||||
|
dimFld
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
GeometricField<Type, fvPatchField, volMesh> volFld
|
||||||
|
(
|
||||||
|
io,
|
||||||
|
dimFld.mesh(),
|
||||||
|
dimFld.dimensions(),
|
||||||
|
dimFld,
|
||||||
|
patchFields
|
||||||
|
);
|
||||||
|
volFld.correctBoundaryConditions();
|
||||||
|
|
||||||
|
convertVolField(ppInterpList, volFld, interpFields, output);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -247,6 +247,8 @@ int main(int argc, char *argv[])
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -331,7 +331,7 @@ int main(int argc, char *argv[])
|
|||||||
Info<< endl;
|
Info<< endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info<< "\ndone" << endl;
|
Info<< "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -156,7 +156,11 @@ void calc
|
|||||||
functionObjectList& fol
|
functionObjectList& fol
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
if (args.optionFound("noFlow"))
|
if (args.optionFound("noRead"))
|
||||||
|
{
|
||||||
|
fol.execute(true);
|
||||||
|
}
|
||||||
|
else if (args.optionFound("noFlow"))
|
||||||
{
|
{
|
||||||
Info<< " Operating in no-flow mode; no models will be loaded."
|
Info<< " Operating in no-flow mode; no models will be loaded."
|
||||||
<< " All vol, surface and point fields will be loaded." << endl;
|
<< " All vol, surface and point fields will be loaded." << endl;
|
||||||
|
|||||||
@ -138,6 +138,8 @@ int main(int argc, char *argv[])
|
|||||||
Info<< endl;
|
Info<< endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Info<< "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -49,6 +49,8 @@ int main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
runTime.setTime(timeDirs[timeI], timeI);
|
runTime.setTime(timeDirs[timeI], timeI);
|
||||||
|
|
||||||
|
Info<< "Time = " << runTime.timeName() << endl;
|
||||||
|
|
||||||
mesh.readUpdate();
|
mesh.readUpdate();
|
||||||
|
|
||||||
volScalarField mgb
|
volScalarField mgb
|
||||||
@ -114,8 +116,12 @@ int main(int argc, char *argv[])
|
|||||||
);
|
);
|
||||||
|
|
||||||
wdot.write();
|
wdot.write();
|
||||||
|
|
||||||
|
Info<< endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Info<< "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -105,6 +105,8 @@ int main(int argc, char *argv[])
|
|||||||
Info<< endl;
|
Info<< endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -144,7 +144,7 @@ void Foam::calc(const argList& args, const Time& runTime, const fvMesh& mesh)
|
|||||||
Info<< " Missing U or T" << endl;
|
Info<< " Missing U or T" << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info<< "\nEnd\n" << endl;
|
Info<< nl << "End" << nl << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -274,6 +274,8 @@ void Foam::calc(const argList& args, const Time& runTime, const fvMesh& mesh)
|
|||||||
{
|
{
|
||||||
Info<< " No phi" << endl;
|
Info<< " No phi" << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Info<< "End" << nl << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -74,7 +74,7 @@ int main(int argc, char *argv[])
|
|||||||
runTime.graphFormat()
|
runTime.graphFormat()
|
||||||
);
|
);
|
||||||
|
|
||||||
Info<< "end" << endl;
|
Info<< "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -612,15 +612,13 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// Read dictionary. (disable class type checking so we can load
|
// Read dictionary
|
||||||
// field)
|
// Note: disable class type checking so we can load field
|
||||||
Info<< "Loading dictionary " << fieldName << endl;
|
Info<< "Loading dictionary " << fieldName << endl;
|
||||||
const word oldTypeName = IOdictionary::typeName;
|
const word oldTypeName = IOdictionary::typeName;
|
||||||
const_cast<word&>(IOdictionary::typeName) = word::null;
|
const_cast<word&>(IOdictionary::typeName) = word::null;
|
||||||
|
|
||||||
IOdictionary fieldDict
|
IOobject fieldHeader
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
(
|
||||||
fieldName,
|
fieldName,
|
||||||
instance,
|
instance,
|
||||||
@ -628,12 +626,17 @@ int main(int argc, char *argv[])
|
|||||||
IOobject::MUST_READ_IF_MODIFIED,
|
IOobject::MUST_READ_IF_MODIFIED,
|
||||||
IOobject::NO_WRITE,
|
IOobject::NO_WRITE,
|
||||||
false
|
false
|
||||||
)
|
|
||||||
);
|
);
|
||||||
|
|
||||||
|
if (fieldHeader.headerOk())
|
||||||
|
{
|
||||||
|
IOdictionary fieldDict(fieldHeader);
|
||||||
|
|
||||||
const_cast<word&>(IOdictionary::typeName) = oldTypeName;
|
const_cast<word&>(IOdictionary::typeName) = oldTypeName;
|
||||||
|
|
||||||
// Fake type back to what was in field
|
// Fake type back to what was in field
|
||||||
const_cast<word&>(fieldDict.type()) = fieldDict.headerClassName();
|
const_cast<word&>(fieldDict.type()) =
|
||||||
|
fieldDict.headerClassName();
|
||||||
|
|
||||||
Info<< "Loaded dictionary " << fieldName
|
Info<< "Loaded dictionary " << fieldName
|
||||||
<< " with entries " << fieldDict.toc() << endl;
|
<< " with entries " << fieldDict.toc() << endl;
|
||||||
@ -648,6 +651,13 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Writing modified fieldDict " << fieldName << endl;
|
Info<< "Writing modified fieldDict " << fieldName << endl;
|
||||||
fieldDict.regIOobject::write();
|
fieldDict.regIOobject::write();
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
WarningIn(args.executable())
|
||||||
|
<< "Requested field to change " << fieldName
|
||||||
|
<< " does not exist in " << fieldHeader.path() << endl;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
entry::disableFunctionEntries = oldFlag;
|
entry::disableFunctionEntries = oldFlag;
|
||||||
|
|||||||
@ -72,7 +72,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
U.write();
|
U.write();
|
||||||
|
|
||||||
Info<< "\n end\n";
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -2,8 +2,8 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -2,8 +2,8 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -2,8 +2,8 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -2,8 +2,8 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd.
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
This file is part of OpenFOAM.
|
This file is part of OpenFOAM.
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -127,7 +127,7 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Kc(EQreactions) = " << iter().Kc(P, T) << endl;
|
Info<< "Kc(EQreactions) = " << iter().Kc(P, T) << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info<< nl << "end" << endl;
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -273,7 +273,7 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Info<< nl << "end" << endl;
|
Info<< nl << "End" << nl << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user