[cig-commits] [commit] rajesh-petsc-schur: Changed the shape of E->NMass as part of caps_per_proc removal (d473dff)

cig_noreply at geodynamics.org cig_noreply at geodynamics.org
Wed Nov 5 19:11:24 PST 2014


Repository : https://github.com/geodynamics/citcoms

On branch  : rajesh-petsc-schur
Link       : https://github.com/geodynamics/citcoms/compare/464e1b32299b15819f93efd98d969cddb84dfe51...f97ae655a50bdbd6dac1923a3471ee4dae178fbd

>---------------------------------------------------------------

commit d473dff90366cf2f474286f590e30d521ed0cb94
Author: Rajesh Kommu <rajesh.kommu at gmail.com>
Date:   Tue Sep 23 12:35:08 2014 -0700

    Changed the shape of E->NMass as part of caps_per_proc removal


>---------------------------------------------------------------

d473dff90366cf2f474286f590e30d521ed0cb94
 lib/Global_operations.c | 2 +-
 lib/Instructions.c      | 2 +-
 lib/Petsc_citcoms.c     | 2 +-
 lib/Size_does_matter.c  | 2 +-
 lib/global_defs.h       | 2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/lib/Global_operations.c b/lib/Global_operations.c
index b619123..0f9b53a 100644
--- a/lib/Global_operations.c
+++ b/lib/Global_operations.c
@@ -580,7 +580,7 @@ double global_v_norm2(struct All_variables *E,  double *V)
         /* L2 norm  */
         temp += (V[eqn1] * V[eqn1] +
                  V[eqn2] * V[eqn2] +
-                 V[eqn3] * V[eqn3]) * E->NMass[CPPR][i];
+                 V[eqn3] * V[eqn3]) * E->NMass[i];
     }
 
     MPI_Allreduce(&temp, &prod, 1, MPI_DOUBLE, MPI_SUM, E->parallel.world);
diff --git a/lib/Instructions.c b/lib/Instructions.c
index 6b3598d..fca6211 100644
--- a/lib/Instructions.c
+++ b/lib/Instructions.c
@@ -983,7 +983,7 @@ void allocate_common_vars(E)
   E->TMass = (double *) malloc((nno+1)*sizeof(double));
 
   /* nodal mass */
-  E->NMass[CPPR] = (double *) malloc((nno+1)*sizeof(double));
+  E->NMass = (double *) malloc((nno+1)*sizeof(double));
 
   nxyz = max(nox*noz,nox*noy);
   nxyz = 2*max(nxyz,noz*noy);
diff --git a/lib/Petsc_citcoms.c b/lib/Petsc_citcoms.c
index 5ab5032..3c7e88a 100644
--- a/lib/Petsc_citcoms.c
+++ b/lib/Petsc_citcoms.c
@@ -20,7 +20,7 @@ double global_v_norm2_PETSc( struct All_variables *E,  Vec v )
         eqn2 = E->id[i].doff[2];
         eqn3 = E->id[i].doff[3];
         /* L2 norm  */
-        temp += (V[eqn1] * V[eqn1] + V[eqn2] * V[eqn2] + V[eqn3] * V[eqn3]) * E->NMass[CPPR][i];
+        temp += (V[eqn1] * V[eqn1] + V[eqn2] * V[eqn2] + V[eqn3] * V[eqn3]) * E->NMass[i];
     }
     ierr = VecRestoreArray( v, &V ); CHKERRQ( ierr );
 
diff --git a/lib/Size_does_matter.c b/lib/Size_does_matter.c
index 707563d..63e2f48 100644
--- a/lib/Size_does_matter.c
+++ b/lib/Size_does_matter.c
@@ -1047,7 +1047,7 @@ void mass_matrix(struct All_variables *E)
 
         if(lev == E->mesh.levmax)
             for(node=1;node<=E->lmesh.NNO[lev];node++)
-                E->NMass[CPPR][node] = E->MASS[lev][node];
+                E->NMass[node] = E->MASS[lev][node];
 
         if (E->control.NMULTIGRID||E->mesh.levmax==lev)
             (E->exchange_node_d)(E,E->MASS[lev],lev);
diff --git a/lib/global_defs.h b/lib/global_defs.h
index 55b79a9..580e470 100644
--- a/lib/global_defs.h
+++ b/lib/global_defs.h
@@ -834,7 +834,7 @@ struct All_variables {
     double *u1;
     double *temp,*temp1;
     double *Mass, *MASS[MAX_LEVELS];
-    double *TMass, *NMass[NCS];
+    double *TMass, *NMass;
     double *SX[MAX_LEVELS][NCS][4],*X[MAX_LEVELS][NCS][4];
     double *sx[NCS][4],*x[NCS][4];
     double *surf_det[NCS][5];



More information about the CIG-COMMITS mailing list