Skip to content

Commit d4ac97a

Browse files
committed
Some more clean up
1 parent 10f27c5 commit d4ac97a

3 files changed

Lines changed: 4 additions & 27 deletions

File tree

src/pmpo_MPMesh.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
#include "pmpo_utils.hpp"
33
#include "pmpo_MPMesh.hpp"
44
#include "pmpo_wachspressBasis.hpp"
5-
#include <unistd.h>
65
namespace polyMPO{
76

87
void printVTP_mesh(MPMesh& mpMesh, int printVTPIndex=-1);
@@ -129,7 +128,6 @@ void MPMesh::CVTTrackingElmCenterBased(const int printVTPIndex){
129128
auto elm2Process = p_mesh->getElm2Process();
130129
auto elm2global = p_mesh->getElmGlobal();
131130

132-
//Since Mesh is static print pnly for 1 time step
133131
if(printVTPIndex>=0) {
134132
printVTP_mesh(printVTPIndex);
135133
}
@@ -167,10 +165,6 @@ void MPMesh::CVTTrackingElmCenterBased(const int printVTPIndex){
167165
minDistSq = neighborDistSq;
168166
}
169167
}
170-
if(abs(mpTgtPos(mp,0)+5.724649188625998e+06) < 1e-10)
171-
printf("Track: %.15e %.15e %.15e => %.15e %.15e %.15e \n", mpTgtPos(mp,0), mpTgtPos(mp,1), mpTgtPos(mp,2),
172-
mpPositions(mp,0), mpPositions(mp,1), mpPositions(mp,2) );
173-
174168
if(closestElm<0){
175169
MPs2Elm(mp) = iElm;
176170
if (elm2Process.size() > 0)

src/pmpo_MPMesh_assembly.hpp

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ void MPMesh::resetPreComputeFlag(){
103103
isPreComputed = false;
104104
}
105105

106-
//Method 1
106+
//Method 1 for coefficients
107107
void MPMesh::computeMatricesAndSolve(){
108108
Kokkos::Timer timer;
109109
//Mesh Information
@@ -209,7 +209,7 @@ void MPMesh::computeMatricesAndSolve(){
209209
pumipic::RecordTime("PolyMPO_Calculate_MLS_Coeff", timer.seconds());
210210
}
211211

212-
//Method 2
212+
//Method 2 for coefficients
213213
void MPMesh::subAssemblyCoeffs(int dim1, int dim2, double* m11, double* m12, double* m13, double* m14,
214214
double* m22, double* m23, double* m24,
215215
double* m33, double* m34,
@@ -299,21 +299,12 @@ void MPMesh::subAssemblyCoeffs(int dim1, int dim2, double* m11, double* m12, dou
299299

300300
}
301301

302-
//Method 2
303-
void MPMesh::solveMatrixAndRegularize( int dim1, double* m11, double* m12, double* m13, double* m14,
302+
//Method 2 for coefficients Solve matrix
303+
void MPMesh::solveMatrixAndRegularize(int dim1, double* m11, double* m12, double* m13, double* m14,
304304
double* m22, double* m23, double* m24,
305305
double* m33, double* m34,
306306
double* m44){
307307

308-
MPI_Comm comm = p_MPs->getMPIComm();
309-
int comm_rank;
310-
MPI_Comm_rank(comm, &comm_rank);
311-
312-
static int count=0;
313-
if(!comm_rank)
314-
std::cout<<__FUNCTION__<<count<<std::endl;
315-
count ++;
316-
317308
auto dual_triangle_area=p_mesh->getMeshField<MeshF_DualTriangleArea>();
318309

319310
kkViewHostU<const double*> m11_h(m11, dim1);

src/pmpo_c.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -265,10 +265,6 @@ void polympo_getMPTgtElmID_f(MPMesh_ptr p_mpmesh,
265265
kkIntViewHostU arrayHost(elmIDs,numMPs);
266266
polyMPO::IntView mpTgtElmIDCopy("mpTgtElmIDNewValue",numMPs);
267267

268-
int rank;
269-
auto mpi_comm=p_MPs->getMPIComm();
270-
MPI_Comm_rank(mpi_comm, &rank);
271-
272268
auto setTgtElmId = PS_LAMBDA(const int&, const int& mp, const int& mask){
273269
if(mask){
274270
mpTgtElmIDCopy(mpAppID(mp)) = mpTgtElmID(mp)+elmIDoffset;
@@ -294,10 +290,6 @@ void polympo_getMPCurElmID_f(MPMesh_ptr p_mpmesh,
294290
kkIntViewHostU arrayHost(elmIDs,numMPs);
295291
polyMPO::IntView mpCurElmIDCopy("mpCurElmIDNewValue",numMPs);
296292

297-
int rank;
298-
auto mpi_comm=p_MPs->getMPIComm();
299-
MPI_Comm_rank(mpi_comm, &rank);
300-
301293
auto getElmId = PS_LAMBDA(const int&, const int& mp, const int& mask){
302294
if(mask){
303295
mpCurElmIDCopy(mpAppID(mp)) = mpCurElmID(mp)+elmIDoffset;

0 commit comments

Comments
 (0)