DESC icon indicating copy to clipboard operation
DESC copied to clipboard

Improve logic for Dommaschk potential fitting

Open dpanici opened this issue 11 months ago • 0 comments

  • The logic when creating the basis modes for fitting a Dommaschk potential to a given magnetic field is cumbersome, especially when the field is stellarator symmetric, involving nested for loops and conditionals. It would be better to re-arrange things and refactor to use numpy where statements instead.

  • Further, it might be that if the field periodicity is known, that only ms which are multiples of NFP are needed, which should also be enforced in the fitting. Currently the fitting includes every l,m up to the specified max l and m.

dpanici avatar Mar 06 '24 19:03 dpanici