diff --git a/documentation/source/fusion-devices/stellarator.md b/documentation/source/fusion-devices/stellarator.md index 4687498df3..41eace1cd6 100644 --- a/documentation/source/fusion-devices/stellarator.md +++ b/documentation/source/fusion-devices/stellarator.md @@ -74,7 +74,7 @@ ixc = 10 * "ISS04 Renormalization Factor" (can also be fixed) ixc = 50 * Coil current density, aka winding pack thickness (required!) ixc = 59 * Winding Pack copper fraction ixc = 56 * Exponential Quench Dumping Time -ixc = 109 * Thermal alpha particle pressure (iterated to consistency, use together with `f_alpha_energy_confinement_min`) +ixc = 109 * Thermal alpha particle pressure (iterated to consistency, use together with `f_t_alpha_energy_confinement_min`) ixc = 169 * Achievable Temperature of the ECRH at the ignition point ``` @@ -131,7 +131,7 @@ The density limit relevant to certain stellarators experiments has been proposed $n_{max} = 0.25(PB_0/R_0a^2_p)^{1/2}$ -where $n$ is the line-averaged electron density in units of $10^{20} m^{-3}$, $p$ is the absorbed heating power (MW), $B_0$ is the on-axis field (t), $R_0$ is the major radius (m), and $a_p$ is the plasma minor radius (m). To enforce the Sudo density limit, turn on constraint equation no. 5 (`fdene != 1` can be used to scale the constraint bound). +where $n$ is the line-averaged electron density in units of $10^{20} m^{-3}$, $p$ is the absorbed heating power (MW), $B_0$ is the on-axis field (t), $R_0$ is the major radius (m), and $a_p$ is the plasma minor radius (m). To enforce the Sudo density limit, turn on constraint equation no. 5 (`f_nd_plasma_electron_limit_max != 1` can be used to scale the constraint bound). Note that the Sudo limit is a radiation based density limit and it is unclear how well this limit extrapolates to reactor parameters, especially as no impurity dependence e.g. is present in the Sudo model. PROCESS features an impurity dependent radiation module already which can be used with `icc=17` and by setting the `f_nd_impurity_electrons` vector. diff --git a/documentation/source/physics-models/plasma_confinement.md b/documentation/source/physics-models/plasma_confinement.md index 9e190f6b6b..58a33a2a6f 100644 --- a/documentation/source/physics-models/plasma_confinement.md +++ b/documentation/source/physics-models/plasma_confinement.md @@ -705,7 +705,7 @@ The constraint uses the loss power and thermal densities hence the inclusion of This constraint can be activated by stating `icc = 62` in the input file. -The value of `f_alpha_energy_confinement_min` can be set to the desired minimum total ratio between the alpha confinement and energy confinement times. +The value of `f_t_alpha_energy_confinement_min` can be set to the desired minimum total ratio between the alpha confinement and energy confinement times. [^1]: N. A. Uckan, International Atomic Energy Agency, Vienna (Austria) and ITER Physics Group, "ITER physics design guidelines: 1989", no. No. 10. Feb. 1990. [^2]: T.C. Hender et al., 'Physics Assessment of the European Reactor Study', AEA FUS 172, 1992. diff --git a/documentation/source/physics-models/plasma_density.md b/documentation/source/physics-models/plasma_density.md index 5b07350b93..7b87649713 100644 --- a/documentation/source/physics-models/plasma_density.md +++ b/documentation/source/physics-models/plasma_density.md @@ -5,7 +5,7 @@ calculated in the run routine `density_limit.run()`, which is called by `physics This constraint can be activated by stating `icc = 5` in the input file. -The value of `i_density_limit` can be set to apply the relevant limit. The variable `fdene` can be set to scale the constraint bound: `nd_plasma_electrons_vol_avg` / `nd_plasma_electrons_max` <= `fdene` (or `nd_plasma_electron_line` / `nd_plasma_electrons_max` <= `fdene` if `i_density_limit = 7`). +The value of `i_density_limit` can be set to apply the relevant limit. The variable `f_nd_plasma_electron_limit_max` can be set to scale the constraint bound: `nd_plasma_electrons_vol_avg` / `nd_plasma_electrons_max` <= `f_nd_plasma_electron_limit_max` (or `nd_plasma_electron_line` / `nd_plasma_electrons_max` <= `f_nd_plasma_electron_limit_max` if `i_density_limit = 7`). For the `i_density_limit = 1-5,8` scalings we scale the function output by the separatrix to volume averaged electron density so that we can set the limit on the volume averaged. **Therefore it is recommended to only use these scalings with an H-mode profile (`i_plasma_pedestal == 1`) otherwise the separatrix density (`nd_plasma_separatrix_electron`) will not be calculated.** diff --git a/examples/data/large_tokamak_eval_IN.DAT b/examples/data/large_tokamak_eval_IN.DAT index 464a9a84ba..1e60fd4241 100644 --- a/examples/data/large_tokamak_eval_IN.DAT +++ b/examples/data/large_tokamak_eval_IN.DAT @@ -92,16 +92,16 @@ dr_shld_blkt_gap = 0.02 * gap between vacuum vessel and blanket (m) *---------------Constraint Variables---------------* b_tf_inboard_max = 14.0 * maximum peak toroidal field (T) (`constraint equation 25`) -fdene = 1.2 * density limit constraint scale (constraint equation 5) +f_nd_plasma_electron_limit_max = 1.2 * density limit constraint scale (constraint equation 5) fiooic = 0.65 * margin for TF coil operating current / critical current ratio fjohc = 0.6 * margin for central solenoid current at end-of-flattop fjohc0 = 0.6 * margin for central solenoid current at beginning of pulse p_plant_electric_net_required_mw = 400.0 * required net electric power (MW) (`constraint equation 16`) p_fusion_total_max_mw = 3000 * maximum fusion power (MW) (`constraint equation 9`) -psepbqarmax = 10.0 * maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`) +p_div_bt_q_aspect_rmajor_max_mw = 10.0 * maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`) t_burn_min = 7200.0 * minimum burn time (s) (KE - no longer itv;; see issue #706) pflux_fw_neutron_max_mw = 2.0 * allowable neutron wall-load (MW/m2) (`constraint equation 8`) -f_alpha_energy_confinement_min = 5.0 * Lower limit on f_alpha_energy_confinement the ratio of alpha particle to energy confinement +f_t_alpha_energy_confinement_min = 5.0 * Lower limit on f_t_alpha_energy_confinementnt the ratio of alpha particle to energy confinement *-------------------Constraints--------------------* diff --git a/examples/data/large_tokamak_varied_min_net_electric_IN.DAT b/examples/data/large_tokamak_varied_min_net_electric_IN.DAT index 62bca42a29..92ae23800a 100644 --- a/examples/data/large_tokamak_varied_min_net_electric_IN.DAT +++ b/examples/data/large_tokamak_varied_min_net_electric_IN.DAT @@ -104,10 +104,10 @@ tmargmin = 1.5 icc = 60 temp_cs_superconductor_margin_min = 1.5 -* Lower limit on f_alpha_energy_confinement (ratio alpha particle/energy confinement times) * +* Lower limit on f_t_alpha_energy_confinement (ratio alpha particle/energy confinement times) * *-------------------------------------------------------------------------------* icc = 62 -f_alpha_energy_confinement_min = 5.0 +f_t_alpha_energy_confinement_min = 5.0 * dump time constraint for VV stresses * *--------------------------------------* @@ -128,7 +128,7 @@ icc = 81 *------------------* icc = 68 -psepbqarmax = 10.0 +p_div_bt_q_aspect_rmajor_max_mw = 10.0 * TF coil stress limits * *-----------------------* @@ -572,4 +572,4 @@ f_a_tf_turn_cable_space_extra_void = 0.3 i_tf_sc_mat = 1 * max fluence in the TF coil -nflutfmax = 1e22 +flu_tf_neutron_fast_maxutron_fast_max = 1e22 diff --git a/examples/data/large_tokamak_varyrun_IN.DAT b/examples/data/large_tokamak_varyrun_IN.DAT index 9aacab06e3..348b4c2363 100644 --- a/examples/data/large_tokamak_varyrun_IN.DAT +++ b/examples/data/large_tokamak_varyrun_IN.DAT @@ -104,10 +104,10 @@ tmargmin = 1.5 icc = 60 temp_cs_superconductor_margin_min = 1.5 -* Lower limit on f_alpha_energy_confinement (ratio alpha particle/energy confinement times) * +* Lower limit on f_t_alpha_energy_confinement (ratio alpha particle/energy confinement times) * *-------------------------------------------------------------------------------* icc = 62 -f_alpha_energy_confinement_min = 5.0 +f_t_alpha_energy_confinement_min = 5.0 * dump time constraint for VV stresses * *--------------------------------------* @@ -128,7 +128,7 @@ icc = 81 *------------------* icc = 68 -psepbqarmax = 10.0 +p_div_bt_q_aspect_rmajor_max_mw = 10.0 * TF coil stress limits * *-----------------------* @@ -572,4 +572,4 @@ f_a_tf_turn_cable_space_extra_void = 0.3 i_tf_sc_mat = 1 * max fluence in the TF coil -nflutfmax = 1e22 +flu_tf_neutron_fast_maxutron_fast_max = 1e22 diff --git a/process/core/constants.py b/process/core/constants.py index 100fe4d657..383fe8218a 100644 --- a/process/core/constants.py +++ b/process/core/constants.py @@ -269,8 +269,7 @@ """Density of Tungsten [kg/m3]""" TEMP_ROOM = 293.15 -""" Room temperature in Kelvin -Assume the room is at 20 degrees Celsius +""" Room temperature in Kelvin. Assuming the room is at 20 degrees Celsius """ RMU0 = 1.256637062e-6 diff --git a/process/core/input.py b/process/core/input.py index 540627a0a0..e0e99e991c 100644 --- a/process/core/input.py +++ b/process/core/input.py @@ -165,7 +165,7 @@ def __post_init__(self): "alstroh": InputVariable("pf_coil", float, range=(1000000.0, 100000000000.0)), "amortization": InputVariable("costs", float, range=(1.0, 50.0)), "anginc": InputVariable("divertor", float, range=(0.0, 1.5707)), - "aplasmin": InputVariable("build", float, range=(0.01, 10.0)), + "rminor_min": InputVariable("build", float, range=(0.01, 10.0)), "aux_build_h": InputVariable("buildings", float, range=(1.0, 100.0)), "aux_build_l": InputVariable("buildings", float, range=(10.0, 1000.0)), "aux_build_w": InputVariable("buildings", float, range=(10.0, 1000.0)), @@ -173,7 +173,7 @@ def __post_init__(self): "auxcool_l": InputVariable("buildings", float, range=(10.0, 1000.0)), "auxcool_w": InputVariable("buildings", float, range=(10.0, 1000.0)), "p_hcd_injected_min_mw": InputVariable("constraints", float, range=(0.01, 100.0)), - "avail_min": InputVariable("costs", float, range=(0.0, 1.0)), + "f_t_plant_available_min": InputVariable("costs", float, range=(0.0, 1.0)), "b_crit_upper_nbti": InputVariable("tfcoil", float, range=(0.0, 30.0)), "p_plant_electric_base": InputVariable( "heat_transport", float, range=(1000000.0, 10000000000.0) @@ -381,7 +381,7 @@ def __post_init__(self): "tfcoil", float, range=(100000000.0, 10000000000000.0) ), "f_a_tf_cool_outboard": InputVariable("tfcoil", float, range=(0.0, 1.0)), - "f_alpha_energy_confinement_min": InputVariable( + "f_t_alpha_energy_confinement_min": InputVariable( "constraints", float, range=(1.0, 100.0) ), "f_asym": InputVariable("stellarator", float, range=(0.9, 2.0)), @@ -428,7 +428,9 @@ def __post_init__(self): "fcuohsu": InputVariable("pf_coil", float, range=(0.0, 1.0)), "fcupfsu": InputVariable("pf_coil", float, range=(0.0, 1.0)), "f_a_tf_turn_cable_copper": InputVariable("tfcoil", float, range=(0.0, 1.0)), - "fdene": InputVariable("constraints", float, range=(0.001, 10.0)), + "f_nd_plasma_electron_limit_max": InputVariable( + "constraints", float, range=(0.001, 10.0) + ), "fiooic": InputVariable("constraints", float, range=(0.001, 1.0)), "fjohc": InputVariable("constraints", float, range=(0.001, 1.0)), "fjohc0": InputVariable("constraints", float, range=(0.001, 1.0)), @@ -460,7 +462,9 @@ def __post_init__(self): "heat_transport", float, range=(0.0, 0.2) ), "fracture_toughness": InputVariable("cs_fatigue", float, range=(0.1, 100000000.0)), - "fradpwr": InputVariable("constraints", float, range=(0.0, 1.0)), + "f_p_plasma_separatrix_rad_max": InputVariable( + "constraints", float, range=(0.0, 1.0) + ), "f_radius_beam_tangency_rmajor": InputVariable( "current_drive", float, range=(0.5, 2.0) ), @@ -584,7 +588,7 @@ def __post_init__(self): "i_nd_plasma_pedestal_separatrix": InputVariable( data_structure.physics_variables, int, choices=[0, 1] ), - "nflutfmax": InputVariable("constraints", float, range=(0.0, 1e24)), + "flu_tf_neutron_fast_max": InputVariable("constraints", float, range=(0.0, 1e24)), "j_tf_coil_full_area": InputVariable("tfcoil", float, range=(10000.0, 1000000000.0)), "f_a_cs_turn_steel": InputVariable("pf_coil", float, range=(0.001, 0.999)), "f_z_cs_tf_internal": InputVariable("pf_coil", float, range=(0.0, 2.0)), @@ -632,8 +636,12 @@ def __post_init__(self): "pres_div_chamber_burn": InputVariable("vacuum", float, range=(0.0, 10.0)), "pres_fw_coolant": InputVariable("fwbs", float, range=(100000.0, 100000000.0)), "prn1": InputVariable("divertor", float, range=(0.0, 1.0)), - "psepbqarmax": InputVariable("constraints", float, range=(1.0, 50.0)), - "pseprmax": InputVariable("constraints", float, range=(1.0, 60.0)), + "p_div_bt_q_aspect_rmajor_max_mw": InputVariable( + "constraints", float, range=(1.0, 50.0) + ), + "p_plasma_separatrix_rmajor_max_mw": InputVariable( + "constraints", float, range=(1.0, 60.0) + ), "ptargf": InputVariable("ife", float, range=(0.1, 100.0)), "temp_cp_max": InputVariable("tfcoil", float, range=(4.0, 573.15)), "ptfnucmax": InputVariable("constraints", float, range=(1e-06, 1.0)), @@ -934,7 +942,9 @@ def __post_init__(self): "wsvfac": InputVariable("buildings", float, range=(0.9, 3.0)), "xi_ebw": InputVariable("current_drive", float, range=(0.0, 1.0)), "xpertin": InputVariable("divertor", float, range=(0.0, 10.0)), - "zeff_max": InputVariable("constraints", float, range=(1.0, 10.0)), + "n_charge_plasma_effective_vol_avg_max": InputVariable( + "constraints", float, range=(1.0, 10.0) + ), "blktmodel": InputVariable("fwbs", int, choices=[0, 1]), "blkttype": InputVariable("fwbs", int, choices=[1, 2, 3]), "breedmat": InputVariable("fwbs", int, choices=[1, 2, 3]), diff --git a/process/core/io/obsolete_vars.py b/process/core/io/obsolete_vars.py index 9afa1ff419..960ae02ea9 100644 --- a/process/core/io/obsolete_vars.py +++ b/process/core/io/obsolete_vars.py @@ -182,7 +182,7 @@ "d_vv_in": "dr_vv_inboard", "d_vv_out": "dr_vv_outboard", "iblnkith": "i_blkt_inboard", - "taulimit": "f_alpha_energy_confinement_min", + "taulimit": "f_t_alpha_energy_confinement_min", "isc": "i_confinement_time", "iradloss": "i_rad_loss", "iinvqd": None, @@ -360,7 +360,7 @@ "tmax_croco": "temp_croco_quench_max", "vdalw": "v_tf_coil_dump_quench_max_kv", "vvhealw": None, - "zeffmax": "zeff_max", + "zeffmax": "n_charge_plasma_effective_vol_avg_max", "f_a_fw_hcd": "f_a_fw_outboard_hcd", "fpumpblkt": "f_p_blkt_coolant_pump_total_heat", "fpumpshld": "f_p_shld_coolant_pump_total_heat", @@ -457,6 +457,14 @@ "dr_hts_tape": "dr_tf_hts_tape", "coppera_m2_max": "tf_coppera_m2_max", "f_ster_div_single": None, + "fradpwr": "f_p_plasma_separatrix_rad_max", + "aplasmin": "rminor_min", + "nflutfmax": "flu_tf_neutron_fast_max", + "pseprmax": "p_plasma_separatrix_rmajor_max_mw", + "avail_min": "f_t_plant_available_min", + "f_alpha_energy_confinement_min": "f_t_alpha_energy_confinement_min", + "zeff_max": "n_charge_plasma_effective_vol_avg_max", + "psepbqarmax": "p_div_bt_q_aspect_rmajor_max_mw", } OBS_VARS_HELP = { diff --git a/process/core/io/plot/scans.py b/process/core/io/plot/scans.py index 09d7ea0d62..0ea06cb267 100644 --- a/process/core/io/plot/scans.py +++ b/process/core/io/plot/scans.py @@ -107,7 +107,7 @@ def plot_scan( 28: "b_plasma_toroidal_on_axis", 29: "radius_plasma_core_norm", 30: "", # OBSOLETE - 31: "f_alpha_energy_confinement_min", + 31: "f_t_alpha_energy_confinement_min", 32: "epsvmc", 33: "ttarget", 34: "qtargettotal", diff --git a/process/core/io/plot/summary.py b/process/core/io/plot/summary.py index a4ef142632..de5848fffe 100644 --- a/process/core/io/plot/summary.py +++ b/process/core/io/plot/summary.py @@ -2817,7 +2817,7 @@ def plot_main_plasma_information( f"Lawson Triple product: {mfile.get('nttau', scan=scan):.4e} keV·s/m³\n" f"Transport loss power assumed in scaling law: {mfile.get('p_plasma_loss_mw', scan=scan):.4f} MW\n" f"Plasma thermal energy (inc. $\\alpha$), $W$: {mfile.get('e_plasma_beta', scan=scan) / 1e9:.4f} GJ\n" - f"Alpha particle confinement time: {mfile.get('t_alpha_confinement', scan=scan):.4f} s | $\\tau_{{\\alpha}}/\\tau_{{e}}$: {mfile.get('f_alpha_energy_confinement', scan=scan):.4f}" + f"Alpha particle confinement time: {mfile.get('t_alpha_confinement', scan=scan):.4f} s | $\\tau_{{\\alpha}}/\\tau_{{e}}$: {mfile.get('f_t_alpha_energy_confinement', scan=scan):.4f}" ) axis.text( @@ -15563,7 +15563,7 @@ def main_plot( temp_quench_max=m_file.get("temp_tf_conductor_quench_max", scan=scan), cu_rrr=m_file.get("rrr_tf_cu", scan=scan), t_quench_detection=m_file.get("t_tf_quench_detection", scan=scan), - fluence=m_file.get("nflutfmax", scan=scan), + fluence=m_file.get("flu_tf_neutron_fast_max", scan=scan), j_operating=m_file.get("j_tf_wp", scan=scan), a_tf_turn_cable_space=m_file.get( "a_tf_turn_cable_space_no_void", scan=scan diff --git a/process/core/io/variable_metadata.py b/process/core/io/variable_metadata.py index aed8636100..69795448e7 100644 --- a/process/core/io/variable_metadata.py +++ b/process/core/io/variable_metadata.py @@ -54,7 +54,7 @@ class VariableMetadata: description="Average electron temperature", units="keV", ), - "f_alpha_energy_confinement_min": VariableMetadata( + "f_t_alpha_energy_confinement_min": VariableMetadata( latex=r"$max : \frac{\tau_\mathrm{\alpha}}{\tau_\mathrm{E}}$", description="Ratio of alpha heating time to energy confinement time", units="", diff --git a/process/core/scan.py b/process/core/scan.py index 30c157676b..534549e9ba 100644 --- a/process/core/scan.py +++ b/process/core/scan.py @@ -92,8 +92,8 @@ def _missing_(cls, var): "b_plasma_toroidal_on_axis", "Tor._field_on_axis_(T)", 28 ) coreradius = ScanVariable("coreradius", "Core_radius", 29) - f_alpha_energy_confinement_min = ScanVariable( - "f_alpha_energy_confinement_min", "t_alpha_confinement/taueff_lower_limit", 31 + f_t_alpha_energy_confinement_min = ScanVariable( + "f_t_alpha_energy_confinement_min", "t_alpha_confinement/taueff_lower_limit", 31 ) epsvmc = ScanVariable("epsvmc", "VMCON error tolerance", 32) boundu129 = ScanVariable("boundu(129)", " Neon upper limit", 38) @@ -1126,7 +1126,7 @@ def scan_select(self, nwp, swp, iscn): case 29: self.data.impurity_radiation.radius_plasma_core_norm = swp[iscn - 1] case 31: - self.data.constraints.f_alpha_energy_confinement_min = swp[iscn - 1] + self.data.constraints.f_t_alpha_energy_confinement_min = swp[iscn - 1] case 32: numerics.epsvmc = swp[iscn - 1] case 38: diff --git a/process/core/solver/constraints.py b/process/core/solver/constraints.py index 5b294cb0ba..4df8e363d8 100644 --- a/process/core/solver/constraints.py +++ b/process/core/solver/constraints.py @@ -9,6 +9,7 @@ from process.core import constants from process.core.exceptions import ProcessError, ProcessValueError from process.core.model import DataStructure +from process.models.physics.density_limit import DensityLimitModel from process.models.physics.physics import BetaComponentLimits from process.models.tfcoil.base import TFConductorModel @@ -378,9 +379,9 @@ def constraint_equation_4(constraint_registration, data): @ConstraintManager.register_constraint(5, "/m³", "<=") def constraint_equation_5(constraint_registration, data): - """Equation for density upper limit + """Equation for electron density upper limit - fdene: density limit scale + f_nd_plasma_electron_limit_max: density limit scale nd_plasma_electrons_vol_avg: electron density (/m³) nd_plasma_electrons_max: density limit (/m³) nd_plasma_electron_line: line averaged electron density (/m³) @@ -394,21 +395,27 @@ def constraint_equation_5(constraint_registration, data): - 6 Hugill-Murakami Mq limit; - 7 Greenwald limit - fdene scales the constraint such that: - nd_plasma_electrons_vol_avg / nd_plasma_electrons_max <= fdene. + f_nd_plasma_electron_limit_max scales the constraint such that: + nd_plasma_electrons_vol_avg / nd_plasma_electrons_max <= f_nd_plasma_electron_limit_max. (Except when i_density_limit=7 when nd_plasma_electron_line is used, not nd_plasma_electrons_vol_avg) """ # Apply Greenwald limit to line-averaged density - if data.physics.i_density_limit == 7: + if data.physics.i_density_limit == DensityLimitModel.GREENWALD: return leq( data.physics.nd_plasma_electron_line, - (data.physics.nd_plasma_electrons_max * data.constraints.fdene), + ( + data.physics.nd_plasma_electrons_max + * data.constraints.f_nd_plasma_electron_limit_max + ), constraint_registration, ) return leq( data.physics.nd_plasma_electrons_vol_avg, - (data.physics.nd_plasma_electrons_max * data.constraints.fdene), + ( + data.physics.nd_plasma_electrons_max + * data.constraints.f_nd_plasma_electron_limit_max + ), constraint_registration, ) @@ -422,7 +429,7 @@ def constraint_equation_6(constraint_registration, data): beta_poloidal: poloidal beta """ return leq( - (data.physics.eps * data.physics.beta_poloidal_vol_avg), + (data.physics.beta_poloidal_eps), data.physics.beta_poloidal_eps_max, constraint_registration, ) @@ -573,34 +580,17 @@ def constraint_equation_16(constraint_registration, data): ) -@ConstraintManager.register_constraint(17, "MW/m³", "<=") +@ConstraintManager.register_constraint(17, "", "<=") def constraint_equation_17(constraint_registration, data): - """Equation for radiation power upper limit - - f_p_alpha_plasma_deposited: fraction of alpha power deposited in plasma - p_hcd_injected_total_mw: total auxiliary injected power (MW) - vol_plasma: plasma volume (m³) - pden_alpha_total_mw: alpha power per volume (MW/m³) - pden_non_alpha_charged_mw: non-alpha charged particle fusion power per volume (MW/m³) - pden_plasma_ohmic_mw: ohmic heating power per volume (MW/m³) - pden_plasma_rad_mw: total radiation power per volume (MW/m³) - fradpwr: core radiation power limit scale - - fradpwr adds a margin to the constraint constraint such that + """Equation for plasma radiation fraction upper limit - pden_plasma_rad_mw / pradmaxpv <= fradpwr + f_p_plasma_separatrix_rad: plasma radiation fraction at the separatrix + f_p_plasma_separatrix_rad_max: maximum allowed plasma radiation fraction at the + separatrix """ - # Maximum possible power/vol_plasma that can be radiated (local) - pradmaxpv = ( - data.current_drive.p_hcd_injected_total_mw / data.physics.vol_plasma - + data.physics.pden_alpha_total_mw * data.physics.f_p_alpha_plasma_deposited - + data.physics.pden_non_alpha_charged_mw - + data.physics.pden_plasma_ohmic_mw - ) - return leq( - data.physics.pden_plasma_rad_mw / pradmaxpv, - data.constraints.fradpwr, + data.physics.f_p_plasma_separatrix_rad, + data.constraints.f_p_plasma_separatrix_rad_max, constraint_registration, ) @@ -651,11 +641,11 @@ def constraint_equation_21(constraint_registration, data): """Equation for minor radius lower limit rminor: plasma minor radius (m) - aplasmin: minimum minor radius (m) + rminor_min: minimum minor radius (m) """ return geq( data.physics.rminor, - data.build.aplasmin, + data.build.rminor_min, constraint_registration, ) @@ -732,20 +722,13 @@ def constraint_equation_24(constraint_registration, data): value = data.physics.beta_total_vol_avg # Here, the beta limit applies to only the thermal component, not the fast alpha or neutral beam parts elif data.physics.i_beta_component == BetaComponentLimits.THERMAL: - value = ( - data.physics.beta_total_vol_avg - - data.physics.beta_fast_alpha - - data.physics.beta_beam - ) + value = data.physics.beta_thermal_vol_avg # Beta limit applies to thermal + neutral beam: components of the total beta, i.e. excludes alphas elif data.physics.i_beta_component == BetaComponentLimits.THERMAL_AND_BEAM: value = data.physics.beta_total_vol_avg - data.physics.beta_fast_alpha # Beta limit applies to toroidal beta elif data.physics.i_beta_component == BetaComponentLimits.TOROIDAL: - value = ( - data.physics.beta_total_vol_avg - * (data.physics.b_plasma_total / data.physics.b_plasma_toroidal_on_axis) ** 2 - ) + value = data.physics.beta_toroidal_vol_avg return leq( value, @@ -762,7 +745,7 @@ def constraint_equation_25(constraint_registration, data): b_tf_inboard_peak_symmetric: mean peak field at TF coil (T) """ return leq( - data.tfcoil.b_tf_inboard_peak_symmetric, + data.tfcoil.b_tf_inboard_peak_with_ripple, data.constraints.b_tf_inboard_max, constraint_registration, ) @@ -1036,8 +1019,8 @@ def constraint_equation_43(constraint_registration, data): raise ProcessValueError("Do not use constraint 43 if itart=0") if data.tfcoil.i_tf_sup == TFConductorModel.WATER_COOLED_COPPER: - temp_cp_average = data.tfcoil.temp_cp_average - 273.15 - tcpav2 = data.tfcoil.tcpav2 - 273.15 + temp_cp_average = data.tfcoil.temp_cp_average - constants.TEMP_ROOM + tcpav2 = data.tfcoil.tcpav2 - constants.TEMP_ROOM else: temp_cp_average = data.tfcoil.temp_cp_average tcpav2 = data.tfcoil.tcpav2 @@ -1059,8 +1042,8 @@ def constraint_equation_44(constraint_registration, data): raise ProcessValueError("Do not use constraint 44 if itart=0") if data.tfcoil.i_tf_sup == TFConductorModel.WATER_COOLED_COPPER: # ! Copper case - temp_cp_max = data.tfcoil.temp_cp_max - 273.15 - temp_cp_peak = data.tfcoil.temp_cp_peak - 273.15 + temp_cp_max = data.tfcoil.temp_cp_max - constants.TEMP_ROOM + temp_cp_peak = data.tfcoil.temp_cp_peak - constants.TEMP_ROOM else: temp_cp_max = data.tfcoil.temp_cp_max temp_cp_peak = data.tfcoil.temp_cp_peak @@ -1176,12 +1159,12 @@ def constraint_equation_52(constraint_registration, data): def constraint_equation_53(constraint_registration, data): """Equation for fast neutron fluence on TF coil upper limit - nflutfmax: max fast neutron fluence on TF coil (n/m²) - nflutf: peak fast neutron fluence on TF coil superconductor (n/m²) + flu_tf_neutron_fast_max: max fast neutron fluence on TF coil (n/m²) + flu_tf_neutron_fast_peak: peak fast neutron fluence on TF coil superconductor (n/m²) """ return leq( - data.fwbs.nflutf, - data.constraints.nflutfmax, + data.fwbs.flu_tf_neutron_fast_peak, + data.constraints.flu_tf_neutron_fast_max, constraint_registration, ) @@ -1202,15 +1185,16 @@ def constraint_equation_54(constraint_registration, data): @ConstraintManager.register_constraint(56, "MW/m", "<=") def constraint_equation_56(constraint_registration, data): - """Equation for power through separatrix / major radius upper limit + """Equation for Pₛₑₚ / R₀ upper limit - pseprmax: maximum ratio of power crossing the separatrix to plasma major radius (Psep/R) (MW/m) + p_plasma_separatrix_rmajor_max_mw: maximum ratio of power crossing the separatrix to + plasma major radius (Pₛₑₚ / R₀) [MW/m] p_plasma_separatrix_mw: power to be conducted to the divertor region (MW) - rmajor: plasma major radius (m) + """ return leq( - (data.physics.p_plasma_separatrix_mw / data.physics.rmajor), - data.constraints.pseprmax, + data.physics.p_plasma_separatrix_rmajor_mw, + data.constraints.p_plasma_separatrix_rmajor_max_mw, constraint_registration, ) @@ -1248,26 +1232,26 @@ def constraint_equation_61(constraint_registration, data): """Equation for availability lower limit f_t_plant_available: Total plant availability fraction - avail_min: Minimum availability + f_t_plant_available_min: Minimum availability """ return geq( data.costs.f_t_plant_available, - data.costs.avail_min, + data.costs.f_t_plant_available_min, constraint_registration, ) @ConstraintManager.register_constraint(62, "", ">=") def constraint_equation_62(constraint_registration, data): - """Lower limit on f_alpha_energy_confinement the ratio of alpha particle to energy confinement times + """Lower limit on f_t_alpha_energy_confinement the ratio of alpha particle to energy confinement times t_alpha_confinement: alpha particle confinement time (s) t_energy_confinement: global thermal energy confinement time (sec) - f_alpha_energy_confinement_min: Lower limit on f_alpha_energy_confinement the ratio of alpha particle to energy confinement times + f_t_alpha_energy_confinement_min: Lower limit on f_t_alpha_energy_confinement the ratio of alpha particle to energy confinement times """ return geq( - data.physics.t_alpha_confinement / data.physics.t_energy_confinement, - data.constraints.f_alpha_energy_confinement_min, + data.physics.f_t_alpha_energy_confinement, + data.constraints.f_t_alpha_energy_confinement_min, constraint_registration, ) @@ -1290,12 +1274,12 @@ def constraint_equation_63(constraint_registration, data): def constraint_equation_64(constraint_registration, data): """Upper limit on Zeff - zeff_max: maximum value for Zeff + n_charge_plasma_effective_vol_avg_max: maximum value for Zeff n_charge_plasma_effective_vol_avg: plasma effective charge """ return leq( data.physics.n_charge_plasma_effective_vol_avg, - data.constraints.zeff_max, + data.constraints.n_charge_plasma_effective_vol_avg_max, constraint_registration, ) @@ -1346,7 +1330,7 @@ def constraint_equation_67(constraint_registration, data): def constraint_equation_68(constraint_registration, data): """Upper limit on Psep scaling (PₛₑₚBₜ / q₉₅AR₀) - psepbqarmax: maximum permitted value of ratio of PₛₑₚBₜ / q₉₅AR₀ (MWT/m) + p_div_bt_q_aspect_rmajor_max_mw: maximum permitted value of ratio of PₛₑₚBₜ / q₉₅AR₀ (MWT/m) p_plasma_separatrix_mw: Power to conducted to the divertor region (MW) b_plasma_toroidal_on_axis: toroidal field on axis (T) (iteration variable 2) q95: safety factor q at 95% flux surface @@ -1368,19 +1352,13 @@ def constraint_equation_68(constraint_registration, data): * data.physics.rmajor ) ), - data.constraints.psepbqarmax, + data.constraints.p_div_bt_q_aspect_rmajor_max_mw, constraint_registration, ) return leq( - ( - ( - data.physics.p_plasma_separatrix_mw - * data.physics.b_plasma_toroidal_on_axis - ) - / (data.physics.q95 * data.physics.aspect * data.physics.rmajor) - ), - data.constraints.psepbqarmax, + data.physics.p_div_bt_q_aspect_rmajor_mw, + data.constraints.p_div_bt_q_aspect_rmajor_max_mw, constraint_registration, ) diff --git a/process/data_structure/build_variables.py b/process/data_structure/build_variables.py index 6099057e16..f4fb5d7c3f 100644 --- a/process/data_structure/build_variables.py +++ b/process/data_structure/build_variables.py @@ -11,8 +11,8 @@ class InboardBlanketConfiguration(IntEnum): @dataclass(slots=True) class BuildData: - aplasmin: float = 0.25 - """minimum minor radius (m)""" + rminor_min: float = 0.25 + """Minimum allowed minor radius (m)""" available_radial_space: float = 0.0 """Minimal radial space between plasma and coils (m)""" diff --git a/process/data_structure/constraint_variables.py b/process/data_structure/constraint_variables.py index b55a45b772..7986752ac9 100644 --- a/process/data_structure/constraint_variables.py +++ b/process/data_structure/constraint_variables.py @@ -7,7 +7,7 @@ class ConstraintData: """minimum auxiliary power (MW) (`constraint equation 40`)""" beta_poloidal_max: float = 0.19 - """maximum poloidal beta (`constraint equation 48`)""" + """Maximum allowed poloidal beta (⟨βₚ⟩<) (`constraint equation 48`)""" big_q_plasma_min: float = 10.0 """minimum fusion gain Q (`constraint equation 28`)""" @@ -15,11 +15,12 @@ class ConstraintData: b_tf_inboard_max: float = 12.0 """maximum peak toroidal field (T) (`constraint equation 25`)""" - fdene: float = 1.0 - """Scaling value for density limit (constraint equation 5)""" + f_nd_plasma_electron_limit_max: float = 1.0 + """Max allowed fraction of electron density limit (`constraint equation 5`)""" - fradpwr: float = 1.0 - """Scaling value for radiation power upper limit (constraint equation 17)""" + f_p_plasma_separatrix_rad_max: float = 1.0 + """Maximum allowed plasma radiation fraction at the separatrix + (`constraint equation 17`)""" fiooic: float = 0.7 """Constraint margin for TF coil operating current / critical current ratio @@ -58,8 +59,8 @@ class ConstraintData: f_p_beam_shine_through_max: float = 1e-3 """maximum neutral beam shine-through fraction (`constraint equation 59`)""" - nflutfmax: float = 1.0e23 - """max fast neutron fluence on TF coil (n/m2) (`blktmodel>0`) (`constraint equation 53`) + flu_tf_neutron_fast_max: float = 1.0e23 + """Max allowed fast neutron fluence on TF coil (n/m²) (`blktmodel>0`) (`constraint equation 53`) Also used for demontable magnets (itart = 1) and superconducting coils (i_tf_sup = 1) and quench protection To set the CP lifetime (`constraint equation 85`) @@ -80,16 +81,16 @@ class ConstraintData: p_fusion_total_max_mw: float = 1.5e3 """maximum fusion power (MW) (`constraint equation 9`)""" - psepbqarmax: float = 9.5 - """maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`)""" + p_div_bt_q_aspect_rmajor_max_mw: float = 9.5 + """Max allowed value of PₛₑₚBₜ / q₉₅AR₀ [MWT/m] (`constraint equation 68`)""" - pseprmax: float = 25.0 - """maximum ratio of power crossing the separatrix to plasma major radius (Psep/R) (MW/m) + p_plasma_separatrix_rmajor_max_mw: float = 25.0 + """Maximum allowed ratio of power crossing the separatrix to plasma major radius (Pₛₑₚ / R₀) [MW/m] (`constraint equation 56`) """ ptfnucmax: float = 1e-3 - """maximum nuclear heating in TF coil (MW/m3) (`constraint equation 54`)""" + """Maximum allowed nuclear heating in TF coil [MW/m³] (`constraint equation 54`)""" tbrmin: float = 1.1 """minimum tritium breeding ratio (`constraint equation 52`)""" @@ -106,12 +107,12 @@ class ConstraintData: pflux_fw_neutron_max_mw: float = 1.0 """allowable neutron wall-load (MW/m2) (`constraint equation 8`)""" - f_alpha_energy_confinement_min: float = 5.0 - """Lower limit on f_alpha_energy_confinement the ratio of alpha particle to energy confinement + f_t_alpha_energy_confinement_min: float = 5.0 + """Minimum allowed value for f_t_alpha_energy_confinement, the ratio of alpha particle to energy confinement times (`constraint equation 62`) """ - zeff_max: float = 3.6 + n_charge_plasma_effective_vol_avg_max: float = 3.6 """maximum value for Zeff (`constraint equation 64`)""" f_h_mode_margin: float = 1.0 diff --git a/process/data_structure/cost_variables.py b/process/data_structure/cost_variables.py index 3efd8bd58c..cc285feb60 100644 --- a/process/data_structure/cost_variables.py +++ b/process/data_structure/cost_variables.py @@ -406,8 +406,8 @@ class CostData: bktcycles: float = 1.0e3 """Number of fusion cycles to reach allowable DPA from DEMO fw/blanket lifetime calculation""" - avail_min: float = 0.75 - """Minimum availability (`constraint equation 61`)""" + f_t_plant_available_min: float = 0.75 + """Minimum allowed plant availability (`constraint equation 61`)""" tok_build_cost_per_vol: float = 1283.0 """Unit cost for tokamak complex buildings, including building and site services ($/m3)""" diff --git a/process/data_structure/fwbs_variables.py b/process/data_structure/fwbs_variables.py index 0bc6208d9b..82a8fa15ce 100644 --- a/process/data_structure/fwbs_variables.py +++ b/process/data_structure/fwbs_variables.py @@ -222,7 +222,7 @@ class FWBSData: - =2 'large' """ - nflutf: float = 0.0 + flu_tf_neutron_fast_peak: float = 0.0 """peak fast neutron fluence on TF coil superconductor [n m^-2] """ npdiv: int = 2 diff --git a/process/data_structure/numerics.py b/process/data_structure/numerics.py index 8499302c80..7d4286f519 100644 --- a/process/data_structure/numerics.py +++ b/process/data_structure/numerics.py @@ -227,9 +227,9 @@ def description(self): * (59) Neutral beam shine-through fraction upper limit (NBI) (itv 105,6,19,4 ) * (60) Central solenoid temperature margin lower limit (SCTF) (itv 106) * (61) Minimum availability value (itv 107) -* (62) f_alpha_energy_confinement the ratio of particle to energy confinement times (itv 110) +* (62) f_t_alpha_energy_confinement the ratio of particle to energy confinement times (itv 110) * (63) The number of ITER-like vacuum pumps n_iter_vacuum_pumps < tfno (itv 111) -* (64) Zeff less than or equal to zeff_max (itv 112) +* (64) Zeff less than or equal to n_charge_plasma_effective_vol_avg_max (itv 112) * (65) Dump time set by VV loads (itv 56, 113) * (66) Limit on rate of change of energy in poloidal field (Use iteration variable 65(t_plant_pulse_plasma_current_ramp_up), 115) diff --git a/process/data_structure/physics_variables.py b/process/data_structure/physics_variables.py index 43af54e6a7..3eade41c81 100644 --- a/process/data_structure/physics_variables.py +++ b/process/data_structure/physics_variables.py @@ -105,79 +105,79 @@ class PhysicsData: """Total mass of the plasma (kg)""" alphaj: float = 1.0 - """current profile index""" + """Plasma current profile index (⍺ⱼ)""" # noqa: RUF001 alphaj_wesson: float = None """Wesson-like current profile index""" alphan: float = 0.25 - """density profile index""" + """Plasma density profile index (⍺ₙ)""" # noqa: RUF001 alphap: float = 0.0 - """pressure profile index""" + """Plasma pressure profile index (⍺ₚ)""" # noqa: RUF001 fusden_alpha_total: float = 0.0 - """Alpha particle production rate per unit volume, from plasma and beams [particles/m3/sec]""" + """Alpha particle production rate per unit volume, from plasma and beams [particles/m³/sec]""" fusden_plasma_alpha: float = 0.0 - """Alpha particle production rate per unit volume, just from plasma [particles/m3/sec]""" + """Alpha particle production rate per unit volume, just from plasma [particles/m³/sec]""" alphat: float = 0.5 - """temperature profile index""" + """Plasma temperature profile index (⍺ₜ)""" # noqa: RUF001 aspect: float = 2.907 - """aspect ratio (`iteration variable 1`)""" + """Plasma aspect ratio (A) (`iteration variable 1`) """ beamfus0: float = 1.0 """multiplier for beam-background fusion calculation""" beta_total_vol_avg: float = 0.042 - """Volume averaged total plasma beta (`iteration variable 5`) (calculated if stellarator)""" + """Volume averaged total plasma beta (⟨β⟩) (`iteration variable 5`) (calculated if stellarator)""" beta_fast_alpha: float = 0.0 - """fast alpha beta component""" + """Fast alpha beta component (β_alpha)""" beta_vol_avg_max: float = 0.0 - """Max allowable volume averaged beta""" + """Max allowable volume averaged beta (⟨β⟩<)""" beta_vol_avg_min: float = 0.0 - """Minimum allowable volume averaged beta""" + """Minimum allowable volume averaged beta (⟨β⟩>)""" beta_beam: float = 0.0 - """neutral beam beta component""" + """Neutral beam beta component (β_beam)""" beta_poloidal_vol_avg: float = 0.0 - """poloidal beta""" + """Volume averaged poloidal beta (⟨βₚ⟩)""" beta_poloidal_eps: float = 0.0 - """Poloidal beta and inverse aspcet ratio product""" + """Poloidal beta and inverse aspcet ratio product (⟨βₚ⟩*ε)""" beta_toroidal_vol_avg: float = 0.0 - """Plasma volume averaged toroidal beta""" + """Volume averaged toroidal beta (⟨βₜ⟩)""" beta_thermal_toroidal_profile: list[float] = field(default_factory=list) - """toroidal beta profile""" + """Toroidal beta profile""" beta_thermal_vol_avg: float = 0.0 - """Plasma volume averaged thermal beta""" + """Volume averaged thermal beta (⟨βₜₕ⟩)""" beta_thermal_poloidal_vol_avg: float = 0.0 - """Plasma volume averaged poloidal thermal beta""" + """Volume averaged poloidal thermal beta (⟨βₚₜₕ⟩)""" beta_thermal_toroidal_vol_avg: float = 0.0 - """Plasma volume averaged toloidal thermal beta""" + """Volume averaged toroidal thermal beta (⟨βₜₕ⟩)""" beta_norm_total: float = 0.0 - """normaised total beta""" + """Normalised total beta (βₙ)""" beta_norm_thermal: float = 0.0 - """normaised thermal beta""" + """Normalised thermal beta (βₙₜₕ)""" beta_norm_toroidal: float = 0.0 - """normaised toroidal beta""" + """Normalised toroidal beta (βₙₜ)""" beta_norm_poloidal: float = 0.0 - """normaised poloidal beta""" + """Normalised poloidal beta (βₙₚ)""" e_plasma_beta_thermal: float = 0.0 """Plasma thermal energy derived from thermal beta""" @@ -189,22 +189,22 @@ class PhysicsData: """Plasma surface average poloidal field (T)""" b_plasma_toroidal_on_axis: float = 5.68 - """Plasma toroidal field on axis (T) (`iteration variable 2`)""" + """Plasma toroidal field on axis (Bᴛ(R₀)) [T] (`iteration variable 2`)""" b_plasma_inboard_toroidal: float = 0.0 - """Plasma inboard toroidal field (T)""" + """Plasma inboard toroidal field (Bᴛ(R₀-a)) [T]""" b_plasma_outboard_toroidal: float = 0.0 - """Plasma outboard toroidal field (T)""" + """Plasma outboard toroidal field (Bᴛ(R₀+a)) [T]""" b_plasma_toroidal_profile: list[float] = field(default_factory=list) - """toroidal field profile in plasma (T)""" + """Plasma toroidal field profile (Bᴛ(r)) [T]""" b_plasma_total: float = 0.0 - """Sum of plasma total toroidal + poloidal field (T)""" + """Sum of plasma total toroidal + poloidal field (Bₜₒₜ) [T]""" e_plasma_magnetic_stored: float = 0.0 - """Plasma stored magnetic energy (J)""" + """Plasma stored magnetic energy [J]""" burnup: float = 0.0 """fractional plasma burnup""" @@ -213,7 +213,7 @@ class PhysicsData: """fractional plasma burnup user input""" b_plasma_vertical_required: float = 0.0 - """Vertical field needed for plasma equilibrium (T)""" + """Vertical field needed for plasma equilibrium (Bᵥ) [T]""" c_beta: float = 0.5 """Destabalisation parameter for i_beta_norm_max=4 beta limit""" @@ -230,10 +230,10 @@ class PhysicsData: """ nd_plasma_electrons_vol_avg: float = 9.8e19 - """Plasma volume averaged electron density (/m3) (`iteration variable 6`)""" + """Plasma volume averaged electron density (⟨nₑ⟩) [/m³] (`iteration variable 6`)""" nd_plasma_fuel_ions_vol_avg: float = 0.0 - """Plasma volume averaged fuel ion density (/m3)""" + """Plasma volume averaged fuel ion density (⟨n_fuel⟩) [/m³]""" dlamee: float = 0.0 """electron-electron coulomb logarithm""" @@ -244,16 +244,16 @@ class PhysicsData: nd_plasma_electron_max_array: list[float] = field( default_factory=lambda: np.zeros(8, dtype=np.float64) ) - """Array of plasma electron density upper limits values (/m3)""" + """Array of plasma electron density upper limits values (nₑ,max) [/m³]""" nd_plasma_alphas_vol_avg: float = 0.0 - """Plasma volume averaged thermal alpha density (/m3)""" + """Plasma volume averaged thermal alpha density (⟨n_α⟩) [/m³]""" # noqa: RUF001 nd_beam_ions: float = 0.0 - """hot beam ion density, variable (/m3)""" + """Hot beam ion density, variable (⟨n_beam⟩) [/m³]""" nd_beam_ions_out: float = 0.0 - """hot beam ion density from calculation (/m3)""" + """Hot beam ion density from calculation [/m³]""" beta_norm_max: float = 3.5 """Troyon-like coefficient for beta scaling""" @@ -274,25 +274,25 @@ class PhysicsData: """Stambaugh-like coefficient for beta scaling""" nd_plasma_electrons_max: float = 0.0 - """Plasma electron max density limit (/m3)""" + """Plasma electron max density limit (nₑ,max) [/m³]""" nd_plasma_ions_total_vol_avg: float = 0.0 - """Plasma volume averaged total ion density (/m3)""" + """Plasma volume averaged total ion density (⟨n_i⟩) [/m³]""" nd_plasma_electron_line: float = 0.0 - """Plasma line averaged electron density (/m3)""" + """Plasma line averaged electron density (⟨nₑ⟩_line) [/m³]""" nd_plasma_protons_vol_avg: float = 0.0 - """Plasma volume averaged proton ash density (/m3)""" + """Plasma volume averaged proton ash density (⟨n_p⟩) [/m³]""" ntau: float = 0.0 - """Fusion double product (s/m3)""" + """Fusion double product [s/m³]""" nTtau: float = 0.0 - """Lawson triple product [keV s / m3]""" + """Lawson triple product [keV s / m³]""" nd_plasma_impurities_vol_avg: float = 0.0 - """Plasma volume averaged impurity (Z > 2) ion density (/m3)""" + """Plasma volume averaged impurity (Z > 2) ion density (⟨n_imp⟩) [/m³]""" gradient_length_ne: float = None """Max. normalised gradient length in el. density (i_plasma_pedestal==0 only)""" @@ -306,7 +306,7 @@ class PhysicsData: """ eps: float = 0.34399724802 - """inverse aspect ratio""" + """Plasma inverse aspect ratio (ε)""" f_c_plasma_auxiliary: float = 0.0 """fraction of plasma current produced by auxiliary current drive""" @@ -488,10 +488,10 @@ class PhysicsData: """ nd_plasma_pedestal_electron: float = 4.0e19 - """electron density of pedestal [m⁻³] (`i_plasma_pedestal==1)""" + """Plasma electron density at pedestal (nₑ,pedestal) [/m³] (`i_plasma_pedestal==1)""" nd_plasma_separatrix_electron: float = 3.0e19 - """electron density at separatrix [m⁻³] (`i_plasma_pedestal==1)""" + """Plasma electron density at separatrix (nₑ,sep) [/m³] (`i_plasma_pedestal==1)""" i_nd_plasma_pedestal_separatrix: int = 1 """switch for pedestal and separatrix density calculation: @@ -503,16 +503,16 @@ class PhysicsData: """critical ballooning parameter value""" nd_plasma_separatrix_electron_eich_max: float = 0.0 - """Eich critical electron density at separatrix [m⁻³]""" + """Eich critical electron density at separatrix [/m³]""" plasma_res_factor: float = 1.0 """plasma resistivity pre-factor""" radius_plasma_pedestal_density_norm: float = 1.0 - """Normalised radius of density pedestal (`i_plasma_pedestal==1`)""" + """PPlasma normalised radius of density pedestal (ρₙ,pedestal) (`i_plasma_pedestal==1`)""" radius_plasma_pedestal_temp_norm: float = 1.0 - """Normalised radius of temperature pedestal (`i_plasma_pedestal==1`)""" + """Plasma normalised radius of temperature pedestal (ρₜ,pedestal) (`i_plasma_pedestal==1`)""" rho_te_max: float = 0.0 """r/a where the temperature gradient is largest (`i_plasma_pedestal==0`)""" @@ -521,24 +521,24 @@ class PhysicsData: """r/a where the density gradient is largest (`i_plasma_pedestal==0`)""" tbeta: float = 2.0 - """temperature profile index beta (`i_plasma_pedestal==1)""" + """Plasma temperature profile index beta (βₜ) (`i_plasma_pedestal==1)""" temp_plasma_pedestal_kev: float = 1.0 - """Plasma electron temperature of pedestal (keV) (`i_plasma_pedestal==1`)""" + """Plasma electron temperature of pedestal (Tₑ,pedestal) [keV] (`i_plasma_pedestal==1`)""" temp_plasma_separatrix_kev: float = 0.1 - """Plasma electron temperature at separatrix (keV) (`i_plasma_pedestal==1`) calculated if reinke + """Plasma electron temperature at separatrix (Tₑ,ₛₑₚ) [keV] (`i_plasma_pedestal==1`) calculated if reinke criterion is used (`icc=78`) """ i_beta_norm_max: int = 1 - """Switch for maximum normalised beta scaling:""" + """Switch for maximum normalised beta scaling (βₙ)""" i_ind_plasma_internal_norm: int = 0 - """Switch for plasma normalised internal inductance scaling:""" + """Switch for plasma normalised internal inductance scaling (lᵢ)""" i_alphaj: int = 0 - """Switch for current profile index scaling:""" + """Switch for plasma current profile index scaling (αⱼ) """ i_rad_loss: int = 1 """switch for radiation loss term usage in power balance (see User Guide): @@ -549,7 +549,7 @@ class PhysicsData: """ i_confinement_time: int = 34 - """switch for energy confinement time scaling law""" + """Switch for plasma energy confinement time scaling law (τₑ)""" i_plasma_wall_gap: int = 1 """Switch for plasma-first wall clearances at the mid-plane: @@ -599,13 +599,13 @@ class PhysicsData: """ plasma_square: float = 0.0 - """plasma squareness used by Sauter plasma shape""" + """Plasma squareness (ζ)""" kappa: float = 1.792 - """plasma separatrix elongation (calculated if `i_plasma_geometry = 1-5, 7 or 9-10`)""" + """Plasma separatrix elongation (κₐ) (calculated if `i_plasma_geometry = 1-5, 7 or 9-10`)""" kappa95: float = 1.6 - """plasma elongation at 95% surface (calculated if `i_plasma_geometry = 0-3, 6, or 8-10`)""" + """Plasma elongation at 95% surface (κ₉₅) (calculated if `i_plasma_geometry = 0-3, 6, or 8-10`)""" kappa_ipb: float = 0.0 """Separatrix elongation calculated for IPB scalings""" @@ -620,31 +620,31 @@ class PhysicsData: """margin to vertical stability""" pres_plasma_thermal_on_axis: float = 0.0 - """Plasma central thermal pressure (no fast ions or beam pressure) (Pa)""" + """Plasma central thermal pressure (p₀) (no fast ions or beam pressure) [Pa]""" pres_plasma_thermal_total_profile: list[float] = field(default_factory=list) - """Profile of total pressure in plasma (Pa)""" + """Profile of total pressure in plasma [Pa]""" pres_plasma_electron_profile: list[float] = field(default_factory=list) - """Profile of electron pressure in plasma (Pa)""" + """Profile of electron pressure in plasma [Pa]""" pres_plasma_ion_total_profile: list[float] = field(default_factory=list) - """Profile of ion pressure in plasma (Pa)""" + """Profile of ion pressure in plasma [Pa]""" pres_plasma_fuel_profile: list[float] = field(default_factory=list) - """Profile of fuel pressure in plasma (Pa)""" + """Profile of fuel pressure in plasma [Pa]""" j_plasma_on_axis: float = 0.0 - """Central plasma current density (A/m2)""" + """Central plasma current density (j₀) [A/m²]""" j_plasma_bootstrap_sauter_profile: list[float] = field(default_factory=list) - """Profile of bootstrap current density in plasma using Sauter et al scaling (A/m2)""" + """Profile of bootstrap current density in plasma using Sauter et al scaling [A/m²]""" n_plasma_profile_elements: int = 501 """Number of elements in plasma profile""" pres_plasma_thermal_vol_avg: float = None - """Volume averaged thermal plasma pressure (no fast ions or beam pressure) (Pa)""" + """Volume averaged thermal plasma pressure (⟨p⟩) (no fast ions or beam pressure) [Pa]""" f_dd_branching_trit: float = 0.0 """branching ratio for DD -> T""" @@ -710,7 +710,7 @@ class PhysicsData: """Power to conducted to the divertor region per major radius (MW/m)""" p_div_bt_q_aspect_rmajor_mw: float = 0.0 - """EU DEMO divertor protection parameter (MW/T/m)""" + """EU DEMO divertor protection parameter (PₛₑₚBₜ / q₉₅AR₀) [MWT/m]""" p_div_lower_separatrix_mw: float = 0.0 """Separatrix power conducted to the lower divertor region (calculated if `i_single_null = 0`) (MW)""" @@ -743,7 +743,7 @@ class PhysicsData: """ion/electron equilibration power per volume (MW/m3)""" plasma_current: float = 0.0 - """plasma current (A)""" + """Plasma current (Iₚ) [A]""" c_plasma_peng_analytic: float = 0.0 """Peng analytic plasma current (A)""" @@ -815,10 +815,10 @@ class PhysicsData: """SOL radiation power (MW) (`stellarator only`)""" pden_plasma_sync_mw: float = 0.0 - """synchrotron radiation power per volume (MW/m3)""" + """Plasma synchrotron radiation power per unit volume [MW/m³]""" p_plasma_sync_mw: float = 0.0 - """Total synchrotron radiation power from plasma (MW)""" + """Total synchrotron radiation power from plasma (Pₛₙ) [MW]""" i_l_h_threshold: int = 19 """switch for L-H mode power threshold scaling to use (see l_h_threshold_powers for list)""" @@ -871,11 +871,10 @@ class PhysicsData: """ion transport power per volume (MW/m3)""" q0: float = 1.0 - """Safety factor on axis""" + """Plasma safety factor on axis (q₀)""" q95: float = 0.0 - """Safety factor at 95% flux surface (iteration variable 18) (unless icurr=2 (ST current scaling), - in which case q95 = mean edge safety factor qbar) + """Plasma safety factor at 95% flux surface (q₉₅) (`iteration variable 18`) """ molflow_plasma_fuelling_required: float = 0.0 @@ -885,10 +884,10 @@ class PhysicsData: """tauratio /1.0/ : ratio of He and pellet particle confinement times""" q95_min: float = 0.0 - """lower limit for edge safety factor""" + """Plasmalower limit for edge safety factor""" qstar: float = 0.0 - """cylindrical safety factor""" + """Plasma cylindrical safety factor (qcyl)""" rad_fraction_sol: float = 0.8 """SoL radiation fraction""" @@ -918,10 +917,10 @@ class PhysicsData: """plasma inductance (H)""" rmajor: float = 8.14 - """plasma major radius (m) (`iteration variable 3`)""" + """Plasma major radius (R₀) [m] (`iteration variable 3`)""" rminor: float = 0.0 - """plasma minor radius (m)""" + """Plasma minor radius (a) [m]""" f_nd_beam_electron: float = 0.005 """hot beam density / n_e (`iteration variable 7`)""" @@ -977,41 +976,41 @@ class PhysicsData: t_alpha_confinement: float = 0.0 """alpha particle confinement time (sec)""" - f_alpha_energy_confinement: float = 0.0 - """alpha particle to energy confinement time ratio""" + f_t_alpha_energy_confinement: float = 0.0 + """Alpha particle to energy confinement time ratio""" temp_plasma_electron_vol_avg_kev: float = 12.9 - """volume averaged electron temperature (keV) (`iteration variable 4`)""" + """Plasma volume averaged electron temperature (⟨Tₑ⟩) [keV] (`iteration variable 4`)""" temp_plasma_electron_on_axis_kev: float = 0.0 - """central electron temperature (keV)""" + """Plasma central electron temperature (Tₑ₀) [keV]""" temp_plasma_electron_density_weighted_kev: float = 0.0 - """density weighted average electron temperature (keV)""" + """Density weighted average electron temperature (⟨Tₑ⟩_n) [keV]""" temp_plasma_electron_line_avg_kev: float = None """Line averaged electron temperature (keV)""" temp_plasma_ion_vol_avg_kev: float = 12.9 - """volume averaged ion temperature (keV). N.B. calculated from temp_plasma_electron_vol_avg_kev if `f_temp_plasma_ion_electron > 0.0`""" + """Volume averaged ion temperature (⟨Tᵢ⟩) [keV]. N.B. calculated from temp_plasma_electron_vol_avg_kev if `f_temp_plasma_ion_electron > 0.0`""" temp_plasma_ion_on_axis_kev: float = 0.0 - """central ion temperature (keV)""" + """Plasma central ion temperature (Tᵢ₀) [keV]""" temp_plasma_ion_density_weighted_kev: float = 0.0 - """density weighted average ion temperature (keV)""" + """Plasma density weighted average ion temperature (⟨Tᵢ⟩_n) [keV]""" f_temp_plasma_ion_electron: float = 1.0 - """ion temperature / electron temperature(used to calculate temp_plasma_ion_vol_avg_kev if `f_temp_plasma_ion_electron > 0.0`""" + """Plasma ratio of ion temperature to electron temperature (used to calculate temp_plasma_ion_vol_avg_kev if `f_temp_plasma_ion_electron > 0.0`)""" triang: float = 0.36 - """plasma separatrix triangularity (calculated if `i_plasma_geometry = 1, 3-5 or 7`)""" + """Plasma separatrix triangularity (δₐ) (calculated if `i_plasma_geometry = 1, 3-5 or 7`)""" triang95: float = 0.24 - """plasma triangularity at 95% surface (calculated if `i_plasma_geometry = 0-2, 6, 8 or 9`)""" + """Plasma triangularity at 95% surface (δ₉₅) (calculated if `i_plasma_geometry = 0-2, 6, 8 or 9`)""" vol_plasma: float = 0.0 - """plasma volume (m3)""" + """Plasma volume [m³]""" vs_plasma_burn_required: float = 0.0 """V-s needed during flat-top (heat + burn times) (Wb)""" @@ -1029,28 +1028,28 @@ class PhysicsData: """Plasma resistive flux consumption for plasma current ramp-up (Vs)(Wb)""" vs_plasma_total_required: float = 0.0 - """total V-s needed (Wb)""" + """Total V-s needed for full plasma pulse [Wb]""" pflux_fw_neutron_mw: float = 0.0 - """average neutron wall load (MW/m2)""" + """Average FW neutron wall load [MW/m²]""" pflux_plasma_surface_neutron_avg_mw: float = 0.0 - """Average neutron flux at plasma surface (MW/m2)""" + """Average neutron flux at plasma surface [MW/m²]""" wtgpd: float = 0.0 - """mass of fuel used per day (g)""" + """Mass of fuel used per day [g]""" a_plasma_poloidal: float = 0.0 - """plasma poloidal cross-sectional area [m^2]""" + """Plasma poloidal cross-sectional area [m²]""" n_charge_plasma_effective_vol_avg: float = 0.0 - """Volume averaged plasma effective charge""" + """Volume averaged plasma effective charge (⟨Zₑ⟩)""" n_charge_plasma_effective_profile: list[float] = field(default_factory=list) """Profile of plasma effective charge""" n_charge_plasma_effective_mass_weighted_vol_avg: float = 0.0 - """Plasma mass-weighted volume averaged plasma effective charge""" + """Plasma mass-weighted volume averaged plasma effective charge (⟨Zₑ⟩ₘ)""" len_plasma_debye_electron_profile: list[float] = field(default_factory=list) """Profile of electron Debye length in plasma (m)""" diff --git a/process/data_structure/scan_variables.py b/process/data_structure/scan_variables.py index f4cdec5d5a..6fcb155fa1 100644 --- a/process/data_structure/scan_variables.py +++ b/process/data_structure/scan_variables.py @@ -65,7 +65,7 @@
  • 28 b_plasma_toroidal_on_axis
  • 29 radius_plasma_core_norm
  • 30 fimpvar # OBSOLETE -
  • 31 f_alpha_energy_confinement_min +
  • 31 f_t_alpha_energy_confinement_min
  • 32 epsvmc
  • 33 ttarget
  • 34 qtargettotal diff --git a/process/models/availability.py b/process/models/availability.py index aca0568a3f..f5a01d20c6 100644 --- a/process/models/availability.py +++ b/process/models/availability.py @@ -1337,9 +1337,9 @@ def avail_st(self, output: bool): if self.data.tfcoil.i_tf_sup == TFConductorModel.SUPERCONDUCTING: po.ovarre( self.outfile, - "Max fast neutron fluence on TF coil (n/m2)", - "(nflutfmax)", - self.data.constraints.nflutfmax, + "Max allowed fast neutron fluence on TF coil (n/m²)", + "(flu_tf_neutron_fast_max)", + self.data.constraints.flu_tf_neutron_fast_max, "OP ", ) po.ovarre( @@ -1463,7 +1463,7 @@ def cp_lifetime(self): if self.data.fwbs.neut_flux_cp <= 0.0 else min( ( - self.data.constraints.nflutfmax + self.data.constraints.flu_tf_neutron_fast_max / (self.data.fwbs.neut_flux_cp * YEAR_SECONDS) ), self.data.costs.life_plant, diff --git a/process/models/physics/confinement_time.py b/process/models/physics/confinement_time.py index e83830d545..5af4ed56fe 100644 --- a/process/models/physics/confinement_time.py +++ b/process/models/physics/confinement_time.py @@ -1379,15 +1379,15 @@ def output_confinement_time_info(self): po.ovarrf( self.outfile, "Alpha particle to energy confinement time ratio (τ_α/τₑ)", # noqa: RUF001 - "(f_alpha_energy_confinement)", - self.data.physics.f_alpha_energy_confinement, + "(f_t_alpha_energy_confinement)", + self.data.physics.f_t_alpha_energy_confinement, "OP ", ) po.ovarrf( self.outfile, - "Lower limit on f_alpha_energy_confinement ((τ_α/τₑ)>)", # noqa: RUF001 - "(f_alpha_energy_confinement_min)", - self.data.constraints.f_alpha_energy_confinement_min, + "Lower limit on f_t_alpha_energy_confinement ((τ_α/τₑ)>)", # noqa: RUF001 + "(f_t_alpha_energy_confinement_min)", + self.data.constraints.f_t_alpha_energy_confinement_min, ) po.oblnkl(self.outfile) diff --git a/process/models/physics/physics.py b/process/models/physics/physics.py index bb05aa2131..c00645c279 100644 --- a/process/models/physics/physics.py +++ b/process/models/physics/physics.py @@ -896,7 +896,7 @@ def run(self): self.data.physics.molflow_plasma_fuelling_required, self.data.physics.rndfuel, self.data.physics.t_alpha_confinement, - self.data.physics.f_alpha_energy_confinement, + self.data.physics.f_t_alpha_energy_confinement, ) = self.phyaux( self.data.physics.aspect, self.data.physics.nd_plasma_fuel_ions_vol_avg, @@ -1446,7 +1446,7 @@ def phyaux( (nucleus-pairs/sec). - rndfuel (float): Fuel burnup rate (reactions/s). - t_alpha_confinement (float): Alpha particle confinement time (s). - - f_alpha_energy_confinement (float): Fraction of alpha energy confinement. + - f_t_alpha_energy_confinement (float): Fraction of alpha energy confinement. This subroutine calculates extra physics related items needed by other parts of the code. @@ -1492,7 +1492,7 @@ def phyaux( # Required fuelling rate (fuel ion pairs/second) (previously Amps) molflow_plasma_fuelling_required = rndfuel / burnup - f_alpha_energy_confinement = t_alpha_confinement / t_energy_confinement + f_t_alpha_energy_confinement = t_alpha_confinement / t_energy_confinement return ( burnup, @@ -1501,7 +1501,7 @@ def phyaux( molflow_plasma_fuelling_required, rndfuel, t_alpha_confinement, - f_alpha_energy_confinement, + f_t_alpha_energy_confinement, ) @staticmethod diff --git a/process/models/stellarator/stellarator.py b/process/models/stellarator/stellarator.py index a35695a1e7..758949cd76 100644 --- a/process/models/stellarator/stellarator.py +++ b/process/models/stellarator/stellarator.py @@ -458,7 +458,7 @@ def blanket_neutronics(self): _, _, _, - self.data.fwbs.nflutf, + self.data.fwbs.flu_tf_neutron_fast_peak, _, _, _, @@ -704,7 +704,7 @@ def st_fwbs(self, output: bool): coilhtmx, dpacop, htheci, - self.data.fwbs.nflutf, + self.data.fwbs.flu_tf_neutron_fast_peak, pheci, pheco, ptfiwp, @@ -1444,8 +1444,8 @@ def st_fwbs(self, output: bool): po.ovarre( self.outfile, "Maximum neutron fluence (n/m2)", - "(nflutf)", - self.data.fwbs.nflutf, + "(flu_tf_neutron_fast_peak)", + self.data.fwbs.flu_tf_neutron_fast_peak, ) po.ovarre( self.outfile, @@ -1732,7 +1732,7 @@ def sc_tf_coil_nuclear_heating_iter90(self): copper stabiliser displacements/atom htheci : peak TF coil case heating (MW/m3) - nflutf : + flu_tf_neutron_fast_peak : maximum neutron fluence (n/m2) pheci : inboard coil case heating (MW) @@ -1759,7 +1759,7 @@ def sc_tf_coil_nuclear_heating_iter90(self): pheci = 0.0 pheco = 0.0 raddose = 0.0 - nflutf = 0.0 + flu_tf_neutron_fast_peak = 0.0 dpacop = 0.0 p_tf_nuclear_heat_mw = 0.0 @@ -1877,7 +1877,7 @@ def sc_tf_coil_nuclear_heating_iter90(self): # Maximum neutron fluence in superconductor (n/m**2) - nflutf = ( + flu_tf_neutron_fast_peak = ( fpsdt * fact[3] * self.data.physics.pflux_fw_neutron_mw @@ -1903,7 +1903,7 @@ def sc_tf_coil_nuclear_heating_iter90(self): coilhtmx, dpacop, htheci, - nflutf, + flu_tf_neutron_fast_peak, pheci, pheco, ptfiwp, @@ -2341,7 +2341,7 @@ def st_phys(self, output): self.data.physics.molflow_plasma_fuelling_required, self.data.physics.rndfuel, self.data.physics.t_alpha_confinement, - self.data.physics.f_alpha_energy_confinement, + self.data.physics.f_t_alpha_energy_confinement, ) = self.physics.phyaux( self.data.physics.aspect, self.data.physics.nd_plasma_fuel_ions_vol_avg, diff --git a/process/models/tfcoil/superconducting.py b/process/models/tfcoil/superconducting.py index e9ae183a21..033e878153 100644 --- a/process/models/tfcoil/superconducting.py +++ b/process/models/tfcoil/superconducting.py @@ -1055,8 +1055,8 @@ def output_tf_superconductor_info(self): po.ovarre( self.outfile, "Max allowed fast neutron fluence on TF coil (n/m²)", - "(nflutfmax)", - self.data.constraints.nflutfmax, + "(flu_tf_neutron_fast_max)", + self.data.constraints.flu_tf_neutron_fast_max, "OP ", ) po.ovarre( @@ -1212,7 +1212,7 @@ def quench_heat_protection_current_density( b_tf_inboard_peak: float, cu_rrr: float, t_tf_quench_detection: float, - nflutfmax: float, + flu_tf_neutron_fast_max: float, ) -> tuple[float, float]: """Calculates the maximum conductor current density limited by the protection limit, and the discharge voltage for a TF coil. @@ -1243,7 +1243,7 @@ def quench_heat_protection_current_density( Copper residual-resistance-ratio t_tf_quench_detection : float Quench detection time (s) - nflutfmax : float + flu_tf_neutron_fast_max : float End-of-life neutron fluence in the copper (1/m²) Returns @@ -1276,7 +1276,7 @@ def quench_heat_protection_current_density( temp_quench_max=temp_tf_conductor_quench_max, cu_rrr=cu_rrr, t_quench_detection=t_tf_quench_detection, - fluence=nflutfmax, + fluence=flu_tf_neutron_fast_max, ) ) @@ -2713,7 +2713,7 @@ def run(self, output: bool = False): b_tf_inboard_peak=self.data.tfcoil.b_tf_inboard_peak_with_ripple, cu_rrr=self.data.tfcoil.rrr_tf_cu, t_tf_quench_detection=self.data.tfcoil.t_tf_quench_detection, - nflutfmax=self.data.constraints.nflutfmax, + flu_tf_neutron_fast_max=self.data.constraints.flu_tf_neutron_fast_max, ) ) @@ -4361,7 +4361,7 @@ def run(self, output: bool = False): b_tf_inboard_peak=self.data.tfcoil.b_tf_inboard_peak_with_ripple, cu_rrr=self.data.tfcoil.rrr_tf_cu, t_tf_quench_detection=self.data.tfcoil.t_tf_quench_detection, - nflutfmax=self.data.constraints.nflutfmax, + flu_tf_neutron_fast_max=self.data.constraints.flu_tf_neutron_fast_max, ) ) diff --git a/tests/integration/data/large_tokamak_IN.DAT b/tests/integration/data/large_tokamak_IN.DAT index 40eea2ece1..6264f1f9eb 100644 --- a/tests/integration/data/large_tokamak_IN.DAT +++ b/tests/integration/data/large_tokamak_IN.DAT @@ -145,7 +145,7 @@ sig_tf_wp_max = 7.5E8 * Allowable maximum shear stress in TF coil conduit (Tr *---------------------* icc = 5 ixc = 6 * nd_plasma_electrons_vol_avg [m-3] -fdene = 1.2 * density limit constraint scale (constraint equation 5) +f_nd_plasma_electron_limit_max = 1.2 * density limit constraint scale (constraint equation 5) nd_plasma_electrons_vol_avg = 7.5E19 * Neutron wall load upper limit * diff --git a/tests/integration/data/large_tokamak_eval.IN.DAT b/tests/integration/data/large_tokamak_eval.IN.DAT index 9b41d2fe5a..8b8c34e373 100644 --- a/tests/integration/data/large_tokamak_eval.IN.DAT +++ b/tests/integration/data/large_tokamak_eval.IN.DAT @@ -92,16 +92,16 @@ dr_shld_blkt_gap = 0.02 * gap between vacuum vessel and blanket (m) *---------------Constraint Variables---------------* b_tf_inboard_max = 14.0 * maximum peak toroidal field (T) (`constraint equation 25`) -fdene = 1.2 * density limit constraint scale (constraint equation 5) +f_nd_plasma_electron_limit_max = 1.2 * density limit constraint scale (constraint equation 5) fiooic = 0.65 fjohc = 0.6 fjohc0 = 0.6 p_plant_electric_net_required_mw = 400.0 * required net electric power (MW) (`constraint equation 16`) p_fusion_total_max_mw = 3000 * maximum fusion power (MW) (`constraint equation 9`) -psepbqarmax = 10.0 * maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`) +p_div_bt_q_aspect_rmajor_max_mw = 10.0 * maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`) t_burn_min = 7200.0 * minimum burn time (s) (KE - no longer itv;; see issue #706) pflux_fw_neutron_max_mw = 2.0 * allowable neutron wall-load (MW/m2) (`constraint equation 8`) -f_alpha_energy_confinement_min = 5.0 * Lower limit on f_alpha_energy_confinement the ratio of alpha particle to energy confinement +f_t_alpha_energy_confinement_min = 5.0 * Lower limit on f_t_alpha_energy_confinement the ratio of alpha particle to energy confinement *-------------------Constraints--------------------* @@ -382,7 +382,7 @@ temp_cs_superconductor_margin_min = 1.5 * minimum allowable temperature margin ; tmargmin = 1.5 * minimum allowable temperature margin ; TFC AND CS (K) v_tf_coil_dump_quench_max_kv = 10.0 * max voltage across TF coil during quench (kV) (`iteration variable 52`) f_a_tf_turn_cable_space_extra_void = 0.3 * coolant fraction of TFC 'cable' (`i_tf_sup=1`); or of TFC leg (`i_tf_ssup=0`) -nflutfmax = 1e22 * max fluence in the TF coil +flu_tf_neutron_fast_max = 1e22 * max fluence in the TF coil *-----------------Times Variables------------------* diff --git a/tests/regression/input_files/large_tokamak_eval.IN.DAT b/tests/regression/input_files/large_tokamak_eval.IN.DAT index e11c591ae0..b0860c6889 100644 --- a/tests/regression/input_files/large_tokamak_eval.IN.DAT +++ b/tests/regression/input_files/large_tokamak_eval.IN.DAT @@ -92,16 +92,16 @@ dr_shld_blkt_gap = 0.02 * gap between vacuum vessel and blanket (m) *---------------Constraint Variables---------------* b_tf_inboard_max = 14.0 * maximum peak toroidal field (T) (`constraint equation 25`) -fdene = 1.2 * density limit constraint scale (constraint equation 5) +f_nd_plasma_electron_limit_max = 1.2 * density limit constraint scale (constraint equation 5) fiooic = 0.65 * margin for TF coil operating current / critical current ratio fjohc = 0.6 * margin for central solenoid current at end-of-flattop fjohc0 = 0.6 * margin for central solenoid current at beginning of pulse p_plant_electric_net_required_mw = 400.0 * required net electric power (MW) (`constraint equation 16`) p_fusion_total_max_mw = 3000 * maximum fusion power (MW) (`constraint equation 9`) -psepbqarmax = 10.0 * maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`) +p_div_bt_q_aspect_rmajor_max_mw = 10.0 * maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`) t_burn_min = 7200.0 * minimum burn time (s) (KE - no longer itv;; see issue #706) pflux_fw_neutron_max_mw = 2.0 * allowable neutron wall-load (MW/m2) (`constraint equation 8`) -f_alpha_energy_confinement_min = 5.0 * Lower limit on f_alpha_energy_confinement the ratio of alpha particle to energy confinement +f_t_alpha_energy_confinement_min = 5.0 * Lower limit on f_t_alpha_energy_confinement the ratio of alpha particle to energy confinement *-------------------Constraints--------------------* @@ -384,7 +384,7 @@ temp_cs_superconductor_margin_min = 1.5 * minimum allowable temperature margin ; tmargmin = 1.5 * minimum allowable temperature margin ; TFC AND CS (K) v_tf_coil_dump_quench_max_kv = 10.0 * max voltage across TF coil during quench (kV) (`iteration variable 52`) f_a_tf_turn_cable_space_extra_void = 0.3 * coolant fraction of TFC 'cable' (`i_tf_sup=1`); or of TFC leg (`i_tf_ssup=0`) -nflutfmax = 1e22 * max fluence in the TF coil +flu_tf_neutron_fast_max = 1e22 * max fluence in the TF coil *-----------------Times Variables------------------* diff --git a/tests/regression/input_files/large_tokamak_nof.IN.DAT b/tests/regression/input_files/large_tokamak_nof.IN.DAT index 663fd28fe5..e1cd7ba171 100644 --- a/tests/regression/input_files/large_tokamak_nof.IN.DAT +++ b/tests/regression/input_files/large_tokamak_nof.IN.DAT @@ -114,10 +114,10 @@ tmargmin = 1.5 icc = 60 temp_cs_superconductor_margin_min = 1.5 -* Lower limit on f_alpha_energy_confinement (ratio alpha particle/energy confinement times) * +* Lower limit on f_t_alpha_energy_confinement (ratio alpha particle/energy confinement times) * *-------------------------------------------------------------------------------* icc = 62 -f_alpha_energy_confinement_min = 5.0 +f_t_alpha_energy_confinement_min = 5.0 * dump time constraint for VV stresses * *--------------------------------------* @@ -138,7 +138,7 @@ icc = 81 *------------------* icc = 68 -psepbqarmax = 10.0 +p_div_bt_q_aspect_rmajor_max_mw = 10.0 * TF coil stress limits * *-----------------------* @@ -152,7 +152,7 @@ sig_tf_wp_max = 7.5E8 * Allowable maximum shear stress in TF coil conduit (Tr *---------------------* icc = 5 ixc = 6 * nd_plasma_electrons_vol_avg [m-3] -fdene = 1.2 * density limit constraint scale (constraint equation 5) +f_nd_plasma_electron_limit_max = 1.2 * density limit constraint scale (constraint equation 5) nd_plasma_electrons_vol_avg = 7.5E19 * Neutron wall load upper limit * @@ -583,4 +583,4 @@ f_a_tf_turn_cable_space_extra_void = 0.3 i_tf_sc_mat = 1 * max fluence in the TF coil -nflutfmax = 1e22 +flu_tf_neutron_fast_max = 1e22 diff --git a/tests/regression/input_files/low_aspect_ratio_DEMO.IN.DAT b/tests/regression/input_files/low_aspect_ratio_DEMO.IN.DAT index 03d4ab16ae..28c48c5a41 100644 --- a/tests/regression/input_files/low_aspect_ratio_DEMO.IN.DAT +++ b/tests/regression/input_files/low_aspect_ratio_DEMO.IN.DAT @@ -181,10 +181,10 @@ beta_total_vol_avg = 3.71965626913446160e-02 ixc = 6 nd_plasma_electrons_vol_avg = 6.88360041658364314e+19 * DESCRIPTION: Electron density (/m3) -* JUSTIFICATION: Density is constrained by fdene +* JUSTIFICATION: Density is constrained by f_nd_plasma_electron_limit_max *ixc = 9 -fdene = 1.2 +f_nd_plasma_electron_limit_max = 1.2 *boundu(9) = 1.2 * DESCRIPTION: margin for density limit (used to set max greenwald fraction) * JUSTIFICATION: Used with icc=5 to enforce density limit @@ -464,7 +464,7 @@ pflux_fw_neutron_max_mw = 8.0 * DESCRIPTION: Allowable wall-load (mw/m2) (icc=8) * JUSTIFICATION: Used with icc=8 to set the enforced max allowable wall load -psepbqarmax = 6.0 +p_div_bt_q_aspect_rmajor_max_mw = 6.0 * DESCRIPTION: maximum ratio of Psep*Bt/qAR (MWT/m) (icc=68) * JUSTIFICATION: @@ -635,7 +635,7 @@ bkt_life_csf = 1 * DESCRIPTION: Switch for whether blanket model feeds n_cycle_min * JUSTIFICATION: choose to make the constraint on blanket and CS the same -nflutfmax = 0.0 +flu_tf_neutron_fast_max = 0.0 * DESCRIPTION: max fast neutron fluence on TF coil (n/m2) used in quench protection * JUSTIFICATION: zero to align with older quench protection model diff --git a/tests/regression/input_files/spherical_tokamak_eval.IN.DAT b/tests/regression/input_files/spherical_tokamak_eval.IN.DAT index 73a3b9f4be..319cb20f50 100644 --- a/tests/regression/input_files/spherical_tokamak_eval.IN.DAT +++ b/tests/regression/input_files/spherical_tokamak_eval.IN.DAT @@ -100,8 +100,8 @@ i_bldgs_size = 0 * switch between routines estimating building sizes (0 = defaul pflux_fw_rad_max = 1.2 * Maximum permitted radiation wall load (MW/m^2) (`constraint equation 67`) f_fw_rad_max = 1.0 * peaking factor for radiation wall load (`constraint equation 67`) p_fusion_total_max_mw = 2500.0 * maximum fusion power (MW) (`constraint equation 9`) -pseprmax = 40.0 * maximum ratio of power crossing the separatrix to plasma major radius (Psep/R) (MW/m) -f_alpha_energy_confinement_min = 5.0 * Lower limit on taup/taueff the ratio of alpha particle to energy confinement +p_plasma_separatrix_rmajor_max_mw = 40.0 * maximum ratio of power crossing the separatrix to plasma major radius (Psep/R) (MW/m) +f_t_alpha_energy_confinement_min = 5.0 * Lower limit on taup/taueff the ratio of alpha particle to energy confinement p_plant_electric_net_required_mw = 100.0 * minimum net electric *-------------------Constraints--------------------* diff --git a/tests/regression/input_files/st_regression.IN.DAT b/tests/regression/input_files/st_regression.IN.DAT index 76d5cc679e..c62de70ee1 100644 --- a/tests/regression/input_files/st_regression.IN.DAT +++ b/tests/regression/input_files/st_regression.IN.DAT @@ -166,9 +166,9 @@ aspect = 1.8 *icc = 21 * DESCRIPTION: Constraint equation for plasma minor radius lower limit * JUSTIFICATION: Turned off, dont care about lower limit -* VARIABLES: aplasmin (minimum minor radius (m)), rminor calculated in-situ +* VARIABLES: rminor_min (minimum minor radius (m)), rminor calculated in-situ -*aplasmin = 0 +*rminor_min = 0 * DESCRIPTION: Minimum minor radius (m) (icc=21) * JUSTIFICATION: Not used, using a defined minor radius @@ -412,11 +412,11 @@ icc = 15 *~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ icc = 62 -* DESCRIPTION: f_alpha_energy_confinement ratio of particle to energy confinement times +* DESCRIPTION: f_t_alpha_energy_confinement ratio of particle to energy confinement times * JUSTIFICATION: Used to constrain helium fraction * VARIABLES: t_energy_confinement,t_alpha_confinement calculated in-situ -f_alpha_energy_confinement_min = 5.0 +f_t_alpha_energy_confinement_min = 5.0 * DESCRIPTION: Ratio of Alpha Particle to Energy Confinement times (icc=62) * JUSTIFICATION: Default based on JET @@ -562,7 +562,7 @@ icc = 17 * JUSTIFICATION: Limit for plasma stability * VARIABLES: Rest calculated in-situ -fradpwr = 0.64 +f_p_plasma_separatrix_rad_max = 0.64 * DESCRIPTION: Radiation power upper limit constraint scale (constraint equation 17) * JUSTIFICATION: Scales the bound of constraint equation 17 @@ -621,9 +621,9 @@ f_nd_impurity_electrons(14) = 5e-05 *Tungsten *icc = 64 * DESCRIPTION: Upper limit on Zeff * JUSTIFICATION: Turned off, dont care about maximum effective charge -* VARIABLES: zeff_max (maximum value for Zeff), zeff calculated in-situ +* VARIABLES: n_charge_plasma_effective_vol_avg_max (maximum value for Zeff), zeff calculated in-situ -*zeff_max = +*n_charge_plasma_effective_vol_avg_max = * DESCRIPTION: Maximum value for Zeff (`constraint equation 64`) * JUSTIFICATION: Not set, not using icc = 64 @@ -678,7 +678,7 @@ i_single_null = 0 *icc = 68 * DESCRIPTION: Upper limit on Psep scaling (PsepB/qAR) * JUSTIFICATION: Turned off, just using Psep/R constraint -* VARIABLES: psepbqarmax (maximum permitted value of ratio of Psep*Bt/qAR (MWT/m)). Rest calculated in-situ +* VARIABLES: p_div_bt_q_aspect_rmajor_max_mw (maximum permitted value of ratio of Psep*Bt/qAR (MWT/m)). Rest calculated in-situ *psepbqarmaX * DESCRIPTION: maximum ratio of Psep*Bt/qAR (MWT/m) (`constraint equation 68`) @@ -691,7 +691,7 @@ icc = 56 * JUSTIFICATION: Divertor protection * VARIABLES: rmajor. p_plasma_separatrix_mw calculated in situ -pseprmax = 40.0 +p_plasma_separatrix_rmajor_max_mw = 40.0 * DESCRIPTION: Maximum ratio of Psep/R (MW/m) (icc=56) * JUSTIFICATION: @@ -1451,9 +1451,9 @@ tftmp = 20.0 *icc = 53 * DESCRIPTION: Constraint equation for fast neutron fluence on TF coil upper limit * JUSTIFICATION: Turned off, do not care about TF coil fluence. -* VARIABLES: nflutfmax(max fast neutron fluence on TF coil (n/m2)),nflutf calculated in situ +* VARIABLES: flu_tf_neutron_fast_max(max fast neutron fluence on TF coil (n/m2)),flu_tf_neutron_fast_peak calculated in situ -* nflutfmax = +* flu_tf_neutron_fast_max = * DESCRIPTION: max fast neutron fluence on TF coil (n/m2) (`blktmodel>0`) (`constraint equation 53`) * Also used for demontable magnets (itart = 1) and superconducting coils (i_tf_sup = 1) * To set the CP lifetime (`constraint equation 85`) @@ -1638,7 +1638,7 @@ i_pf_conductor = 0 *icc = 60 * DESCRIPTION: Constraint equation for Central Solenoid s/c temperature margin lower limit * JUSTIFICATION: Turned off, do not care about temp lower limit -* VARIABLES: avail_min (Minimum availability), f_t_plant_available calculated in-situ +* VARIABLES: f_t_plant_available_min (Minimum availability), f_t_plant_available calculated in-situ *temp_cs_superconductor_margin_min = * DESCRIPTION: Minimum allowable temp margin: CS (K) (icc = 60) @@ -3166,7 +3166,7 @@ i_plant_availability = 0 * JUSTIFICATION: Turned off, do not care about availability limit * VARIABLES: temp_cs_superconductor_margin_min (Minimum allowable temperature margin in CS (K)), temp_cs_superconductor_margin calculated in-situ -*avail_min = +*f_t_plant_available_min = * DESCRIPTION: Minimum availability (`constraint equation 61`) * JUSTIFICATION: testing diff --git a/tests/regression/input_files/stellarator_helias.IN.DAT b/tests/regression/input_files/stellarator_helias.IN.DAT index 1ca02320e9..96426a3033 100644 --- a/tests/regression/input_files/stellarator_helias.IN.DAT +++ b/tests/regression/input_files/stellarator_helias.IN.DAT @@ -44,9 +44,9 @@ icc = 82 * icc_toroidalbuild * Radial build consistency for stellarators (itv 172 f_avspace) icc = 83 * icc_placeforblanket -* f_alpha_energy_confinement the ratio of particle to energy confinement times (itv 110) +* f_t_alpha_energy_confinement the ratio of particle to energy confinement times (itv 110) icc = 62 * icc_thermalHe -f_alpha_energy_confinement_min = 4 * tau_He/tau_E +f_t_alpha_energy_confinement_min = 4 * tau_He/tau_E *** QUENCH LIMITS *** @@ -130,7 +130,7 @@ i_confinement_time = 38 *Switch for energy confinement time scaling law (38: ISS f_sync_reflect = 0.6 *Synchrotron wall reflectivity factor f_temp_plasma_ion_electron = 0.95 *Ion temperature / electron temperature -fradpwr = 1. +f_p_plasma_separatrix_rad_max = 1. *--------------Stellarator Variables---------------* diff --git a/tests/unit/models/stellarator/test_stellarator.py b/tests/unit/models/stellarator/test_stellarator.py index e999ef959f..d96f68a0e4 100644 --- a/tests/unit/models/stellarator/test_stellarator.py +++ b/tests/unit/models/stellarator/test_stellarator.py @@ -2277,7 +2277,7 @@ def test_sctfcoil_nuclear_heating_iter90( coilhtmx, dpacop, htheci, - nflutf, + flu_tf_neutron_fast_peak, pheci, pheco, ptfiwp, @@ -2289,7 +2289,9 @@ def test_sctfcoil_nuclear_heating_iter90( assert coilhtmx == pytest.approx(sctfcoilnuclearheatingiter90param.expected_coilhtmx) assert dpacop == pytest.approx(sctfcoilnuclearheatingiter90param.expected_dpacop) assert htheci == pytest.approx(sctfcoilnuclearheatingiter90param.expected_htheci) - assert nflutf == pytest.approx(sctfcoilnuclearheatingiter90param.expected_nflutf) + assert flu_tf_neutron_fast_peak == pytest.approx( + sctfcoilnuclearheatingiter90param.expected_nflutf + ) assert pheci == pytest.approx(sctfcoilnuclearheatingiter90param.expected_pheci) assert pheco == pytest.approx(sctfcoilnuclearheatingiter90param.expected_pheco) assert ptfiwp == pytest.approx(sctfcoilnuclearheatingiter90param.expected_ptfiwp) diff --git a/tests/unit/models/test_availability.py b/tests/unit/models/test_availability.py index 61a7cd47d9..638d1bedd5 100644 --- a/tests/unit/models/test_availability.py +++ b/tests/unit/models/test_availability.py @@ -623,7 +623,7 @@ def test_cp_lifetime(monkeypatch, availability, i_tf_sup, exp): """ monkeypatch.setattr(availability.data.tfcoil, "i_tf_sup", i_tf_sup) - monkeypatch.setattr(availability.data.constraints, "nflutfmax", 1.0e23) + monkeypatch.setattr(availability.data.constraints, "flu_tf_neutron_fast_max", 1.0e23) monkeypatch.setattr(availability.data.fwbs, "neut_flux_cp", 5.0e14) monkeypatch.setattr(availability.data.costs, "cpstflnc", 20.0) monkeypatch.setattr(availability.data.physics, "pflux_fw_neutron_mw", 5.0) diff --git a/tests/unit/models/tfcoil/test_sctfcoil.py b/tests/unit/models/tfcoil/test_sctfcoil.py index 75aedf4398..08e31b26fc 100644 --- a/tests/unit/models/tfcoil/test_sctfcoil.py +++ b/tests/unit/models/tfcoil/test_sctfcoil.py @@ -136,7 +136,7 @@ def test_protect(protectparam, sctfcoil): b_tf_inboard_peak=protectparam.peak_field, cu_rrr=protectparam.cu_rrr, t_tf_quench_detection=protectparam.detection_time, - nflutfmax=protectparam.fluence, + flu_tf_neutron_fast_max=protectparam.fluence, ) assert ajwpro == pytest.approx(protectparam.expected_ajwpro) @@ -382,7 +382,7 @@ def test_supercon(superconparam, monkeypatch, cicc_sctfcoil): ) monkeypatch.setattr( - cicc_sctfcoil.data.constraints, "nflutfmax", superconparam.fluence + cicc_sctfcoil.data.constraints, "flu_tf_neutron_fast_max", superconparam.fluence ) monkeypatch.setattr(