Routines to compute field line displacement and correlation length#389
Routines to compute field line displacement and correlation length#389
Conversation
The routines to compute the radial displacement of a magnetic field line and the radial magnetic field correlation length, useful to evaluate the occurrence of a nonzonal transion, are added to the `Diagnostics` class.
…/pyro-kinetics/pyrokinetics into enhancements/nonzonal_transition
| " before using any diagnostic" | ||
| ) | ||
|
|
||
| if self.pyro.gk_code not in ["CGYRO", "GS2", "GENE"]: |
There was a problem hiding this comment.
Why is it only available for these codes? The 4D fields are spit out for other codes too (STELLA/GKW)
There was a problem hiding this comment.
Yes, that's legacy. I will took that out.
… codes available in pyro
|
@mgiacomin the tests are failing due to an issue in the Freeqdsk library. Try merging unstable into this branch and then pushing again Overall this looks nice! I think it all works but it may be worth looking at if we can speed this up if this is quite slow. Haven't tried it myself yet. Have you benchmarked it against a "known" case? |
|
Haven't looked this myself yet unfortunately. I managed to talk to MJ Pueschel at APS and he is planning to have a look at a STEP simulation (/marconi_scratch/userexternal/dkennedy/contribs/MJ/) with his own NZT diagnostics. We could benchmark against this. |
|
After merging I have only tested these routines on STEP data. As Dan just wrote, he will carry out a proper benchmark with MJ Pueschel. |
|
Will wait for @dake0795 to check but happy to merge and then optimise later as needed. |
…dded a small routine to calculate the stocashtic diffusion coefficient - see Nevins et al, PRL, 2011
a3064dd to
e95d14d
Compare
This PR adds a couple of routines to the
Diagnostics, which can be used to evaluate the radial displacement of magnetic field lines after half poloidal turn and the radial correlation length of magnetic perturbations. These quantities are linked to the nonzonal transition described in Pueschel et al. Phys. Rev. Lett. 110, 155005 (2013) .@bpatel2107 I don't know while tests failed in the last commit where I simply added an example. Note that tests passed in the commit before and the example is not covered by any test.
@dake0795 Did you try these new routines? Are they working smoothly?