Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions documentation/proc-pages/physics-models/error.txt
Original file line number Diff line number Diff line change
Expand Up @@ -504,11 +504,7 @@ account the fuel ratios \texttt{fdeut}, \texttt{ftrit} and
be input by the user.

The impurity fraction of one of the elements listed in array
\texttt{fimp} may be used as an iteration variable. The element to use
is specified using input parameter \texttt{impvar}, which may be set to
a value between 3 and \texttt{nimp}, and the initial estimate to use for
the element's impurity fraction must be set using iteration variable no.
102 (\texttt{fimpvar}).
\texttt{fimp} may be used as an iteration variable.

The synchrotron radiation power\footnote{Albajar, Nuclear Fusion
\textbf{41} (2001) 665} \footnote{Fidone, Giruzzi and Granata, Nuclear
Expand Down
6 changes: 2 additions & 4 deletions documentation/proc-pages/physics-models/plasma.md
Original file line number Diff line number Diff line change
Expand Up @@ -377,10 +377,8 @@ plasma quasi-neutrality taking into account the fuel ratios
be input by the user or selected as an iteration variable.

The impurity fraction of any one of the elements listed in array `fimp` (other than hydrogen
isotopes and helium) may be used as an iteration variable. The element to use is specified using
input parameter `impvar`, which may be set to a value between 3 and `nimp`, and the initial
estimate to use for the element's impurity fraction must be set using iteration
variable no. 102 (`fimpvar`).
isotopes and helium) may be used as an iteration variable.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we explain how this is done here, rather than just stating that it is possible?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was going to sort this in #3001. Though can do a quick fix here

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that would be prefered given it doesn't really make sense right now.

Copy link
Copy Markdown
Collaborator Author

@chris-ashe chris-ashe Dec 7, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@timothy-nunn Have added a description please check

The impurity fraction to be varied can be set simply with `fimp(i) = <value>`, where `i` is the corresponding number value for the desired impurity in the table above.

The synchrotron radiation power[^11] [^12] is assumed to originate from the
plasma core. The wall reflection factor `ssync` may be set by the user.
Expand Down
18 changes: 18 additions & 0 deletions process/io/obsolete_vars.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,4 +74,22 @@
"rad_fraction_core": "rad_fraction_LCFS",
"thshield": ["thshield_ib", "thshield_ob", "thshield_vb"],
"igeom": None,
"fgamp": None,
"divleg_profile_inner": None,
"divleg_profile_outer": None,
"iprimnloss": None,
"rho_ecrh": None,
"ifispact": None,
"fmsbc": None,
"fmsbl": None,
"fmsdwe": None,
"fmsdwi": None,
"fmsfw": None,
"fmsoh": None,
"fmssh": None,
"fmstf": None,
"quench_detection_ef": None,
"farc4tf": None,
"impvar": None,
"fimpvar": None,
}
4 changes: 2 additions & 2 deletions process/io/plot_radial_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ def main(args=None):
"tbrmin",
"bt",
"coreradius",
"fimpvar",
Comment thread
timothy-nunn marked this conversation as resolved.
"Obsolete", # Removed
"taulimit",
"epsvmc",
"ttarget",
Expand All @@ -277,7 +277,7 @@ def main(args=None):
"boundu(135)",
"blnkoth",
"fimp(9)",
"rho_ecrh",
"Obsolete", # Removed
"alstrtf",
"tmargmin_tf",
"boundu(152)",
Expand Down
4 changes: 2 additions & 2 deletions process/io/plot_scans.py
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ def main(args=None):
nsweep_dict[27] = "tbrmin"
nsweep_dict[28] = "bt"
nsweep_dict[29] = "coreradius"
nsweep_dict[30] = "fimpvar"
nsweep_dict[30] = "" # OBSOLETE
nsweep_dict[31] = "taulimit"
nsweep_dict[32] = "epsvmc"
nsweep_dict[33] = "ttarget"
Expand All @@ -359,7 +359,7 @@ def main(args=None):
nsweep_dict[40] = "boundu(135)"
nsweep_dict[41] = "blnkoth"
nsweep_dict[42] = "fimp(9)"
nsweep_dict[43] = "rho_ecrh"
nsweep_dict[43] = "Obsolete" # Removed
nsweep_dict[44] = "alstrtf"
nsweep_dict[45] = "tmargmin_tf"
nsweep_dict[46] = "boundu(152)"
Expand Down
2 changes: 1 addition & 1 deletion process/io/process_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -769,7 +769,7 @@ def __init__(self, configfilename="config_evaluate_uncertainties.json"):
if "bound" in varname:
del_list += [varname]
add_bounds = True
elif "fimp(" in varname: # fimpvar also exists!
elif "fimp(" in varname:
# has different format in MFILE!!
fimpno = int(varname.split("(")[1].split(")")[0])
self.output_vars[i] = "fimp({:02}".format(fimpno)
Expand Down
2 changes: 1 addition & 1 deletion scripts/create_dicts_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
]

# parameters that start with f, but are not f-values
NON_F_VALUES = ["fcohbop", "fvsbrnni", "feffcd", "fcutfsu", "fimpvar"]
NON_F_VALUES = ["fcohbop", "fvsbrnni", "feffcd", "fcutfsu"]

# PROCESS TF Coil types
DICT_TF_TYPE = {
Expand Down
32 changes: 0 additions & 32 deletions source/fortran/build_variables.f90
Original file line number Diff line number Diff line change
Expand Up @@ -85,30 +85,6 @@ module build_variables
real(dp) :: fcspc
!! Fraction of space occupied by CS pre-compression structure

real(dp) :: fmsbc
!! Martensitic fraction of steel in (non-existent!) bucking cylinder

real(dp) :: fmsbl
!! Martensitic fraction of steel in blanket

real(dp) :: fmsdwe
!! Martensitic fraction of steel in cryostat

real(dp) :: fmsdwi
!! Martensitic fraction of steel in vacuum vessel

real(dp) :: fmsfw
!! Martensitic fraction of steel in first wall

real(dp) :: fmsoh
!! Martensitic fraction of steel in central solenoid

real(dp) :: fmssh
!! Martensitic fraction of steel in shield

real(dp) :: fmstf
!! Martensitic fraction of steel in TF coil

real(dp) :: fseppc
!! Separation force in CS coil pre-compression structure

Expand Down Expand Up @@ -348,14 +324,6 @@ subroutine init_build_variables
d_vv_bot = 0.07D0
f_avspace = 1.0D0
fcspc = 0.6D0
fmsbc = 0.0D0
fmsbl = 0.0D0
fmsdwe = 0.0D0
fmsdwi = 0.0D0
fmsfw = 0.0D0
fmsoh = 0.0D0
fmssh = 0.0D0
fmstf = 0.0D0
fseppc = 3.5D8
fwarea = 0.0D0
fwareaib = 0.0D0
Expand Down
4 changes: 0 additions & 4 deletions source/fortran/current_drive_variables.f90
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,6 @@ module current_drive_variables
real(dp) :: gamma_ecrh
!! User input ECRH gamma (1.0e20 A/(W m^2))

real(dp) :: rho_ecrh
!! normalised minor radius at which electron cyclotron current drive is maximum

real(dp) :: xi_ebw
!! User scaling input for EBW plasma heating. Default 0.43

Expand Down Expand Up @@ -270,7 +267,6 @@ subroutine init_current_drive_variables
ftritbm = 1.0D-6
gamcd = 0.0D0
gamma_ecrh = 0.35D0
rho_ecrh = 0.1D0
xi_ebw = 0.8D0
iefrf = 5
iefrffix = 0
Expand Down
14 changes: 0 additions & 14 deletions source/fortran/divertor_variables.f90
Original file line number Diff line number Diff line change
Expand Up @@ -76,14 +76,6 @@ module divertor_variables
real(dp) :: divfix
!! divertor structure vertical thickness (m)

real(dp) :: divleg_profile_inner
!! length of 2D profile of inner leg surface (m)
!! default value = estimated from side-view strawperson diagram, August 2021

real(dp) :: divleg_profile_outer
!! length of 2D profile of outer leg surface (m)
!! default value = estimated from side-view strawperson diagram, August 2021

real(dp) :: divmas
!! divertor plate mass (kg)

Expand All @@ -99,9 +91,6 @@ module divertor_variables
real(dp) :: fdiva
!! divertor area fudge factor (for ITER, Sept 1990)

real(dp) :: fgamp
!! sheath potential factor (not used)

real(dp) :: fhout
!! fraction of power to outboard divertor (for single null)

Expand Down Expand Up @@ -207,14 +196,11 @@ subroutine init_divertor_variables
divdens = 1.0D4
divdum = 0
divfix = 0.2D0
divleg_profile_inner = 0.563D0
divleg_profile_outer = 2.596D0
divmas = 0.0D0
divplt = 0.035D0
divsur = 0.0D0
fdfs = 10.0D0
fdiva = 1.11D0
fgamp = 1.0D0
fhout = 0.0D0
fififi = 4.0D-3
flux_exp = 2.0D0
Expand Down
7 changes: 0 additions & 7 deletions source/fortran/heat_transport_variables.f90
Original file line number Diff line number Diff line change
Expand Up @@ -107,12 +107,6 @@ module heat_transport_variables
!! - =0 pre-2014 version
!! - =1 comprehensive 2014 model

integer :: iprimnloss
!! switch for lost neutron power through holes destiny (ipowerflow=0):
!!
!! - =0 does not contribute to energy generation cycle
!! - =1 contributes to energy generation cycle

integer :: iprimshld
!! Switch for shield thermal power destiny:
!!
Expand Down Expand Up @@ -224,7 +218,6 @@ subroutine init_heat_transport_variables
htpmw_shld = 0.0D0
htpsecmw = 0.0D0
ipowerflow = 1
iprimnloss = 0
iprimshld = 1
nphx = 0
pacpmw = 0.0D0
Expand Down
13 changes: 1 addition & 12 deletions source/fortran/impurity_radiation.f90
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ module impurity_radiation_module

!! fimp(nimp) /1.0,0.1,0.02,0.0,0.0,0.0,0.0,0.0,0.0016,0.0,0.0,0.0,0.0,0.0/ :
!! impurity number density fractions relative to electron density
!! (iteration variable 102 is fimp(impvar))
!!
real(dp), public, dimension(nimp) :: fimp

character*2, public, dimension(nimp) :: imp_label
Expand All @@ -62,15 +62,6 @@ module impurity_radiation_module
!! <LI> (13) Xenon
!! <LI> (14) Tungsten</UL>

!! fimpvar /1.0e-3/ : impurity fraction to be used as fimp(impvar)
!! (iteration variable 102)
! Deprecated
real(dp), public :: fimpvar

!! impvar : impurity to be iterated (deprecated)
!! variable number 102 is turned on
integer, public :: impvar

! Declare impurity data type

! type :: imp_dat
Expand Down Expand Up @@ -141,8 +132,6 @@ subroutine init_impurity_radiation_module
'Kr', &
'Xe', &
'W_'/)
fimpvar = 1.0D-3
impvar = 9
toolow = .false.
impurity_arr_Label = " "
impurity_arr_Z = 0
Expand Down
6 changes: 2 additions & 4 deletions source/fortran/initial.f90
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ subroutine initial
init_itv_74, init_itv_75, init_itv_79, init_itv_81, init_itv_82, init_itv_83, &
init_itv_84, init_itv_85, init_itv_86, init_itv_89, init_itv_90, init_itv_91, &
init_itv_92, init_itv_93, init_itv_94, init_itv_95, init_itv_96, init_itv_97, &
init_itv_98, init_itv_102, init_itv_103, init_itv_104, init_itv_105, &
init_itv_98, init_itv_103, init_itv_104, init_itv_105, &
init_itv_106, init_itv_107, init_itv_108, init_itv_109, init_itv_110, &
init_itv_111, init_itv_112, init_itv_113, init_itv_114, init_itv_115, &
init_itv_116, init_itv_117, init_itv_118, init_itv_119, init_itv_120, &
Expand Down Expand Up @@ -155,7 +155,6 @@ subroutine initial
call init_itv_97
call init_itv_98
!Not used
call init_itv_102
call init_itv_103
call init_itv_104
call init_itv_105
Expand Down Expand Up @@ -261,7 +260,7 @@ subroutine check
use physics_variables, only: aspect, eped_sf, fdeut, fgwped, fhe3, &
fgwsep, ftrit, ibss, i_single_null, icurr, ieped, idivrt, ishape, &
iradloss, isc, ipedestal, ilhthresh, itart, nesep, rhopedn, rhopedt, &
rnbeam, ifispact, neped, te, tauee_in, tesep, teped, itartpf, ftar
rnbeam, neped, te, tauee_in, tesep, teped, itartpf, ftar
use pulse_variables, only: lpulse
use reinke_variables, only: fzactual, impvardiv
use tfcoil_variables, only: casthi, casthi_is_fraction, casths, i_tf_sup, &
Expand Down Expand Up @@ -345,7 +344,6 @@ subroutine check

if (ftrit < 1.0D-3) then ! tritium fraction is negligible
triv = 0.0D0
ifispact = 0
trithtmw = 0.0D0
end if

Expand Down
Loading