3 SUBROUTINE b_stepon( KLUCH, k_auto, nstep, dt, time,
4 * r_ax,z_ax ,key_dmf,dpsdt)
8 c---------------------------------------------------------------
11 c-----------------------------------------------------------------------
20 real*8 platok,psex_bnd
26 common/psi_test/ psi_ext_bon(300)
34 IF( kluch .NE. 0 ) go to 1111
39 if(k_auto.eq.0) go to 2005
41 if(kastr.eq.1) go to 1150
43 write(fname,
'(a,a)') path(1:kname),
'durs.dat'
83 call
tab_efit(tokf,psax,eqdfn,rax,zax,b0,r0)
109 write(fname,
'(a,a)') path(1:kname),
'inpol.dat'
110 open(1,file=fname,form=
'formatted')
127 call
eqb( alf0,alf1,alf2, bet0,bet1,bet2, alw0,alw1,alw2,
129 * keyctr, nstep, tokf, rax,zax, b0,r0, psax, igdf,
130 * n_tht, n_psi, epsro, nurs, i_eqdsk,i_bsh,
149 psi0_bnd=psex_bnd+pspl_av
150 psex_bnd=psex_bnd+dpsdt*dt
157 call
eqb( alf0,alf1,alf2, bet0,bet1,bet2, alw0,alw1,alw2,
159 * keyctr, nstep, platok, rax,zax, b0,r0, psax, igdf,
160 * n_tht, n_psi, epsro, nurs, i_eqdsk,i_bsh,
169 SUBROUTINE f_stepon( KLUCH, k_auto, nstep, dt, time,
170 * voltpf, d_pf_mat,d_tcam_mat,r_ax,z_ax ,key_dmf)
174 c---------------------------------------------------------------
175 include
'Descript.inc'
184 c-----------------------------------------------------------------------
186 common/comeqg/ ncequi
187 common /nostep/ kstep
194 common /comsta/ platok,eqdfn,i_bsh
195 c-----------------------------------------------------------------------
197 dimension rc(nclim), zc(nclim), pc(nclim), psip(nclim),
198 * vc(nclim), hc(nclim)
200 dimension rc1(nclim), zc1(nclim), rc2(nclim), zc2(nclim),
201 * rc3(nclim), zc3(nclim), rc4(nclim), zc4(nclim)
203 INTEGER necon(nilim), ntype(nclim)
204 dimension wecon(nilim)
206 common/comst0/ res(njlim), volk(njlim), volkp1(njlim)
208 common/comst1/ pjk(njlim),pjkp1(njlim),pjkp(njlim),pjkd(njlim)
209 common/comst2/ psk(njlim), pskp1(njlim),pskp(njlim),pskm1(njlim)
211 common/comloo/ rloop(nloopp),zloop(nloopp),
212 & rprob(nprobp),zprob(nprobp),fiprob(nprobp),nloop,nprob
215 c***********************************************************************
221 c***********************************************************************
227 c***********************************************************************
228 common /key_for_pet/ key_fixbon
258 bbb = 1.d0 / (2.d0*pi)
280 c=============================================
285 IF( kluch .NE. 0 ) go to 1111
302 c--------------------------------------------------------------------
307 c-----------------------------------------------------------------
308 c --- input of
"BASIC" equlibrium
parameters from file
"durs.dat"
312 if(k_auto.eq.0) go to 2005
316 write(fname,
'(a,a)') path(1:kname),
'durs.dat'
317 open(1,file=fname,form=
'formatted')
366 c***********************************************************************
367 c--- input of positions of
"PF_PROBE" points:
369 CALL
propnt( nout, nter, ninfw, ngra1,
370 * nprob, rprob, zprob, fiprob )
371 c***********************************************************************
372 c--- input of positions of
"FL_LOOP" points:
374 CALL
loopnt( nout, nter, ninfw, ngra1,
375 * nloop, rloop, zloop )
376 c***********************************************************************
379 c***********************************************************************
380 c--- input
parameters of pfc system and passiv conductors
382 CALL
conduc( nc, ncequi, ncpfc, nfw, nbp, nvv,
383 * rc,zc, pc, vc,hc, ntype,
384 * rc1,zc1, rc2,zc2, rc3,zc3, rc4,zc4,
387 * nout, nter, ninfw, ngra1 )
389 c***********************************************************************
390 c--- definition induct. and selfinduct.
matrix
391 c--- for
"EDDY" conductors:
"PPIND" from
COMMON /ppidps/
394 CALL
l_matr( nout, nter, nc, ncpfc,
395 * ntype, rc, zc, vc, hc,
398 c-----------------------------------------------------------------------
399 c --- initial condition(currents) for circuit equations
403 IF( l.LE.nequi )
THEN
407 pjk(l) = pc(ncpfc+l-nequi)
412 write(fname,
'(a,a)') path(1:kname),
'currents.wr'
413 open(1,file=fname,form=
'formatted')
415 write(1,*) nequi,ncequi
416 write(1,*)(pjk(j),j=1,ncequi)
419 write(fname,
'(a,a)') path(1:kname),
'res_mat.wr'
420 open(1,file=fname,form=
'formatted')
422 write(1,*) (res(j),j=1,ncequi)
425 call
wrcoil(nc,ncpfc,rc,zc,pc,necon,wecon)
428 c..... toroidal currents of passive conductor structures
433 c********************************************************************
450 call
rd_prob( nprob, rprob, zprob, fiprob )
452 call
rd_loop( nloop, rloop, zloop )
454 write(fname,
'(a,a)') path(1:kname),
'currents.wr'
455 open(1,file=fname,form=
'formatted')
457 read(1,*) nequi,ncequi
458 read(1,*)(pjk(j),j=1,ncequi)
461 write(fname,
'(a,a)') path(1:kname),
'res_mat.wr'
462 open(1,file=fname,form=
'formatted')
464 read(1,*) (res(j),j=1,ncequi)
467 call
rdcoil(nc,ncpfc,rc,zc,pc,necon,wecon)
487 cccc voltage for
zero time-level
490 volk(i) = voltpf(i)*bbb
504 call
eqb( alf0,alf1,alf2, bet0,bet1,bet2, alw0,alw1,alw2,
506 * keyctr, nstep, platok, rax,zax, b0,r0, psax, igdf,
507 * n_tht, n_psi, epsro, nurs, i_eqdsk,i_bsh,
513 call
eqa_in(alf0,alf1,alf2,bet0,bet1,bet2,nursb,
514 * keyctr,igdf,kstep,platok,
516 * rloop,zloop,nloop, rprob,zprob,nprob,
517 * necon,wecon,ntype )
527 WRITE(*,*)
'START OF BASIC FREE BOUNDARY EQUILIBRIUM'
530 * keyctr,igdf,kstep,platok, psax,i_betp,betplx,
531 * rax,zax, rxpnt,zxpnt, psbo, psdel,
532 * rc,zc,nc, pjk,ncequi, psip,
533 * rloop,zloop,nloop, rprob,zprob,nprob,
534 * zli3,betpol,betful,
535 * necon,wecon,ntype , nflag, errarr)
540 call
f_bndmat(rc,zc,nc,rloop,zloop,nloop,rprob,zprob,nprob)
544 * keyctr,igdf,kstep,platok, psax,i_betp,betplx,
545 * rax,zax, rxpnt,zxpnt, psbo, psdel,
546 * rc,zc,nc, pjk,ncequi, psip,
547 * rloop,zloop,nloop, rprob,zprob,nprob,
548 * zli3,betpol,betful,
549 * necon,wecon,ntype , nflag, errarr)
554 c------------------------------------------------------------------
559 c------------------------------------------------------------------
584 psi0_bnd=pspl_av+psex_av
603 psi0_bnd=pspl_av+psex_av
606 dpsdt=(psi_eav-psi_eav_n)/dt
608 c***********************************************************************
609 c computing of
"VOLKP1" voltage for circuit equation
610 c for new time level kstep
613 volkp1(i) = voltpf(i)*bbb
618 c-----------------------------------------------------------------------
632 IF( kstep.EQ.1 )
THEN
641 CALL
evslv( nles, nreg, tstep, tstep, sigm,
642 * ncequi, volk, volkp1, res,
643 * psk, pskp1, pjk, pjkp1, pjkp,
644 * nout, nter, keypri, ereve )
647 c***********************************************************************
650 c----------------------------------------------------------------
651 c the initial approximation for the
case of closed-
loop evolution
656 c----------------------------------------------------------------
661 CALL
evslv( nles, nreg, tstepr, tstep, sigm,
662 * ncequi, volk, volkp1, res,
664 * pskm1, psk, pjk, pjkp1, pjkp,
665 * nout, nter, keypri, ereve )
668 c***********************************************************************
671 * keyctr,igdf,nstep,platok, psax,i_betp,betplx,
672 * rax,zax, rxpnt,zxpnt, psbo, psdel,
673 * rc,zc,nc, pjkp1,ncequi, psip,
674 * rloop,zloop,nloop, rprob,zprob,nprob,
675 * zli3,betpol,betful,
676 * necon,wecon,ntype , nflag, errarr)
679 c------------------------------------------------------------------
695 c------------------------------------------------------------------
710 CALL
evslv( nles, nreg, tstep, tstep, sigm,
711 * ncequi, volk, volkp1, res,
712 * psk, pskp1, pjk, pjkp1, pjkp,
713 * nout, nter, keypri, ereve )
723 pjkp1(l) = sgmcur*pjkp1(l) + (1.0d0 - sgmcur)*pjkp(l)
725 c-----------------------------------------------------------------------
728 * keyctr,igdf,nstep,platok, psax,i_betp,betplx,
729 * rax,zax, rxpnt,zxpnt, psbo, psdel,
730 * rc,zc,nc, pjkp1,ncequi, psip,
731 * rloop,zloop,nloop, rprob,zprob,nprob,
732 * zli3,betpol,betful,
733 * necon,wecon,ntype , nflag, errarr)
738 c------------------------------------------------------------------
744 c------------------------------------------------------------------
761 write(*,*)
'stepon:erro',erro
770 IF( erro .LT. enels )
THEN
774 IF( knel .GE. knels )
THEN
778 write(*,*)
'stepon:limit of iterations is exceded'
779 write(*,*)
'knel=',knel
794 c 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000 1000
800 d_pf_mat(i) = pjkp1(i)*1.0d6
804 d_tcam_mat(i-nequi) = pjkp1(i)*1.0d6
829 betpol_t(i_tim)=betpol
830 bettor_t(i_tim)=betful
subroutine eqa_ax(dt, time,
subroutine put_ipl(placur)
subroutine tab_efit(tokf, psax, eqdfn, rax, zax, b0, r0)
subroutine zero(x1, y1, x2, y2, func, err, x, y, izero, ll)
subroutine b_stepon(KLUCH, k_auto, nstep, dt, time,
subroutine conduc(NC, NCEQUI, NCPFC, NFW, NBP, NVV, RC, ZC, PC, VC, HC, NTYPE, RC1, ZC1, RC2, ZC2, RC3, ZC3, RC4, ZC4, RES, VOLK, VOLKP1, NECON, WECON, NOUT, NTER, NINFW, ngra1)
subroutine get_ipl(placur)
subroutine eqa_in(alf0, alf1, alf2, bet0, bet1, bet2, nursb,
subroutine loopnt(NOUT, NTER, NINFW, NGRA1,
subroutine rdcoil(nk, nkcoil, rk, zk, tk, necon, wecon)
subroutine eqb(alf0, alf1, alf2, bet0, bet1, bet2, alw0, alw1, alw2,
subroutine rd_loop(NLOO, RLOO, ZLOO)
subroutine get_flfi(flfi_m)
subroutine l_matr(NOUT,NTER, NC, NCPFC,
subroutine wr_step(numwr, time, istep)
subroutine f_psib_ext(psex_av)
subroutine wrcoil(nk, nkcoil, rk, zk, tk, necon, wecon)
subroutine psib_pla(pspl_av)
subroutine evslv(NLES, NREG, TSTEP0, TSTEP, SIGM, NJ, VOLK, VOLKP1, RES, PSPK, PSPKP1, CRPK, CRPKP1, CRPKP, NOUT, NTER, KEYPRI, EREVE)
subroutine put_psib0(psi0_bnd)
subroutine f_bndmat(rk, zk, nk, rlop, zlop, nlop, rprob, zprob, nprob)
subroutine evolution(T, R_in, R_out, El, Tr_l, Tr_U, Ip)
subroutine propnt(NOUT, NTER, NINFW, NGRA1,
subroutine rd_prob(NPRO, RPRO, ZPRO, FIPRO)
subroutine f_stepon(KLUCH, k_auto, nstep, dt, time,
subroutine f_psib_pla(pspl_av)