Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve Discrepancy in asymmetric boozmn output file compared to SIMSOPT booz_xform #1544

Open
dpanici opened this issue Jan 28, 2025 · 1 comment
Assignees
Labels
P2 Medium Priority, not urgent but should be on the near-term agend

Comments

@dpanici
Copy link
Collaborator

dpanici commented Jan 28, 2025

In #680 , the ability to create booz_xform style boozmn.nc output files was implemented in DESC. It agrees well with the hidden symmetries booz_xform code except in the numnc variable (techincally pmnc), which has the opposite sign in the simsopt and DESC output files. I am not sure what this discrepancy is, and it does not seem to affect the rest of the quantities, confusingly. Because it is numnc, it is only non-stellarator-symmetric calcuations which are affected.

Regardless, the DESC boozmn output files, when re-loaded and compared to the DESC quantities for R,Z, |B| etc, compare well, and the saved Fourier coefficients also agree well with those of the SIMSOPT booz_xform. The only discrepancy is with numnc.

In stellarator symmetry, every quantity agrees between the DESC output and the hidden symmetries booz_xform output

@dpanici dpanici added P2 Medium Priority, not urgent but should be on the near-term agend question Further information is requested labels Jan 28, 2025
@dpanici dpanici self-assigned this Jan 28, 2025
@dpanici dpanici removed the question Further information is requested label Jan 28, 2025
@dpanici
Copy link
Collaborator Author

dpanici commented Feb 5, 2025

It may be related to the way we save asymmetric wout files and convert from our lambda to the VMEC-equivalent lambda, if the lmnc is somehow saved with the wrong sign, then maybe that could explain this? though I definitely thought we had compared and got agreement in our asym wout... worth another check

linking the comment where we explain our logic when saving lambda to wout:

# should negate lambda coefs bc theta_DESC + lambda = theta_PEST,

# should negate lambda coefs bc theta_DESC + lambda = theta_PEST,
# since we are reversing the theta direction (and the theta_PEST direction),
# so -theta_PEST = -theta_DESC - lambda, so the negative of lambda is what
# should be saved, so that would be negating all of eq.L_lmn
# BUT since we are also reversing the poloidal angle direction, which
# would negate only the coeffs of L_lmn corresponding to m<0
# (sin theta modes in DESC), the effective result is to only
# negate the cos(theta) (m>0) lambda modes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2 Medium Priority, not urgent but should be on the near-term agend
Projects
None yet
Development

No branches or pull requests

1 participant