Make plasma-surface distance calculations robust when using NFP #652
Labels
low priority
Nice to have, but not needed right away
objectives
Adding or improving objective functions
Currently, if we want to compute the$(\theta=0, \zeta=0)$ the closest point on the winding surface is at $(\theta=0,\zeta=\epsilon$ where $\epsilon>0$ is some small number of radians. Then due to the symmetry, we can say that the closest point on the surface for the plasma point $(\theta=0, \zeta=2\pi/NFP)$ is on the surface at $(\theta=0, \zeta=2\pi/NFP+\epsilon)$ , which is NOT included on the grids we by default use when both surfaces have
PlasmaVesselDistance
objective for two surfaces withNFP>1
, and let's say the surface is such that for the point on the plasma surface atNFP>1
, resulting in instead a closest point which is not the true closest point.To remedy this, we can calculate distance not by using cartesian distance formula (which we do now) but instead by calculating the cylindrical coordinates of each, and calculating the distance using some modding of the toroidal angle with$2\pi/NFP$ to account for this
The text was updated successfully, but these errors were encountered: