[Users] Carpet: operate on one refinement level?

Scott Hawley scott.hawley at belmont.edu
Mon May 20 16:35:13 CDT 2013


Hi, I can't seem to get the right combinations of modes correct...

I want to do a set of operations on the base grid, i.e. reflevel==0.

I've used BEGIN_REFLEVEL_LOOP before, but I no longer want a loop, just
level zero.
I'm trying this....

  BEGIN_GLOBAL_MODE (cctkGH) {
     BEGIN_LEVEL_MODE (cctkGH) {
        SWITCH_TO_LEVEL( cctkGH, 0) {

             //my other code here...
        } END_SWITCH_TO_LEVEL;
     } END_LEVEL_MODE;
  } END_GLOBAL_MODE;



...but I get a failed assertion:
Assertion failed: (not is_global_mode()), function level_escape, file
/Users/shawley/Cactus/configs/bruiser/build/Carpet/modes.cc, line 1123.


If I take out the two lines with "GLOBAL_MODE", I get the same failed
assertion.


What's the proper way to implement this?
Thanks,
Scott



P.S.- For now, I'll just use...

BEGIN_GLOBAL_MODE (cctkGH) {
   BEGIN_REFLEVEL_LOOP (cctkGH) {

      if (reflevel != 0) break;
      //my other code here....
   } END_REFLEVEL_LOOP;
} END_GLOBAL_MODE;



...but this seems pretty inelegant.




More information about the Users mailing list