diff options
Diffstat (limited to 'Hilbert/Algorithm.hpp')
-rw-r--r-- | Hilbert/Algorithm.hpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/Hilbert/Algorithm.hpp b/Hilbert/Algorithm.hpp index b2ad5f8..bcc3b55 100644 --- a/Hilbert/Algorithm.hpp +++ b/Hilbert/Algorithm.hpp @@ -101,7 +101,7 @@ namespace Hilbert { assert( 0 <= d && d < n ); e = l; - e.toggleBit( d ); //#D d == n-1 ? 0 : d+1 ); + e.toggle( d ); //#D d == n-1 ? 0 : d+1 ); // Update direction d += 1 + t.fsb(); @@ -110,7 +110,7 @@ namespace Hilbert assert( 0 <= d && d < n ); if ( ! (w.rack() & 1) ) - e.toggleBit( d == 0 ? n-1 : d-1 ); //#D d ); + e.toggle( d == 0 ? n-1 : d-1 ); //#D d ); return; } @@ -130,7 +130,7 @@ namespace Hilbert { assert( 0 <= d && d < n ); e = l; - e.toggleBit( d );//#D d == n-1 ? 0 : d+1 ); + e.toggle( d );//#D d == n-1 ? 0 : d+1 ); // Update direction d += 1 + t.fsb(); @@ -157,10 +157,10 @@ namespace Hilbert int ho = m*n; // Initialize - e.zero(); + e.reset(); d = D0; - l.zero(); - h.zero(); + l.reset(); + h.reset(); int r, b; BBV_MODSPLIT(r,b,n-1); @@ -238,11 +238,11 @@ namespace Hilbert int d, i, j, ho; // Initialize - e.zero(); + e.reset(); d = D0; - l.zero(); + l.reset(); for ( j = 0; j < n; j++ ) - p[j].zero(); + p[j].reset(); ho = m*n; @@ -408,11 +408,11 @@ namespace Hilbert } // Initialize - e.zero(); + e.reset(); d = D0; - l.zero(); + l.reset(); for ( j = 0; j < n; j++ ) - p[j].zero(); + p[j].reset(); // Work from MSB to LSB for ( i = m-1; i >= 0; i-- ) @@ -424,7 +424,7 @@ namespace Hilbert // Get the Hilbert index bits M -= b; - r.zero(); // GetBits doesn't do this + r.reset(); // GetBits doesn't do this getBits<HC,I>(hc,b,M,r); // w = GrayCodeRankInv(r) |