[cig-commits] r13431 - in long/3D/Gale/trunk: . src/Gale/Utils/src

walter at geodynamics.org walter at geodynamics.org
Mon Dec 1 14:32:56 PST 2008


Author: walter
Date: 2008-12-01 14:32:55 -0800 (Mon, 01 Dec 2008)
New Revision: 13431

Modified:
   long/3D/Gale/trunk/
   long/3D/Gale/trunk/src/Gale/Utils/src/MixedStabiliserTerm.c
Log:
 r2386 at dante:  boo | 2008-12-01 14:31:31 -0800
 Use the correct geometric factor in 3D for MixedStabiliserTerm



Property changes on: long/3D/Gale/trunk
___________________________________________________________________
Name: svk:merge
   - 3a629746-de10-0410-b17b-fd6ecaaa963e:/cig:2382
   + 3a629746-de10-0410-b17b-fd6ecaaa963e:/cig:2386

Modified: long/3D/Gale/trunk/src/Gale/Utils/src/MixedStabiliserTerm.c
===================================================================
--- long/3D/Gale/trunk/src/Gale/Utils/src/MixedStabiliserTerm.c	2008-12-01 21:05:04 UTC (rev 13430)
+++ long/3D/Gale/trunk/src/Gale/Utils/src/MixedStabiliserTerm.c	2008-12-01 22:32:55 UTC (rev 13431)
@@ -175,7 +175,7 @@
    ElementType* elementType;
    IntegrationPointsSwarm* swarm;
    IntegrationPoint* integrationPoint;
-   const double oneOnSixteen = 0.0625;
+   double geometric_factor;
    double** localElStiffMat;
    int ii, jj, kk;
    double sumVisc = 0.0, visc;
@@ -260,10 +260,12 @@
    /* Normalize the viscosity factor by dividing by cell area. */
    viscFac = cellArea / sumVisc;
 
-   /* Adjust the calculated mass matrix by the 'special operator'. */
+   /* Adjust the calculated mass matrix by the 'special operator'. The
+      nElNodes term comes from an averaging operator applied twice. */
+
    for( ii = 0; ii < nElNodes; ii++ ) {
       for( jj = 0; jj < nElNodes; jj++ )
-         localElStiffMat[ii][jj] -= oneOnSixteen * cellArea;
+        localElStiffMat[ii][jj] -= cellArea/(nElNodes*nElNodes);
    }
 
    /* Apply the viscosity factor and negate the calculated value. */



More information about the CIG-COMMITS mailing list