[cig-commits] commit: Fix a bug when the refined box is not on the bottom boundary.

Mercurial hg at geodynamics.org
Fri Feb 25 14:16:05 PST 2011


changeset:   72:78f870959148
user:        Walter Landry <wlandry at caltech.edu>
date:        Wed Feb 02 16:33:30 2011 -0800
files:       V_Boundary_Refine/refine.C
description:
Fix a bug when the refined box is not on the bottom boundary.


diff -r 589e7f172c2b -r 78f870959148 V_Boundary_Refine/refine.C
--- a/V_Boundary_Refine/refine.C	Wed Feb 02 15:40:08 2011 -0800
+++ b/V_Boundary_Refine/refine.C	Wed Feb 02 16:33:30 2011 -0800
@@ -73,9 +73,9 @@ void SAMRAI::geom::V_Boundary_Refine::re
    if(std::abs(overlap_box.lower(0)-overlap_box.upper(0))==(axis==0 ? 1 : 0))
      {
        boundary_direction=0;
-       if(fine_box.upper(0)<overlap_box.lower(0))
+       if(fine_box.upper(0)<=overlap_box.lower(0))
          boundary_positive=true;
-       else if(fine_box.lower(0)>overlap_box.upper(0))
+       else if(fine_box.lower(0)>=overlap_box.upper(0))
          boundary_positive=false;
        else
          abort();
@@ -84,9 +84,9 @@ void SAMRAI::geom::V_Boundary_Refine::re
            (axis==1 ? 1 : 0))
      {
        boundary_direction=1;
-       if(fine_box.upper(1)<overlap_box.lower(1))
+       if(fine_box.upper(1)<=overlap_box.lower(1))
          boundary_positive=true;
-       else if(fine_box.lower(1)>overlap_box.upper(1))
+       else if(fine_box.lower(1)>=overlap_box.upper(1))
          boundary_positive=false;
        else
          abort();



More information about the CIG-COMMITS mailing list