17 REAL(rprec),
DIMENSION(ns,0:ntor,0:mpol1,ntmax),
INTENT(inout) :: gcr
18 REAL(rprec),
DIMENSION(ns,0:ntor,0:mpol1,ntmax),
INTENT(inout) :: gcz
19 REAL(rprec),
DIMENSION(ns,0:ntor,0:mpol1,ntmax),
INTENT(inout) :: gcl
20 real(rprec),
intent(in) :: fsqrz, old_fsqz
22 INTEGER,
PARAMETER :: n0=0
23 INTEGER,
PARAMETER :: m0=0
24 INTEGER,
PARAMETER :: m1=1
25 INTEGER,
PARAMETER :: n3d=0
26 INTEGER,
PARAMETER :: nasym=1
28 INTEGER :: jedge, j, n, m, i
31 logical,
parameter :: skip_scalfor_dbg = .true.
54 r1 = one/(2.0_dp*
r0scale)**2.0_dp
62 IF (deliter.lt.50 .and. fsqrz.lt.1.e-6_dp)
then
subroutine getfsq(gcr, gcz, gnormr, gnormz, gnorm, medge)
Compute total force residual on flux surfaces.
real(rprec), dimension(:), allocatable crd
real(rprec), dimension(:,:), allocatable brd
real(rprec), dimension(:,:), allocatable azd
integer iter1
number of iterations at which the currently active evolution was branched off from
real(rprec), dimension(:,:), allocatable brm
real(rprec), dimension(:,:), allocatable bzd
real(rprec), dimension(:,:), allocatable bzm
real(rprec), dimension(:,:), allocatable ard
real(rprec), dimension(:,:), allocatable arm
integer iter2
total number of iterations
real(rprec), dimension(:,:), allocatable azm
integer, parameter modd
parity selection label for odd poloidal modes of R and Z
integer ntmax
number of contributing Fourier basis function (can be 1, 2 or 4); assigned in read_indata()
integer, parameter meven
parity selection label for even poloidal modes of R and Z
subroutine constrain_m1(gcr, gcz, old_fsqz)
Compute internal gr , gz required for constraint.
subroutine scale_m1(gcr, gcz)
Compute internal gr , gz required for constraint.
subroutine residue_con(gcr, gcz, gcl, fsqrz, old_fsqz)
Compute invariant residuals.
subroutine scalfor(gcx, axm, bxm, axd, bxd, cx, iflag, skip_scalfor_dbg)
Build forces from different contributions.