Several MHDCT test problem additions.

#244 Merged at 3b3bb1f
  1. dcollins4096

Several mostly innocuous additions to make MHDCT usable for a wider array of test problems.

  1. Grid_FlagCellsToBeRefinedByJeansLength.C, move the allocation of temperature outside of the ProblemType conditional. (This is the only change that will have impact outside of MHDCT, I believe)
  2. CollapseMHD3DInitialize.C now supports MHDCT.
  3. Added a new BinaryCollapseTest that uses the MHD3DInitialize with MHDCT
  4. Grid_MHD2DTestInitializeGrid.C now supports MHDCT
  5. Added RayleightTaylor_CT_Suppressed.enzo test that uses MHD2D initializer. This suppresses the growth of RT mushrooms with a magnetic field.
  6. Changed the treatment of reflecting boundary conditions for MHDCT. This reflects what is done with Dedner. Not especially physically motivated in either case.
  7. Now with Banyl=1, DivB will be written out for MHDCT.
  8. TurbulenceSimulation now supports MHDCT

Comments (18)

  1. Sam Skillman

    Once the missing ' below gets fixed, I'll comment on the results of the automatic testing. While that is happening, can I get @jsoishi , @haoxu , and @jforbes to take a look at the PR? Specifically, could one of you make sure to run the new test problems and make the plots?

  2. Sam Skillman

    Ping @jsoishi @haoxu @jforbes . @dcollins4096 Looks like a merge conflict popped up.

    1. dcollins4096 author

      Interesting, it did not like that jforbes and I fixed the same thing twice. I've fixed it.

  3. J. S. Oishi

    All of this looks good to me, except the ExternalBoundary condition stuff, which I don't have the knowledge to evaluate. I will go ahead and approve, but please note especially @samskillman and @dcollins4096 that I haven't reviewed the code in src/enzo/ExternalBoundary_SetMagneticBoundary.C.

  4. Sam Skillman

    Made some style/comment comments. Everything else looks fine, though I admit I also don't know what the changes in the SetMagneticBoundary.C are changing. @dcollins4096 care to elaborate a bit?

    1. dcollins4096 author

      Originally I had treated the magnetic field as though it were the velocity. That's not entirely correct, and the physically correct solution will depend on the conductivity of the boundary. This caused significant noise at the corners. Treating the magnetic field like a scalar is still imperfect, but allows the code to run without generating extra inconsistencies. The big problem is that in the face, if changing the sign of the normal component is to be consistent, only solutions with zero normal component are consistent. For the Rayleigh Taylor problem, we want the pressure wave to be reflected at the bottom, but want a vertical field, which means the bottom cannot be a perfect conductor.

      A more elaborate boundary should be developed as its need arises, that allows for the specification of the conductivity at the interface. Any new boundary should be able to reproduce this result.

    1. Sam Skillman

      This is a side-effect of testing that was necessary for the grackle 2.0 PR. I'm now going to work on updating the gold again with the MHD RT test above. Comments/approvals should continue as if everything is passing.

    1. Sam Skillman

      My patch seems to have fixed the spurious errors from grackle stuff. @dcollins4096 mind adding an image generated from BinaryCollapseMHDCT/ It's in the full suite, which I don't run, and just want to see that the plot makes something useful to look at. After that, I'm okay with merging, and I'll update the gold tomorrow, hopefully combining this and the grackle stuff.

      1. dcollins4096 author

        I added an image for the BinaryCollapse, reduced the number of outputs, made it run faster. Also added a plot and notes for the rayleigh-taylor suppressed.