stinit Subroutine

public subroutine stinit()

Routine to initialise the variables relevant to stellarators author: P J Knight, CCFE, Culham Science Centre author: F Warmer, IPP Greifswald None This routine initialises the variables relevant to stellarators. Many of these may override the values set in routine initial. !

Arguments

None

Contents

Source Code


Source Code

  subroutine stinit

    !! Routine to initialise the variables relevant to stellarators
    !! author: P J Knight, CCFE, Culham Science Centre
    !! author: F Warmer, IPP Greifswald
    !! None
    !! This routine initialises the variables relevant to stellarators.
    !! Many of these may override the values set in routine
    !! <A HREF="initial.html">initial</A>.
    !!     !
    ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

    use build_variables, only: gapoh, iohcl, ohcth, tfootfi
    use current_drive_variables, only: irfcd
    use pfcoil_variables, only: ohhghf
    use physics_variables, only: aspect, dnbeta, kappa, kappa95, q, rmajor, &
      triang, hfac, tauscl
    use numerics, only: boundl, boundu
    use stellarator_variables, only: istell
    use tfcoil_variables, only: n_tf
    use times_variables, only: t_burn, t_cycle, tdown, t_between_pulse, t_fusion_ramp, t_current_ramp_up, &
      t_pulse_repetition, t_ramp_down, t_precharge
		use global_variables, only: icase
		use constants, only: pi, rmu0, nout
    implicit none

    !  Arguments

    !  Local variables

    !real(dp) :: fsum

    ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

    ! This routine is called before (!!!) the input file. put everything that depends on the input file in stcaller
    if (istell == 0) return

    boundu(1) = 40.0D0 ! allow higher aspect ratio
    !  Numerics quantities

    !boundl(1) = 5.0D0


    !boundu(3) = 30.0D0
    !boundu(29) = 20.0D0

    !  These lines switch off tokamak specifics (solenoid, pf coils, pulses etc.).
    !  Are they still up to date? (26/07/22 JL)

    !  Build quantities

    ohcth = 0.0D0
    iohcl = 0
    ohhghf = 0.0D0
    gapoh = 0.0D0
    tfootfi = 1.0D0

    !  Physics quantities

    dnbeta = 0.0D0
    kappa95 = 1.0D0
    triang = 0.0D0
    q = 1.03D0

    !  Turn off current drive

    irfcd = 0

    !  Times for different phases

    t_precharge = 0.0D0
    t_current_ramp_up = 0.0D0
    t_burn = 3.15576D7  !  one year
    t_ramp_down = 0.0D0
    t_pulse_repetition = t_current_ramp_up + t_fusion_ramp + t_burn + t_ramp_down
    tdown  = t_precharge + t_current_ramp_up + t_ramp_down + t_between_pulse
    t_cycle = t_precharge + t_current_ramp_up + t_fusion_ramp + t_burn + t_ramp_down + t_between_pulse

  end subroutine stinit