Using CoilSet.from_eqdsk mis-classifies coils #645
Labels
bug
Something isn't working
build_stage
low priority
pf_coil
Tasks relating to the PF coils
STEP
Tasks relating to the STEP project
Describe the bug
The CoilSet.from_group_vecs method (called by CoilSet.from_eqdsk) uses a simple heuristic to distinguish between PF coils and CS coils: if
dx
anddz
are equal then they are PF coils, otherwise they are CS. Presumably this has been sufficient when working with conventional Tokamak designs but it is not reliable for Spherical Tokamaks.Steps to reproduce
I encountered this when trying to design some new behaviour for the STEP code (making it possible to read in old runs). This code is not public. A JSON serialisation of the original coils is given below:
After read-in, they were serialised as follows:
(There are also three coils missing but this appears to be due to a problem with the STEP reactor class itself creating coils separately from the EQDSK.)
Expected behaviour
The names of the coils in JSON above should be the same.
Environment (please complete the following information)
Additional context
This is not an urgent bug for me as I can reconstruct the coils directly from another serialisation produced by the STEP reactor code.
The text was updated successfully, but these errors were encountered: