-
Notifications
You must be signed in to change notification settings - Fork 11
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
labeling of PF coil currents in the code #3086
Comments
Hi Vinay, The PF coil currents are labelled in numerous different confusing ways in the code, I am afraid. I will have a look. |
Vinay is definitely right. The definitions are as follows, where we can read the final letter of each variable name as b=beginning, f=flattop and s=stop(?): real(dp), dimension(ngc2) :: curpfb
!! PF coil current array, at beginning of pulse (MA)
!! Indexed by coil number, not group number
real(dp), dimension(ngc2) :: curpff
!! PF coil current array, at flat top (MA)
!! Indexed by coil number, not group number
real(dp), dimension(ngc2) :: curpfs
!! PF coil current array, at end of pulse (MA)
!! Indexed by coil number, not group number The code, however, uses these variables in the opposite time-ordering: # Beginning of pulse: t = tv.tramp
pfv.curpfs[ncl] = 1.0e-6 * pf.ccl0[nng]
# Beginning of flat-top: t = tv.tramp+tv.tohs
pfv.curpff[ncl] = 1.0e-6 * (
pf.ccls[nng] - (pf.ccl0[nng] * pfv.fcohbof / pfv.fcohbop)
)
# End of flat-top: t = tv.tramp+tv.tohs+tv.t_fusion_ramp+tv.tburn
pfv.curpfb[ncl] = 1.0e-6 * (
pf.ccls[nng] - (pf.ccl0[nng] * (1.0e0 / pfv.fcohbop))
) This is followed by special code for the central solenoid, which also seems backward: # Current in Central Solenoid as a function of time
# N.B. If the Central Solenoid is not present then ioheof is zero.
pfv.curpfs[ncl] = -1.0e-6 * ioheof * pfv.fcohbop
pfv.curpff[ncl] = 1.0e-6 * ioheof * pfv.fcohbof
pfv.curpfb[ncl] = 1.0e-6 * ioheof Note that Possibly the use of the final letter "s" has confused the coder. |
The variable curpfb is defined as the PF coil current array, at beginning of pulse (MA), while in the module pfcoil.py, it seems to be defined as the current at EOF. Am I interpreting this correctly?
The text was updated successfully, but these errors were encountered: