34 void sammMesh::readCouples()
36 fileName couplesFileName(casePrefix_ +
".cpl");
38 IFstream couplesFile(couplesFileName);
40 if (couplesFile.good())
47 label matchLabel, nEntries, typeFlag;
48 label masterCell, masterFace;
49 label slaveCell, slaveFace;
51 while (!(couplesFile >> matchLabel).eof())
55 couplesFile >> nEntries;
57 couplesFile >> typeFlag;
62 <<
"void sammMesh::readCouples() : "
63 <<
"couple " << matchLabel <<
" is not an integral match. "
64 <<
"Currently not supported" <<
endl;
68 couplesFile >> masterCell >> masterFace;
71 faceList& masterFaces = cellFaces_[masterCell - 1];
90 [cellShapes_[masterCell - 1].model().index()]
95 label nSlavesToRead = nEntries - 1;
98 label slaveToAdd = masterFaces.
size();
101 masterFaces.
setSize(masterFaces.
size() + nSlavesToRead);
103 for (
int i = 0; i < nSlavesToRead; i++)
105 couplesFile >> slaveCell >> slaveFace;
107 masterFaces[slaveToAdd] =
114 [cellShapes_[slaveCell - 1].model().index()]
130 forAll (cellFaces_, cellI)
132 faceList& curFaces = cellFaces_[cellI];
134 label zeroSizeFound = 0;
138 if (curFaces[faceI].empty())
144 if (zeroSizeFound > 0)
155 if (oldFaces[faceI].size())
157 curFaces[nFaces] = oldFaces[faceI];
168 <<
"void sammMesh::readCouples() : "
169 <<
"Cannot read file "
171 <<
". No matches defined."