Go to the source code of this file.
Functions | |
std::ifstream | kivaFile (kivaFileName) |
if (!kivaFile.good()) | |
pointField | points (nPoints) |
labelList | idface (nPoints) |
labelList | fv (nPoints) |
for (label i=0;i< nPoints;i++) | |
labelList | i1tab (nPoints) |
labelList | i3tab (nPoints) |
labelList | i8tab (nPoints) |
labelList | idreg (nPoints) |
labelList | f (nPoints) |
labelList | bcl (nPoints) |
labelList | bcf (nPoints) |
labelList | bcb (nPoints) |
if (mTable==0) | |
labelList | imtab (nPoints) |
labelList | jmtab (nPoints) |
labelList | kmtab (nPoints) |
face | quadFace (4) |
face | triFace (3) |
if (pFaces[LINER].size() &&pFaces[LINER][0].size() &&pFaces[CYLINDERHEAD].size() &&pFaces[CYLINDERHEAD][0].size()) | |
if (pFaces[WEDGE].size() &&pFaces[WEDGE][0].size()) | |
faceListList | boundary (nPatches) |
wordList | patchNames (nPatches) |
wordList | patchTypes (nPatches) |
labelList | pointLabels (nPoints, -1) |
forAll (cellShapes, celli) | |
forAll (pointLabels, pointi) | |
points | setSize (newPointi) |
forAll (boundary, patchi) | |
preservePatchTypes (runTime, runTime.constant(), polyMesh::meshSubDir, patchNames, patchDicts, defaultFacesName, defaultFacesType) | |
forAll (patchNames, patchi) | |
polyMesh | pShapeMesh (IOobject(polyMesh::defaultRegion, runTime.constant(), runTime), std::move(points), cellShapes, boundary, patchNames, patchDicts, defaultFacesName, defaultFacesType) |
Variables | |
Info<< "Reading kiva grid from file "<< kivaFileName<< endl;char title[120];kivaFile.getline(title, 120, '\n');label nPoints, nCells, nRegs;kivaFile > nCells nPoints | nRegs |
label | i4 |
label | nBfaces = 0 |
label | mTable |
Info<< "Finished reading KIVA file"<< endl;cellShapeList cellShapes(nPoints);labelList cellZoning(nPoints, -1);const cellModel &hex=cellModel::ref(cellModel::HEX);labelList hexLabels(8);label activeCells=0;labelList pointMap(nPoints);forAll(pointMap, i){ pointMap[i]=i;}for(label i=0;i< nPoints;i++){ if(f[i] > 0.0) { hexLabels[0]=i;hexLabels[1]=i1tab[i];hexLabels[2]=i3tab[i1tab[i]];hexLabels[3]=i3tab[i];hexLabels[4]=i8tab[i];hexLabels[5]=i1tab[i8tab[i]];hexLabels[6]=i3tab[i1tab[i8tab[i]]];hexLabels[7]=i3tab[i8tab[i]];cellShapes[activeCells].reset(hex, hexLabels);edgeList edges=cellShapes[activeCells].edges();forAll(edges, ei) { if(edges[ei].mag(points)< SMALL) { label start=pointMap[edges[ei].start()];while(start !=pointMap[start]) { start=pointMap[start];} label end=pointMap[edges[ei].end()];while(end !=pointMap[end]) { end=pointMap[end];} label minLabel=min(start, end);pointMap[start]=pointMap[end]=minLabel;} } cellZoning[activeCells]=idreg[i];activeCells++;}}cellShapes.setSize(activeCells);cellZoning.setSize(activeCells);forAll(cellShapes, celli){ cellShape &cs=cellShapes[celli];forAll(cs, i) { cs[i]=pointMap[cs[i]];} cs.collapse();}label bcIDs[11]={-1, 0, 2, 4, -1, 5, -1, 6, 7, 8, 9};const label nBCs=12;const word *kivaPatchTypes[nBCs]={ &wallPolyPatch::typeName, &wallPolyPatch::typeName, &wallPolyPatch::typeName, &wallPolyPatch::typeName, &symmetryPolyPatch::typeName, &wedgePolyPatch::typeName, &polyPatch::typeName, &polyPatch::typeName, &polyPatch::typeName, &polyPatch::typeName, &symmetryPolyPatch::typeName, &oldCyclicPolyPatch::typeName};enum patchTypeNames{ PISTON, VALVE, LINER, CYLINDERHEAD, AXIS, WEDGE, INFLOW, OUTFLOW, PRESIN, PRESOUT, SYMMETRYPLANE, CYCLIC};const char *kivaPatchNames[nBCs]={ "piston", "valve", "liner", "cylinderHead", "axis", "wedge", "inflow", "outflow", "presin", "presout", "symmetryPlane", "cyclic"};List< SLList< face > > | pFaces [nBCs] |
label | nPatches = 0 |
word | defaultFacesName = "defaultFaces" |
word | defaultFacesType = emptyPolyPatch::typeName |
label | nAddedPatches = 0 |
label | newPointi = 0 |
PtrList< dictionary > | patchDicts |
std::ifstream kivaFile | ( | kivaFileName | ) |
if | ( | !kivaFile. | good() | ) |
Definition at line 3 of file readKivaGrid.H.
References Foam::exit(), Foam::FatalError, and FatalErrorInFunction.
pointField points | ( | nPoints | ) |
labelList idface | ( | nPoints | ) |
labelList fv | ( | nPoints | ) |
for | ( | ) |
Definition at line 23 of file readKivaGrid.H.
References fv(), i4, idface(), kivaFile(), and points().
labelList i1tab | ( | nPoints | ) |
labelList i3tab | ( | nPoints | ) |
labelList i8tab | ( | nPoints | ) |
labelList idreg | ( | nPoints | ) |
labelList f | ( | nPoints | ) |
Referenced by dynamicOversetFvMesh::active(), isoSurfacePoint::adaptPatchFields(), multivariateSurfaceInterpolationScheme< Type >::fieldTable::add(), singleProcessorFaceSets::add(), vtmWriter::add(), polyMeshAdder::add(), polyTopoChange::addFace(), dynamicOversetFvMesh::addInterpolation(), snappyLayerDriver::addLayers(), unwatchedIOdictionary::addWatch(), regIOobject::addWatch(), fileOperation::addWatches(), masterUncollatedFileOperation::addWatches(), polyMeshTetDecomposition::adjustTetBasePtIs(), singleProcessorFaceSets::apply(), fvPatchField< vector >::autoMap(), Foam::average(), averageNeighbourFvGeometryScheme::averageCentres(), patchMeshWriter::beginPiece(), booleanSurface::booleanSurface(), primitiveMeshTools::boundaryFaceSkewness(), searchableBox::boundingSpheres(), triSurfaceMesh::boundingSpheres(), nearWallFields::calcAddressing(), PatchTools::calcBounds(), BrownianMotionForce< CloudType >::calcCoupled(), cellMatcher::calcEdgeAddressing(), coupledPolyPatch::calcFaceTol(), triSurfaceTools::calcInterpolationWeights(), cellMatcher::calcLocalFaces(), cellMatcher::calcPointFaceIndex(), primitiveMesh::calcPointOrder(), createShellMesh::calcPointRegions(), cutFace::calcSubFace(), cutFacePLIC::calcSubFace(), cutFaceIso::calcSubFace(), cutFaceAdvect::calcSubFace(), MUCSheterogeneousRate< CloudType >::calculate(), rotorDiskSource::calculate(), nutUSpaldingWallFunctionFvPatchScalarField::calcUTau(), pointMVCWeight::calcWeights(), inverseDistance::cellBb(), cellMatcher::cellMatcher(), cell::centre(), cellModel::centre(), repatchPolyTopoChanger::changeAnchorPoint(), primitiveMesh::checkCellsZipUp(), primitiveMesh::checkEdgeLength(), primitiveMeshGeometry::checkFaceAngles(), polyMeshGeometry::checkFaceAngles(), polyMeshGeometry::checkFaceFlatness(), primitiveMeshGeometry::checkFacePyramids(), polyMeshGeometry::checkFacePyramids(), primitiveMesh::checkFacePyramids(), MeshedSurface< Foam::face >::checkFaces(), Foam::checkFaceSizeMatch(), polyMeshTetDecomposition::checkFaceTets(), primitiveMeshGeometry::checkFaceTwist(), polyMeshGeometry::checkFaceTwist(), primitiveMesh::checkFaceVertices(), Foam::checkFireEdges(), hexRef8::checkMesh(), edgeCollapser::checkMeshQuality(), PatchTools::checkOrientation(), searchableSurfaces::checkQuality(), triSurface::checkTriangles(), polyMeshGeometry::checkTriangleTwist(), TomiyamaLift::Cl(), averageNeighbourFvGeometryScheme::clipFaceTet(), Foam::cmptAv(), Foam::cmptMag(), Foam::cmptMagSqr(), Foam::cmptMax(), Foam::cmptMin(), cellShape::collapsedFaces(), triSurfaceTools::collapseEdges(), ORourkeCollision< CloudType >::collideSorted(), triSurface::compactPoints(), MeshedSurface< Foam::face >::compactPoints(), Foam::component(), processorLduInterface::compressedReceive(), processorLduInterface::compressedSend(), edgeCollapser::consistentCollapse(), inversePointDistanceDiffusivity::correct(), CentredFitScheme< Type, Polynomial, Stencil >::correction(), pointLinear< Type >::correction(), Foam::countConnectivity(), removePoints::countPointUsage(), wallBoundedParticle::crossDiagonalEdge(), wallBoundedParticle::crossEdgeConnectedFace(), STARCDMeshReader::cullPoints(), wallBoundedParticle::currentEdge(), triSurfaceTools::curvatures(), cutFaceAdvect::cutPoints(), decompositionMethod::decompose(), meshRefinement::doSplitFaces(), meshRefinement::dupNonManifoldBoundaryPoints(), primitiveMesh::edgeFaces(), PatchTools::edgeOwner(), directionInfo::edgeToFaceIndex(), directionInfo::enterDomain(), multiRegion::execute(), turbulenceFields::execute(), hexCell::face(), Patch::faceCentres(), primitiveMeshTools::faceConcavity(), NASCore::faceDecomposition(), ABAQUSCore::faceDecomposition(), primitiveMesh::faceEdges(), primitiveMeshTools::faceFlatness(), hexRef8::faceLevel(), Patch::faceNormals(), mappedPatchBase::facePoint(), primitiveMeshTools::facePyramidVolume(), hexCell::faces(), Foam::vtk::Tools::Faces(), primitiveMeshTools::faceSkewness(), polyMeshTetDecomposition::faceTetIndices(), faceTriangulation::faceTriangulation(), tetIndices::faceTriIs(), fieldSelection::filters(), polyMeshTetDecomposition::findBasePoint(), localPointRegion::findDuplicateFaces(), patchProbes::findElements(), FitData< CentredFitSnGradData< Polynomial >, extendedCentredCellToFaceStencil, Polynomial >::findFaceDirs(), treeDataPrimitivePatch< PatchType >::findIntersection(), meshSearch::findNearestBoundaryFace(), wallBoundedStreamLine::findNearestTet(), sampledSet::findNearFace(), polyMeshTetDecomposition::findSharedBasePoint(), polyMeshTetDecomposition::findTet(), OSstream::flags(), ISstream::flags(), forAll(), pairPotentialList::force(), pairPotential::force(), noiseFFT::frequencies(), noiseModel::gainA(), noiseModel::gainB(), noiseModel::gainC(), noiseModel::gainD(), PatchTools::gatherAndMerge(), Foam::gAverage(), isoSurfacePoint::generateFaceTriPoints(), ensightSurfaceReader::geometry(), coupledPolyPatch::getAnchorPoints(), isoSurfaceBase::getCellCutType(), snappySnapDriver::getFacePoints(), Foam::ensightOutput::Detail::getFaceSizes(), surfaceSets::getHangingCells(), edgeFaceCirculator::getMinIndex(), boundaryMesh::getNearest(), boundaryMesh::getNTris(), cellDistFuncs::getPointNeighbours(), coupledPolyPatch::getRotation(), hexRef8::getSplitPoints(), treeDataFace::getVolumeType(), treeDataPrimitivePatch< PatchType >::getVolumeType(), wallBoundedParticle::hitProcessorPatch(), FreeStream< CloudType >::inflow(), dynamicRefineFvMesh::init(), turbulenceFields::initialise(), waveModel::initialiseGeometry(), streamLineBase::initInterpolations(), processorPolyPatch::initUpdateMesh(), blendedInterfacialModel::interpolate(), dynamicOversetFvMesh::interpolate(), patchTransformedInterpolation::interpolate(), meshToMesh0::interpolateField(), Foam::interpolatePointToCell(), meshRefinement::intersectedPoints(), face::intersection(), fileOperation::isFileOrDir(), isoSurfacePoint::isoSurfacePoint(), isoSurfaceTopo::isoSurfaceTopo(), triSurfaceMesh::isSurfaceClosed(), Foam::levelSetFraction(), triSurfaceLoader::load(), cell::mag(), Foam::mag(), cellModel::mag(), Foam::magSqr(), highAspectRatioFvGeometryScheme::makeAverageCentres(), primitiveMeshTools::makeFaceCentresAndAreas(), stabilisedFvGeometryScheme::makeFaceCentresAndAreas(), Field< Foam::Vector2D >::map(), volSurfaceMapping::mapToField(), volSurfaceMapping::mapToSurface(), edgeCollapser::markFaceZoneEdges(), edgeCollapser::markSmallSliverFaces(), momentOfInertia::massPropertiesPatch(), Foam::max(), Foam::maxMagSqr(), noiseFFT::meanPf(), propellerInfo::meanSampleDiskField(), polyMeshAdder::mergePoints(), triSurfaceTools::mergePoints(), Foam::min(), Foam::minMagSqr(), Foam::minMax(), Foam::minMaxMag(), polyMeshTetDecomposition::minQuality(), hexCell::modelFaces(), tetCell::modelFaces(), polyTopoChange::modifyFace(), solidParticle::move(), findCellParticle::move(), trackedParticle::move(), DSMCParcel< ParcelType >::move(), MPPICParcel< ParcelType >::move(), molecule::move(), KinematicParcel< ParcelType >::move(), regionModel1D::moveMesh(), cyclicAMIFvPatch::movePoints(), primitiveMesh::movePoints(), multiSolidBodyMotionSolver::multiSolidBodyMotionSolver(), face::nearestPointClassify(), Field< Foam::Vector2D >::NewCalculatedType(), MeshedSurfaceProxy< Face >::nTriangles(), MeshedSurface< Foam::face >::nTriangles(), noiseFFT::octaveBandInfo(), noiseFFT::octaves(), noiseModel::octaves(), isotropic::oneByTau(), nonEquilibrium::oneByTau(), ConstMatrixBlock< MatrixType >::operator Field< cmptType >(), MatrixBlock< MatrixType >::operator Field< cmptType >(), spatialTransform::transpose::operator&(), spatialTransform::dual::operator&(), findNearestMaskedOp< PatchType >::operator()(), treeDataPrimitivePatch< PatchType >::findNearestOp::operator()(), treeDataFace::findNearestOp::operator()(), FieldMapper::operator()(), treeDataCell::findIntersectOp::operator()(), treeDataPrimitivePatch< PatchType >::findSelfIntersectOp::operator()(), Field< Foam::Vector2D >::operator/=(), Foam::operator<<(), MatrixBlock< MatrixType >::operator=(), Foam::operator>>(), Foam::operator^(), triSurfaceTools::oppositeVertex(), oldCyclicPolyPatch::order(), triSurfaceTools::otherVertices(), distributedTriSurfaceMesh::overlappingSurface(), searchableRotatedBox::overlaps(), treeDataFace::overlaps(), treeDataPrimitivePatch< PatchType >::overlaps(), Pair< word >::Pair(), CollisionRecordList< vector, vector >::pairAccessed(), CollisionRecordList< vector, vector >::pairData(), CollisionRecordList< vector, vector >::pairOrigIdOfOther(), CollisionRecordList< vector, vector >::pairOrigProcOfOther(), KinematicCloud< Cloud< basicKinematicCollidingParcel > >::patchData(), faPatch::patchInternalField(), fvPatch::patchInternalField(), LBFGS::pivotFields(), polyMesh::pointInCell(), primitiveMesh::pointInCell(), pointMVCWeight::pointMVCWeight(), PatchTools::pointNormals(), FaceInteraction< CloudType >::postFace(), Foam::pow(), Foam::printTriangle(), pointNoise::processData(), noiseFFT::PSDf(), noiseModel::RAf(), face::ray(), noiseModel::RBf(), noiseModel::RCf(), noiseModel::RDf(), OBJsurfaceFormat< Face >::read(), OFFsurfaceFormat< Face >::read(), AC3DsurfaceFormat< Face >::read(), STARCDsurfaceFormat< Face >::read(), NASsurfaceFormat< Face >::read(), VTKsurfaceFormat< Face >::read(), multiRegion::read(), energySpectrum::read(), boundaryMesh::read(), wallBoundedStreamLine::read(), turbulenceFields::read(), STARCDMeshReader::readCells(), triSurfaceLoader::readDir(), FIREMeshReader::readFaces(), DimensionedField< Type, Foam::pointMesh >::readField(), CollidingParcel< ParcelType >::readFields(), liquidProperties::readIfPresent(), CollidingParcel< ParcelType >::readObjects(), processorLduInterface::receive(), fileName::relative(), surfaceFormatsCore::relativeFilePath(), triSurface::relativeFilePath(), snappySnapDriver::repatchToSurface(), vtuSizing::reset(), ODESolver::resizeField(), includeEtcEntry::resolveEtcFile(), includeEntry::resolveFile(), faceAreaWeightAMI::restartUncoveredSourceFace(), Foam::rewritePatchLabels(), Field< Foam::Vector2D >::rmap(), noiseFFT::RMSmeanPf(), edgeFaceCirculator::sameOrder(), sampledSurface::sampleOnPoints(), sampledPatch::sampleOnPoints(), sampledFaceZone::sampleOnPoints(), processorLduInterface::send(), edgeFaceCirculator::setCanonical(), IOstream::setf(), noiseModel::setOctaveBands(), duplicatePoints::setRefinement(), removeCells::setRefinement(), perfectInterface::setRefinement(), faceCollapser::setRefinement(), removePoints::setRefinement(), boundaryCutter::setRefinement(), createShellMesh::setRefinement(), combineFaces::setRefinement(), tetDecomposer::setRefinement(), removeFaces::setRefinement(), meshCutAndRemove::setRefinement(), meshCutter::setRefinement(), edgeCollapser::setRefinement(), addPatchCellLayer::setRefinement(), hexRef8::setRefinement(), combineFaces::setUnrefinement(), ThermoCloud< Foam::DSMCCloud >::sigmap(), sizeGroup::sizeGroup(), solidBodyMotionSolver::solidBodyMotionSolver(), sixDoFRigidBodyMotionSolver::solve(), rigidBodyMeshMotionSolver::solve(), rigidBodyMeshMotion::solve(), PatchTools::sortedEdgeFaces(), noiseModel::SPL(), Foam::sqr(), AMIInterpolation::srcPointFace(), Foam::stabilise(), MeshedSurface< Foam::face >::stitchFaces(), Foam::sum(), Foam::sumCmptMag(), Foam::sumMag(), Foam::sumSqr(), triSurfaceTools::surfaceNormal(), triSurfaceTools::surfaceSide(), SVD::SVD(), swapec(), face::symmhash_code(), syncTools::syncEdgeMap(), Foam::T(), Foam::tetCutPrism0(), Foam::tetCutPrism01(), Foam::tetCutPrism23(), Foam::tetCutTet(), AMIInterpolation::tgtPointFace(), cutFaceAdvect::timeIntegratedFaceFlux(), fileName::toAbsolute(), particle< Type >::track(), wallBoundedParticle::trackToEdge(), particle< Type >::trackToFace(), cyclicACMILduInterfaceField::transformCoupleField(), cyclicAMILduInterfaceField::transformCoupleField(), cyclicLduInterfaceField::transformCoupleField(), processorLduInterfaceField::transformCoupleField(), cyclicFaPatchField< Type >::transformCoupleField(), processorFaPatchField< Type >::transformCoupleField(), faceAreaIntersect::triangleFan(), faceAreaIntersect::triangulate(), boundaryMesh::triangulate(), triSurfaceTools::triangulate(), MeshedSurface< Foam::face >::triangulate(), triSurfaceTools::triangulateFaceCentre(), boundaryMesh::triangulateLocal(), advancingFrontAMI::triangulatePatch(), Foam::triCutQuad(), Foam::triCutTri(), tetIndices::triIs(), noiseModel::uniformFrequencies(), IOstream::unsetf(), MPPICParcel< ParcelType >::trackingData::updateAverages(), KinematicParcel< ParcelType >::trackingData::updateAverages(), directionInfo::updateCell(), sixDoFRigidBodyDisplacementPointPatchVectorField::updateCoeffs(), outletMappedUniformInletFvPatchField< Type >::updateCoeffs(), patchFaceOrientation::updateEdge(), patchEdgeFaceRegions::updateEdge(), patchFaceOrientation::updateFace(), patchEdgeFaceRegions::updateFace(), patchInjectionBase::updateMesh(), processorPolyPatch::updateMesh(), removePoints::updateMesh(), combineFaces::updateMesh(), exprResultDelayed::updateReadValue(), triSurfaceTools::validTri(), triSurfaceTools::vertexNormals(), triSurfaceTools::vertexNormalWeight(), surfaceIteratorPLIC::vofCutCell(), surfaceIteratorIso::vofCutCell(), cuttingSurfaceBase::walkCellCuts(), CollisionRecordList< vector, vector >::wallAccessed(), CollisionRecordList< vector, vector >::wallData(), wallLayerCells::wallLayerCells(), CollisionRecordList< vector, vector >::wallPRel(), FLMAsurfaceFormat< Face >::write(), X3DsurfaceFormat< Face >::write(), OBJsurfaceFormat< Face >::write(), SMESHsurfaceFormat< Face >::write(), OFFsurfaceFormat< Face >::write(), TRIsurfaceFormat< Face >::write(), ABAQUSsurfaceFormat< Face >::write(), STARCDsurfaceFormat< Face >::write(), NASsurfaceFormat< Face >::write(), mesh::write(), VTKsurfaceFormat< Face >::write(), VTPsurfaceFormat< Face >::write(), OBJstream::write(), multiRegion::write(), rawWriter::write(), gltfSetWriter< Type >::write(), ensightFaces::write(), multiFieldValue::write(), turbulenceFields::write(), STLsurfaceFormat< Face >::writeAscii(), STLsurfaceFormat< Face >::writeBinary(), forces::writeBinnedForceMoment(), box::writeBoxes(), Foam::ensightOutput::writeFaceList(), CollidingParcel< ParcelType >::writeFields(), fieldAverage::writeFieldType(), isoAdvection::writeIsoFaces(), AABBTree< Type >::writeOBJ(), coupledPolyPatch::writeOBJ(), Foam::meshTools::writeOBJ(), enrichedPatch::writeOBJ(), CollidingParcel< ParcelType >::writeObjects(), patchMeshWriter::writePolys(), patchMeshWriter::writePolysLegacy(), Foam::ensightOutput::writePolysPoints(), gltfSetWriter< Type >::writeStaticTracks(), triSurface::writeStats(), MeshedSurface< Foam::face >::writeStats(), abaqusWriter::writeTemplate(), rawWriter::writeTemplate(), nastranWriter::writeTemplate(), x3dWriter::writeTemplate(), noiseModel::writeWeightings(), Foam::writeZone(), alphatJayatillekeWallFunctionFvPatchScalarField::yPlusTherm(), alphatPhaseChangeJayatillekeWallFunctionFvPatchScalarField::yPlusTherm(), and zoneMotion::zoneMotion().
labelList bcl | ( | nPoints | ) |
labelList bcf | ( | nPoints | ) |
labelList bcb | ( | nPoints | ) |
if | ( | mTable | = = 0 | ) |
Definition at line 77 of file readKivaGrid.H.
References Foam::exit(), Foam::FatalError, and FatalErrorInFunction.
labelList imtab | ( | nPoints | ) |
labelList jmtab | ( | nPoints | ) |
labelList kmtab | ( | nPoints | ) |
face quadFace | ( | 4 | ) |
face triFace | ( | 3 | ) |
Referenced by tetCell::face(), tetIndices::faceTriIs(), if(), momentOfInertia::massPropertiesPatch(), momentOfInertia::massPropertiesShell(), momentOfInertia::massPropertiesSolid(), triFace::reverseFace(), MeshedSurface< Foam::face >::transcribe(), tetIndices::triIs(), and patchInjectionBase::updateMesh().
if | ( | pFaces. | size() &&pFaces.size() &&pFaces.size() &&pFaces.size()[LINER][LINER][0][CYLINDERHEAD][CYLINDERHEAD][0] | ) |
Definition at line 321 of file readKivaGrid.H.
References Foam::endl(), forAll(), Foam::Info, Foam::min(), pFaces, and points().
if | ( | pFaces. | size() &&pFaces.size()[WEDGE][WEDGE][0] | ) |
Definition at line 410 of file readKivaGrid.H.
References cellShapes, Foam::degToRad(), nPatches, pFaces, points(), and Foam::tan().
faceListList boundary | ( | nPatches | ) |
wordList patchNames | ( | nPatches | ) |
Referenced by snappyRefineDriver::addFaceZones(), polyBoundaryMesh::checkDefinition(), ensightMesh::correct(), extrudePatchMesh::extrudePatchMesh(), cellDistFuncs::getPatchIDs(), voxelMeshSearch::makeMesh(), Foam::nonProcessorPatchNames(), ParticleErosion< CloudType >::ParticleErosion(), patchInjection::patchInjection(), polyBoundaryMesh::patchSet(), Foam::preservePatchTypes(), fieldExtents::read(), fvMeshSubset::setCellSubset(), and wallLayerCells::wallLayerCells().
wordList patchTypes | ( | nPatches | ) |
Referenced by age::execute(), extrudePatchMesh::extrudePatchMesh(), forAll(), cellVolumeWeight::interpolatePatchTypes(), trackingInverseDistance::markBoundaries(), inverseDistance::markBoundaries(), cellVolumeWeight::update(), and searchableSurfaces::writeStats().
labelList pointLabels | ( | nPoints | , |
- | 1 | ||
) |
Referenced by polyMeshAdder::add(), polyTopoChange::addMesh(), setToPointZone::applyToSet(), faPatch::calcPointEdges(), cellModel::centre(), cellModel::edge(), cellModel::edges(), cellModel::face(), cellModel::faces(), forAll(), processorFaPatch::initUpdateMesh(), cell::labels(), cellModel::mag(), processorFaPatch::makeNonGlobalPatchPoints(), surfaceFeatures::nearestSamples(), cell::points(), lumpedPointMovement::setInterpolator(), lumpedPointMovement::setPatchControl(), globalMeshData::sharedPointGlobalLabels(), globalMeshData::sharedPoints(), processorFaPatch::updateMesh(), coupledPolyPatch::writeOBJ(), and Foam::vtk::writePointSet().
forAll | ( | cellShapes | , |
celli | |||
) |
Definition at line 487 of file readKivaGrid.H.
References cellShapes, and pointLabels().
Referenced by forAll(), and if().
forAll | ( | pointLabels | , |
pointi | |||
) |
Definition at line 497 of file readKivaGrid.H.
References newPointi, pointLabels(), and points().
Referenced by polyTopoChanger::addTopologyModifiers(), Field< Foam::Vector2D >::autoMap(), tetherPotentialList::buildPotentials(), pairPotentialList::buildPotentials(), coalCloudList::coalCloudList(), face::collapse(), CompactIOField< T, BaseType >::CompactIOField(), CompactIOList< face, label >::CompactIOList(), nearWallDist::correct(), patchPatchDist::correct(), faceTriangulation::faceTriangulation(), forceList::forceList(), GlobalIOField< vector >::GlobalIOField(), GlobalIOList< kinematicParcelInjectionData >::GlobalIOList(), processorFvPatchField< Type >::initEvaluate(), calculatedProcessorFvPatchField< Type >::initEvaluate(), injectionModelList::injectionModelList(), IOField< Type >::IOField(), IOList< labelList >::IOList(), IOMap< T >::IOMap(), Field< Foam::Vector2D >::map(), profileModelList::profileModelList(), GeometricField< Type, PatchField, GeoMesh >::Boundary::readField(), regionModelFunctionObjectList::regionModelFunctionObjectList(), CompactListList< T, Container >::resize(), ParSortableList< Type >::sort(), transferModelList::transferModelList(), and uniformInterpolationTable< scalar >::uniformInterpolationTable().
forAll | ( | boundary | , |
patchi | |||
) |
Definition at line 519 of file readKivaGrid.H.
References boundary(), f(), forAll(), and pointLabels().
preservePatchTypes | ( | runTime | , |
runTime. | constant(), | ||
polyMesh::meshSubDir | , | ||
patchNames | , | ||
patchDicts | , | ||
defaultFacesName | , | ||
defaultFacesType | |||
) |
forAll | ( | patchNames | , |
patchi | |||
) |
Definition at line 544 of file readKivaGrid.H.
References patchDicts, and patchTypes().
polyMesh pShapeMesh | ( | IOobject(polyMesh::defaultRegion, runTime.constant(), runTime) | , |
std::move(points) | , | ||
cellShapes | , | ||
boundary | , | ||
patchNames | , | ||
patchDicts | , | ||
defaultFacesName | , | ||
defaultFacesType | |||
) |
Info<< "Reading kiva grid from file " << kivaFileName << endl;char title[120];kivaFile.getline(title, 120, '\n');label nPoints, nCells, nRegs;kivaFile > nCells nPoints nRegs |
Definition at line 17 of file readKivaGrid.H.
label i4 |
Definition at line 20 of file readKivaGrid.H.
Referenced by for().
label nBfaces = 0 |
Definition at line 45 of file readKivaGrid.H.
kivaFile mTable |
Definition at line 74 of file readKivaGrid.H.
Info<< "Finished reading KIVA file" << endl;cellShapeList cellShapes(nPoints);labelList cellZoning(nPoints, -1);const cellModel& hex = cellModel::ref(cellModel::HEX);labelList hexLabels(8);label activeCells = 0;labelList pointMap(nPoints);forAll(pointMap, i){ pointMap[i] = i;}for (label i=0; i<nPoints; i++){ if (f[i] > 0.0) { hexLabels[0] = i; hexLabels[1] = i1tab[i]; hexLabels[2] = i3tab[i1tab[i]]; hexLabels[3] = i3tab[i]; hexLabels[4] = i8tab[i]; hexLabels[5] = i1tab[i8tab[i]]; hexLabels[6] = i3tab[i1tab[i8tab[i]]]; hexLabels[7] = i3tab[i8tab[i]]; cellShapes[activeCells].reset(hex, hexLabels); edgeList edges = cellShapes[activeCells].edges(); forAll(edges, ei) { if (edges[ei].mag(points) < SMALL) { label start = pointMap[edges[ei].start()]; while (start != pointMap[start]) { start = pointMap[start]; } label end = pointMap[edges[ei].end()]; while (end != pointMap[end]) { end = pointMap[end]; } label minLabel = min(start, end); pointMap[start] = pointMap[end] = minLabel; } } cellZoning[activeCells] = idreg[i]; activeCells++; }}cellShapes.setSize(activeCells);cellZoning.setSize(activeCells);forAll(cellShapes, celli){ cellShape& cs = cellShapes[celli]; forAll(cs, i) { cs[i] = pointMap[cs[i]]; } cs.collapse();}label bcIDs[11] = {-1, 0, 2, 4, -1, 5, -1, 6, 7, 8, 9};const label nBCs = 12;const word* kivaPatchTypes[nBCs] ={ &wallPolyPatch::typeName, &wallPolyPatch::typeName, &wallPolyPatch::typeName, &wallPolyPatch::typeName, &symmetryPolyPatch::typeName, &wedgePolyPatch::typeName, &polyPatch::typeName, &polyPatch::typeName, &polyPatch::typeName, &polyPatch::typeName, &symmetryPolyPatch::typeName, &oldCyclicPolyPatch::typeName};enum patchTypeNames{ PISTON, VALVE, LINER, CYLINDERHEAD, AXIS, WEDGE, INFLOW, OUTFLOW, PRESIN, PRESOUT, SYMMETRYPLANE, CYCLIC};const char* kivaPatchNames[nBCs] ={ "piston", "valve", "liner", "cylinderHead", "axis", "wedge", "inflow", "outflow", "presin", "presout", "symmetryPlane", "cyclic"};List<SLList<face> > pFaces[nBCs] |
Definition at line 235 of file readKivaGrid.H.
Referenced by singleProcessorFaceSets::add(), singleProcessorFaceSets::apply(), snappySnapDriver::avgCellCentres(), Foam::meshTools::calcBoxPointNormals(), polyMeshTetDecomposition::cellTetIndices(), PrimitivePatch<::Foam::List< labelledTri >, pointField >::checkPointManifold(), wallBoundedParticle::crossEdgeConnectedFace(), decompositionMethod::decompose(), polyMeshTetDecomposition::faceTetIndices(), cellClassification::fillRegionPoints(), polyMeshTetDecomposition::findBasePoint(), localPointRegion::findDuplicateFaces(), polyMeshTetDecomposition::findSharedBasePoint(), polyMeshTetDecomposition::findTet(), cellLooper::getVertFacesNonEdge(), treeDataFace::getVolumeType(), if(), volPointInterpolation::interpolateBoundaryField(), triSurfaceMesh::isSurfaceClosed(), mappedPolyPatch::newInternalProcFaces(), mappedWallPolyPatch::newInternalProcFaces(), oldCyclicPolyPatch::order(), boundaryMesh::patchify(), primitiveMesh::pointCells(), PatchTools::pointNormals(), Foam::polyMeshZipUpCells(), perfectInterface::setRefinement(), removePoints::setRefinement(), hexRef8::setUnrefinement(), triSurfaceTools::trackToEdge(), dynamicRefineFvMesh::unrefine(), and triSurfaceTools::vertexNormals().
label nPatches = 0 |
Definition at line 396 of file readKivaGrid.H.
Referenced by if().
word defaultFacesName = "defaultFaces" |
Definition at line 455 of file readKivaGrid.H.
Referenced by Foam::preservePatchTypes().
word defaultFacesType = emptyPolyPatch::typeName |
Definition at line 456 of file readKivaGrid.H.
Referenced by Foam::preservePatchTypes().
label nAddedPatches = 0 |
Definition at line 458 of file readKivaGrid.H.
label newPointi = 0 |
Definition at line 496 of file readKivaGrid.H.
Referenced by extendedEdgeMesh::add(), polyTopoChange::changeMesh(), extendedEdgeMesh::flipNormals(), forAll(), triSurfaceTools::greenRefine(), hexRef8::subset(), triSurfaceTools::triangulateFaceCentre(), hexRef8Data::updateMesh(), pointZoneSet::updateMesh(), boundaryCutter::updateMesh(), localPointRegion::updateMesh(), addPatchCellLayer::updateMesh(), hexRef8::updateMesh(), and polyMesh::updateMesh().
PtrList<dictionary> patchDicts |
Definition at line 532 of file readKivaGrid.H.
Referenced by forAll(), blockMesh::patchDicts(), and Foam::preservePatchTypes().