// Return the neighbour face point from the mapped indices inline label facePointN ( const int facei, const block& block, const label i, const label j ) { switch (facei) { case 0: return facePointN(block, 0, i, j); case 1: return facePointN(block, block.meshDensity().x(), i, j); case 2: return facePointN(block, i, 0, j); case 3: return facePointN(block, i, block.meshDensity().y(), j); case 4: return facePointN(block, i, j, 0); case 5: return facePointN(block, i, j, block.meshDensity().z()); default: return -1; } }
// Return the neighbour face point from the signed indices inline label facePointN ( const block& block, const label i, const label j, const label k ) { return block.vtxLabel ( unsignIndex(i, block.meshDensity().x()), unsignIndex(j, block.meshDensity().y()), unsignIndex(k, block.meshDensity().z()) ); }
// Return the number of divisions in each direction for the face Pair<label> faceNij(const label facei, const block& block) { Pair<label> fnij; int i = facei/2; if (i == 0) { fnij.first() = block.meshDensity().y() + 1; fnij.second() = block.meshDensity().z() + 1; } else if (i == 1) { fnij.first() = block.meshDensity().x() + 1; fnij.second() = block.meshDensity().z() + 1; } else if (i == 2) { fnij.first() = block.meshDensity().x() + 1; fnij.second() = block.meshDensity().y() + 1; } return fnij; }