[cig-commits] [commit] rajesh-petsc-schur: Changed the shape of E->Eqn_k2 as part of caps_per_proc_removal (c767670)

cig_noreply at geodynamics.org cig_noreply at geodynamics.org
Wed Sep 24 15:24:38 PDT 2014


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

On branch  : rajesh-petsc-schur
Link       : https://github.com/geodynamics/citcoms/compare/980de677d7efb78fdd5c41fd4b35a9283a2d251f...b86b2dd00f2bd13fb282a2eb9169871be4b1e923

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

commit c7676705508f7b432f9a1e548a0753e0979dd02e
Author: Rajesh Kommu <rajesh.kommu at gmail.com>
Date:   Wed Sep 24 13:40:26 2014 -0700

    Changed the shape of E->Eqn_k2 as part of caps_per_proc_removal


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

c7676705508f7b432f9a1e548a0753e0979dd02e
 lib/Construct_arrays.c         | 12 ++++++------
 lib/Element_calculations.c     |  2 +-
 lib/General_matrix_functions.c |  2 +-
 lib/global_defs.h              |  2 +-
 4 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/lib/Construct_arrays.c b/lib/Construct_arrays.c
index e4726c1..b00ba81 100644
--- a/lib/Construct_arrays.c
+++ b/lib/Construct_arrays.c
@@ -290,7 +290,7 @@ void construct_node_maps(E)
          }
 
        E->Eqn_k1[lev] = (higher_precision *)malloc(matrix*sizeof(higher_precision));
-       E->Eqn_k2[lev][CPPR] = (higher_precision *)malloc(matrix*sizeof(higher_precision));
+       E->Eqn_k2[lev] = (higher_precision *)malloc(matrix*sizeof(higher_precision));
        E->Eqn_k3[lev][CPPR] = (higher_precision *)malloc(matrix*sizeof(higher_precision));
 
        E->mesh.matrix_size[lev] = matrix;
@@ -339,7 +339,7 @@ void construct_node_ks(E)
 	    E->BI[level][i] = zero;
         for(i=0;i<E->mesh.matrix_size[level];i++) {
             E->Eqn_k1[level][i] = zero;
-            E->Eqn_k2[level][CPPR][i] = zero;
+            E->Eqn_k2[level][i] = zero;
             E->Eqn_k3[level][CPPR][i] = zero;
             }
 
@@ -393,7 +393,7 @@ void construct_node_ks(E)
 		    assert(found /* direction 1 */);
 
 		    E->Eqn_k1[level][loc0+index] +=  w1*ww1*elt_K[pp*lms+qq]; /* direction 1 */
-		    E->Eqn_k2[level][CPPR][loc0+index] +=  w2*ww1*elt_K[(pp+1)*lms+qq]; /* direction 1 */
+		    E->Eqn_k2[level][loc0+index] +=  w2*ww1*elt_K[(pp+1)*lms+qq]; /* direction 1 */
 		    E->Eqn_k3[level][CPPR][loc0+index] +=  w3*ww1*elt_K[(pp+2)*lms+qq]; /* direction 1 */
 
 		     /* search for direction 2*/
@@ -409,7 +409,7 @@ void construct_node_ks(E)
 		    assert(found /* direction 2 */);
 
 		    E->Eqn_k1[level][loc0+index] += w1*ww2*elt_K[pp*lms+qq+1]; /* direction 1 */
-		    E->Eqn_k2[level][CPPR][loc0+index] += w2*ww2*elt_K[(pp+1)*lms+qq+1]; /* direction 2 */
+		    E->Eqn_k2[level][loc0+index] += w2*ww2*elt_K[(pp+1)*lms+qq+1]; /* direction 2 */
 		    E->Eqn_k3[level][CPPR][loc0+index] += w3*ww2*elt_K[(pp+2)*lms+qq+1]; /* direction 3 */
 
 		    /* search for direction 3*/
@@ -425,7 +425,7 @@ void construct_node_ks(E)
                     assert(found /* direction 3 */);
 
 		    E->Eqn_k1[level][loc0+index] += w1*ww3*elt_K[pp*lms+qq+2]; /* direction 1 */
-        E->Eqn_k2[level][CPPR][loc0+index] += w2*ww3*elt_K[(pp+1)*lms+qq+2]; /* direction 2 */
+        E->Eqn_k2[level][loc0+index] += w2*ww3*elt_K[(pp+1)*lms+qq+2]; /* direction 2 */
 		    E->Eqn_k3[level][CPPR][loc0+index] += w3*ww3*elt_K[(pp+2)*lms+qq+2]; /* direction 3 */
 
 		    }   /* end for j */
@@ -471,7 +471,7 @@ void rebuild_BI_on_boundary(E)
 
             C=E->Node_map[level] + (i-1)*max_eqn;
             B1=E->Eqn_k1[level]+(i-1)*max_eqn;
-            B2=E->Eqn_k2[level][CPPR]+(i-1)*max_eqn;
+            B2=E->Eqn_k2[level]+(i-1)*max_eqn;
             B3=E->Eqn_k3[level][CPPR]+(i-1)*max_eqn;
 
             for(j=3;j<max_eqn;j++) {
diff --git a/lib/Element_calculations.c b/lib/Element_calculations.c
index e1fdd1b..3c4d0f4 100644
--- a/lib/Element_calculations.c
+++ b/lib/Element_calculations.c
@@ -537,7 +537,7 @@ void n_assemble_del2_u(E,u,Au,level,strip_bcs)
 
        C=E->Node_map[level] + (e-1)*max_eqn;
        B1=E->Eqn_k1[level]+(e-1)*max_eqn;
-       B2=E->Eqn_k2[level][CPPR]+(e-1)*max_eqn;
+       B2=E->Eqn_k2[level]+(e-1)*max_eqn;
        B3=E->Eqn_k3[level][CPPR]+(e-1)*max_eqn;
 
        for(i=3;i<max_eqn;i++)  {
diff --git a/lib/General_matrix_functions.c b/lib/General_matrix_functions.c
index d120068..5257c81 100644
--- a/lib/General_matrix_functions.c
+++ b/lib/General_matrix_functions.c
@@ -485,7 +485,7 @@ void gauss_seidel(E,d0,F,Ad,acc,cycles,level,guess)
 	    eqn3=E->ID[level][i].doff[3];
             C=E->Node_map[level]+(i-1)*max_eqn;
 	    B1=E->Eqn_k1[level]+(i-1)*max_eqn;
-	    B2=E->Eqn_k2[level][CPPR]+(i-1)*max_eqn;
+	    B2=E->Eqn_k2[level]+(i-1)*max_eqn;
  	    B3=E->Eqn_k3[level][CPPR]+(i-1)*max_eqn;
 
                  /* Ad on boundaries differs after the following operation, but
diff --git a/lib/global_defs.h b/lib/global_defs.h
index 71429e0..48eead5 100644
--- a/lib/global_defs.h
+++ b/lib/global_defs.h
@@ -819,7 +819,7 @@ struct All_variables {
     struct REF_STATE refstate;
 
 
-    higher_precision *Eqn_k1[MAX_LEVELS],*Eqn_k2[MAX_LEVELS][NCS],*Eqn_k3[MAX_LEVELS][NCS];
+    higher_precision *Eqn_k1[MAX_LEVELS],*Eqn_k2[MAX_LEVELS],*Eqn_k3[MAX_LEVELS][NCS];
     int *Node_map [MAX_LEVELS];
 
     double *BI[MAX_LEVELS],*BPI[MAX_LEVELS];



More information about the CIG-COMMITS mailing list