searchingEngine.H
Go to the documentation of this file.
1 Random rndGen(653213);
2 
3 // Determine mesh bounding boxes:
4 List<treeBoundBox> meshBb
5 (
6  1,
7  treeBoundBox
8  (
9  boundBox(coarseMesh.points(), false)
10  ).extend(1e-3)
11 );
12 
13 // Dummy bounds dictionary
14 dictionary dict;
15 dict.add("bounds", meshBb);
16 dict.add
17 (
18  "distributionType",
19  distributedTriSurfaceMesh::distributionTypeNames_
20  [
21  distributedTriSurfaceMesh::FROZEN
22  ]
23 );
24 dict.add("mergeDistance", small);
25 
28 {
29  const polyPatch& pp = patches[patchi];
30  if
31  (
32  !pp.coupled()
33  && !isA<cyclicAMIPolyPatch>(pp)
34  && !isA<emptyPolyPatch>(pp)
35  )
36  {
37  includePatches.insert(patchi);
38  }
39 }
40 
41 labelList triSurfaceToAgglom(5*nFineFaces);
42 
43 const triSurface localSurface = triangulate
44 (
45  patches,
46  includePatches,
47  finalAgglom,
48  triSurfaceToAgglom,
49  globalNumbering,
50  coarsePatches
51 );
52 
53 
54 distributedTriSurfaceMesh surfacesMesh
55 (
56  IOobject
57  (
58  "wallSurface.stl",
59  runTime.constant(),
60  searchableSurface::geometryDir(runTime),
61  runTime,
62  IOobject::NO_READ,
63  IOobject::NO_WRITE
64  ),
65  localSurface,
66  dict
67 );
68 
69 
70 triSurfaceToAgglom.resize(surfacesMesh.size());
71 
72 //surfacesMesh.searchableSurface::write();
73 
74 surfacesMesh.setField(triSurfaceToAgglom);
dictionary dict
forAll(patches, patchi)
distributedTriSurfaceMesh surfacesMesh(IOobject("wallSurface.stl", runTime.constant(), searchableSurface::geometryDir(runTime), runTime, IOobject::NO_READ, IOobject::NO_WRITE), localSurface, dict)
engineTime & runTime
patches[0]
HashSet< label, Hash< label > > labelHashSet
A HashSet with label keys.
Definition: HashSet.H:211
labelList triSurfaceToAgglom(5 *nFineFaces)
List< label > labelList
A List of labels.
Definition: labelList.H:56
List< treeBoundBox > meshBb(1, treeBoundBox(boundBox(coarseMesh.points(), false)).extend(1e-3))
labelHashSet includePatches
Random rndGen(653213)
label patchi
const dimensionedScalar e
Elementary charge.
Definition: doubleScalar.H:105