BUGFIX: Uninitialised member variables
[foam-extend-3.2.git] / applications / solvers / solidMechanics / elasticAcpSolidFoam / updateCrackPropagationPatchesInternalFaces.H
blob2ba387387c48a22cd343c7821fc972ad20e85449
2     labelHashSet selectedFaces;
4     const labelListList& edgeFaces = mesh.edgeFaces();
6     const scalarField& cohesiveZoneI = cohesiveZone.internalField();
8     forAll (crackPropagationPatches, patchI)
9     {
10         label curPatchID = crackPropagationPatches[patchI];
12         const labelList& patchEdges =
13             mesh.boundaryMesh()[curPatchID].meshEdges();
15         forAll(patchEdges, edgeI)
16         {
17             label curEdge = patchEdges[edgeI];
19             const labelList& curFaces = edgeFaces[curEdge];
21             forAll(curFaces, faceI)
22             {
23                 if (curFaces[faceI] < mesh.nInternalFaces())
24                 {
25                     if (cohesiveZoneI[curFaces[faceI]] > (1.0 - SMALL))
26                     {
27                         if (!selectedFaces.found(curFaces[faceI]))
28                         {
29                             selectedFaces.insert(curFaces[faceI]);
30                         }
31                     }
32                 }
33             }
34         }
35     }
38 //     if (notchPatchID != -1)
39 //     {
40 //         const labelList& notchPatchEdges =
41 //             mesh.boundaryMesh()[notchPatchID].meshEdges();
43 //         forAll(notchPatchEdges, edgeI)
44 //         {
45 //             label curEdge = notchPatchEdges[edgeI];
47 //             const labelList& curFaces = edgeFaces[curEdge];
49 //             forAll(curFaces, faceI)
50 //             {
51 //                 if (curFaces[faceI] < mesh.nInternalFaces())
52 //                 {
53 //                     if (cohesiveZoneI[curFaces[faceI]] > (1.0 - SMALL))
54 //                     {
55 //                         selectedFaces.insert(curFaces[faceI]);
56 //                     }
57 //                 }
58 //             }
59 //         }
60 //     }
62 //     if (mesh.boundary()[cohesivePatchID].size())
63 //     {
64 //         const labelList& cohesivePatchEdges =
65 //             mesh.boundaryMesh()[cohesivePatchID].meshEdges();
67 //         forAll(cohesivePatchEdges, edgeI)
68 //         {
69 //             label curEdge = cohesivePatchEdges[edgeI];
71 //             const labelList& curFaces = edgeFaces[curEdge];
73 //             forAll(curFaces, faceI)
74 //             {
75 //                 if (curFaces[faceI] < mesh.nInternalFaces())
76 //                 {
77 //                     if (cohesiveZoneI[curFaces[faceI]] > (1.0 - SMALL))
78 //                     {
79 //                         selectedFaces.insert(curFaces[faceI]);
80 //                     }
81 //                 }
82 //             }
83 //         }
84 //     }
86     crackPropagationPatchesInternalFaces = labelList(selectedFaces.toc());