1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
11 OpenFOAM is free software: you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by
13 the Free Software Foundation, either version 3 of the License, or
14 (at your option) any later version.
16 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 You should have received a copy of the GNU General Public License
22 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
24 \*---------------------------------------------------------------------------*/
26 #include "primitiveMesh.H"
27 #include "indexedOctree.H"
28 #include "treeDataCell.H"
29 #include "demandDrivenData.H"
30 #include "indexedOctree.H"
31 #include "treeDataCell.H"
33 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
35 void Foam::primitiveMesh::printAllocated() const
37 Pout<< "primitiveMesh allocated :" << endl;
42 Pout<< " Cell shapes" << endl;
47 Pout<< " Edges" << endl;
52 Pout<< " Cell-cells" << endl;
57 Pout<< " Edge-cells" << endl;
62 Pout<< " Point-cells" << endl;
67 Pout<< " Cell-faces" << endl;
72 Pout<< " Edge-faces" << endl;
77 Pout<< " Point-faces" << endl;
82 Pout<< " Cell-edges" << endl;
87 Pout<< " Face-edges" << endl;
92 Pout<< " Point-edges" << endl;
97 Pout<< " Point-point" << endl;
102 Pout<< " Cell-point" << endl;
107 Pout<< " Cell-tree" << endl;
113 Pout<< " Cell-centres" << endl;
118 Pout<< " Face-centres" << endl;
123 Pout<< " Cell-volumes" << endl;
128 Pout<< " Face-areas" << endl;
134 void Foam::primitiveMesh::clearGeom()
138 Pout<< "primitiveMesh::clearGeom() : "
139 << "clearing geometric data"
143 deleteDemandDrivenData(cellCentresPtr_);
144 deleteDemandDrivenData(faceCentresPtr_);
145 deleteDemandDrivenData(cellVolumesPtr_);
146 deleteDemandDrivenData(faceAreasPtr_);
150 void Foam::primitiveMesh::clearAddressing()
154 Pout<< "primitiveMesh::clearAddressing() : "
155 << "clearing topology"
159 deleteDemandDrivenData(cellShapesPtr_);
163 deleteDemandDrivenData(ccPtr_);
164 deleteDemandDrivenData(ecPtr_);
165 deleteDemandDrivenData(pcPtr_);
167 deleteDemandDrivenData(cfPtr_);
168 deleteDemandDrivenData(efPtr_);
169 deleteDemandDrivenData(pfPtr_);
171 deleteDemandDrivenData(cePtr_);
172 deleteDemandDrivenData(fePtr_);
173 deleteDemandDrivenData(pePtr_);
174 deleteDemandDrivenData(ppPtr_);
175 deleteDemandDrivenData(cpPtr_);
177 deleteDemandDrivenData(cellTreePtr_);
181 void Foam::primitiveMesh::clearCellTree()
183 deleteDemandDrivenData(cellTreePtr_);
187 void Foam::primitiveMesh::clearOut()
194 // ************************************************************************* //