182{
184 using std::vector;
185 vector<int> vertex;
186 vector<int> iEdge_01;
187 vector<int> iEdge_12;
188 vector<int> iEdge_23;
189 vector<int> iEdge_30;
190 vector<int> iEdge_04;
191 vector<int> iEdge_14;
192 vector<int> iEdge_25;
193 vector<int> iEdge_35;
194 vector<int> iEdge_45;
195 vector<int> iFace_0123;
196 vector<int> iFace_014;
197 vector<int> iFace_1254;
198 vector<int> iFace_325;
199 vector<int> iFace_0354;
200 vector<int> interiorVolumePoints;
201 vector<int> map;
202
203
204 for (
size_t z = 0, index = 0;
z < npts; ++
z)
205 {
206 for (size_t y = 0; y < npts; ++y)
207 {
208 for (
size_t x = 0; x < npts -
z; ++x, ++index)
209 {
210 if (isVertex(x, y,
z, npts))
211 {
212 vertex.push_back(index);
213 }
214 else if (isEdge(x, y,
z, npts))
215 {
216 if (isEdge_01(x, y,
z, npts))
217 {
218 iEdge_01.push_back(index);
219 }
220 else if (isEdge_12(x, y,
z, npts))
221 {
222 iEdge_12.push_back(index);
223 }
224 else if (isEdge_23(x, y,
z, npts))
225 {
226 iEdge_23.push_back(index);
227 }
228 else if (isEdge_30(x, y,
z, npts))
229 {
230 iEdge_30.push_back(index);
231 }
232 else if (isEdge_04(x, y,
z, npts))
233 {
234 iEdge_04.push_back(index);
235 }
236 else if (isEdge_14(x, y,
z, npts))
237 {
238 iEdge_14.push_back(index);
239 }
240 else if (isEdge_25(x, y,
z, npts))
241 {
242 iEdge_25.push_back(index);
243 }
244 else if (isEdge_35(x, y,
z, npts))
245 {
246 iEdge_35.push_back(index);
247 }
248 else if (isEdge_45(x, y,
z, npts))
249 {
250 iEdge_45.push_back(index);
251 }
252 }
253 else if (isFace(x, y,
z, npts))
254 {
255 if (isFace_0123(x, y,
z, npts))
256 {
257 iFace_0123.push_back(index);
258 }
259 else if (isFace_014(x, y,
z, npts))
260 {
261 iFace_014.push_back(index);
262 }
263 else if (isFace_1254(x, y,
z, npts))
264 {
265 iFace_1254.push_back(index);
266 }
267 else if (isFace_325(x, y,
z, npts))
268 {
269 iFace_325.push_back(index);
270 }
271 else if (isFace_0354(x, y,
z, npts))
272 {
273 iFace_0354.push_back(index);
274 }
275 }
276 else
277 {
278 interiorVolumePoints.push_back(index);
279 }
280 }
281 }
282 }
283
284 for (size_t n = 0; n < vertex.size(); ++n)
285 {
286 map.push_back(vertex[n]);
287 }
288
289 for (size_t n = 0; n < iEdge_01.size(); ++n)
290 {
291 map.push_back(iEdge_01[n]);
292 }
293
294 for (size_t n = 0; n < iEdge_12.size(); ++n)
295 {
296 map.push_back(iEdge_12[n]);
297 }
298
299 for (size_t n = 0; n < iEdge_23.size(); ++n)
300 {
301 map.push_back(iEdge_23[n]);
302 }
303
304 for (size_t n = 0; n < iEdge_30.size(); ++n)
305 {
306 map.push_back(iEdge_30[n]);
307 }
308
309 for (size_t n = 0; n < iEdge_04.size(); ++n)
310 {
311 map.push_back(iEdge_04[n]);
312 }
313
314 for (size_t n = 0; n < iEdge_14.size(); ++n)
315 {
316 map.push_back(iEdge_14[n]);
317 }
318
319 for (size_t n = 0; n < iEdge_25.size(); ++n)
320 {
321 map.push_back(iEdge_25[n]);
322 }
323
324 for (size_t n = 0; n < iEdge_35.size(); ++n)
325 {
326 map.push_back(iEdge_35[n]);
327 }
328
329 for (size_t n = 0; n < iEdge_45.size(); ++n)
330 {
331 map.push_back(iEdge_45[n]);
332 }
333
334 for (size_t n = 0; n < iFace_0123.size(); ++n)
335 {
336 map.push_back(iFace_0123[n]);
337 }
338
339 for (size_t n = 0; n < iFace_014.size(); ++n)
340 {
341 map.push_back(iFace_014[n]);
342 }
343
344 for (size_t n = 0; n < iFace_1254.size(); ++n)
345 {
346 map.push_back(iFace_1254[n]);
347 }
348
349 for (size_t n = 0; n < iFace_325.size(); ++n)
350 {
351 map.push_back(iFace_325[n]);
352 }
353
354 for (size_t n = 0; n < iFace_0354.size(); ++n)
355 {
356 map.push_back(iFace_0354[n]);
357 }
358
359 for (size_t n = 0; n < interiorVolumePoints.size(); ++n)
360 {
361 map.push_back(interiorVolumePoints[n]);
362 }
363
364 Array<OneD, NekDouble> points[3];
368
369 for (size_t index = 0; index < map.size(); ++index)
370 {
371 points[0][index] =
m_points[0][index];
372 points[1][index] =
m_points[1][index];
373 points[2][index] =
m_points[2][index];
374 }
375
376 for (size_t index = 0; index < map.size(); ++index)
377 {
378 m_points[0][index] = points[0][map[index]];
379 m_points[1][index] = points[1][map[index]];
380 m_points[2][index] = points[2][map[index]];
381 }
382}
Array< OneD, DataType > m_points[3]
Storage for the point locations, allowing for up to a 3D points storage.
size_t GetNumPoints() const
size_t GetTotNumPoints() const
std::vector< double > z(NPUPPER)