[cig-commits] commit: Logic error with the hack...

Mercurial hg at geodynamics.org
Mon Nov 24 11:31:08 PST 2008


changeset:   112:41cd28fb3d6e
user:        LukeHodkinson
date:        Tue Aug 26 08:13:15 2008 +0000
files:       MaterialPoints/src/MaterialPointsSwarm.c
description:
Logic error with the hack...


diff -r a97f93eb103b -r 41cd28fb3d6e MaterialPoints/src/MaterialPointsSwarm.c
--- a/MaterialPoints/src/MaterialPointsSwarm.c	Tue Aug 26 07:36:43 2008 +0000
+++ b/MaterialPoints/src/MaterialPointsSwarm.c	Tue Aug 26 08:13:15 2008 +0000
@@ -422,7 +422,7 @@ void _MaterialPointsSwarm_UpdateHook( vo
                            if( !strcmp( material->name, "quartzFriction" ) ) {
                               Grid_Lift( grid, cell, inds );
                               if( inds[0] > 1 && inds[0] < grid->sizes[0] - 2 &&
-                                  inds[1] > 1 && inds[1] < grid->sizes[1] - 2 )
+                                  inds[1] > 1 )
                               {
                                  materialPoint->materialIndex = Materials_Register_GetIndex( self->materials_Register, "quartz" );
                               }
@@ -430,7 +430,7 @@ void _MaterialPointsSwarm_UpdateHook( vo
                            else if( !strcmp( material->name, "corundumFriction" ) ) {
                               Grid_Lift( grid, cell, inds );
                               if( inds[0] > 1 && inds[0] < grid->sizes[0] - 2 &&
-                                  inds[1] > 1 && inds[1] < grid->sizes[1] - 2 )
+                                  inds[1] > 1 )
                               {
                                  materialPoint->materialIndex = Materials_Register_GetIndex( self->materials_Register, "corundum" );
                               }
@@ -438,7 +438,7 @@ void _MaterialPointsSwarm_UpdateHook( vo
                            if( !strcmp( material->name, "quartz" ) ) {
                               Grid_Lift( grid, cell, inds );
                               if( inds[0] <= 1 || inds[0] >= grid->sizes[0] - 2 ||
-                                  inds[1] <= 1 || inds[1] >= grid->sizes[1] - 2 )
+                                  inds[1] <= 1 )
                               {
                                  materialPoint->materialIndex = Materials_Register_GetIndex( self->materials_Register, "quartzFriction" );
                               }
@@ -446,7 +446,7 @@ void _MaterialPointsSwarm_UpdateHook( vo
                            else if( !strcmp( material->name, "corundum" ) ) {
                               Grid_Lift( grid, cell, inds );
                               if( inds[0] <= 1 || inds[0] >= grid->sizes[0] - 2 ||
-                                  inds[1] <= 1 || inds[1] >= grid->sizes[1] - 2 )
+                                  inds[1] <= 1 )
                               {
                                  materialPoint->materialIndex = Materials_Register_GetIndex( self->materials_Register, "corundumFriction" );
                               }



More information about the CIG-COMMITS mailing list