35 void Foam::block::blockBoundary()
37 label ni = blockDef_.
n().
x();
38 label nj = blockDef_.
n().
y();
39 label nk = blockDef_.
n().
z();
44 label wallCellLabel = 0;
47 boundaryPatches_[wallLabel].
setSize(nj*nk);
48 for (label
k = 0;
k <= nk - 1;
k++)
50 for (label j = 0; j <= nj - 1; j++)
52 boundaryPatches_[wallLabel][wallCellLabel].
setSize(4);
55 boundaryPatches_[wallLabel][wallCellLabel][0] =
57 boundaryPatches_[wallLabel][wallCellLabel][1] =
58 vtxLabel(0, j,
k + 1);
59 boundaryPatches_[wallLabel][wallCellLabel][2] =
60 vtxLabel(0, j + 1,
k + 1);
61 boundaryPatches_[wallLabel][wallCellLabel][3] =
62 vtxLabel(0, j + 1,
k);
73 boundaryPatches_[wallLabel].
setSize(nj*nk);
75 for (label
k = 0;
k <= nk - 1;
k++)
77 for (label j = 0; j <= nj - 1; j++)
79 boundaryPatches_[wallLabel][wallCellLabel].
setSize(4);
82 boundaryPatches_[wallLabel][wallCellLabel][0] =
84 boundaryPatches_[wallLabel][wallCellLabel][1] =
86 boundaryPatches_[wallLabel][wallCellLabel][2] =
87 vtxLabel(ni, j+1,
k+1);
88 boundaryPatches_[wallLabel][wallCellLabel][3] =
102 boundaryPatches_[wallLabel].
setSize(ni*nk);
103 for (label i = 0; i <= ni - 1; i++)
105 for (label
k = 0;
k <= nk - 1;
k++)
107 boundaryPatches_[wallLabel][wallCellLabel].
setSize(4);
110 boundaryPatches_[wallLabel][wallCellLabel][0] =
112 boundaryPatches_[wallLabel][wallCellLabel][1] =
113 vtxLabel(i + 1, 0,
k);
114 boundaryPatches_[wallLabel][wallCellLabel][2] =
115 vtxLabel(i + 1, 0,
k + 1);
116 boundaryPatches_[wallLabel][wallCellLabel][3] =
117 vtxLabel(i, 0,
k + 1);
128 boundaryPatches_[wallLabel].
setSize(ni*nk);
130 for (label i = 0; i <= ni - 1; i++)
132 for (label
k = 0;
k <= nk - 1;
k++)
134 boundaryPatches_[wallLabel][wallCellLabel].
setSize(4);
137 boundaryPatches_[wallLabel][wallCellLabel][0] =
139 boundaryPatches_[wallLabel][wallCellLabel][1] =
140 vtxLabel(i, nj,
k + 1);
141 boundaryPatches_[wallLabel][wallCellLabel][2] =
142 vtxLabel(i + 1, nj,
k + 1);
143 boundaryPatches_[wallLabel][wallCellLabel][3] =
144 vtxLabel(i + 1, nj,
k);
157 boundaryPatches_[wallLabel].
setSize(ni*nj);
159 for (label i = 0; i <= ni - 1; i++)
161 for (label j = 0; j <= nj - 1; j++)
163 boundaryPatches_[wallLabel][wallCellLabel].
setSize(4);
166 boundaryPatches_[wallLabel][wallCellLabel][0] =
168 boundaryPatches_[wallLabel][wallCellLabel][1] =
169 vtxLabel(i, j + 1, 0);
170 boundaryPatches_[wallLabel][wallCellLabel][2] =
171 vtxLabel(i + 1, j + 1, 0);
172 boundaryPatches_[wallLabel][wallCellLabel][3] =
173 vtxLabel(i + 1, j, 0);
184 boundaryPatches_[wallLabel].
setSize(ni*nj);
186 for (label i = 0; i <= ni - 1; i++)
188 for (label j = 0; j <= nj - 1; j++)
190 boundaryPatches_[wallLabel][wallCellLabel].
setSize(4);
193 boundaryPatches_[wallLabel][wallCellLabel][0] =
195 boundaryPatches_[wallLabel][wallCellLabel][1] =
196 vtxLabel(i + 1, j, nk);
197 boundaryPatches_[wallLabel][wallCellLabel][2] =
198 vtxLabel(i + 1, j + 1, nk);
199 boundaryPatches_[wallLabel][wallCellLabel][3] =
200 vtxLabel(i, j + 1, nk);