Bug in calculation of ShiftAngle (qloop) #1626
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When the integral of the field line pitch (qinty, qloop) is calculated
in
my_int_y
, the values of the loop integral were set in allregions. There are multiple surfaces for each xi index (PF regions,
and core) so this variable would be overwritten multiple times.
In practice it seems that the value it ended up with was the value in
the core, at least for the MAST double null g014220.00200 case I
tried. Hopefully this means that the bug didn't actually have any
effect on the resulting grids.
To try to catch bugs where qloop (->ShiftAngle) is used, the values
are set to NaN if they do not correspond to closed field-line regions.