diff --git a/documentation/source/unique-models/buildings_sizes.md b/documentation/source/unique-models/buildings_sizes.md index 9b4570b15d..5dfaa8423d 100644 --- a/documentation/source/unique-models/buildings_sizes.md +++ b/documentation/source/unique-models/buildings_sizes.md @@ -141,4 +141,4 @@ Amalgamating multiple individual buildings (and using an average height), this e ## Summary variables - Effective floor area for AC power module, `a_plant_floor_effective`: total floor area (m2) across all buildings. This estimate attempts to account for multiple floors within buildings by assuming an average storey height of 6m across the site; the volume of all buildings is therefore summed and divided by 6. -- Total volume of nuclear buildings, `volnucb`: sum of all nuclear building (external) volumes. +- Total volume of nuclear buildings, `vol_plant_nuclear_buildings`: sum of all nuclear building (external) volumes. diff --git a/process/core/init.py b/process/core/init.py index e3dada67a7..e0f5ae2e9c 100644 --- a/process/core/init.py +++ b/process/core/init.py @@ -403,7 +403,7 @@ def check_process(inputs): # noqa: ARG001 if ( data_structure.physics_variables.f_plasma_fuel_tritium < 1.0e-3 ): # tritium fraction is negligible - data_structure.buildings_variables.triv = 0.0 + data_structure.buildings_variables.vol_plant_tritium_fuel_building = 0.0 data_structure.heat_transport_variables.p_tritium_plant_electric_mw = 0.0 if data_structure.impurity_radiation_module.f_nd_impurity_electrons[1] != 0.1: diff --git a/process/core/input.py b/process/core/input.py index 7cb7b76577..62c2caafed 100644 --- a/process/core/input.py +++ b/process/core/input.py @@ -181,7 +181,7 @@ def __post_init__(self): "fkzohm": InputVariable(data_structure.physics_variables, float, range=(0.5, 2.0)), "abktflnc": InputVariable(data_structure.cost_variables, float, range=(0.1, 100.0)), "adivflnc": InputVariable(data_structure.cost_variables, float, range=(0.1, 100.0)), - "admv": InputVariable( + "vol_plant_administration_building": InputVariable( data_structure.buildings_variables, float, range=(1.0e4, 1.0e6) ), "airtemp": InputVariable( @@ -344,7 +344,7 @@ def __post_init__(self): "control_buildings_w": InputVariable( data_structure.buildings_variables, float, range=(10.0, 1000.0) ), - "conv": InputVariable( + "vol_plant_control_building": InputVariable( data_structure.buildings_variables, float, range=(10000.0, 1000000.0) ), "coolp": InputVariable( @@ -794,7 +794,9 @@ def __post_init__(self): "fmgdmw": InputVariable( data_structure.heat_transport_variables, float, range=(0.0, 100.0) ), - "fndt": InputVariable(data_structure.buildings_variables, float, range=(0.0, 10.0)), + "dz_plant_reactor_building_foundation": InputVariable( + data_structure.buildings_variables, float, range=(0.0, 10.0) + ), "f_p_beam_orbit_loss": InputVariable( data_structure.current_drive_variables, float, range=(0.0, 0.999) ), @@ -1232,9 +1234,13 @@ def __post_init__(self): "outgrat_fw": InputVariable( data_structure.vacuum_variables, float, range=(1e-10, 1e-06) ), - "rbrt": InputVariable(data_structure.buildings_variables, float, range=(0.0, 10.0)), + "dz_plant_reactor_building_roof": InputVariable( + data_structure.buildings_variables, float, range=(0.0, 10.0) + ), "rbvfac": InputVariable(data_structure.buildings_variables, float, range=(0.9, 3.0)), - "rbwt": InputVariable(data_structure.buildings_variables, float, range=(0.0, 10.0)), + "dx_plant_reactor_building_wall": InputVariable( + data_structure.buildings_variables, float, range=(0.0, 10.0) + ), "radius_cp_coolant_channel": InputVariable( data_structure.tfcoil_variables, float, range=(1e-06, 1.0) ), @@ -1326,7 +1332,9 @@ def __post_init__(self): "rrr_tf_cu": InputVariable( data_structure.tfcoil_variables, float, range=(1.0, 1000.0) ), - "rxcl": InputVariable(data_structure.buildings_variables, float, range=(0.0, 10.0)), + "dr_plant_reactor_extra_clearance": InputVariable( + data_structure.buildings_variables, float, range=(0.0, 10.0) + ), "sec_buildings_h": InputVariable( data_structure.buildings_variables, float, range=(1.0, 100.0) ), @@ -1358,7 +1366,7 @@ def __post_init__(self): data_structure.build_variables, float, range=(0.0, 10.0) ), "shmf": InputVariable(data_structure.buildings_variables, float, range=(0.0, 1.0)), - "shov": InputVariable( + "vol_plant_shops_warehouse_buildings": InputVariable( data_structure.buildings_variables, float, range=(1000.0, 1000000.0) ), "sig_tf_case_max": InputVariable( @@ -1385,7 +1393,9 @@ def __post_init__(self): "startupratio": InputVariable( data_structure.cost_variables, float, range=(0.0, 10.0) ), - "stcl": InputVariable(data_structure.buildings_variables, float, range=(0.0, 10.0)), + "dz_plant_reactor_building_crane_roof_clearance": InputVariable( + data_structure.buildings_variables, float, range=(0.0, 10.0) + ), "str_cs_con_res": InputVariable( data_structure.tfcoil_variables, float, range=(-0.02, 0.02) ), @@ -1516,7 +1526,7 @@ def __post_init__(self): "temp_plasma_separatrix_kev": InputVariable( data_structure.physics_variables, float, range=(0.0, 20.0) ), - "tfcbv": InputVariable( + "vol_plant_tf_power_supplies_building": InputVariable( data_structure.buildings_variables, float, range=(10000.0, 1000000.0) ), "dx_tf_wp_insertion_gap": InputVariable( @@ -1586,13 +1596,15 @@ def __post_init__(self): "f_temp_plasma_ion_electron": InputVariable( data_structure.physics_variables, float, range=(0.0, 2.0) ), - "trcl": InputVariable(data_structure.buildings_variables, float, range=(0.0, 10.0)), + "dr_plant_reactor_building_transport_clearance": InputVariable( + data_structure.buildings_variables, float, range=(0.0, 10.0) + ), "triang": InputVariable(data_structure.physics_variables, float, range=(-1.0, 1.0)), "triang95": InputVariable(data_structure.physics_variables, float, range=(0.0, 1.0)), "p_tritium_plant_electric_mw": InputVariable( data_structure.heat_transport_variables, float, range=(0.0, 100.0) ), - "triv": InputVariable( + "vol_plant_tritium_fuel_building": InputVariable( data_structure.buildings_variables, float, range=(10000.0, 1000000.0) ), "turbine_hall_h": InputVariable( @@ -1773,7 +1785,7 @@ def __post_init__(self): "watertemp": InputVariable( data_structure.water_usage_variables, float, range=(0.0, 25.0) ), - "wgt": InputVariable( + "m_plant_reactor_building_crane_capacity": InputVariable( data_structure.buildings_variables, float, range=(10000.0, 1000000.0) ), "wgt2": InputVariable( diff --git a/process/core/io/plot_proc.py b/process/core/io/plot_proc.py index e1006a497f..a71d5d5e64 100644 --- a/process/core/io/plot_proc.py +++ b/process/core/io/plot_proc.py @@ -35,6 +35,7 @@ from process.core.solver.objectives import OBJECTIVE_NAMES from process.data_structure import impurity_radiation_module from process.models.build import Build +from process.models.buildings import BuildingsITER1992 from process.models.geometry.blanket import ( blanket_geometry_double_null, blanket_geometry_single_null, @@ -10147,7 +10148,7 @@ def plot_tf_coil_structure(axis: plt.Axes, mfile: mf.MFile, scan: int, colour_sc axis.text( (r_tf_inboard_out + r_tf_outboard_in) / 1.5, -z_tf_inside_half / 12, - f"{r_tf_outboard_in - r_tf_inboard_in:.3f} m", + f"{mfile.get('dr_tf_internal_midplane', scan=scan):.3f} m", fontsize=7, color="black", verticalalignment="center", @@ -10171,7 +10172,7 @@ def plot_tf_coil_structure(axis: plt.Axes, mfile: mf.MFile, scan: int, colour_sc axis.text( (r_tf_inboard_out + r_tf_outboard_in) / 1.5, 0.0, - f"{(r_tf_outboard_in + dr_tf_outboard) - r_tf_inboard_in:.3f} m", + f"{mfile.get('dr_tf_full_midplane', scan=scan):.3f} m", fontsize=7, color="black", verticalalignment="center", @@ -13902,7 +13903,24 @@ def main_plot( ax24 = figs[33].add_subplot(111) # set_position([left, bottom, width, height]) -> height ~ 0.66 => ~2/3 of page height ax24.set_position([0.08, 0.35, 0.84, 0.57]) - plot_system_power_profiles_over_time(ax24, m_file, scan, figs[33]) + plot_system_power_profiles_over_time(ax24, m_file, scan, figs[34]) + + reactor_hall_ax = figs[34].add_subplot(111, aspect="equal") + plot_full_machine_poloidal_cross_section( + reactor_hall_ax, + m_file, + scan, + radial_build, + colour_scheme, + ) + + BuildingsITER1992.plot_reactor_hall( + axis=reactor_hall_ax, + mfile=m_file, + scan=scan, + radial_build=radial_build, + colour_scheme=colour_scheme, + ) def create_thickness_builds(m_file, scan: int): @@ -13979,7 +13997,7 @@ def main(args=None): # create main plot # Increase range when adding new page - pages = [plt.figure(figsize=(12, 9), dpi=80) for i in range(34)] + pages = [plt.figure(figsize=(12, 9), dpi=80) for i in range(35)] # run main_plot main_plot( diff --git a/process/data_structure/buildings_variables.py b/process/data_structure/buildings_variables.py index b27b5f6f33..56c2dd923f 100644 --- a/process/data_structure/buildings_variables.py +++ b/process/data_structure/buildings_variables.py @@ -1,4 +1,4 @@ -admv: float = None +vol_plant_administration_building: float = None """administration building volume (m3)""" @@ -66,7 +66,7 @@ """control building height (m)""" -conv: float = None +vol_plant_control_building: float = None """control building volume (m3)""" @@ -114,7 +114,7 @@ """vertical clearance from TF coil to cryostat (m)""" -cryvol: float = None +vol_plant_cryoplant_building: float = None """volume of cryoplant building (m3)""" @@ -122,6 +122,9 @@ """effective total floor space (m2)""" +dz_plant_reactor_building_internal: float = None +"""Internal height of the reactor building (m)""" + elecdist_l: float = None """Transformers and electrical distribution facilities length (m)""" @@ -158,7 +161,7 @@ """Energy Storage facilities height (m)""" -elevol: float = None +vol_plant_electrical_building: float = None """volume of electrical equipment building (m3)""" @@ -174,7 +177,7 @@ """Fuel Cycle facilities width (m)""" -fndt: float = None +dz_plant_reactor_building_foundation: float = None """foundation thickness (m)""" @@ -354,15 +357,15 @@ """reactor building volume multiplication factor""" -rbrt: float = None +dz_plant_reactor_building_roof: float = None """reactor building roof thickness (m)""" -rbvol: float = None +vol_plant_reactor_building: float = None """reactor building volume (m3)""" -rbwt: float = None +dx_plant_reactor_building_wall: float = None """reactor building wall thickness (m)""" @@ -394,7 +397,7 @@ """reactor building wall thickness (m)""" -rmbvol: float = None +vol_plant_maintenance_assembly_building: float = None """volume of maintenance and assembly building (m3)""" @@ -410,11 +413,13 @@ """robotics buildings height (m)""" -row: float = None +dr_plant_reactor_crane_clearance: float = None """clearance to building wall for crane operation (m)""" +dz_plant_reactor_building_crane: float = None +"""Height of crane operation in the reactor building (m)""" -rxcl: float = None +dr_plant_reactor_extra_clearance: float = None """clearance around reactor (m)""" @@ -434,7 +439,7 @@ """fraction of shield mass per TF coil to be moved in the maximum shield lift""" -shov: float = None +vol_plant_shops_warehouse_buildings: float = None """shops and warehouse volume (m3)""" @@ -450,11 +455,11 @@ """staff buildings height (m)""" -stcl: float = None +dz_plant_reactor_building_crane_roof_clearance: float = None """clearance above crane to roof (m)""" -tfcbv: float = None +vol_plant_tf_power_supplies_building: float = None """volume of TF coil power supply building (m3) (calculated if TF coils are superconducting)""" @@ -462,11 +467,11 @@ """transportation clearance between components (m)""" -trcl: float = None +dr_plant_reactor_building_transport_clearance: float = None """transportation clearance between components (m)""" -triv: float = None +vol_plant_tritium_fuel_building: float = None """volume of tritium, fuel handling and health physics buildings (m3)""" @@ -494,11 +499,11 @@ """tritiated waste storage building height (m)""" -volrci: float = None +vol_plant_reactor_building_internal: float = None """internal volume of reactor building (m3)""" -volnucb: float = None +vol_plant_nuclear_buildings: float = None """sum of nuclear buildings volumes (m3)""" @@ -526,7 +531,7 @@ """water, laundry & drainage buildings height (m)""" -wgt: float = None +m_plant_reactor_building_crane_capacity: float = None """reactor building crane capacity (kg) (calculated if 0 is input)""" @@ -546,11 +551,11 @@ """[cold] workshop buildings height (m)""" -wrbi: float = None +dr_plant_reactor_building_internal_half: float = None """distance from centre of machine to building wall (m)""" -wsvol: float = None +vol_plant_warm_shop_building: float = None """volume of warm shop building (m3)""" @@ -612,7 +617,7 @@ def init_buildings_variables(): global \ - admv, \ + vol_plant_administration_building, \ admvol, \ aux_build_l, \ aux_build_w, \ @@ -629,7 +634,7 @@ def init_buildings_variables(): control_buildings_l, \ control_buildings_w, \ control_buildings_h, \ - conv, \ + vol_plant_control_building, \ convol, \ crane_arm_h, \ crane_clrnc_h, \ @@ -641,8 +646,9 @@ def init_buildings_variables(): cryostore_w, \ cryostore_h, \ cryostat_clrnc, \ - cryvol, \ + vol_plant_cryoplant_building, \ a_plant_floor_effective, \ + dz_plant_reactor_building_internal, \ elecdist_l, \ elecdist_w, \ elecdist_h, \ @@ -652,11 +658,11 @@ def init_buildings_variables(): elecstore_l, \ elecstore_w, \ elecstore_h, \ - elevol, \ + vol_plant_electrical_building, \ esbldgm3, \ fc_building_l, \ fc_building_w, \ - fndt, \ + dz_plant_reactor_building_foundation, \ gas_buildings_l, \ gas_buildings_w, \ gas_buildings_h, \ @@ -701,9 +707,9 @@ def init_buildings_variables(): pibv, \ qnty_sfty_fac, \ rbvfac, \ - rbrt, \ - rbvol, \ - rbwt, \ + dz_plant_reactor_building_roof, \ + vol_plant_reactor_building, \ + dx_plant_reactor_building_wall, \ reactor_clrnc, \ reactor_fndtn_thk, \ reactor_hall_l, \ @@ -711,46 +717,47 @@ def init_buildings_variables(): reactor_hall_h, \ reactor_roof_thk, \ reactor_wall_thk, \ - rmbvol, \ + vol_plant_maintenance_assembly_building, \ robotics_l, \ robotics_w, \ robotics_h, \ - row, \ - rxcl, \ + dr_plant_reactor_crane_clearance, \ + dz_plant_reactor_building_crane, \ + dr_plant_reactor_extra_clearance, \ sec_buildings_l, \ sec_buildings_w, \ sec_buildings_h, \ shmf, \ - shov, \ + vol_plant_shops_warehouse_buildings, \ shovol, \ staff_buildings_area, \ staff_buildings_h, \ - stcl, \ - tfcbv, \ + dz_plant_reactor_building_crane_roof_clearance, \ + vol_plant_tf_power_supplies_building, \ transp_clrnc, \ - trcl, \ - triv, \ + dr_plant_reactor_building_transport_clearance, \ + vol_plant_tritium_fuel_building, \ turbine_hall_l, \ turbine_hall_w, \ turbine_hall_h, \ tw_storage_l, \ tw_storage_w, \ tw_storage_h, \ - volrci, \ - volnucb, \ + vol_plant_reactor_building_internal, \ + vol_plant_nuclear_buildings, \ warm_shop_l, \ warm_shop_w, \ warm_shop_h, \ water_buildings_l, \ water_buildings_w, \ water_buildings_h, \ - wgt, \ + m_plant_reactor_building_crane_capacity, \ wgt2, \ workshop_l, \ workshop_w, \ workshop_h, \ - wrbi, \ - wsvol, \ + dr_plant_reactor_building_internal_half, \ + vol_plant_warm_shop_building, \ wsvfac, \ a_reactor_bldg, \ a_ee_ps_bldg, \ @@ -766,7 +773,7 @@ def init_buildings_variables(): a_cryo_inert_gas_bldg, \ a_security_bldg - admv = 1.0e5 + vol_plant_administration_building = 1.0e5 admvol = 0.0 aux_build_l = 60.0 aux_build_w = 30.0 @@ -783,7 +790,7 @@ def init_buildings_variables(): control_buildings_l = 80.0 control_buildings_w = 60.0 control_buildings_h = 6.0 - conv = 6.0e4 + vol_plant_control_building = 6.0e4 convol = 0.0 crane_arm_h = 10.0 crane_clrnc_h = 4.0 @@ -795,8 +802,9 @@ def init_buildings_variables(): cryostore_w = 30.0 cryostore_h = 20.0 cryostat_clrnc = 2.5 - cryvol = 0.0 + vol_plant_cryoplant_building = 0.0 a_plant_floor_effective = 0.0 + dz_plant_reactor_building_internal = 0.0 elecdist_l = 380.0 elecdist_w = 350.0 elecdist_h = 5.0 @@ -806,11 +814,11 @@ def init_buildings_variables(): elecstore_l = 100.0 elecstore_w = 60.0 elecstore_h = 12.0 - elevol = 0.0 + vol_plant_electrical_building = 0.0 esbldgm3 = 1.0e3 fc_building_l = 60.0 fc_building_w = 60.0 - fndt = 2.0 + dz_plant_reactor_building_foundation = 2.0 gas_buildings_l = 25.0 gas_buildings_w = 15.0 gas_buildings_h = 5.0 @@ -855,9 +863,9 @@ def init_buildings_variables(): pibv = 2.0e4 qnty_sfty_fac = 2.0 rbvfac = 1.6 - rbrt = 1.0 - rbvol = 0.0 - rbwt = 2.0 + dz_plant_reactor_building_roof = 1.0 + vol_plant_reactor_building = 0.0 + dx_plant_reactor_building_wall = 2.0 reactor_clrnc = 4.0 reactor_fndtn_thk = 2.0 reactor_hall_l = 0.0 @@ -865,33 +873,34 @@ def init_buildings_variables(): reactor_hall_h = 0.0 reactor_roof_thk = 1.0 reactor_wall_thk = 2.0 - rmbvol = 0.0 + vol_plant_maintenance_assembly_building = 0.0 robotics_l = 50.0 robotics_w = 30.0 robotics_h = 30.0 - row = 4.0 - rxcl = 4.0 + dr_plant_reactor_crane_clearance = 4.0 + dz_plant_reactor_building_crane = 4.0 + dr_plant_reactor_extra_clearance = 4.0 sec_buildings_l = 30.0 sec_buildings_w = 25.0 sec_buildings_h = 6.0 shmf = 0.5 - shov = 1.0e5 + vol_plant_shops_warehouse_buildings = 1.0e5 shovol = 0.0 staff_buildings_h = 5.0 staff_buildings_area = 4.8e5 - stcl = 3.0 - tfcbv = 2.0e4 + dz_plant_reactor_building_crane_roof_clearance = 3.0 + vol_plant_tf_power_supplies_building = 2.0e4 transp_clrnc = 1.0 - trcl = 1.0 - triv = 4.0e4 + dr_plant_reactor_building_transport_clearance = 1.0 + vol_plant_tritium_fuel_building = 4.0e4 turbine_hall_l = 109.0 turbine_hall_w = 62.0 turbine_hall_h = 15.0 tw_storage_l = 90.0 tw_storage_w = 30.0 tw_storage_h = 5.0 - volnucb = 0.0 - volrci = 0.0 + vol_plant_nuclear_buildings = 0.0 + vol_plant_reactor_building_internal = 0.0 warm_shop_l = 100.0 warm_shop_w = 50.0 warm_shop_h = 10.0 @@ -901,11 +910,11 @@ def init_buildings_variables(): workshop_l = 150.0 workshop_w = 125.0 workshop_h = 10.0 - wgt = 5.0e5 + m_plant_reactor_building_crane_capacity = 5.0e5 wgt2 = 1.0e5 - wrbi = 0.0 + dr_plant_reactor_building_internal_half = 0.0 wsvfac = 1.9 - wsvol = 0.0 + vol_plant_warm_shop_building = 0.0 a_reactor_bldg = 8.32e3 a_ee_ps_bldg = 2.133e4 a_aux_services_bldg = 1.0e3 diff --git a/process/data_structure/tfcoil_variables.py b/process/data_structure/tfcoil_variables.py index 3b757b99a4..cd58cbee44 100644 --- a/process/data_structure/tfcoil_variables.py +++ b/process/data_structure/tfcoil_variables.py @@ -767,6 +767,12 @@ (calculated for stellarators) """ +dr_tf_full_midplane: float = None +"""Full radial thickness of TF coil at midplane (m)""" + +dr_tf_internal_midplane: float = None +"""Internal radial thickness of TF coil at midplane (m)""" + dr_tf_wp_with_insulation: float = None """radial thickness of winding pack (m) (`iteration variable 140`) (issue #514)""" @@ -1221,6 +1227,8 @@ def init_tfcoil_variables(): dx_tf_turn_insulation, \ layer_ins, \ dr_tf_nose_case, \ + dr_tf_full_midplane, \ + dr_tf_internal_midplane, \ dr_tf_wp_with_insulation, \ dx_tf_turn_steel, \ dx_tf_wp_insulation, \ @@ -1454,6 +1462,8 @@ def init_tfcoil_variables(): dx_tf_turn_insulation = 8e-4 layer_ins = 0.0 dr_tf_nose_case = 0.3 + dr_tf_full_midplane = 0.0 + dr_tf_internal_midplane = 0.0 dr_tf_wp_with_insulation = 0.0 dx_tf_turn_steel = 8e-3 dx_tf_wp_insulation = 0.018 diff --git a/process/models/buildings.py b/process/models/buildings.py index 66aeb6ead5..e936e147f3 100644 --- a/process/models/buildings.py +++ b/process/models/buildings.py @@ -1,7 +1,11 @@ import logging +from enum import IntEnum +from typing import TYPE_CHECKING, Literal +import matplotlib.pyplot as plt import numpy as np +import process.core.io.mfile as mf from process.core import constants from process.core import process_output as po from process.core.model import Model @@ -22,9 +26,19 @@ CurrentDriveModel, ) +if TYPE_CHECKING: + pass + logger = logging.getLogger(__name__) +class BuildingsModel(IntEnum): + """Enum for building size estimation models""" + + ITER_1992 = 0 + CHAPMAN_2024 = 1 + + class Buildings(Model): """ @@ -37,6 +51,8 @@ def __init__(self): This routine calls the buildings calculations. """ self.outfile = constants.NOUT # output file unit + self.iter_1992 = BuildingsITER1992() + self.chapman_2024 = BuildingsChapman2024() def output(self): self.run(output=True) @@ -44,14 +60,16 @@ def output(self): def run(self, output: bool = False): # Find TF coil radial positions # outboard edge: outboard mid-leg radial position + half-thickness of outboard leg - tfro = build_variables.r_tf_outboard_mid + ( + r_tf_outboard_out = build_variables.r_tf_outboard_mid + ( build_variables.dr_tf_outboard * 0.5e0 ) # inboard edge: inboard mid-leg radial position - half-thickness of inboard leg - tfri = build_variables.r_tf_inboard_mid - (build_variables.dr_tf_inboard * 0.5e0) + r_tf_inboard_in = build_variables.r_tf_inboard_mid - ( + build_variables.dr_tf_inboard * 0.5e0 + ) # Find width, in radial dimension, of TF coil (m) - tf_radial_dim = tfro - tfri + tf_radial_dim = r_tf_outboard_out - r_tf_inboard_in # Find full height of TF coil (m) # = 2 * (mid-plane to TF coil inside edge + thickness of coil) @@ -64,54 +82,65 @@ def run(self, output: bool = False): # Calculate building areas and volumes - if buildings_variables.i_bldgs_size == 1: + if ( + BuildingsModel(buildings_variables.i_bldgs_size) + == BuildingsModel.CHAPMAN_2024 + ): # Updated building estimates - self.bldgs_sizes(output, tf_radial_dim, tf_vertical_dim) + self.chapman_2024.calculate_building_sizes_chapman( + output, tf_radial_dim, tf_vertical_dim + ) else: # Previous estimation work ( - buildings_variables.cryvol, - buildings_variables.volrci, - buildings_variables.rbvol, - buildings_variables.rmbvol, - buildings_variables.wsvol, - buildings_variables.elevol, - ) = self.bldgs( - output, - pfcoil_variables.r_pf_coil_outer_max, - pfcoil_variables.m_pf_coil_max, - tfro, - tfri, - tf_vertical_dim, - tfmtn, - tfcoil_variables.n_tf_coils, - build_variables.r_shld_outboard_outer, - build_variables.r_shld_inboard_inner, - 2.0e0 + buildings_variables.vol_plant_cryoplant_building, + buildings_variables.vol_plant_reactor_building_internal, + buildings_variables.vol_plant_reactor_building, + buildings_variables.vol_plant_maintenance_assembly_building, + buildings_variables.vol_plant_warm_shop_building, + buildings_variables.vol_plant_electrical_building, + ) = self.iter_1992.calculate_building_sizes_1992( + r_pf_coil_outer_max=pfcoil_variables.r_pf_coil_outer_max, + m_pf_coil_max=pfcoil_variables.m_pf_coil_max, + r_tf_outboard_out=r_tf_outboard_out, + r_tf_inboard_in=r_tf_inboard_in, + dz_tf_full=tf_vertical_dim, + m_tf_coil_tonne=tfmtn, + n_tf_coils=tfcoil_variables.n_tf_coils, + r_shld_outboard_outer=build_variables.r_shld_outboard_outer, + r_shld_inboard_inner=build_variables.r_shld_inboard_inner, + dz_shld=2.0e0 * (build_variables.z_tf_inside_half - build_variables.dz_shld_vv_gap) - build_variables.dz_vv_upper - build_variables.dz_vv_lower, - fwbs_variables.whtshld, - fwbs_variables.r_cryostat_inboard, - heat_transport_variables.helpow, + m_shld_total=fwbs_variables.whtshld, + r_cryostat_outboard=fwbs_variables.r_cryostat_inboard, + helpow=heat_transport_variables.helpow, ) - def bldgs( + if output: + self.iter_1992.output_buildings() + + +class BuildingsITER1992: + def __init__(self): + self.outfile = constants.NOUT + + def calculate_building_sizes_1992( self, - output: bool, - pfr, - pfm, - tfro, - tfri, - tfh, - tfm, + r_pf_coil_outer_max, + m_pf_coil_max, + r_tf_outboard_out, + r_tf_inboard_in, + dz_tf_full, + m_tf_coil_tonne, n_tf_coils, - shro, - shri, - shh, - shm, - crr, + r_shld_outboard_outer, + r_shld_inboard_inner, + dz_shld, + m_shld_total, + r_cryostat_outboard, helpow, ): """Determines the sizes of the plant buildings @@ -130,85 +159,99 @@ def bldgs( ---------- output: - pfr : + r_pf_coil_outer_max : largest PF coil outer radius, m - pfm : + m_pf_coil_max : largest PF coil mass, tonne - tfro : + r_tf_outboard_out : outer radius of TF coil, m - tfri : + r_tf_inboard_in : inner radius of TF coil, m - tfh : + dz_tf_full : full height of TF coil, m - tfm : + m_tf_coil_tonne : mass of one TF coil, tonne n_tf_coils : number of tf coils - shro : + r_shld_outboard_outer : outer radius of attached shield, m - shri : + r_shld_inboard_inner : inner radius of attached shield, m - shh : + dz_shld : height of attached shield, m - shm : + m_shld_total : total mass of attached shield, kg - crr : + r_cryostat_outboard : outer radius of common cryostat, m helpow : total cryogenic load, W Returns ------- - cryv: + vol_plant_cryoplant_building: volume of cryogenic building, m3 - vrci: + vol_plant_reactor_building_internal: inner volume of reactor building, m3 - rbv: + vol_plant_reactor_building: outer volume of reactor building, m3 - rmbv: + vol_plant_maintenance_assembly_building: volume of reactor maintenance building, m3 - wsv: + vol_plant_warm_shop_building: volume of warm shop, m3 - elev: + vol_plant_electrical_building: volume of electrical buildings, m3 """ # Reactor building # Determine basic machine radius (m) - # crr : cryostat radius (m) - # pfr : radius of largest PF coil (m) - # tfro : outer radius of TF coil (m) - bmr = max(crr, pfr, tfro) + # r_cryostat_outboard : cryostat radius (m) + # r_pf_coil_outer_max : radius of largest PF coil (m) + # r_tf_outboard_out : outer radius of TF coil (m) + r_machine = max(r_cryostat_outboard, r_pf_coil_outer_max, r_tf_outboard_out) # Determine largest transported piece - sectl = shro - shri # Shield thicknes (m) - coill = tfro - tfri # TF coil thickness (m) - sectl = max(coill, sectl) + dz_shld_full = ( + r_shld_outboard_outer - r_shld_inboard_inner + ) # Shield thicknes (m) + dz_tf_full_midplane = ( + r_tf_outboard_out - r_tf_inboard_in + ) # TF coil thickness (m) + dz_shld_full = max(dz_tf_full_midplane, dz_shld_full) # Calculate half width of building (m) - # rxcl : clearance around reactor, m - # trcl : transportation clearance between components, m + # dr_plant_reactor_extra_clearance : clearance around reactor, m + # dr_plant_reactor_building_transport_clearance : transportation clearance between components, m # row : clearance to building wall for crane operation, m # 19.48258241468535 + 4 + max(13.764874193548387 - 4.7423258064516141, 17.123405859443331 - 2.9939411851091102) + 1 + 4 = 42.61204708901957 - buildings_variables.wrbi = ( - bmr - + buildings_variables.rxcl - + sectl - + buildings_variables.trcl - + buildings_variables.row + buildings_variables.dr_plant_reactor_building_internal_half = ( + r_machine + + buildings_variables.dr_plant_reactor_extra_clearance + + dz_shld_full + + buildings_variables.dr_plant_reactor_building_transport_clearance + + buildings_variables.dr_plant_reactor_crane_clearance ) # Calculate length to allow PF or cryostat laydown (m) # Laydown length (m) - layl = max(crr, pfr) + len_reactor_laydown = max(r_cryostat_outboard, r_pf_coil_outer_max) # Diagonal length (m) - hy = bmr + buildings_variables.rxcl + sectl + buildings_variables.trcl + layl + hy = ( + r_machine + + buildings_variables.dr_plant_reactor_extra_clearance + + dz_shld_full + + buildings_variables.dr_plant_reactor_building_transport_clearance + + len_reactor_laydown + ) # Angle between diagonal length and floor (m) - ang = (buildings_variables.wrbi - buildings_variables.trcl - layl) / hy + ang = ( + buildings_variables.dr_plant_reactor_building_internal_half + - buildings_variables.dr_plant_reactor_building_transport_clearance + - len_reactor_laydown + ) / hy # Cap angle at 1 if abs(ang) > 1.0e0: @@ -216,58 +259,85 @@ def bldgs( # Length to allow laydown (m) drbi = ( - buildings_variables.trcl - + layl + buildings_variables.dr_plant_reactor_building_transport_clearance + + len_reactor_laydown + hy * np.sin(np.arccos(ang)) - + buildings_variables.wrbi + + buildings_variables.dr_plant_reactor_building_internal_half ) # Crane height based on maximum lift (m) - # wgt : reactor building crane capacity (kg) + # m_plant_reactor_building_crane_capacity : reactor building crane capacity (kg) # Calculated if 0 is input # shmf : fraction of shield mass per TF coil to be moved in # the maximum shield lift - if buildings_variables.wgt > 1.0e0: - wt = buildings_variables.wgt + if buildings_variables.m_plant_reactor_building_crane_capacity > 1.0e0: + m_plant_reactor_building_crane_capacity = ( + buildings_variables.m_plant_reactor_building_crane_capacity + ) else: - wt = buildings_variables.shmf * shm / n_tf_coils - wt = max(wt, 1.0e3 * pfm, 1.0e3 * tfm) + m_plant_reactor_building_crane_capacity = ( + buildings_variables.shmf * m_shld_total / n_tf_coils + ) + m_plant_reactor_building_crane_capacity = max( + m_plant_reactor_building_crane_capacity, + 1.0e3 * m_pf_coil_max, + 1.0e3 * m_tf_coil_tonne, + ) # Crane height (m) - crcl = 9.41e-6 * wt + 5.1e0 + buildings_variables.dz_plant_reactor_building_crane = ( + 9.41e-6 * m_plant_reactor_building_crane_capacity + 5.1e0 + ) # Building height (m) # dz_tf_cryostat : clearance from TF coil to cryostat top, m # clh2 : clearance beneath TF coil to foundation, including basement, m - # stcl : clearance above crane to roof, m - # Additional tfh allows TF coil to be lifted right out - hrbi = ( + # dz_plant_reactor_building_crane_roof_clearance : clearance above crane to roof, m + # Additional dz_tf_full allows TF coil to be lifted right out + dz_plant_reactor_building_internal = ( + buildings_variables.dz_plant_reactor_building_internal + ) = ( buildings_variables.clh2 - + 2.0e0 * tfh + + 2.0e0 * dz_tf_full + buildings_variables.dz_tf_cryostat - + buildings_variables.trcl - + crcl - + buildings_variables.stcl + + buildings_variables.dr_plant_reactor_building_transport_clearance + + buildings_variables.dz_plant_reactor_building_crane + + buildings_variables.dz_plant_reactor_building_crane_roof_clearance ) # Internal volume (m3) - vrci = ( - buildings_variables.rbvfac * 2.0e0 * buildings_variables.wrbi * drbi * hrbi + buildings_variables.vol_plant_reactor_building_internal = ( + buildings_variables.rbvfac + * 2.0e0 + * buildings_variables.dr_plant_reactor_building_internal_half + * drbi + * dz_plant_reactor_building_internal ) try: - assert vrci < np.inf + assert buildings_variables.vol_plant_reactor_building_internal < np.inf except AssertionError: - logger.exception("vrci is inf. Kludging to 1e10.") - vrci = 1e10 + logger.exception( + "vol_plant_reactor_building_internal is inf. Kludging to 1e10." + ) + buildings_variables.vol_plant_reactor_building_internal = 1e10 # External dimensions of reactor building (m) - # rbwt : reactor building wall thickness, m - # rbrt : reactor building roof thickness, m - # fndt : foundation thickness, m - rbw = 2.0e0 * buildings_variables.wrbi + 2.0e0 * buildings_variables.rbwt - rbl = drbi + 2.0e0 * buildings_variables.rbwt - rbh = hrbi + buildings_variables.rbrt + buildings_variables.fndt - rbv = buildings_variables.rbvfac * rbw * rbl * rbh + # dx_plant_reactor_building_wall : reactor building wall thickness, m + # dz_plant_reactor_building_roof : reactor building roof thickness, m + # dz_plant_reactor_building_foundation : foundation thickness, m + rbw = ( + 2.0e0 * buildings_variables.dr_plant_reactor_building_internal_half + + 2.0e0 * buildings_variables.dx_plant_reactor_building_wall + ) + rbl = drbi + 2.0e0 * buildings_variables.dx_plant_reactor_building_wall + rbh = ( + dz_plant_reactor_building_internal + + buildings_variables.dz_plant_reactor_building_roof + + buildings_variables.dz_plant_reactor_building_foundation + ) + buildings_variables.vol_plant_reactor_building = ( + buildings_variables.rbvfac * rbw * rbl * rbh + ) # Maintenance building # The reactor maintenance building includes the hot cells, the @@ -277,16 +347,29 @@ def bldgs( # Transport corridor size # hcwt : hot cell wall thickness, m - tcw = shro - shri + 4.0e0 * buildings_variables.trcl - tcl = 5.0e0 * tcw + 2.0e0 * buildings_variables.hcwt + dr_plant_transport_corridor = ( + r_shld_outboard_outer + - r_shld_inboard_inner + + 4.0e0 * buildings_variables.dr_plant_reactor_building_transport_clearance + ) + tcl = 5.0e0 * dr_plant_transport_corridor + 2.0e0 * buildings_variables.hcwt # Decontamination cell size - dcw = 2.0e0 * tcw + 1.0e0 + dcw = 2.0e0 * dr_plant_transport_corridor + 1.0e0 # Hot cell size # hccl : clearance around components in hot cell, m - hcw = shro - shri + 3.0e0 * buildings_variables.hccl + 2.0e0 - hcl = 3.0e0 * (shro - shri) + 4.0e0 * buildings_variables.hccl + tcw + hcw = ( + r_shld_outboard_outer + - r_shld_inboard_inner + + 3.0e0 * buildings_variables.hccl + + 2.0e0 + ) + hcl = ( + 3.0e0 * (r_shld_outboard_outer - r_shld_inboard_inner) + + 4.0e0 * buildings_variables.hccl + + dr_plant_transport_corridor + ) # Maintenance building dimensions rmbw = hcw + dcw + 3.0e0 * buildings_variables.hcwt @@ -298,33 +381,42 @@ def bldgs( if buildings_variables.wgt2 > 1.0e0: wgts = buildings_variables.wgt2 else: - wgts = buildings_variables.shmf * shm / n_tf_coils + wgts = buildings_variables.shmf * m_shld_total / n_tf_coils cran = 9.41e-6 * wgts + 5.1e0 rmbh = ( 10.0e0 - + shh - + buildings_variables.trcl + + dz_shld + + buildings_variables.dr_plant_reactor_building_transport_clearance + cran - + buildings_variables.stcl - + buildings_variables.fndt + + buildings_variables.dz_plant_reactor_building_crane_roof_clearance + + buildings_variables.dz_plant_reactor_building_foundation + ) + tch = ( + dz_shld + + buildings_variables.dz_plant_reactor_building_crane_roof_clearance + + buildings_variables.dz_plant_reactor_building_foundation ) - tch = shh + buildings_variables.stcl + buildings_variables.fndt # Volume - rmbv = buildings_variables.mbvfac * rmbw * rmbl * rmbh + tcw * tcl * tch + buildings_variables.vol_plant_maintenance_assembly_building = ( + buildings_variables.mbvfac * rmbw * rmbl * rmbh + + dr_plant_transport_corridor * tcl * tch + ) # Warm shop and hot cell gallery wsa = (rmbw + 7.0e0) * 20.0e0 + rmbl * 7.0e0 - wsv = buildings_variables.wsvfac * wsa * rmbh + buildings_variables.vol_plant_warm_shop_building = ( + buildings_variables.wsvfac * wsa * rmbh + ) # Cryogenic building volume - cryv = 55.0e0 * helpow**0.5 + buildings_variables.vol_plant_cryoplant_building = 55.0e0 * helpow**0.5 # Other building volumes # pibv : power injection building volume, m3 # esbldgm3 is forced to be zero if no energy storage is required (i_pulsed_plant=0) - elev = ( - buildings_variables.tfcbv + buildings_variables.vol_plant_electrical_building = ( + buildings_variables.vol_plant_tf_power_supplies_building + buildings_variables.pfbldgm3 + buildings_variables.esbldgm3 + buildings_variables.pibv @@ -332,81 +424,161 @@ def bldgs( # Calculate effective floor area for ac power module buildings_variables.a_plant_floor_effective = ( - rbv - + rmbv - + wsv - + buildings_variables.triv - + elev - + buildings_variables.conv - + cryv - + buildings_variables.admv - + buildings_variables.shov + buildings_variables.vol_plant_reactor_building + + buildings_variables.vol_plant_maintenance_assembly_building + + buildings_variables.vol_plant_warm_shop_building + + buildings_variables.vol_plant_tritium_fuel_building + + buildings_variables.vol_plant_electrical_building + + buildings_variables.vol_plant_control_building + + buildings_variables.vol_plant_cryoplant_building + + buildings_variables.vol_plant_administration_building + + buildings_variables.vol_plant_shops_warehouse_buildings ) / 6.0e0 - buildings_variables.admvol = buildings_variables.admv - buildings_variables.shovol = buildings_variables.shov - buildings_variables.convol = buildings_variables.conv + buildings_variables.admvol = ( + buildings_variables.vol_plant_administration_building + ) + buildings_variables.shovol = ( + buildings_variables.vol_plant_shops_warehouse_buildings + ) + buildings_variables.convol = buildings_variables.vol_plant_control_building # Total volume of nuclear buildings - buildings_variables.volnucb = vrci + rmbv + wsv + buildings_variables.triv + cryv + buildings_variables.vol_plant_nuclear_buildings = ( + buildings_variables.vol_plant_reactor_building_internal + + buildings_variables.vol_plant_maintenance_assembly_building + + buildings_variables.vol_plant_warm_shop_building + + buildings_variables.vol_plant_tritium_fuel_building + + buildings_variables.vol_plant_cryoplant_building + ) - # Output ! - # !!!!!!!!! + return ( + buildings_variables.vol_plant_cryoplant_building, + buildings_variables.vol_plant_reactor_building_internal, + buildings_variables.vol_plant_reactor_building, + buildings_variables.vol_plant_maintenance_assembly_building, + buildings_variables.vol_plant_warm_shop_building, + buildings_variables.vol_plant_electrical_building, + ) - if output: - po.oheadr(self.outfile, "Plant Buildings System") - po.ovarre( - self.outfile, "Internal volume of reactor building (m3)", "(vrci)", vrci - ) - po.ovarre( - self.outfile, - "Dist from centre of torus to bldg wall (m)", - "(wrbi)", - buildings_variables.wrbi, - ) - po.ovarre( - self.outfile, - "Effective floor area (m2)", - "(a_plant_floor_effective)", - buildings_variables.a_plant_floor_effective, - ) - po.ovarre(self.outfile, "Reactor building volume (m3)", "(rbv)", rbv) - po.ovarre( - self.outfile, "Reactor maintenance building volume (m3)", "(rmbv)", rmbv - ) - po.ovarre(self.outfile, "Warmshop volume (m3)", "(wsv)", wsv) - po.ovarre( - self.outfile, - "Tritium building volume (m3)", - "(triv)", - buildings_variables.triv, - ) - po.ovarre(self.outfile, "Electrical building volume (m3)", "(elev)", elev) - po.ovarre( - self.outfile, - "Control building volume (m3)", - "(conv)", - buildings_variables.conv, - ) - po.ovarre(self.outfile, "Cryogenics building volume (m3)", "(cryv)", cryv) - po.ovarre( - self.outfile, - "Administration building volume (m3)", - "(admv)", - buildings_variables.admv, - ) - po.ovarre( - self.outfile, "Shops volume (m3)", "(shov)", buildings_variables.shov - ) - po.ovarre( - self.outfile, - "Total volume of nuclear buildings (m3)", - "(volnucb)", - buildings_variables.volnucb, - ) + def output_buildings(self): + po.oheadr(self.outfile, "Plant Buildings System") + po.ovarre( + self.outfile, + "Internal volume of reactor building (m3)", + "(vol_plant_reactor_building_internal)", + buildings_variables.vol_plant_reactor_building_internal, + ) + po.ovarre( + self.outfile, + "Dist from centre of torus to bldg wall (m)", + "(dr_plant_reactor_building_internal_half)", + buildings_variables.dr_plant_reactor_building_internal_half, + ) + po.ovarre( + self.outfile, + "Internal reactor building height (m)", + "(dz_plant_reactor_building_internal)", + buildings_variables.dz_plant_reactor_building_internal, + ) + po.ovarre( + self.outfile, + "Effective floor area (m2)", + "(a_plant_floor_effective)", + buildings_variables.a_plant_floor_effective, + ) + po.ovarre( + self.outfile, + "Reactor building volume (m3)", + "(vol_plant_reactor_building)", + buildings_variables.vol_plant_reactor_building, + ) + po.ovarre( + self.outfile, + "Reactor maintenance building volume (m3)", + "(vol_plant_maintenance_assembly_building)", + buildings_variables.vol_plant_maintenance_assembly_building, + ) + po.ovarre( + self.outfile, + "Warmshop volume (m3)", + "(vol_plant_warm_shop_building)", + buildings_variables.vol_plant_warm_shop_building, + ) + po.ovarre( + self.outfile, + "Tritium building volume (m3)", + "(vol_plant_tritium_fuel_building)", + buildings_variables.vol_plant_tritium_fuel_building, + ) + po.ovarre( + self.outfile, + "Electrical building volume (m3)", + "(vol_plant_electrical_building)", + buildings_variables.vol_plant_electrical_building, + ) + po.ovarre( + self.outfile, + "Control building volume (m3)", + "(vol_plant_control_building)", + buildings_variables.vol_plant_control_building, + ) + po.ovarre( + self.outfile, + "Cryogenics building volume (m3)", + "(vol_plant_cryoplant_building)", + buildings_variables.vol_plant_cryoplant_building, + ) + po.ovarre( + self.outfile, + "Administration building volume (m3)", + "(vol_plant_administration_building)", + buildings_variables.vol_plant_administration_building, + ) + po.ovarre( + self.outfile, + "Shops volume (m3)", + "(vol_plant_shops_warehouse_buildings)", + buildings_variables.vol_plant_shops_warehouse_buildings, + ) + po.ovarre( + self.outfile, + "Total volume of nuclear buildings (m3)", + "(vol_plant_nuclear_buildings)", + buildings_variables.vol_plant_nuclear_buildings, + ) + + @staticmethod + def plot_reactor_hall( + axis: plt.Axes, + mfile: mf.MFile, + scan: int, + radial_build, + colour_scheme: Literal[1, 2], + ): + """Plots the reactor hall dimensions as a rectangle on the provided axis.""" + + dr_half = mfile.get("dr_plant_reactor_building_internal_half", scan=scan) + height = mfile.get("dz_plant_reactor_building_internal", scan=scan) + dx_plant_reactor_building_wall = mfile.get( + "dx_plant_reactor_building_wall", scan=scan + ) + + rect = plt.Rectangle( + (-dr_half, -height / 2), + 2 * dr_half, + height, + fill=False, + edgecolor="grey", + linewidth=2, + ) + axis.add_patch(rect) - return cryv, vrci, rbv, rmbv, wsv, elev - def bldgs_sizes(self, output, tf_radial_dim, tf_vertical_dim): +class BuildingsChapman2024: + def __init__(self): + self.outfile = constants.NOUT + + def calculate_building_sizes_chapman(self, output, tf_radial_dim, tf_vertical_dim): """Subroutine that estimates the sizes (footprints and volumes) of buildings within a fusion power plant. Some estimates are scaled with parameters of the fusion plant, @@ -1000,7 +1172,9 @@ def bldgs_sizes(self, output, tf_radial_dim, tf_vertical_dim): buildings_variables.a_plant_floor_effective = buildings_total_vol / 6.0e0 # Total volume of nuclear buildings - buildings_variables.volnucb = reactor_build_totvol + hotcell_vol_ext + buildings_variables.vol_plant_nuclear_buildings = ( + reactor_build_totvol + hotcell_vol_ext + ) # Output if output: @@ -1207,8 +1381,8 @@ def bldgs_sizes(self, output, tf_radial_dim, tf_vertical_dim): po.ovarre( self.outfile, "Total volume of nuclear buildings (m3)", - "(volnucb)", - buildings_variables.volnucb, + "(vol_plant_nuclear_buildings)", + buildings_variables.vol_plant_nuclear_buildings, ) if buildings_variables.i_bldgs_v == 1: diff --git a/process/models/costs/costs.py b/process/models/costs/costs.py index be7f2198e3..9f74314deb 100644 --- a/process/models/costs/costs.py +++ b/process/models/costs/costs.py @@ -1087,7 +1087,7 @@ def acc21(self): cost_variables.c212 = ( 1.0e-6 * cost_variables.ucrb - * buildings_variables.rbvol**exprb + * buildings_variables.vol_plant_reactor_building**exprb * cmlsa[cost_variables.lsa - 1] ) @@ -1103,13 +1103,13 @@ def acc21(self): cost_variables.c2141 = ( 1.0e-6 * cost_variables.UCMB - * buildings_variables.rmbvol**exprb + * buildings_variables.vol_plant_maintenance_assembly_building**exprb * cmlsa[cost_variables.lsa - 1] ) cost_variables.c2142 = ( 1.0e-6 * cost_variables.UCWS - * buildings_variables.wsvol**exprb + * buildings_variables.vol_plant_warm_shop_building**exprb * cmlsa[cost_variables.lsa - 1] ) cost_variables.c214 = cost_variables.c2141 + cost_variables.c2142 @@ -1119,7 +1119,7 @@ def acc21(self): cost_variables.c215 = ( 1.0e-6 * cost_variables.UCTR - * buildings_variables.triv**exprb + * buildings_variables.vol_plant_tritium_fuel_building**exprb * cmlsa[cost_variables.lsa - 1] ) @@ -1128,7 +1128,7 @@ def acc21(self): cost_variables.c216 = ( 1.0e-6 * cost_variables.UCEL - * buildings_variables.elevol**exprb + * buildings_variables.vol_plant_electrical_building**exprb * cmlsa[cost_variables.lsa - 1] ) @@ -1157,7 +1157,7 @@ def acc21(self): cost_variables.c2174 = ( 1.0e-6 * cost_variables.UCCR - * buildings_variables.cryvol**exprb + * buildings_variables.vol_plant_cryoplant_building**exprb * cmlsa[cost_variables.lsa - 1] ) cost_variables.c217 = ( @@ -2401,7 +2401,10 @@ def acc2273(self): * cost_variables.UCDTC * ( (cfrht / 1.0e4) ** 0.6e0 - * (buildings_variables.volrci + buildings_variables.wsvol) + * ( + buildings_variables.vol_plant_reactor_building_internal + + buildings_variables.vol_plant_warm_shop_building + ) ) ) else: @@ -2416,7 +2419,11 @@ def acc2274(self): cost_variables.c2274 = ( 1.0e-6 * cost_variables.UCNBV - * (buildings_variables.volrci + buildings_variables.wsvol) ** 0.8e0 + * ( + buildings_variables.vol_plant_reactor_building_internal + + buildings_variables.vol_plant_warm_shop_building + ) + ** 0.8e0 ) # Apply Nth kind factor diff --git a/process/models/ife.py b/process/models/ife.py index 825a921dfd..247037dba6 100644 --- a/process/models/ife.py +++ b/process/models/ife.py @@ -930,8 +930,8 @@ def bld2019(self): ife_variables.v3dzu = ( (ife_variables.zu6 + ife_variables.zl6) - + buildings_variables.trcl - + buildings_variables.stcl + + buildings_variables.dr_plant_reactor_building_transport_clearance + + buildings_variables.dz_plant_reactor_building_crane_roof_clearance + 5.1 + 9.41e-6 * 1.0e5 ) @@ -2273,18 +2273,26 @@ def ifebdg(self, output: bool = False): hrbi = ife_variables.zl7 + ife_variables.zu7 # Distance from centre of device to wall - buildings_variables.wrbi = ife_variables.r7 + buildings_variables.dr_plant_reactor_building_internal_half = ife_variables.r7 # Internal volume (square floor) - vrci = (2.0 * buildings_variables.wrbi) ** 2 * hrbi + vrci = ( + 2.0 * buildings_variables.dr_plant_reactor_building_internal_half + ) ** 2 * hrbi # External dimensions # RBWT = wall thickness # RBRT = roof thickness # FNDT = foundation thickness - rbw = 2.0 * (ife_variables.r7 + buildings_variables.rbwt) + rbw = 2.0 * ( + ife_variables.r7 + buildings_variables.dx_plant_reactor_building_wall + ) rbl = rbw - rbh = hrbi + buildings_variables.rbrt + buildings_variables.fndt + rbh = ( + hrbi + + buildings_variables.dz_plant_reactor_building_roof + + buildings_variables.dz_plant_reactor_building_foundation + ) # External volume rbv = rbw * rbl * rbh @@ -2303,7 +2311,10 @@ def ifebdg(self, output: bool = False): # Transport corridor size - tcw = ife_variables.r6 + 4.0 * buildings_variables.trcl + tcw = ( + ife_variables.r6 + + 4.0 * buildings_variables.dr_plant_reactor_building_transport_clearance + ) tcl = 5.0 * tcw + 2.0 * buildings_variables.hcwt # Decontamination cell size @@ -2335,13 +2346,17 @@ def ifebdg(self, output: bool = False): rmbh = ( 10.0 + (ife_variables.zl6 + ife_variables.zu6) - + buildings_variables.trcl + + buildings_variables.dr_plant_reactor_building_transport_clearance + cran + 5.1 - + buildings_variables.stcl - + buildings_variables.fndt + + buildings_variables.dz_plant_reactor_building_crane_roof_clearance + + buildings_variables.dz_plant_reactor_building_foundation + ) + tch = ( + shh + + buildings_variables.dz_plant_reactor_building_crane_roof_clearance + + buildings_variables.dz_plant_reactor_building_foundation ) - tch = shh + buildings_variables.stcl + buildings_variables.fndt # Volume @@ -2369,28 +2384,38 @@ def ifebdg(self, output: bool = False): rbv + rmbv + wsv - + buildings_variables.triv + + buildings_variables.vol_plant_tritium_fuel_building + elev - + buildings_variables.conv + + buildings_variables.vol_plant_control_building + cryv - + buildings_variables.admv - + buildings_variables.shov + + buildings_variables.vol_plant_administration_building + + buildings_variables.vol_plant_shops_warehouse_buildings ) / 6.0 # Convert local into global variables - buildings_variables.admvol = buildings_variables.admv - buildings_variables.convol = buildings_variables.conv - buildings_variables.elevol = elev - buildings_variables.rbvol = rbv - buildings_variables.rmbvol = rmbv - buildings_variables.shovol = buildings_variables.shov - buildings_variables.volrci = vrci - buildings_variables.wsvol = wsv + buildings_variables.admvol = ( + buildings_variables.vol_plant_administration_building + ) + buildings_variables.convol = buildings_variables.vol_plant_control_building + buildings_variables.vol_plant_electrical_building = elev + buildings_variables.vol_plant_reactor_building = rbv + buildings_variables.vol_plant_maintenance_assembly_building = rmbv + buildings_variables.shovol = ( + buildings_variables.vol_plant_shops_warehouse_buildings + ) + buildings_variables.vol_plant_reactor_building_internal = vrci + buildings_variables.vol_plant_warm_shop_building = wsv # Total volume of nuclear buildings - buildings_variables.volnucb = vrci + rmbv + wsv + buildings_variables.triv + cryv + buildings_variables.vol_plant_nuclear_buildings = ( + vrci + + rmbv + + wsv + + buildings_variables.vol_plant_tritium_fuel_building + + cryv + ) if not output: return @@ -2402,8 +2427,8 @@ def ifebdg(self, output: bool = False): process_output.ovarre( self.outfile, "Dist from device centre to bldg wall (m)", - "(wrbi)", - buildings_variables.wrbi, + "(dr_plant_reactor_building_internal_half)", + buildings_variables.dr_plant_reactor_building_internal_half, ) process_output.ovarre( self.outfile, @@ -2419,8 +2444,8 @@ def ifebdg(self, output: bool = False): process_output.ovarre( self.outfile, "Tritium building volume (m3)", - "(triv)", - buildings_variables.triv, + "(vol_plant_tritium_fuel_building)", + buildings_variables.vol_plant_tritium_fuel_building, ) process_output.ovarre( self.outfile, "Electrical building volume (m3)", "(elev)", elev @@ -2428,8 +2453,8 @@ def ifebdg(self, output: bool = False): process_output.ovarre( self.outfile, "Control building volume (m3)", - "(conv)", - buildings_variables.conv, + "(vol_plant_control_building)", + buildings_variables.vol_plant_control_building, ) process_output.ovarre( self.outfile, "Cryogenics building volume (m3)", "(cryv)", cryv @@ -2437,17 +2462,20 @@ def ifebdg(self, output: bool = False): process_output.ovarre( self.outfile, "Administration building volume (m3)", - "(admv)", - buildings_variables.admv, + "(vol_plant_administration_building)", + buildings_variables.vol_plant_administration_building, ) process_output.ovarre( - self.outfile, "Shops volume (m3)", "(shov)", buildings_variables.shov + self.outfile, + "Shops volume (m3)", + "(vol_plant_shops_warehouse_buildings)", + buildings_variables.vol_plant_shops_warehouse_buildings, ) process_output.ovarre( self.outfile, "Total volume of nuclear buildings (m3)", - "(volnucb)", - buildings_variables.volnucb, + "(vol_plant_nuclear_buildings)", + buildings_variables.vol_plant_nuclear_buildings, ) def ifevac(self): diff --git a/process/models/power.py b/process/models/power.py index 9a85ed9465..3b7d29b2a6 100644 --- a/process/models/power.py +++ b/process/models/power.py @@ -2010,7 +2010,7 @@ def tfpwcall(self, output: bool): tfcoil_variables.tfckw, tfcoil_variables.len_tf_bus, tfcoil_variables.drarea, - buildings_variables.tfcbv, + buildings_variables.vol_plant_tf_power_supplies_building, heat_transport_variables.p_tf_electric_supplies_mw, ) = self.tfcpwr( output, @@ -2171,7 +2171,7 @@ def tfcpwr( drarea = 0.5e0 * ndumpr * (1.0e0 + r1emj) ** 0.667e0 # Total TF coil power conversion building volume, m3 - tfcbv = 6.0e0 * tfcfsp + vol_plant_tf_power_supplies_building = 6.0e0 * tfcfsp # TF coil AC inductive power demand, MW xpwrmw = xpower / 0.9e0 @@ -2185,7 +2185,7 @@ def tfcpwr( # tftsp = tfcfsp # Total TF coil power conversion building volume, m3 - # tftbv = tfcbv + # tftbv = vol_plant_tf_power_supplies_building # Output section if output: @@ -2305,9 +2305,9 @@ def tfcpwr( ) po.ovarre( self.outfile, - "TF coil power conv. building volume (m3)", - "(tfcbv)", - tfcbv, + "TF coil power vol_plant_control_building. building volume (m3)", + "(vol_plant_tf_power_supplies_building)", + vol_plant_tf_power_supplies_building, "OP ", ) po.ovarre( @@ -2325,7 +2325,13 @@ def tfcpwr( "OP ", ) - return (tfckw, len_tf_bus, drarea, tfcbv, p_tf_electric_supplies_mw) + return ( + tfckw, + len_tf_bus, + drarea, + vol_plant_tf_power_supplies_building, + p_tf_electric_supplies_mw, + ) def power_profiles_over_time( self, diff --git a/process/models/tfcoil/base.py b/process/models/tfcoil/base.py index 272aef36d9..398ead61cf 100644 --- a/process/models/tfcoil/base.py +++ b/process/models/tfcoil/base.py @@ -82,6 +82,8 @@ def run_base_tf(self): superconducting_tf_coil_variables.r_tf_outboard_out, tfcoil_variables.dx_tf_inboard_out_toroidal, tfcoil_variables.a_tf_leg_outboard, + tfcoil_variables.dr_tf_full_midplane, + tfcoil_variables.dr_tf_internal_midplane, tfcoil_variables.dr_tf_plasma_case, tfcoil_variables.dx_tf_side_case_min, ) = self.tf_global_geometry( @@ -204,6 +206,8 @@ def tf_global_geometry( - **rad_tf_coil_inboard_toroidal_half** (*float*): Toroidal angular spacing of each TF coil [radians]. - **tan_theta_coil** (*float*): Tangent of the toroidal angular spacing. - **a_tf_inboard_total** (*float*): Cross-sectional area of the inboard leg of the TF coil [m²]. + - **dr_tf_full_midplane** (*float*): Full external coil width at mid-plane [m]. + - **dr_tf_internal_midplane** (*float*): Full internal coil width at mid-plane [m]. - **r_tf_outboard_in** (*float*): Inner radius of the outboard leg of the TF coil [m]. - **r_tf_outboard_out** (*float*): Outer radius of the outboard leg of the TF coil [m]. - **dx_tf_inboard_out_toroidal** (*float*): Width of the inboard leg at the outer edge in the toroidal direction [m]. @@ -245,6 +249,14 @@ def tf_global_geometry( # Area of rectangular cross-section TF outboard leg [m^2] a_tf_leg_outboard = dx_tf_inboard_out_toroidal * dr_tf_outboard + # ===================================================================== + # Full external coil width at mid-plane [m] + + dr_tf_full_midplane = r_tf_outboard_out - r_tf_inboard_in + + # Full internal coil width at mid-plane [m] + dr_tf_internal_midplane = r_tf_outboard_in - r_tf_inboard_out + # ====================================================================== # Plasma facing front case thickness [m] @@ -293,6 +305,8 @@ def tf_global_geometry( r_tf_outboard_out, dx_tf_inboard_out_toroidal, a_tf_leg_outboard, + dr_tf_full_midplane, + dr_tf_internal_midplane, dr_tf_plasma_case, dx_tf_side_case_min, ) @@ -749,6 +763,20 @@ def outtf(self): "(dr_tf_outboard)", build_variables.dr_tf_outboard, ) + po.ovarre( + self.outfile, + "Full external coil width at mid-plane (m)", + "(dr_tf_full_midplane)", + tfcoil_variables.dr_tf_full_midplane, + "OP ", + ) + po.ovarre( + self.outfile, + "Full internal coil width at mid-plane (m)", + "(dr_tf_internal_midplane)", + tfcoil_variables.dr_tf_internal_midplane, + "OP ", + ) po.ovarre( self.outfile, "Outboard leg toroidal thickness (m)", diff --git a/tests/regression/input_files/IFE.IN.DAT b/tests/regression/input_files/IFE.IN.DAT index 06493b2de5..ddd58823e3 100644 --- a/tests/regression/input_files/IFE.IN.DAT +++ b/tests/regression/input_files/IFE.IN.DAT @@ -251,8 +251,8 @@ ucme = 3.0D8 *Cost of maintenance equipment ($) *---------------Buildings Variables----------------* pibv = 4.0D4 *Power injection building volume (m3) -rbrt = 3.2 *Reactor building roof thickness (m) -rbwt = 3.2 *Reactor building wall thickness (m) +dz_plant_reactor_building_roof = 3.2 *Reactor building roof thickness (m) +dx_plant_reactor_building_wall = 3.2 *Reactor building wall thickness (m) *---------------Heat Transport Variables-----------* eta_turbine = 0.45 *Thermal-to-electric conversion efficiency diff --git a/tests/unit/test_buildings.py b/tests/unit/test_buildings.py index d567052ea7..deb8d714da 100644 --- a/tests/unit/test_buildings.py +++ b/tests/unit/test_buildings.py @@ -29,7 +29,7 @@ def buildings(): class BldgsSizesParam(NamedTuple): i_bldgs_v: Any a_plant_floor_effective: Any - volnucb: Any + vol_plant_nuclear_buildings: Any bioshld_thk: Any reactor_wall_thk: Any reactor_roof_thk: Any @@ -172,7 +172,7 @@ class BldgsSizesParam(NamedTuple): BldgsSizesParam( i_bldgs_v=0, a_plant_floor_effective=0, - volnucb=0, + vol_plant_nuclear_buildings=0, bioshld_thk=2.5, reactor_wall_thk=2, reactor_roof_thk=1, @@ -311,7 +311,7 @@ class BldgsSizesParam(NamedTuple): BldgsSizesParam( i_bldgs_v=0, a_plant_floor_effective=1539392.0963074313, - volnucb=5212998.1139194397, + vol_plant_nuclear_buildings=5212998.1139194397, bioshld_thk=2.5, reactor_wall_thk=2, reactor_roof_thk=1, @@ -456,7 +456,11 @@ def test_bldgs_sizes(buildings, bldgssizesparam, monkeypatch): "a_plant_floor_effective", bldgssizesparam.a_plant_floor_effective, ) - monkeypatch.setattr(buildings_variables, "volnucb", bldgssizesparam.volnucb) + monkeypatch.setattr( + buildings_variables, + "vol_plant_nuclear_buildings", + bldgssizesparam.vol_plant_nuclear_buildings, + ) monkeypatch.setattr(buildings_variables, "bioshld_thk", bldgssizesparam.bioshld_thk) monkeypatch.setattr( buildings_variables, "reactor_wall_thk", bldgssizesparam.reactor_wall_thk @@ -741,7 +745,7 @@ def test_bldgs_sizes(buildings, bldgssizesparam, monkeypatch): monkeypatch.setattr(physics_variables, "rmajor", bldgssizesparam.rmajor) monkeypatch.setattr(physics_variables, "rminor", bldgssizesparam.rminor) - buildings.bldgs_sizes( + buildings.chapman_2024.calculate_building_sizes_chapman( tf_radial_dim=bldgssizesparam.tf_radial_dim, tf_vertical_dim=bldgssizesparam.tf_vertical_dim, output=False, @@ -759,37 +763,37 @@ def test_bldgs_sizes(buildings, bldgssizesparam, monkeypatch): class BldgsParam(NamedTuple): - wrbi: Any - rxcl: Any - trcl: Any + dr_plant_reactor_building_internal_half: Any + dr_plant_reactor_extra_clearance: Any + dr_plant_reactor_building_transport_clearance: Any row: Any - wgt: Any + m_plant_reactor_building_crane_capacity: Any shmf: Any clh2: Any dz_tf_cryostat: Any - stcl: Any + dz_plant_reactor_building_crane_roof_clearance: Any rbvfac: Any - rbwt: Any - rbrt: Any - fndt: Any + dx_plant_reactor_building_wall: Any + dz_plant_reactor_building_roof: Any + dz_plant_reactor_building_foundation: Any hcwt: Any hccl: Any wgt2: Any mbvfac: Any wsvfac: Any - tfcbv: Any + vol_plant_tf_power_supplies_building: Any pfbldgm3: Any esbldgm3: Any pibv: Any a_plant_floor_effective: Any admvol: Any - triv: Any - conv: Any - admv: Any - shov: Any + vol_plant_tritium_fuel_building: Any + vol_plant_control_building: Any + vol_plant_administration_building: Any + vol_plant_shops_warehouse_buildings: Any shovol: Any convol: Any - volnucb: Any + vol_plant_nuclear_buildings: Any iprint: Any outfile: Any pfr: Any @@ -823,37 +827,37 @@ class BldgsParam(NamedTuple): "bldgsparam", ( BldgsParam( - wrbi=0, - rxcl=4, - trcl=1, + dr_plant_reactor_building_internal_half=0, + dr_plant_reactor_extra_clearance=4, + dr_plant_reactor_building_transport_clearance=1, row=4, - wgt=500000, + m_plant_reactor_building_crane_capacity=500000, shmf=0.5, clh2=15, dz_tf_cryostat=5.7514039424138126, - stcl=3, + dz_plant_reactor_building_crane_roof_clearance=3, rbvfac=1.6000000000000001, - rbwt=2, - rbrt=1, - fndt=2, + dx_plant_reactor_building_wall=2, + dz_plant_reactor_building_roof=1, + dz_plant_reactor_building_foundation=2, hcwt=1.5, hccl=5, wgt2=100000, mbvfac=2.7999999999999998, wsvfac=1.8999999999999999, - tfcbv=10601.097615432001, + vol_plant_tf_power_supplies_building=10601.097615432001, pfbldgm3=20000, esbldgm3=1000, pibv=20000, a_plant_floor_effective=0, admvol=0, - triv=40000, - conv=60000, - admv=100000, - shov=100000, + vol_plant_tritium_fuel_building=40000, + vol_plant_control_building=60000, + vol_plant_administration_building=100000, + vol_plant_shops_warehouse_buildings=100000, shovol=0, convol=0, - volnucb=0, + vol_plant_nuclear_buildings=0, iprint=0, outfile=11, pfr=18.98258241468535, @@ -883,37 +887,37 @@ class BldgsParam(NamedTuple): expected_elev=51601.097615432001, ), BldgsParam( - wrbi=42.612047089019569, - rxcl=4, - trcl=1, + dr_plant_reactor_building_internal_half=42.612047089019569, + dr_plant_reactor_extra_clearance=4, + dr_plant_reactor_building_transport_clearance=1, row=4, - wgt=500000, + m_plant_reactor_building_crane_capacity=500000, shmf=0.5, clh2=15, dz_tf_cryostat=5.8405005070918357, - stcl=3, + dz_plant_reactor_building_crane_roof_clearance=3, rbvfac=1.6000000000000001, - rbwt=2, - rbrt=1, - fndt=2, + dx_plant_reactor_building_wall=2, + dz_plant_reactor_building_roof=1, + dz_plant_reactor_building_foundation=2, hcwt=1.5, hccl=5, wgt2=100000, mbvfac=2.7999999999999998, wsvfac=1.8999999999999999, - tfcbv=10609.268177478583, + vol_plant_tf_power_supplies_building=10609.268177478583, pfbldgm3=20000, esbldgm3=1000, pibv=20000, a_plant_floor_effective=379235.17804514873, admvol=100000, - triv=40000, - conv=60000, - admv=100000, - shov=100000, + vol_plant_tritium_fuel_building=40000, + vol_plant_control_building=60000, + vol_plant_administration_building=100000, + vol_plant_shops_warehouse_buildings=100000, shovol=100000, convol=60000, - volnucb=1812276.5359386117, + vol_plant_nuclear_buildings=1812276.5359386117, iprint=0, outfile=11, pfr=18.982980877139834, @@ -945,25 +949,63 @@ class BldgsParam(NamedTuple): ), ) def test_bldgs(buildings, bldgsparam, monkeypatch): - monkeypatch.setattr(buildings_variables, "wrbi", bldgsparam.wrbi) - monkeypatch.setattr(buildings_variables, "rxcl", bldgsparam.rxcl) - monkeypatch.setattr(buildings_variables, "trcl", bldgsparam.trcl) - monkeypatch.setattr(buildings_variables, "row", bldgsparam.row) - monkeypatch.setattr(buildings_variables, "wgt", bldgsparam.wgt) + monkeypatch.setattr( + buildings_variables, + "dr_plant_reactor_building_internal_half", + bldgsparam.dr_plant_reactor_building_internal_half, + ) + monkeypatch.setattr( + buildings_variables, + "dr_plant_reactor_extra_clearance", + bldgsparam.dr_plant_reactor_extra_clearance, + ) + monkeypatch.setattr( + buildings_variables, + "dr_plant_reactor_building_transport_clearance", + bldgsparam.dr_plant_reactor_building_transport_clearance, + ) + monkeypatch.setattr( + buildings_variables, "row", bldgsparam.dr_plant_reactor_crane_clearance + ) + monkeypatch.setattr( + buildings_variables, + "m_plant_reactor_building_crane_capacity", + bldgsparam.m_plant_reactor_building_crane_capacity, + ) monkeypatch.setattr(buildings_variables, "shmf", bldgsparam.shmf) monkeypatch.setattr(buildings_variables, "clh2", bldgsparam.clh2) monkeypatch.setattr(buildings_variables, "dz_tf_cryostat", bldgsparam.dz_tf_cryostat) - monkeypatch.setattr(buildings_variables, "stcl", bldgsparam.stcl) + monkeypatch.setattr( + buildings_variables, + "dz_plant_reactor_building_crane_roof_clearance", + bldgsparam.dz_plant_reactor_building_crane_roof_clearance, + ) monkeypatch.setattr(buildings_variables, "rbvfac", bldgsparam.rbvfac) - monkeypatch.setattr(buildings_variables, "rbwt", bldgsparam.rbwt) - monkeypatch.setattr(buildings_variables, "rbrt", bldgsparam.rbrt) - monkeypatch.setattr(buildings_variables, "fndt", bldgsparam.fndt) + monkeypatch.setattr( + buildings_variables, + "dx_plant_reactor_building_wall", + bldgsparam.dx_plant_reactor_building_wall, + ) + monkeypatch.setattr( + buildings_variables, + "dz_plant_reactor_building_roof", + bldgsparam.dz_plant_reactor_building_roof, + ) + monkeypatch.setattr( + buildings_variables, + "dz_plant_reactor_building_foundation", + bldgsparam.dz_plant_reactor_building_foundation, + ) monkeypatch.setattr(buildings_variables, "hcwt", bldgsparam.hcwt) monkeypatch.setattr(buildings_variables, "hccl", bldgsparam.hccl) monkeypatch.setattr(buildings_variables, "wgt2", bldgsparam.wgt2) monkeypatch.setattr(buildings_variables, "mbvfac", bldgsparam.mbvfac) monkeypatch.setattr(buildings_variables, "wsvfac", bldgsparam.wsvfac) - monkeypatch.setattr(buildings_variables, "tfcbv", bldgsparam.tfcbv) + monkeypatch.setattr( + buildings_variables, + "vol_plant_tf_power_supplies_building", + bldgsparam.vol_plant_tf_power_supplies_building, + ) monkeypatch.setattr(buildings_variables, "pfbldgm3", bldgsparam.pfbldgm3) monkeypatch.setattr(buildings_variables, "esbldgm3", bldgsparam.esbldgm3) monkeypatch.setattr(buildings_variables, "pibv", bldgsparam.pibv) @@ -973,19 +1015,39 @@ def test_bldgs(buildings, bldgsparam, monkeypatch): bldgsparam.a_plant_floor_effective, ) monkeypatch.setattr(buildings_variables, "admvol", bldgsparam.admvol) - monkeypatch.setattr(buildings_variables, "triv", bldgsparam.triv) - monkeypatch.setattr(buildings_variables, "conv", bldgsparam.conv) - monkeypatch.setattr(buildings_variables, "admv", bldgsparam.admv) - monkeypatch.setattr(buildings_variables, "shov", bldgsparam.shov) + monkeypatch.setattr( + buildings_variables, + "vol_plant_tritium_fuel_building", + bldgsparam.vol_plant_tritium_fuel_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_control_building", + bldgsparam.vol_plant_control_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_administration_building", + bldgsparam.vol_plant_administration_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_shops_warehouse_buildings", + bldgsparam.vol_plant_shops_warehouse_buildings, + ) monkeypatch.setattr(buildings_variables, "shovol", bldgsparam.shovol) monkeypatch.setattr(buildings_variables, "convol", bldgsparam.convol) - monkeypatch.setattr(buildings_variables, "volnucb", bldgsparam.volnucb) + monkeypatch.setattr( + buildings_variables, + "vol_plant_nuclear_buildings", + bldgsparam.vol_plant_nuclear_buildings, + ) - cryv, vrci, rbv, rmbv, wsv, elev = buildings.bldgs( + cryv, vrci, rbv, rmbv, wsv, elev = buildings.iter_1992.calculate_building_sizes_1992( output=False, pfr=bldgsparam.pfr, pfm=bldgsparam.pfm, - tfro=bldgsparam.tfro, + r_tf_outboard_out=bldgsparam.tfro, tfri=bldgsparam.tfri, tfh=bldgsparam.tfh, tfm=bldgsparam.tfm, @@ -998,14 +1060,18 @@ def test_bldgs(buildings, bldgsparam, monkeypatch): helpow=bldgsparam.helpow, ) - assert buildings_variables.wrbi == pytest.approx(bldgsparam.expected_wrbi) + assert buildings_variables.dr_plant_reactor_building_internal_half == pytest.approx( + bldgsparam.expected_wrbi + ) assert buildings_variables.a_plant_floor_effective == pytest.approx( bldgsparam.expected_a_plant_floor_effective ) assert buildings_variables.admvol == pytest.approx(bldgsparam.expected_admvol) assert buildings_variables.shovol == pytest.approx(bldgsparam.expected_shovol) assert buildings_variables.convol == pytest.approx(bldgsparam.expected_convol) - assert buildings_variables.volnucb == pytest.approx(bldgsparam.expected_volnucb) + assert buildings_variables.vol_plant_nuclear_buildings == pytest.approx( + bldgsparam.expected_volnucb + ) assert cryv == pytest.approx(bldgsparam.expected_cryv) assert vrci == pytest.approx(bldgsparam.expected_vrci) diff --git a/tests/unit/test_costs_1990.py b/tests/unit/test_costs_1990.py index 1843269b92..b02784d450 100644 --- a/tests/unit/test_costs_1990.py +++ b/tests/unit/test_costs_1990.py @@ -182,8 +182,8 @@ def acc2273_param(**kwargs): # Default parameters defaults = { "f_plasma_fuel_tritium": 0.0001, - "volrci": data_structure.buildings_variables.volrci, - "wsvol": data_structure.buildings_variables.wsvol, + "vol_plant_reactor_building_internal": data_structure.buildings_variables.vol_plant_reactor_building_internal, + "vol_plant_warm_shop_building": data_structure.buildings_variables.vol_plant_warm_shop_building, "expected": approx(0.0, abs=0.00001), } @@ -204,8 +204,8 @@ def acc2273_params(): acc2273_param(), acc2273_param( f_plasma_fuel_tritium=0.5, - volrci=1299783.4, - wsvol=132304.1, + vol_plant_reactor_building_internal=1299783.4, + vol_plant_warm_shop_building=132304.1, expected=approx(74.12, abs=0.01), ), ] @@ -226,8 +226,16 @@ def acc2273_fix(request, monkeypatch, costs): # Mock variables used by acc2273() # Some may be parameterised - monkeypatch.setattr(data_structure.buildings_variables, "wsvol", param["wsvol"]) - monkeypatch.setattr(data_structure.buildings_variables, "volrci", param["volrci"]) + monkeypatch.setattr( + data_structure.buildings_variables, + "vol_plant_warm_shop_building", + param["vol_plant_warm_shop_building"], + ) + monkeypatch.setattr( + data_structure.buildings_variables, + "vol_plant_reactor_building_internal", + param["vol_plant_reactor_building_internal"], + ) monkeypatch.setattr( physics_variables, "f_plasma_fuel_tritium", param["f_plasma_fuel_tritium"] ) @@ -258,8 +266,14 @@ def test_acc2274(monkeypatch, costs): :param monkeypatch: Mock fixture :type monkeypatch: object """ - monkeypatch.setattr(data_structure.buildings_variables, "wsvol", 132304.1) - monkeypatch.setattr(data_structure.buildings_variables, "volrci", 1299783.4) + monkeypatch.setattr( + data_structure.buildings_variables, "vol_plant_warm_shop_building", 132304.1 + ) + monkeypatch.setattr( + data_structure.buildings_variables, + "vol_plant_reactor_building_internal", + 1299783.4, + ) monkeypatch.setattr(cost_variables, "fkind", 1) monkeypatch.setattr(cost_variables, "c2274", 0) @@ -697,21 +711,21 @@ def test_acc9(monkeypatch, costs): class Acc21Param(NamedTuple): shovol: Any = None - triv: Any = None + vol_plant_tritium_fuel_building: Any = None - elevol: Any = None + vol_plant_electrical_building: Any = None - rbvol: Any = None + vol_plant_reactor_building: Any = None - cryvol: Any = None + vol_plant_cryoplant_building: Any = None - rmbvol: Any = None + vol_plant_maintenance_assembly_building: Any = None admvol: Any = None convol: Any = None - wsvol: Any = None + vol_plant_warm_shop_building: Any = None ucrb: Any = None @@ -787,14 +801,14 @@ class Acc21Param(NamedTuple): ( Acc21Param( shovol=100000, - triv=40000, - elevol=51601.097615432001, - rbvol=1356973.2891062023, - cryvol=15247.180612719381, - rmbvol=421473.52130148414, + vol_plant_tritium_fuel_building=40000, + vol_plant_electrical_building=51601.097615432001, + vol_plant_reactor_building=1356973.2891062023, + vol_plant_cryoplant_building=15247.180612719381, + vol_plant_maintenance_assembly_building=421473.52130148414, admvol=100000, convol=60000, - wsvol=130018.25667917728, + vol_plant_warm_shop_building=130018.25667917728, ucrb=400, ireactor=1, cturbb=38, @@ -832,14 +846,14 @@ class Acc21Param(NamedTuple): ), Acc21Param( shovol=100000, - triv=40000, - elevol=51609.268177478581, - rbvol=1358540.6868905292, - cryvol=25826.919937316459, - rmbvol=423252.94369581528, + vol_plant_tritium_fuel_building=40000, + vol_plant_electrical_building=51609.268177478581, + vol_plant_reactor_building=1358540.6868905292, + vol_plant_cryoplant_building=25826.919937316459, + vol_plant_maintenance_assembly_building=423252.94369581528, admvol=100000, convol=60000, - wsvol=130255.93791329287, + vol_plant_warm_shop_building=130255.93791329287, ucrb=400, ireactor=1, cturbb=38, @@ -892,21 +906,45 @@ def test_acc21(acc21param, monkeypatch, costs): monkeypatch.setattr(buildings_variables, "shovol", acc21param.shovol) - monkeypatch.setattr(buildings_variables, "triv", acc21param.triv) + monkeypatch.setattr( + buildings_variables, + "vol_plant_tritium_fuel_building", + acc21param.vol_plant_tritium_fuel_building, + ) - monkeypatch.setattr(buildings_variables, "elevol", acc21param.elevol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_electrical_building", + acc21param.vol_plant_electrical_building, + ) - monkeypatch.setattr(buildings_variables, "rbvol", acc21param.rbvol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_reactor_building", + acc21param.vol_plant_reactor_building, + ) - monkeypatch.setattr(buildings_variables, "cryvol", acc21param.cryvol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_cryoplant_building", + acc21param.vol_plant_cryoplant_building, + ) - monkeypatch.setattr(buildings_variables, "rmbvol", acc21param.rmbvol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_maintenance_assembly_building", + acc21param.vol_plant_maintenance_assembly_building, + ) monkeypatch.setattr(buildings_variables, "admvol", acc21param.admvol) monkeypatch.setattr(buildings_variables, "convol", acc21param.convol) - monkeypatch.setattr(buildings_variables, "wsvol", acc21param.wsvol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_warm_shop_building", + acc21param.vol_plant_warm_shop_building, + ) monkeypatch.setattr(cost_variables, "ucrb", acc21param.ucrb) @@ -4477,9 +4515,9 @@ def test_acc2272_rut(acc2272param, monkeypatch, costs): class Acc2273Param(NamedTuple): - wsvol: Any = None + vol_plant_warm_shop_building: Any = None - volrci: Any = None + vol_plant_reactor_building_internal: Any = None fkind: Any = None @@ -4498,8 +4536,8 @@ class Acc2273Param(NamedTuple): "acc2273param", ( Acc2273Param( - wsvol=130018.25667917728, - volrci=1205439.8543893537, + vol_plant_warm_shop_building=130018.25667917728, + vol_plant_reactor_building_internal=1205439.8543893537, fkind=1, f_plasma_fuel_tritium=0.5, c227=0, @@ -4508,8 +4546,8 @@ class Acc2273Param(NamedTuple): expected_c2273=69.115208498727412, ), Acc2273Param( - wsvol=130255.93791329287, - volrci=1206887.4047542624, + vol_plant_warm_shop_building=130255.93791329287, + vol_plant_reactor_building_internal=1206887.4047542624, fkind=1, f_plasma_fuel_tritium=0.5, c227=284.96904049038437, @@ -4532,9 +4570,17 @@ def test_acc2273_rut(acc2273param, monkeypatch, costs): :type monkeypatch: _pytest.monkeypatch.monkeypatch """ - monkeypatch.setattr(buildings_variables, "wsvol", acc2273param.wsvol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_warm_shop_building", + acc2273param.vol_plant_warm_shop_building, + ) - monkeypatch.setattr(buildings_variables, "volrci", acc2273param.volrci) + monkeypatch.setattr( + buildings_variables, + "vol_plant_reactor_building_internal", + acc2273param.vol_plant_reactor_building_internal, + ) monkeypatch.setattr(cost_variables, "fkind", acc2273param.fkind) @@ -4554,9 +4600,9 @@ def test_acc2273_rut(acc2273param, monkeypatch, costs): class Acc2274Param(NamedTuple): - wsvol: Any = None + vol_plant_warm_shop_building: Any = None - volrci: Any = None + vol_plant_reactor_building_internal: Any = None fkind: Any = None @@ -4573,8 +4619,8 @@ class Acc2274Param(NamedTuple): "acc2274param", ( Acc2274Param( - wsvol=130018.25667917728, - volrci=1205439.8543893537, + vol_plant_warm_shop_building=130018.25667917728, + vol_plant_reactor_building_internal=1205439.8543893537, fkind=1, c227=0, c2274=0, @@ -4582,8 +4628,8 @@ class Acc2274Param(NamedTuple): expected_c2274=79.525098581749191, ), Acc2274Param( - wsvol=130255.93791329287, - volrci=1206887.4047542624, + vol_plant_warm_shop_building=130255.93791329287, + vol_plant_reactor_building_internal=1206887.4047542624, fkind=1, c227=284.96904049038437, c2274=79.525098581749191, @@ -4605,9 +4651,17 @@ def test_acc2274_rut(acc2274param, monkeypatch, costs): :type monkeypatch: _pytest.monkeypatch.monkeypatch """ - monkeypatch.setattr(buildings_variables, "wsvol", acc2274param.wsvol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_warm_shop_building", + acc2274param.vol_plant_warm_shop_building, + ) - monkeypatch.setattr(buildings_variables, "volrci", acc2274param.volrci) + monkeypatch.setattr( + buildings_variables, + "vol_plant_reactor_building_internal", + acc2274param.vol_plant_reactor_building_internal, + ) monkeypatch.setattr(cost_variables, "fkind", acc2274param.fkind) diff --git a/tests/unit/test_ife.py b/tests/unit/test_ife.py index 66879372a6..0770186a9d 100644 --- a/tests/unit/test_ife.py +++ b/tests/unit/test_ife.py @@ -2272,8 +2272,8 @@ def test_ifepw1(ifepw1param, monkeypatch, ife): class Bld2019Param(NamedTuple): a_fw_total: Any = None - trcl: Any = None - stcl: Any = None + dr_plant_reactor_building_transport_clearance: Any = None + dz_plant_reactor_building_crane_roof_clearance: Any = None tbr: Any = None f_p_blkt_multiplication: Any = None ifetyp: Any = None @@ -2364,8 +2364,8 @@ class Bld2019Param(NamedTuple): ( Bld2019Param( a_fw_total=0.0, - trcl=1.0, - stcl=3.0, + dr_plant_reactor_building_transport_clearance=1.0, + dz_plant_reactor_building_crane_roof_clearance=3.0, tbr=0.0, f_p_blkt_multiplication=1.26, ifetyp=4, @@ -2645,8 +2645,16 @@ def test_bld2019(bld2019param, monkeypatch, ife): :type monkeypatch: _pytest.monkeypatch.monkeypatch """ monkeypatch.setattr(first_wall_variables, "a_fw_total", bld2019param.a_fw_total) - monkeypatch.setattr(buildings_variables, "trcl", bld2019param.trcl) - monkeypatch.setattr(buildings_variables, "stcl", bld2019param.stcl) + monkeypatch.setattr( + buildings_variables, + "dr_plant_reactor_building_transport_clearance", + bld2019param.dr_plant_reactor_building_transport_clearance, + ) + monkeypatch.setattr( + buildings_variables, + "dz_plant_reactor_building_crane_roof_clearance", + bld2019param.dz_plant_reactor_building_crane_roof_clearance, + ) monkeypatch.setattr(fwbs_variables, "tbr", bld2019param.tbr) monkeypatch.setattr( fwbs_variables, "f_p_blkt_multiplication", bld2019param.f_p_blkt_multiplication @@ -2856,30 +2864,30 @@ def test_ifeacp(ifeacpparam, monkeypatch, ife): class IfebdgParam(NamedTuple): - wrbi: Any = None - rbwt: Any = None - rbrt: Any = None - fndt: Any = None - trcl: Any = None + dr_plant_reactor_building_internal_half: Any = None + dx_plant_reactor_building_wall: Any = None + dz_plant_reactor_building_roof: Any = None + dz_plant_reactor_building_foundation: Any = None + dr_plant_reactor_building_transport_clearance: Any = None hcwt: Any = None hccl: Any = None wgt2: Any = None - stcl: Any = None + dz_plant_reactor_building_crane_roof_clearance: Any = None pibv: Any = None a_plant_floor_effective: Any = None - triv: Any = None - conv: Any = None - admv: Any = None - shov: Any = None + vol_plant_tritium_fuel_building: Any = None + vol_plant_control_building: Any = None + vol_plant_administration_building: Any = None + vol_plant_shops_warehouse_buildings: Any = None admvol: Any = None convol: Any = None - elevol: Any = None - rbvol: Any = None - rmbvol: Any = None + vol_plant_electrical_building: Any = None + vol_plant_reactor_building: Any = None + vol_plant_maintenance_assembly_building: Any = None shovol: Any = None - volrci: Any = None - wsvol: Any = None - volnucb: Any = None + vol_plant_reactor_building_internal: Any = None + vol_plant_warm_shop_building: Any = None + vol_plant_nuclear_buildings: Any = None whtshld: Any = None helpow: Any = None zl7: Any = None @@ -2905,30 +2913,30 @@ class IfebdgParam(NamedTuple): "ifebdgparam", ( IfebdgParam( - wrbi=0.0, - rbwt=3.2000000000000002, - rbrt=3.2000000000000002, - fndt=2.0, - trcl=1.0, + dr_plant_reactor_building_internal_half=0.0, + dx_plant_reactor_building_wall=3.2000000000000002, + dz_plant_reactor_building_roof=3.2000000000000002, + dz_plant_reactor_building_foundation=2.0, + dr_plant_reactor_building_transport_clearance=1.0, hcwt=1.5, hccl=5.0, wgt2=100000.0, - stcl=3.0, + dz_plant_reactor_building_crane_roof_clearance=3.0, pibv=40000.0, a_plant_floor_effective=0.0, - triv=40000.0, - conv=60000.0, - admv=100000.0, - shov=100000.0, + vol_plant_tritium_fuel_building=40000.0, + vol_plant_control_building=60000.0, + vol_plant_administration_building=100000.0, + vol_plant_shops_warehouse_buildings=100000.0, admvol=0.0, convol=0.0, - elevol=0.0, - rbvol=0.0, - rmbvol=0.0, + vol_plant_electrical_building=0.0, + vol_plant_reactor_building=0.0, + vol_plant_maintenance_assembly_building=0.0, shovol=0.0, - volrci=0.0, - wsvol=0.0, - volnucb=0.0, + vol_plant_reactor_building_internal=0.0, + vol_plant_warm_shop_building=0.0, + vol_plant_nuclear_buildings=0.0, whtshld=1067310.9593707009, helpow=20277.29636048527, zl7=5.8499999999999996, @@ -2963,34 +2971,98 @@ def test_ifebdg(ifebdgparam, monkeypatch, ife): :param monkeypatch: pytest fixture used to mock module/class variables :type monkeypatch: _pytest.monkeypatch.monkeypatch """ - monkeypatch.setattr(buildings_variables, "wrbi", ifebdgparam.wrbi) - monkeypatch.setattr(buildings_variables, "rbwt", ifebdgparam.rbwt) - monkeypatch.setattr(buildings_variables, "rbrt", ifebdgparam.rbrt) - monkeypatch.setattr(buildings_variables, "fndt", ifebdgparam.fndt) - monkeypatch.setattr(buildings_variables, "trcl", ifebdgparam.trcl) + monkeypatch.setattr( + buildings_variables, + "dr_plant_reactor_building_internal_half", + ifebdgparam.dr_plant_reactor_building_internal_half, + ) + monkeypatch.setattr( + buildings_variables, + "dx_plant_reactor_building_wall", + ifebdgparam.dx_plant_reactor_building_wall, + ) + monkeypatch.setattr( + buildings_variables, + "dz_plant_reactor_building_roof", + ifebdgparam.dz_plant_reactor_building_roof, + ) + monkeypatch.setattr( + buildings_variables, + "dz_plant_reactor_building_foundation", + ifebdgparam.dz_plant_reactor_building_foundation, + ) + monkeypatch.setattr( + buildings_variables, + "dr_plant_reactor_building_transport_clearance", + ifebdgparam.dr_plant_reactor_building_transport_clearance, + ) monkeypatch.setattr(buildings_variables, "hcwt", ifebdgparam.hcwt) monkeypatch.setattr(buildings_variables, "hccl", ifebdgparam.hccl) monkeypatch.setattr(buildings_variables, "wgt2", ifebdgparam.wgt2) - monkeypatch.setattr(buildings_variables, "stcl", ifebdgparam.stcl) + monkeypatch.setattr( + buildings_variables, + "dz_plant_reactor_building_crane_roof_clearance", + ifebdgparam.dz_plant_reactor_building_crane_roof_clearance, + ) monkeypatch.setattr(buildings_variables, "pibv", ifebdgparam.pibv) monkeypatch.setattr( buildings_variables, "a_plant_floor_effective", ifebdgparam.a_plant_floor_effective, ) - monkeypatch.setattr(buildings_variables, "triv", ifebdgparam.triv) - monkeypatch.setattr(buildings_variables, "conv", ifebdgparam.conv) - monkeypatch.setattr(buildings_variables, "admv", ifebdgparam.admv) - monkeypatch.setattr(buildings_variables, "shov", ifebdgparam.shov) + monkeypatch.setattr( + buildings_variables, + "vol_plant_tritium_fuel_building", + ifebdgparam.vol_plant_tritium_fuel_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_control_building", + ifebdgparam.vol_plant_control_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_administration_building", + ifebdgparam.vol_plant_administration_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_shops_warehouse_buildings", + ifebdgparam.vol_plant_shops_warehouse_buildings, + ) monkeypatch.setattr(buildings_variables, "admvol", ifebdgparam.admvol) monkeypatch.setattr(buildings_variables, "convol", ifebdgparam.convol) - monkeypatch.setattr(buildings_variables, "elevol", ifebdgparam.elevol) - monkeypatch.setattr(buildings_variables, "rbvol", ifebdgparam.rbvol) - monkeypatch.setattr(buildings_variables, "rmbvol", ifebdgparam.rmbvol) + monkeypatch.setattr( + buildings_variables, + "vol_plant_electrical_building", + ifebdgparam.vol_plant_electrical_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_reactor_building", + ifebdgparam.vol_plant_reactor_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_maintenance_assembly_building", + ifebdgparam.vol_plant_maintenance_assembly_building, + ) monkeypatch.setattr(buildings_variables, "shovol", ifebdgparam.shovol) - monkeypatch.setattr(buildings_variables, "volrci", ifebdgparam.volrci) - monkeypatch.setattr(buildings_variables, "wsvol", ifebdgparam.wsvol) - monkeypatch.setattr(buildings_variables, "volnucb", ifebdgparam.volnucb) + monkeypatch.setattr( + buildings_variables, + "vol_plant_reactor_building_internal", + ifebdgparam.vol_plant_reactor_building_internal, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_warm_shop_building", + ifebdgparam.vol_plant_warm_shop_building, + ) + monkeypatch.setattr( + buildings_variables, + "vol_plant_nuclear_buildings", + ifebdgparam.vol_plant_nuclear_buildings, + ) monkeypatch.setattr(fwbs_variables, "whtshld", ifebdgparam.whtshld) monkeypatch.setattr(heat_transport_variables, "helpow", ifebdgparam.helpow) monkeypatch.setattr(ife_variables, "zl7", ifebdgparam.zl7) @@ -3002,19 +3074,33 @@ def test_ifebdg(ifebdgparam, monkeypatch, ife): ife.ifebdg() - assert buildings_variables.wrbi == pytest.approx(ifebdgparam.expected_wrbi) + assert buildings_variables.dr_plant_reactor_building_internal_half == pytest.approx( + ifebdgparam.expected_wrbi + ) assert buildings_variables.a_plant_floor_effective == pytest.approx( ifebdgparam.expected_a_plant_floor_effective ) assert buildings_variables.admvol == pytest.approx(ifebdgparam.expected_admvol) assert buildings_variables.convol == pytest.approx(ifebdgparam.expected_convol) - assert buildings_variables.elevol == pytest.approx(ifebdgparam.expected_elevol) - assert buildings_variables.rbvol == pytest.approx(ifebdgparam.expected_rbvol) - assert buildings_variables.rmbvol == pytest.approx(ifebdgparam.expected_rmbvol) + assert buildings_variables.vol_plant_electrical_building == pytest.approx( + ifebdgparam.expected_elevol + ) + assert buildings_variables.vol_plant_reactor_building == pytest.approx( + ifebdgparam.expected_rbvol + ) + assert buildings_variables.vol_plant_maintenance_assembly_building == pytest.approx( + ifebdgparam.expected_rmbvol + ) assert buildings_variables.shovol == pytest.approx(ifebdgparam.expected_shovol) - assert buildings_variables.volrci == pytest.approx(ifebdgparam.expected_volrci) - assert buildings_variables.wsvol == pytest.approx(ifebdgparam.expected_wsvol) - assert buildings_variables.volnucb == pytest.approx(ifebdgparam.expected_volnucb) + assert buildings_variables.vol_plant_reactor_building_internal == pytest.approx( + ifebdgparam.expected_volrci + ) + assert buildings_variables.vol_plant_warm_shop_building == pytest.approx( + ifebdgparam.expected_wsvol + ) + assert buildings_variables.vol_plant_nuclear_buildings == pytest.approx( + ifebdgparam.expected_volnucb + ) class Ifepw2Param(NamedTuple): diff --git a/tests/unit/test_tfcoil.py b/tests/unit/test_tfcoil.py index e52b3a6f8d..23befda3f2 100644 --- a/tests/unit/test_tfcoil.py +++ b/tests/unit/test_tfcoil.py @@ -275,6 +275,8 @@ def test_cntrpst(cntrpst_asset, monkeypatch, reinitialise_error_module, tfcoil): pytest.approx(5.15), # r_tf_outboard_out pytest.approx(0.780361288064513), # dx_tf_inboard_out_toroidal pytest.approx(0.2341083864193539), # a_tf_leg_outboard + pytest.approx(5.15 - 1.5), # dr_tf_full_midplane + pytest.approx(4.85 - 2.0), # dr_tf_internal_midplane pytest.approx(0.03842943919353914), # dr_tf_plasma_case pytest.approx(0.0), # dx_tf_side_case_min ), @@ -300,6 +302,8 @@ def test_cntrpst(cntrpst_asset, monkeypatch, reinitialise_error_module, tfcoil): pytest.approx(4.625), # r_tf_outboard_out pytest.approx(0.9317485623690747), # dx_tf_inboard_out_toroidal pytest.approx(0.23293714059226867), # a_tf_leg_outboard + pytest.approx(4.625 - 1.4), # dr_tf_full_midplane + pytest.approx(4.375 - 1.8), # dr_tf_internal_midplane pytest.approx(0.04), # dr_tf_plasma_case pytest.approx(0.019426316451256392), # dx_tf_side_case_min ),