[cig-commits] [commit] rajesh-petsc-schur: cleaned up assemble_div_u; results dont match master (154d1e7)

cig_noreply at geodynamics.org cig_noreply at geodynamics.org
Wed Nov 5 19:04:10 PST 2014


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

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

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

commit 154d1e7a9de39e9d36ce8f5216e817447c883f6a
Author: Rajesh Kommu <rajesh.kommu at gmail.com>
Date:   Wed Sep 10 10:09:22 2014 -0700

    cleaned up assemble_div_u; results dont match master


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

154d1e7a9de39e9d36ce8f5216e817447c883f6a
 lib/Element_calculations.c | 34 +++++++++++++++++-----------------
 1 file changed, 17 insertions(+), 17 deletions(-)

diff --git a/lib/Element_calculations.c b/lib/Element_calculations.c
index c577c52..9737875 100644
--- a/lib/Element_calculations.c
+++ b/lib/Element_calculations.c
@@ -712,24 +712,24 @@ void assemble_div_u(struct All_variables *E,
     const int dims=E->mesh.nsd;
     const int npno=E->lmesh.NPNO[level];
 
-  for(m=1;m<=E->sphere.caps_per_proc;m++)
-    for(e=0;e<npno;e++)
-      divU[m][e] = 0.0;
-
-  for(m=1;m<=E->sphere.caps_per_proc;m++)
-       for(a=1;a<=ends;a++)   {
-	  p = (a-1)*dims;
-          for(e=1;e<=nel;e++) {
-	    b = E->IEN[level][m][e].node[a];
-	    j1= E->ID[level][m][b].doff[1];
-            j2= E->ID[level][m][b].doff[2];
-	    j3= E->ID[level][m][b].doff[3];
-	    divU[m][e] += E->elt_del[level][m][e].g[p  ][0] * U[m][j1]
-	                + E->elt_del[level][m][e].g[p+1][0] * U[m][j2]
-	                + E->elt_del[level][m][e].g[p+2][0] * U[m][j3];
-	    }
-	 }
+    for(m=1;m<=E->sphere.caps_per_proc;m++)
+      for(e=0;e<npno;e++)
+        divU[m][e] = 0.0;
 
+    for(m=1;m<=E->sphere.caps_per_proc;m++) {
+      for(a=1;a<=ends;a++) {
+        p = (a-1)*dims;
+        for(e=0;e<nel;e++) {
+          b = E->IEN[level][m][e+1].node[a];
+          j1= E->ID[level][m][b].doff[1];
+          j2= E->ID[level][m][b].doff[2];
+          j3= E->ID[level][m][b].doff[3];
+          divU[m][e] += E->elt_del[level][m][e+1].g[p  ][0] * U[m][j1]
+                      + E->elt_del[level][m][e+1].g[p+1][0] * U[m][j2]
+                      + E->elt_del[level][m][e+1].g[p+2][0] * U[m][j3];
+        }
+      }
+    }
 }
 
 



More information about the CIG-COMMITS mailing list