From 83df2127417dd454376155ebd2e49d725f0e0f4c Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Wed, 22 Jan 2025 17:15:52 +0000 Subject: [PATCH 01/27] Fix to keff for MG scattering --- Tallies/TallyClerks/keffImplicitClerk_class.f90 | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Tallies/TallyClerks/keffImplicitClerk_class.f90 b/Tallies/TallyClerks/keffImplicitClerk_class.f90 index 008c50e02..d7f4852dd 100644 --- a/Tallies/TallyClerks/keffImplicitClerk_class.f90 +++ b/Tallies/TallyClerks/keffImplicitClerk_class.f90 @@ -26,7 +26,7 @@ module keffImplicitClerk_class private - !! Locations of diffrent bins wrt memory Address of the clerk + !! Locations of different bins wrt memory Address of the clerk integer(shortInt), parameter :: MEM_SIZE = 5 integer(longInt), parameter :: IMP_PROD = 0 ,& ! Implicit neutron production (from fission) SCATTER_PROD = 1 ,& ! Analog Stattering production (N,XN) @@ -38,7 +38,7 @@ module keffImplicitClerk_class !! and on analog estimators of (N,XN) reactions and leakage !! !! Private Members: - !! targetSTD -> Target Standard Deviation for convergance check + !! targetSTD -> Target Standard Deviation for convergence check !! !! Interface: !! tallyClerk interface @@ -96,10 +96,10 @@ subroutine init(self, dict, name) ! Set name call self % setName(name) - ! Configure convergance trigger + ! Configure convergence trigger call dict % getOrDefault(chr,'trigger','no') - ! Read convergance target + ! Read convergence target if( charCmp(chr,'yes')) then call dict % get(self % targetSTD,'SDtarget') @@ -126,7 +126,7 @@ elemental subroutine kill(self) end subroutine kill !! - !! Returns array of codes that represent diffrent reports + !! Returns array of codes that represent different reports !! !! See tallyClerk_inter for details !! @@ -225,7 +225,7 @@ subroutine reportOutColl(self, p, MT, muL, xsData, mem) score = 2.0_defReal * p % preCollision % wgt case(N_4N) score = 3.0_defReal * p % preCollision % wgt - case(macroAllScatter) ! Catch weight change for MG scattering + case(macroAllScatter, macroIEScatter) ! Catch weight change for MG scattering score = max(p % w - p % preCollision % wgt, ZERO) case default score = ZERO @@ -289,7 +289,7 @@ subroutine reportCycleEnd(self, end, mem) end subroutine reportCycleEnd !! - !! Perform convergance check in the Clerk + !! Perform convergence check in the Clerk !! !! See tallyClerk_inter for details !! @@ -306,7 +306,7 @@ function isConverged(self, mem) result(isIt) end function isConverged !! - !! Display convergance progress on the console + !! Display convergence progress on the console !! !! See tallyClerk_inter for details !! From 0791fe251f443601ed3b11332c7ac187d5ab13c4 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Thu, 6 Feb 2025 19:15:33 +0000 Subject: [PATCH 02/27] BEAVRS_HZP and geometry fixes Added in the BEAVRS model with the D-bank partially inserted. Also fixed a flaw in the geometry where the outermost cell was defined such that there could be a rare particle lost between it and the geometry boundary. --- InputFiles/Benchmarks/BEAVRS/BEAVRS2D | 3 +- .../Benchmarks/BEAVRS/{BEAVRS => BEAVRS_ARO} | 9 +- InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP | 2410 +++++++++++++++++ 3 files changed, 2416 insertions(+), 6 deletions(-) rename InputFiles/Benchmarks/BEAVRS/{BEAVRS => BEAVRS_ARO} (97%) create mode 100644 InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP diff --git a/InputFiles/Benchmarks/BEAVRS/BEAVRS2D b/InputFiles/Benchmarks/BEAVRS/BEAVRS2D index 0ace8d16c..899a59c71 100644 --- a/InputFiles/Benchmarks/BEAVRS/BEAVRS2D +++ b/InputFiles/Benchmarks/BEAVRS/BEAVRS2D @@ -114,7 +114,8 @@ geometry { thickGrid {type simpleCell; id 55; surfaces (90 -91); filltype mat; material Inconel;} thinGrid {type simpleCell; id 56; surfaces (-92 93); filltype mat; material Inconel;} - pressureVessel { type simpleCell; id 7; surfaces (-1 2); filltype mat; material CarbonSteel;} + ! Does not use surface 1 to define it as that bounds the geometry + pressureVessel { type simpleCell; id 7; surfaces (2); filltype mat; material CarbonSteel;} RPVLiner { type simpleCell; id 8; surfaces (-2 3); filltype mat; material SS304;} outerWater1 {type simpleCell; id 9; surfaces (-3 4 ); filltype mat; material Water;} diff --git a/InputFiles/Benchmarks/BEAVRS/BEAVRS b/InputFiles/Benchmarks/BEAVRS/BEAVRS_ARO similarity index 97% rename from InputFiles/Benchmarks/BEAVRS/BEAVRS rename to InputFiles/Benchmarks/BEAVRS/BEAVRS_ARO index 52e5cb575..dd3ed25c5 100644 --- a/InputFiles/Benchmarks/BEAVRS/BEAVRS +++ b/InputFiles/Benchmarks/BEAVRS/BEAVRS_ARO @@ -3,14 +3,12 @@ !! This is not a fully faithful replica of BEAVRS at HZP: !! all rods are fully withdrawn. !! In reality, some rods are partially inserted. -!! TODO: add rods in the appropriate assemblies at the -!! correct heights! !! type eigenPhysicsPackage; -pop 10000000; +pop 1000000; active 50; -inactive 200; +inactive 150; XSdata ce; dataType ce; @@ -216,7 +214,8 @@ geometry { thickGrid {type simpleCell; id 555; surfaces (90 ); filltype mat; material Inconel;} thinGrid {type simpleCell; id 556; surfaces (92 ); filltype mat; material Zircaloy;} - pressureVessel { type simpleCell; id 7; surfaces (-1 2); filltype mat; material CarbonSteel;} + // Don't need to bound PV by 1 since it is the bounding surface of the geometry. + pressureVessel { type simpleCell; id 7; surfaces ( 2); filltype mat; material CarbonSteel;} RPVLiner { type simpleCell; id 8; surfaces (-2 3); filltype mat; material SS304;} outerWater1 {type simpleCell; id 9; surfaces (-3 4 ); filltype mat; material Water;} diff --git a/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP b/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP new file mode 100644 index 000000000..5a740ce28 --- /dev/null +++ b/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP @@ -0,0 +1,2410 @@ +!! +!! 3D BEAVRS benchmark +!! At HZP, the D bank of rods is partially inserted up +!! to 115 steps inserted / 113 steps withdrawn. +!! A step corresponds to an increment of 1.58193cm +!! +type eigenPhysicsPackage; + +pop 1000000; +active 50; +inactive 250; +XSdata ce; +dataType ce; + +collisionOperator { neutronCE {type neutronCEstd;}} + +transportOperator { + !type transportOperatorDT; + type transportOperatorHT; cache 1; + } + +inactiveTally { + shannon { + type shannonEntropyClerk; + map {type multiMap; + maps (xax yax zax); + xax { type spaceMap; grid lin; min -161.2773; max 161.2773; N 15; axis x;} + yax { type spaceMap; grid lin; min -161.2773; max 161.2773; N 15; axis y;} + zax { type spaceMap; grid lin; min 36.748; max 402.508; N 15; axis z;} + } + cycles 200; + } + +} + +activeTally { + pinFissRadial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type multiMap; maps (xax yax); + xax {type spaceMap; axis x; grid lin; N 255; min -161.2773; max 161.2773; } + yax {type spaceMap; axis y; grid lin; N 255; min -161.2773; max 161.2773; } + } + } + assemblyFissRadial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type multiMap; maps (xax yax); + xax {type spaceMap; axis x; grid lin; N 15; min -161.2773; max 161.2773; } + yax {type spaceMap; axis y; grid lin; N 15; min -161.2773; max 161.2773; } + } + } + fissionAxial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type spaceMap; axis z; grid lin; N 60; min 36.748; max 402.508;} + } + fissionYZ { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type multiMap; maps (yax zax); + yax {type spaceMap; axis y; grid lin; N 255; min -161.2773; max 161.2773; } + zax {type spaceMap; axis z; grid lin; N 60; min 36.748; max 402.508;} + } + } +} + +geometry { + type geometryStd; + boundary ( 0 0 0 0 0 0); + graph {type shrunk;} + + surfaces { + + // thickness specifications for RPV and RPV liner + outerRPV { id 1; type zTruncCylinder; radius 241.3; origin (0.0 0.0 230.0); halfwidth 230; } + innerRPV { id 2; type zCylinder; radius 219.710; origin (0.0 0.0 0.0); } + innerRPVLiner { id 3; type zCylinder; radius 219.150; origin (0.0 0.0 0.0); } + + // thickness specifications for neutron shield + outerBoundNS { id 4; type zCylinder; radius 201.630; origin (0.0 0.0 0.0); } + innerBoundNS { id 5; type zCylinder; radius 194.84; origin (0.0 0.0 0.0); } + + // thickness specifications for core barrel + outerCoreBarrel { id 6; type zCylinder; radius 193.675; origin (0.0 0.0 0.0); } + innerCoreBarrel { id 7; type zCylinder; radius 187.96; origin (0.0 0.0 0.0); } + + // four planes that intersect to bound the Neutron shield panel + P1 { id 8; type plane; coeffs (-0.48480962025 0.87461970714 0.0 0.0);} + P2 { id 9; type plane; coeffs (-0.87461970714 0.48480962025 0.0 0.0);} + P3 { id 10; type plane; coeffs (-0.87461970714 -0.48480962025 0.0 0.0);} + P4 { id 11; type plane; coeffs (-0.48480962025 -0.87461970714 0.0 0.0);} + + // bounding widths for baffle on various sides + // right & left refers to the side of the reactor that it is on + // close/away refers to its location in relation to the LATTICE it is a part of + // (NOT the reactor itself) + rightClose { id 50; type plane; coeffs (1.0 0.0 0.0 8.36662);} + rightAway { id 51; type plane; coeffs (1.0 0.0 0.0 10.58912);} + leftClose { id 52; type plane; coeffs (-1.0 0.0 0.0 8.36662);} + leftAway { id 53; type plane; coeffs (-1.0 0.0 0.0 10.58912);} + bottomClose { id 54; type plane; coeffs (0.0 -1.0 0.0 8.36662);} + bottomAway { id 55; type plane; coeffs (0.0 -1.0 0.0 10.58912);} + topClose { id 56; type plane; coeffs (0.0 1.0 0.0 8.36662);} + topAway { id 57; type plane; coeffs (0.0 1.0 0.0 10.58912);} + + // thickness specifications for grid with thickness of 0.0198cm (Inconel) + pinThickGridInner { id 90; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.61015 0.61015 0.0); } + pinThickGridOuter { id 91; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.62992 0.62992 0.0); } + + // thickness specifications for grid with thickness of 0.0194cm (Zircaloy) + pinThinGridInner { id 92; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.61049 0.61049 0.0); } + pinThinGridOuter { id 93; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.62992 0.62992 0.0); } + + // inner and outer surfaces of assembly sleeves (both SS and Zircaloy) + assemblySleeveInner { id 94; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (10.70864 10.70864 0.0); } + assemblySleeveOuter { id 95; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (10.74798 10.74798 0.0); } + + + // Axial planes across core height + // Names are based on axial heights + plane460 { id 100; type plane; coeffs (0.0 0.0 1.0 460.0 ); } + plane431p876 { id 101; type plane; coeffs (0.0 0.0 1.0 431.876); } + plane423p049 { id 102; type plane; coeffs (0.0 0.0 1.0 423.049); } + plane421p532 { id 103; type plane; coeffs (0.0 0.0 1.0 421.532); } + plane419p704 { id 104; type plane; coeffs (0.0 0.0 1.0 419.704); } + plane417p164 { id 105; type plane; coeffs (0.0 0.0 1.0 417.164); } + plane415p164 { id 106; type plane; coeffs (0.0 0.0 1.0 415.164); } + plane411p806 { id 107; type plane; coeffs (0.0 0.0 1.0 411.806); } + plane403p778 { id 108; type plane; coeffs (0.0 0.0 1.0 403.778); } + plane402p508 { id 109; type plane; coeffs (0.0 0.0 1.0 402.508); } + plane401p238 { id 110; type plane; coeffs (0.0 0.0 1.0 401.238); } + plane364p725 { id 111; type plane; coeffs (0.0 0.0 1.0 364.725); } + plane359p01 { id 112; type plane; coeffs (0.0 0.0 1.0 359.01 ); } + plane312p528 { id 113; type plane; coeffs (0.0 0.0 1.0 312.528); } + plane306p813 { id 114; type plane; coeffs (0.0 0.0 1.0 306.813); } + plane260p331 { id 115; type plane; coeffs (0.0 0.0 1.0 260.331); } + plane254p616 { id 116; type plane; coeffs (0.0 0.0 1.0 254.616); } + plane208p134 { id 117; type plane; coeffs (0.0 0.0 1.0 208.134); } + plane202p419 { id 118; type plane; coeffs (0.0 0.0 1.0 202.419); } + plane155p937 { id 119; type plane; coeffs (0.0 0.0 1.0 155.937); } + plane150p222 { id 120; type plane; coeffs (0.0 0.0 1.0 150.222); } + plane143p428 { id 121; type plane; coeffs (0.0 0.0 1.0 143.428); } + plane103p74 { id 122; type plane; coeffs (0.0 0.0 1.0 103.74 ); } + plane98p025 { id 123; type plane; coeffs (0.0 0.0 1.0 98.025 ); } + plane41p828 { id 124; type plane; coeffs (0.0 0.0 1.0 41.828 ); } + plane40p558 { id 125; type plane; coeffs (0.0 0.0 1.0 40.558 ); } + plane40p52 { id 126; type plane; coeffs (0.0 0.0 1.0 40.52 ); } + plane39p958 { id 127; type plane; coeffs (0.0 0.0 1.0 39.958 ); } + plane38p66 { id 128; type plane; coeffs (0.0 0.0 1.0 38.66 ); } + plane37p1621 { id 129; type plane; coeffs (0.0 0.0 1.0 37.1621); } + plane36p748 { id 130; type plane; coeffs (0.0 0.0 1.0 36.748 ); } + plane35 { id 131; type plane; coeffs (0.0 0.0 1.0 35.0 ); } + plane20 { id 132; type plane; coeffs (0.0 0.0 1.0 20.0 ); } + plane0 { id 133; type plane; coeffs (0.0 0.0 1.0 0.0 ); } + + planeSteelBottom { id 134; type plane; coeffs (0.0 0.0 1.0 400.638); } + planeCRLowerBottom { id 135; type plane; coeffs (0.0 0.0 1.0 402.508); } // same as 109 on withdrawal + planeCRUpperBottom { id 136; type plane; coeffs (0.0 0.0 1.0 504.108); } // out of core on withdrawal + + plane322p1861 {id 137; type plane; coeffs (0 0 1 322.18609);} + plane220p586 {id 138; type plane; coeffs (0 0 1 220.5861);} + plane218p716 {id 139; type plane; coeffs (0 0 1 218.71609);} + + } + + cells { + + // assembly wrappers and surrounding water at various heights + wrapper1 {type simpleCell; id 2001; surfaces (94 -95 129 -126); filltype mat; material SS304;} + wrapper2 {type simpleCell; id 2002; surfaces (94 -95 123 -122); filltype mat; material Zircaloy;} + wrapper3 {type simpleCell; id 2003; surfaces (94 -95 120 -119); filltype mat; material Zircaloy;} + wrapper4 {type simpleCell; id 2004; surfaces (94 -95 118 -117); filltype mat; material Zircaloy;} + wrapper5 {type simpleCell; id 2005; surfaces (94 -95 116 -115); filltype mat; material Zircaloy;} + wrapper6 {type simpleCell; id 2006; surfaces (94 -95 114 -113); filltype mat; material Zircaloy;} + wrapper7 {type simpleCell; id 2007; surfaces (94 -95 112 -111); filltype mat; material Zircaloy;} + wrapper8 {type simpleCell; id 2008; surfaces (94 -95 107 -106); filltype mat; material SS304;} + + assemWater0 {type simpleCell; id 2009; surfaces (94 -129); filltype mat; material Water;} + assemWater1 {type simpleCell; id 2010; surfaces (94 -95 126 -123); filltype mat; material Water;} + assemWater2 {type simpleCell; id 2011; surfaces (94 -95 122 -120); filltype mat; material Water;} + assemWater3 {type simpleCell; id 2012; surfaces (94 -95 119 -118); filltype mat; material Water;} + assemWater4 {type simpleCell; id 2013; surfaces (94 -95 117 -116); filltype mat; material Water;} + assemWater5 {type simpleCell; id 2014; surfaces (94 -95 115 -114); filltype mat; material Water;} + assemWater6 {type simpleCell; id 2015; surfaces (94 -95 113 -112); filltype mat; material Water;} + assemWater7 {type simpleCell; id 2016; surfaces (94 -95 111 -107); filltype mat; material Water;} + assemWater8 {type simpleCell; id 2017; surfaces (94 -95 106); filltype mat; material Water;} + assemWaterEx {type simpleCell; id 2018; surfaces (95); filltype mat; material Water;} + + // assemblies inside the wrappers + assem1424 {type simpleCell; id 2019; surfaces (-94); filltype uni; universe 1424;} + assem1416 {type simpleCell; id 2020; surfaces (-94); filltype uni; universe 1416;} + assem1431 {type simpleCell; id 2021; surfaces (-94); filltype uni; universe 1431;} + assem60316 {type simpleCell; id 2022; surfaces (-94); filltype uni; universe 60316;} + assem603112 {type simpleCell; id 2023; surfaces (-94); filltype uni; universe 603112;} + assem60313 {type simpleCell; id 2024; surfaces (-94); filltype uni; universe 60313;} + assem60319 {type simpleCell; id 2025; surfaces (-94); filltype uni; universe 60319;} + assem15315 {type simpleCell; id 2026; surfaces (-94); filltype uni; universe 15315;} + assem15317 {type simpleCell; id 2027; surfaces (-94); filltype uni; universe 15317;} + assem15311 {type simpleCell; id 2028; surfaces (-94); filltype uni; universe 15311;} + assem153111 {type simpleCell; id 2029; surfaces (-94); filltype uni; universe 153111;} + assem1631 {type simpleCell; id 2030; surfaces (-94); filltype uni; universe 1631;} + assem2031 {type simpleCell; id 2031; surfaces (-94); filltype uni; universe 2031;} + assem1224 {type simpleCell; id 2032; surfaces (-94); filltype uni; universe 1224;} + assem1624 {type simpleCell; id 2033; surfaces (-94); filltype uni; universe 1624;} + + // unrodded assemblies in wrappers + assem2424 {type simpleCell; id 2034; surfaces (-94); filltype uni; universe 2424;} + assem2416 {type simpleCell; id 2035; surfaces (-94); filltype uni; universe 2416;} + assem2431 {type simpleCell; id 2036; surfaces (-94); filltype uni; universe 2431;} + assem70316 {type simpleCell; id 2037; surfaces (-94); filltype uni; universe 70316;} + assem703112 {type simpleCell; id 2038; surfaces (-94); filltype uni; universe 703112;} + assem70313 {type simpleCell; id 2039; surfaces (-94); filltype uni; universe 70313;} + assem70319 {type simpleCell; id 2040; surfaces (-94); filltype uni; universe 70319;} + assem25315 {type simpleCell; id 2041; surfaces (-94); filltype uni; universe 25315;} + assem25317 {type simpleCell; id 2042; surfaces (-94); filltype uni; universe 25317;} + assem25311 {type simpleCell; id 2043; surfaces (-94); filltype uni; universe 25311;} + assem253111 {type simpleCell; id 2044; surfaces (-94); filltype uni; universe 253111;} + assem2631 {type simpleCell; id 2045; surfaces (-94); filltype uni; universe 2631;} + assem3031 {type simpleCell; id 2046; surfaces (-94); filltype uni; universe 3031;} + assem2224 {type simpleCell; id 2047; surfaces (-94); filltype uni; universe 2224;} + assem2624 {type simpleCell; id 2048; surfaces (-94); filltype uni; universe 2624;} + + // rodded assemblies in wrappers + assem1425 {type simpleCell; id 2049; surfaces (-94); filltype uni; universe 1425;} + assem1417 {type simpleCell; id 2050; surfaces (-94); filltype uni; universe 1417;} + + // pin grids - thick at the top and bottom, thin in fuelled region + thickGrid {type simpleCell; id 555; surfaces (90 ); filltype mat; material Inconel;} + thinGrid {type simpleCell; id 556; surfaces (92 ); filltype mat; material Zircaloy;} + + // Don't need to bound PV by 1 since it is the bounding surface of the geometry. + pressureVessel { type simpleCell; id 7; surfaces (2); filltype mat; material CarbonSteel;} + RPVLiner { type simpleCell; id 8; surfaces (-2 3); filltype mat; material SS304;} + outerWater1 {type simpleCell; id 9; surfaces (-3 4 ); filltype mat; material Water;} + + // Neutron shields + NS1 { type simpleCell; id 10; surfaces (-4 5 -8 9); filltype mat; material SS304;} + NS2 { type simpleCell; id 11; surfaces (-4 5 8 -9); filltype mat; material SS304;} + NS3 { type simpleCell; id 12; surfaces (-4 5 -10 11); filltype mat; material SS304;} + NS4 { type simpleCell; id 13; surfaces (-4 5 10 -11); filltype mat; material SS304;} + + // Water in the arc between neutron shields + outerWaterSeg1 {type simpleCell; id 14; surfaces (-4 5 ); filltype mat; material Water;} + outerWater2 {type simpleCell; id 15; surfaces (-5 6 ); filltype mat; material Water;} + + // Outer core + coreBarrel { type simpleCell; id 16; surfaces (-6 7); filltype mat; material SS304;} + core {type simpleCell; id 17; surfaces (-5); filltype uni; universe 9999;} + + + // Gridded pins + + // THICK GRID + // 2.4% in grid + grid24Thick {type simpleCell; id 253; surfaces (-90); filltype uni; universe 24000;} + // guide tube in grid + gridGTThick {type simpleCell; id 254; surfaces (-90); filltype uni; universe 12000;} + // 3.1% in grid + grid31Thick {type simpleCell; id 255; surfaces (-90); filltype uni; universe 31000;} + // 1.6 % in grid + grid16Thick {type simpleCell; id 256; surfaces (-90); filltype uni; universe 16000;} + // instrumentation tube in grid + gridITThick {type simpleCell; id 257; surfaces (-90); filltype uni; universe 14000;} + // empty GT at dashpot in grid + gridGTDPThick {type simpleCell; id 258; surfaces (-90); filltype uni; universe 1010;} + // pin upper fuel plenum in grid + gridFPPThick {type simpleCell; id 259; surfaces (-90); filltype uni; universe 1008;} + // stainless steel in guide tube in grid + gridSSGThick {type simpleCell; id 260; surfaces (-90); filltype uni; universe 1023;} + // stainless steel in dash pot in grid + gridSSDPThick {type simpleCell; id 261; surfaces (-90); filltype uni; universe 1024;} + // BP plenum in grid + gridBPPThick {type simpleCell; id 262; surfaces (-90); filltype uni; universe 1012;} + // Lower rodded GT in grid + gridLRGTThick {type simpleCell; id 263; surfaces (-90); filltype uni; universe 1014;} + // Upper rodded GT in grid + gridURGTThick {type simpleCell; id 463; surfaces (-90); filltype uni; universe 1013;} + + // THIN GRID + // 2.4% in grid + grid24Thin {type simpleCell; id 264; surfaces (-92); filltype uni; universe 24000;} + // guide tube in grid + gridGTThin {type simpleCell; id 265; surfaces (-92); filltype uni; universe 12000;} + // burnable poison in grid + gridBPThin {type simpleCell; id 266; surfaces (-92); filltype uni; universe 1000;} + // 3.1% in grid + grid31Thin {type simpleCell; id 267; surfaces (-92); filltype uni; universe 31000;} + // 1.6 % in grid + grid16Thin {type simpleCell; id 268; surfaces (-92); filltype uni; universe 16000;} + // instrumentation tube in grid + gridITThin {type simpleCell; id 269; surfaces (-92); filltype uni; universe 14000;} + // empty GT at dashpot in grid + gridGTDPThin {type simpleCell; id 270; surfaces (-92); filltype uni; universe 1010;} + // pin upper fuel plenum in grid + gridFPPThin {type simpleCell; id 271; surfaces (-92); filltype uni; universe 1008;} + // stainless steel in guide tube in grid + gridSSGTThin {type simpleCell; id 272; surfaces (-92); filltype uni; universe 1023;} + // stainless steel in dash pot in grid + gridSSDPThin {type simpleCell; id 273; surfaces (-92); filltype uni; universe 1024;} + // BP plenum in grid + gridBPPThin {type simpleCell; id 274; surfaces (-92); filltype uni; universe 1012;} + // Lower rodded GT in grid (not used when rods fully withdrawn) + gridLRGTThin {type simpleCell; id 275; surfaces (-92); filltype uni; universe 1014;} + // Upper rodded GT in grid (not used when rods fully withdrawn) + gridURGTThin {type simpleCell; id 475; surfaces (-92); filltype uni; universe 1013;} + + + // 3.1% enriched pins, axial layering + 31FP460 {type simpleCell; id 100; surfaces ( 101); filltype uni; universe 1001;} + 31FP431 {type simpleCell; id 101; surfaces (-101 102); filltype uni; universe 1003;} + 31FP423 {type simpleCell; id 102; surfaces (-102 104); filltype uni; universe 1001;} + 31FP419 {type simpleCell; id 103; surfaces (-104 105); filltype uni; universe 1006;} + 31FP417 {type simpleCell; id 104; surfaces (-105 106); filltype uni; universe 1008;} + 31FP415 {type simpleCell; id 105; surfaces (-106 107); filltype uni; universe 1017;} + 31FP411 {type simpleCell; id 106; surfaces (-107 109); filltype uni; universe 1008;} + 31FP402 {type simpleCell; id 107; surfaces (-109 111); filltype uni; universe 31000;} + 31FP364 {type simpleCell; id 108; surfaces (-111 112); filltype uni; universe 9231;} + 31FP359 {type simpleCell; id 109; surfaces (-112 113); filltype uni; universe 31000;} + 31FP312 {type simpleCell; id 110; surfaces (-113 114); filltype uni; universe 9231;} + 31FP306 {type simpleCell; id 111; surfaces (-114 115); filltype uni; universe 31000;} + 31FP260 {type simpleCell; id 112; surfaces (-115 116); filltype uni; universe 9231;} + 31FP254 {type simpleCell; id 113; surfaces (-116 117); filltype uni; universe 31000;} + 31FP208 {type simpleCell; id 114; surfaces (-117 118); filltype uni; universe 9231;} + 31FP202 {type simpleCell; id 115; surfaces (-118 119); filltype uni; universe 31000;} + 31FP155 {type simpleCell; id 116; surfaces (-119 120); filltype uni; universe 9231;} + 31FP150 {type simpleCell; id 117; surfaces (-120 122); filltype uni; universe 31000;} + 31FP103 {type simpleCell; id 118; surfaces (-122 123); filltype uni; universe 9231;} + 31FP98 {type simpleCell; id 119; surfaces (-123 126); filltype uni; universe 31000;} + 31FP4052 {type simpleCell; id 120; surfaces (-126 129); filltype uni; universe 1131;} + 31FP37 {type simpleCell; id 121; surfaces (-129 130); filltype uni; universe 31000;} + 31FP36 {type simpleCell; id 122; surfaces (-130 131); filltype uni; universe 1006;} + 31FP35 {type simpleCell; id 123; surfaces (-131 132); filltype uni; universe 1003;} + 31FP20 {type simpleCell; id 124; surfaces (-132 ); filltype uni; universe 1001;} + + + //2.4% enriched pins, axial layering + 24FP460 {type simpleCell; id 125; surfaces ( 101); filltype uni; universe 1001;} + 24FP431 {type simpleCell; id 126; surfaces (-101 102); filltype uni; universe 1003;} + 24FP423 {type simpleCell; id 127; surfaces (-102 104); filltype uni; universe 1001;} + 24FP419 {type simpleCell; id 128; surfaces (-104 105); filltype uni; universe 1006;} + 24FP417 {type simpleCell; id 129; surfaces (-105 106); filltype uni; universe 1008;} + 24FP415 {type simpleCell; id 130; surfaces (-106 107); filltype uni; universe 1017;} + 24FP411 {type simpleCell; id 131; surfaces (-107 109); filltype uni; universe 1008;} + 24FP402 {type simpleCell; id 132; surfaces (-109 111); filltype uni; universe 24000;} + 24FP364 {type simpleCell; id 133; surfaces (-111 112); filltype uni; universe 9224;} + 24FP359 {type simpleCell; id 134; surfaces (-112 113); filltype uni; universe 24000;} + 24FP312 {type simpleCell; id 135; surfaces (-113 114); filltype uni; universe 9224;} + 24FP306 {type simpleCell; id 136; surfaces (-114 115); filltype uni; universe 24000;} + 24FP260 {type simpleCell; id 137; surfaces (-115 116); filltype uni; universe 9224;} + 24FP254 {type simpleCell; id 138; surfaces (-116 117); filltype uni; universe 24000;} + 24FP208 {type simpleCell; id 139; surfaces (-117 118); filltype uni; universe 9224;} + 24FP202 {type simpleCell; id 140; surfaces (-118 119); filltype uni; universe 24000;} + 24FP155 {type simpleCell; id 141; surfaces (-119 120); filltype uni; universe 9224;} + 24FP150 {type simpleCell; id 142; surfaces (-120 122); filltype uni; universe 24000;} + 24FP103 {type simpleCell; id 143; surfaces (-122 123); filltype uni; universe 9224;} + 24FP98 {type simpleCell; id 144; surfaces (-123 126); filltype uni; universe 24000;} + 24FP4052 {type simpleCell; id 145; surfaces (-126 129); filltype uni; universe 1124;} + 24FP37 {type simpleCell; id 146; surfaces (-129 130); filltype uni; universe 24000;} + 24FP36 {type simpleCell; id 147; surfaces (-130 131); filltype uni; universe 1006;} + 24FP35 {type simpleCell; id 148; surfaces (-131 132); filltype uni; universe 1003;} + 24FP20 {type simpleCell; id 149; surfaces (-132); filltype uni; universe 1001;} + + //1.6% enriched pins, axial layering + 16FP460 {type simpleCell; id 150; surfaces ( 101); filltype uni; universe 1001;} + 16FP431 {type simpleCell; id 151; surfaces (-101 102); filltype uni; universe 1003;} + 16FP423 {type simpleCell; id 152; surfaces (-102 104); filltype uni; universe 1001;} + 16FP419 {type simpleCell; id 153; surfaces (-104 105); filltype uni; universe 1006;} + 16FP417 {type simpleCell; id 154; surfaces (-105 106); filltype uni; universe 1008;} + 16FP415 {type simpleCell; id 155; surfaces (-106 107); filltype uni; universe 1017;} + 16FP411 {type simpleCell; id 156; surfaces (-107 109); filltype uni; universe 1008;} + 16FP402 {type simpleCell; id 157; surfaces (-109 111); filltype uni; universe 16000;} + 16FP364 {type simpleCell; id 158; surfaces (-111 112); filltype uni; universe 9216;} + 16FP359 {type simpleCell; id 159; surfaces (-112 113); filltype uni; universe 16000;} + 16FP312 {type simpleCell; id 160; surfaces (-113 114); filltype uni; universe 9216;} + 16FP306 {type simpleCell; id 161; surfaces (-114 115); filltype uni; universe 16000;} + 16FP260 {type simpleCell; id 162; surfaces (-115 116); filltype uni; universe 9216;} + 16FP254 {type simpleCell; id 163; surfaces (-116 117); filltype uni; universe 16000;} + 16FP208 {type simpleCell; id 164; surfaces (-117 118); filltype uni; universe 9216;} + 16FP202 {type simpleCell; id 165; surfaces (-118 119); filltype uni; universe 16000;} + 16FP155 {type simpleCell; id 166; surfaces (-119 120); filltype uni; universe 9216;} + 16FP150 {type simpleCell; id 167; surfaces (-120 122); filltype uni; universe 16000;} + 16FP103 {type simpleCell; id 168; surfaces (-122 123); filltype uni; universe 9216;} + 16FP98 {type simpleCell; id 169; surfaces (-123 126); filltype uni; universe 16000;} + 16FP4052 {type simpleCell; id 170; surfaces (-126 129); filltype uni; universe 1116;} + 16FP37 {type simpleCell; id 171; surfaces (-129 130); filltype uni; universe 16000;} + 16FP36 {type simpleCell; id 172; surfaces (-130 131); filltype uni; universe 1006;} + 16FP35 {type simpleCell; id 173; surfaces (-131 132); filltype uni; universe 1003;} + 16FP20 {type simpleCell; id 174; surfaces (-132); filltype uni; universe 1001;} + + + //guide tube, with CR, axial layering + GC460 {type simpleCell; id 175; surfaces ( 101); filltype uni; universe 1014;} + GC431 {type simpleCell; id 176; surfaces (-101 106); filltype uni; universe 1014;} // Nozzle/support plate BW? Replaced just with rod + GC415 {type simpleCell; id 177; surfaces (-106 107); filltype uni; universe 1018;} // Rodded w/ grid + GC411 {type simpleCell; id 178; surfaces (-107 109); filltype uni; universe 1014;} + GC402 {type simpleCell; id 179; surfaces (-109 134); filltype uni; universe 1015;} + GC400 {type simpleCell; id 180; surfaces (-134 111); filltype uni; universe 12000;} + GC364 {type simpleCell; id 181; surfaces (-111 112); filltype uni; universe 9112;} + GC359 {type simpleCell; id 182; surfaces (-112 113); filltype uni; universe 12000;} + GC312 {type simpleCell; id 183; surfaces (-113 114); filltype uni; universe 9112;} + GC306 {type simpleCell; id 184; surfaces (-114 115); filltype uni; universe 12000;} + GC260 {type simpleCell; id 185; surfaces (-115 116); filltype uni; universe 9112;} + GC254 {type simpleCell; id 186; surfaces (-116 117); filltype uni; universe 12000;} + GC208 {type simpleCell; id 187; surfaces (-117 118); filltype uni; universe 9112;} + GC202 {type simpleCell; id 188; surfaces (-118 119); filltype uni; universe 12000;} + GC155 {type simpleCell; id 189; surfaces (-119 120); filltype uni; universe 9112;} + GC150 {type simpleCell; id 190; surfaces (-120 122); filltype uni; universe 12000;} + GC103 {type simpleCell; id 191; surfaces (-122 123); filltype uni; universe 9112;} + GC98 {type simpleCell; id 192; surfaces (-123 126); filltype uni; universe 1010;} + GC4052 {type simpleCell; id 193; surfaces (-126 127); filltype uni; universe 12000;} + GC39 {type simpleCell; id 194; surfaces (-127 129); filltype uni; universe 1019;} + GC37 {type simpleCell; id 195; surfaces (-129 131); filltype uni; universe 1010;} + GC35 {type simpleCell; id 196; surfaces (-131 132); filltype uni; universe 1005;} + GC20 {type simpleCell; id 197; surfaces (-132); filltype uni; universe 1001;} + + + // instrumentation tube, axial layering + IT460 {type simpleCell; id 198; surfaces ( 102); filltype uni; universe 1001;} + IT423 {type simpleCell; id 199; surfaces (-102 106); filltype uni; universe 14000;} + IT415 {type simpleCell; id 200; surfaces (-106 107); filltype uni; universe 1114;} + IT411 {type simpleCell; id 201; surfaces (-107 111); filltype uni; universe 14000;} + IT364 {type simpleCell; id 202; surfaces (-111 112); filltype uni; universe 9114;} + IT359 {type simpleCell; id 203; surfaces (-112 113); filltype uni; universe 14000;} + IT312 {type simpleCell; id 204; surfaces (-113 114); filltype uni; universe 9114;} + IT306 {type simpleCell; id 205; surfaces (-114 115); filltype uni; universe 14000;} + IT260 {type simpleCell; id 206; surfaces (-115 116); filltype uni; universe 9114;} + IT254 {type simpleCell; id 207; surfaces (-116 117); filltype uni; universe 14000;} + IT208 {type simpleCell; id 208; surfaces (-117 118); filltype uni; universe 9114;} + IT202 {type simpleCell; id 209; surfaces (-118 119); filltype uni; universe 14000;} + IT155 {type simpleCell; id 210; surfaces (-119 120); filltype uni; universe 9114;} + IT150 {type simpleCell; id 211; surfaces (-120 122); filltype uni; universe 14000;} + IT103 {type simpleCell; id 212; surfaces (-122 123); filltype uni; universe 9114;} + IT98 {type simpleCell; id 213; surfaces (-123 126); filltype uni; universe 14000;} + IT4052 {type simpleCell; id 214; surfaces (-126 129); filltype uni; universe 1114;} + IT37 {type simpleCell; id 215; surfaces (-129 131); filltype uni; universe 14000;} + IT35 {type simpleCell; id 216; surfaces (-131 132); filltype uni; universe 1005;} + IT20 {type simpleCell; id 217; surfaces (-132 ); filltype uni; universe 1011;} + + + // burnable absorber, axial layering + BA460 {type simpleCell; id 218; surfaces ( 101); filltype uni; universe 1001;} + BA431 {type simpleCell; id 219; surfaces (-101 102); filltype uni; universe 1002;} + BA423 {type simpleCell; id 220; surfaces (-102 103); filltype uni; universe 1023;} + BA421 {type simpleCell; id 230; surfaces (-103 106); filltype uni; universe 1012;} + BA415 {type simpleCell; id 231; surfaces (-106 107); filltype uni; universe 1027;} + BA411 {type simpleCell; id 232; surfaces (-107 110); filltype uni; universe 1012;} + BA401 {type simpleCell; id 233; surfaces (-110 111); filltype uni; universe 1000;} + BA364 {type simpleCell; id 234; surfaces (-111 112); filltype uni; universe 1110;} + BA359 {type simpleCell; id 235; surfaces (-112 113); filltype uni; universe 1000;} + BA312 {type simpleCell; id 236; surfaces (-113 114); filltype uni; universe 1110;} + BA306 {type simpleCell; id 237; surfaces (-114 115); filltype uni; universe 1000;} + BA260 {type simpleCell; id 238; surfaces (-115 116); filltype uni; universe 1110;} + BA254 {type simpleCell; id 239; surfaces (-116 117); filltype uni; universe 1000;} + BA208 {type simpleCell; id 240; surfaces (-117 118); filltype uni; universe 1110;} + BA202 {type simpleCell; id 241; surfaces (-118 119); filltype uni; universe 1000;} + BA155 {type simpleCell; id 242; surfaces (-119 120); filltype uni; universe 1110;} + BA150 {type simpleCell; id 243; surfaces (-120 122); filltype uni; universe 1000;} + BA103 {type simpleCell; id 244; surfaces (-122 123); filltype uni; universe 1110;} + BA98 {type simpleCell; id 245; surfaces (-123 125); filltype uni; universe 1000;} + BA4055 {type simpleCell; id 246; surfaces (-125 126); filltype uni; universe 1023;} + BA4052 {type simpleCell; id 247; surfaces (-126 127); filltype uni; universe 1021;} + BA39 {type simpleCell; id 248; surfaces (-127 128); filltype uni; universe 1025;} + BA38 {type simpleCell; id 249; surfaces (-128 129); filltype uni; universe 1019;} + BA37 {type simpleCell; id 250; surfaces (-129 131); filltype uni; universe 1010;} + BA35 {type simpleCell; id 251; surfaces (-131 132); filltype uni; universe 1005;} + BA20 {type simpleCell; id 252; surfaces (-132 ); filltype uni; universe 1001;} + + //guide tube, no CR, axial layering + GT460 {type simpleCell; id 353; surfaces ( 101); filltype uni; universe 1001;} + GT431 {type simpleCell; id 354; surfaces (-101 102); filltype uni; universe 1005;} + GT423 {type simpleCell; id 355; surfaces (-102 106); filltype uni; universe 12000;} + GT415 {type simpleCell; id 356; surfaces (-106 107); filltype uni; universe 1112;} + GT411 {type simpleCell; id 357; surfaces (-107 111); filltype uni; universe 12000;} + GT364 {type simpleCell; id 358; surfaces (-111 112); filltype uni; universe 9112;} + GT359 {type simpleCell; id 359; surfaces (-112 113); filltype uni; universe 12000;} + GT312 {type simpleCell; id 360; surfaces (-113 114); filltype uni; universe 9112;} + GT306 {type simpleCell; id 361; surfaces (-114 115); filltype uni; universe 12000;} + GT260 {type simpleCell; id 362; surfaces (-115 116); filltype uni; universe 9112;} + GT254 {type simpleCell; id 363; surfaces (-116 117); filltype uni; universe 12000;} + GT208 {type simpleCell; id 364; surfaces (-117 118); filltype uni; universe 9112;} + GT202 {type simpleCell; id 365; surfaces (-118 119); filltype uni; universe 12000;} + GT155 {type simpleCell; id 366; surfaces (-119 120); filltype uni; universe 9112;} + GT150 {type simpleCell; id 367; surfaces (-120 122); filltype uni; universe 12000;} + GT103 {type simpleCell; id 368; surfaces (-122 123); filltype uni; universe 9112;} + GT98 {type simpleCell; id 369; surfaces (-123 126); filltype uni; universe 1010;} + GT4052 {type simpleCell; id 370; surfaces (-126 127); filltype uni; universe 12000;} + GT39 {type simpleCell; id 371; surfaces (-127 129); filltype uni; universe 1019;} + GT37 {type simpleCell; id 372; surfaces (-129 131); filltype uni; universe 1010;} + GT35 {type simpleCell; id 373; surfaces (-131 132); filltype uni; universe 1005;} + GT20 {type simpleCell; id 374; surfaces (-132); filltype uni; universe 1001;} + + //guide tube, partially inserted CR, axial layering + // Note: universe is basically a combo of fully and partially inserted rods + GP460 {type simpleCell; id 375; surfaces ( 101); filltype uni; universe 1013;} + GP431 {type simpleCell; id 376; surfaces (-101 102); filltype uni; universe 1013;} + GP423 {type simpleCell; id 377; surfaces (-102 106); filltype uni; universe 1013;} + GP415 {type simpleCell; id 378; surfaces (-106 107); filltype uni; universe 1133;} + GP411 {type simpleCell; id 379; surfaces (-107 111); filltype uni; universe 1013;} + GP364 {type simpleCell; id 380; surfaces (-111 112); filltype uni; universe 9233;} + GP359 {type simpleCell; id 381; surfaces (-112 137); filltype uni; universe 1013;} + GP322 {type simpleCell; id 382; surfaces (-137 113); filltype uni; universe 1014;} + GP312 {type simpleCell; id 383; surfaces (-113 114); filltype uni; universe 9232;} + GP306 {type simpleCell; id 384; surfaces (-114 115); filltype uni; universe 1014;} + GP260 {type simpleCell; id 385; surfaces (-115 116); filltype uni; universe 9232;} + GP254 {type simpleCell; id 386; surfaces (-116 138); filltype uni; universe 1014;} + GP220 {type simpleCell; id 387; surfaces (-138 139); filltype uni; universe 1023;} + GP219 {type simpleCell; id 388; surfaces (-139 117); filltype uni; universe 12000;} + GP208 {type simpleCell; id 389; surfaces (-117 118); filltype uni; universe 9112;} + GP202 {type simpleCell; id 390; surfaces (-118 119); filltype uni; universe 12000;} + GP155 {type simpleCell; id 391; surfaces (-119 120); filltype uni; universe 9112;} + GP150 {type simpleCell; id 392; surfaces (-120 122); filltype uni; universe 12000;} + GP103 {type simpleCell; id 393; surfaces (-122 123); filltype uni; universe 9112;} + GP98 {type simpleCell; id 394; surfaces (-123 126); filltype uni; universe 1010;} + GP4052 {type simpleCell; id 395; surfaces (-126 127); filltype uni; universe 12000;} + GP39 {type simpleCell; id 396; surfaces (-127 129); filltype uni; universe 1019;} + GP37 {type simpleCell; id 397; surfaces (-129 131); filltype uni; universe 1010;} + GP35 {type simpleCell; id 398; surfaces (-131 132); filltype uni; universe 1005;} + GP20 {type simpleCell; id 399; surfaces (-132); filltype uni; universe 1001;} + + // control rod, axial layering + // Used (probably with some modification) only when fully inserted + //CR460 {type simpleCell; id 448; surfaces (-120 121); filltype uni; universe 1002;} + //CR415 {type simpleCell; id 449; surfaces (-126 403); filltype uni; universe 1013;} + //CR403 {type simpleCell; id 450; surfaces (-403 402); filltype uni; universe 1015;} + //CR402 {type simpleCell; id 451; surfaces (-402 1430); filltype uni; universe 1013;} + //CR143 {type simpleCell; id 452; surfaces (-1430 41); filltype uni; universe 1014;} + //CR41 {type simpleCell; id 453; surfaces (-41 143); filltype uni; universe 1002;} + //CR39 {type simpleCell; id 454; surfaces (-143 147); filltype uni; universe 1001;} + //CR35 {type simpleCell; id 455; surfaces (-147 148); filltype uni; universe 1005;} + //CR20 {type simpleCell; id 456; surfaces (-148 149); filltype uni; universe 1001;} + + + + outsideLeftBaffle { type simpleCell; id 52; surfaces (-50); filltype mat; material Water;} + leftBaffle { type simpleCell; id 53; surfaces (50 -51); filltype mat; material SS304;} + insideLeftBaffle { type simpleCell; id 54; surfaces (51); filltype mat; material Water;} + + outsideRightBaffle { type simpleCell; id 55; surfaces (-52); filltype mat; material Water;} + RightBaffle { type simpleCell; id 56; surfaces (52 -53); filltype mat; material SS304;} + insideRightBaffle { type simpleCell; id 57; surfaces (53); filltype mat; material Water;} + + outsideTopBaffle { type simpleCell; id 58; surfaces (-54); filltype mat; material Water;} + TopBaffle { type simpleCell; id 59; surfaces (54 -55); filltype mat; material SS304;} + insideTopBaffle { type simpleCell; id 60; surfaces (55); filltype mat; material Water;} + + outsideBottomBaffle { type simpleCell; id 61; surfaces (-56); filltype mat; material Water;} + BottomBaffle { type simpleCell; id 62; surfaces (56 -57); filltype mat; material SS304;} + insideBottomBaffle { type simpleCell; id 63; surfaces (57); filltype mat; material Water;} + + topLeftCornerBaffle1 { type simpleCell; id 64; surfaces (52 -53 -57); filltype mat; material SS304;} + topLeftCornerBaffle2 { type simpleCell; id 65; surfaces (56 -57 -52); filltype mat; material SS304;} + topLeftCornerGap1 { type simpleCell; id 66; surfaces (57); filltype mat; material Water;} + topLeftCornerGap2 { type simpleCell; id 67; surfaces (53); filltype mat; material Water;} + topLeftMajorGap { type simpleCell; id 68; surfaces (-56 -52); filltype mat; material Water;} + + topRightCornerBaffle1 { type simpleCell; id 69; surfaces (-57 50 -51); filltype mat; material SS304;} + topRightCornerBaffle2 { type simpleCell; id 70; surfaces (-50 56 -57); filltype mat; material SS304;} + topRightCornerGap1 { type simpleCell; id 71; surfaces (57); filltype mat; material Water;} + topRightCornerGap2 { type simpleCell; id 72; surfaces (51); filltype mat; material Water;} + topRightMajorGap { type simpleCell; id 73; surfaces (-56 -50); filltype mat; material Water;} + + bottomLeftCornerBaffle1 { type simpleCell; id 74; surfaces (-55 52 -53); filltype mat; material SS304;} + bottomLeftCornerBaffle2 { type simpleCell; id 75; surfaces (-55 54 -52); filltype mat; material SS304;} + bottomLeftCornerGap1 { type simpleCell; id 76; surfaces (55); filltype mat; material Water;} + bottomLeftCornerGap2 { type simpleCell; id 77; surfaces (53); filltype mat; material Water;} + bottomLeftMajorGap { type simpleCell; id 78; surfaces (-54 -52); filltype mat; material Water;} + + bottomRightCornerBaffle1 { type simpleCell; id 79; surfaces (-51 50 -55); filltype mat; material SS304;} + bottomRightCornerBaffle2 { type simpleCell; id 80; surfaces (-55 54 -50); filltype mat; material SS304;} + bottomRightCornerGap1 { type simpleCell; id 81; surfaces (51); filltype mat; material Water;} + bottomRightCornerGap2 { type simpleCell; id 82; surfaces (55); filltype mat; material Water;} + bottomRightMajorGap { type simpleCell; id 83; surfaces (-50 -54); filltype mat; material Water;} + + + TLSG1 { type simpleCell; id 84; surfaces (-56 -52); filltype mat; material Water;} + TLSG2 { type simpleCell; id 85; surfaces (-56 52); filltype mat; material Water;} + TLSG3 { type simpleCell; id 86; surfaces (56 -52); filltype mat; material Water;} + topLeftSquare { type simpleCell; id 87; surfaces (56 52); filltype mat; material SS304;} + + TRSG1 { type simpleCell; id 88; surfaces (-56 50); filltype mat; material Water;} + TRSG2 { type simpleCell; id 89; surfaces (-56 -50); filltype mat; material Water;} + TRSG3 { type simpleCell; id 90; surfaces (56 -50); filltype mat; material Water;} + topRightSquare { type simpleCell; id 91; surfaces (56 50); filltype mat; material SS304;} + + BLSG1 { type simpleCell; id 92; surfaces (54 -52); filltype mat; material Water;} + BLSG2 { type simpleCell; id 93; surfaces (-54 52); filltype mat; material Water;} + BLSG3 { type simpleCell; id 94; surfaces (-54 -52); filltype mat; material Water;} + bottomLeftSquare { type simpleCell; id 95; surfaces (54 52); filltype mat; material SS304;} + + BRSG1 { type simpleCell; id 96; surfaces (-54 50); filltype mat; material Water;} + BRSG2 { type simpleCell; id 97; surfaces (54 -50); filltype mat; material Water;} + BRSG3 { type simpleCell; id 98; surfaces (-54 -50); filltype mat; material Water;} + bottomRightSquare { type simpleCell; id 99; surfaces (54 50); filltype mat; material SS304;} + } + + universes { + root { id 1; type rootUniverse; border 1; fill u<8888>; } + + // Pin universes + + //Burnable poison + pinBPaboveDP { id 1000; type pinUniverse; radii (0.21400 0.23051 0.24130 0.42672 0.43688 0.48387 0.56134 0.60198 0.0); + fills (Air SS304 Helium BorosilicateGlass Helium SS304 Water Zircaloy Water);} + pinBPPlenumGeometry { id 1012; type pinUniverse; radii ( 0.21400 0.23051 0.43688 0.48387 0.50419 0.54610 0.0); + fills (Air SS304 Helium SS304 Water Zircaloy Water);} + + //guide tubes + pinGTaboveDP { id 12000; type pinUniverse; radii (0.56134 0.60198 0.0 ); fills (Water Zircaloy Water);} + pinGTatDP { id 1010; type pinUniverse; radii (0.50419 0.54610 0.0); fills (Water Zircaloy Water);} + + //INST Tube + pinIT { id 14000; type pinUniverse; radii (0.43688 0.48387 0.56134 0.60198 0.0 ); + fills (Air Zircaloy Water Zircaloy Water);} + pinBareInstrumentThimble { id 1011; type pinUniverse; radii (0.43688 0.48387 0.0); fills (Air Zircaloy Water);} + + // Fuel pins + pin16 { id 16000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + fills (UO2-16 Helium Zircaloy Water);} + pin24 { id 24000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + fills (UO2-24 Helium Zircaloy Water);} + pin31 { id 31000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + fills (UO2-31 Helium Zircaloy Water);} + // Higher enrichments not used + //pin32 { id 32000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + // fills (UO2-32 Helium Zircaloy Water);} + //pin34 { id 34000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + // fills (UO2-34 Helium Zircaloy Water);} + + pinWater { id 1001; type pinUniverse; radii ( 0.0); fills (Water);} + + + // Solid pins, assumed radius to be that of a fuel pin (0.45720) + pinNozzle_SupportSteel { id 1003; type pinUniverse; radii ( 0.45720 0.0); fills (SupportPlateSS Water);} + pinSupportPlateBW { id 1005; type pinUniverse; radii ( 0.45720 0.0); fills (SupportPlateBW Water);} + pinZircaloy { id 1006; type pinUniverse; radii ( 0.45720 0.0); fills (Zircaloy Water);} + + + SSinDashPot { id 1024; type pinUniverse; radii (0.50419 0.54610 0.0); fills (SS304 Zircaloy Water);} + SSinGuideTube { id 1023; type pinUniverse; radii ( 0.56134 0.60198 0.0); fills (SS304 Zircaloy Water);} + SSnoGuideTube { id 1002; type pinUniverse; radii ( 0.56134 0.0); fills (SS304 Water);} + + + pinUpperFuelPlenum { id 1008; type pinUniverse; radii ( 0.06459 0.40005 0.45720 0.0); + fills (Inconel Helium Zircaloy Water);} + + // Control rod pins + pinControlRodUpper { id 1013; type pinUniverse; radii ( 0.37338 0.38608 0.48387 0.56134 0.60198 0.0); + fills (B4C Helium SS304 Water Zircaloy Water);} + pinControlRodLower { id 1014; type pinUniverse; radii ( 0.38227 0.38608 0.48387 0.56134 0.60198 0.0); + fills (Ag-In-Cd Helium SS304 Water Zircaloy Water);} + pinControlRodSpacer { id 1015; type pinUniverse; radii ( 0.37845 0.38608 0.48387 0.56134 0.60198 0.0); + fills (SS304 Helium SS304 Water Zircaloy Water);} + pinControlRodPlenum { id 1016; type pinUniverse; radii ( 0.06459 0.38608 0.48387 0.56134 0.60198 0.0); + fills (Inconel Helium SS304 Water Zircaloy Water);} + + // pins that have grids + fuelRodPlenumWithGridThick { + id 1017; + type cellUniverse; + cells ( 259 555);} + + GTRodThick { + id 1018; + type cellUniverse; + cells (263 555);} + + dashPotGuideTubeGridThick { + id 1019; + type cellUniverse; + cells ( 258 555);} + + dashPotGuideTubeGridThin { + id 1020; + type cellUniverse; + cells ( 270 556);} + + SSinGuideTubeThick { + id 1021; + type cellUniverse; + cells ( 260 555);} + + SSinGuideTubeThin { + id 1022; + type cellUniverse; + cells ( 272 556);} + + SSinDashPotThick { + id 1025; + type cellUniverse; + cells ( 261 555);} + + SSinDashPotThin { + id 1026; + type cellUniverse; + cells ( 273 556);} + + BPPlenumThick { + id 1027; + type cellUniverse; + cells ( 262 555);} + + BPPlenumThin { + id 1028; + type cellUniverse; + cells ( 274 556);} + + BPaboveDPThin { + id 1110; + type cellUniverse; + cells (266 556);} + + GTThick { + id 1112; + type cellUniverse; + cells (254 555);} + + ITThick { + id 1114; + type cellUniverse; + cells (257 555);} + + pin16Thick { + id 1116; + type cellUniverse; + cells (256 555);} + + pin24Thick { + id 1124; + type cellUniverse; + cells (253 555);} + + pin31Thick { + id 1131; + type cellUniverse; + cells (255 555);} + + LowerRodGTThick { + id 1132; + type cellUniverse; + cells (263 555);} + + UpperRodGTThick { + id 1133; + type cellUniverse; + cells (463 555);} + + BPThin { // Is this necessary given 1110, BPaboveDPThin??? + id 9110; + type cellUniverse; + cells (266 556);} + + GTThin { + id 9112; + type cellUniverse; + cells (265 556);} + + ITThin { + id 9114; + type cellUniverse; + cells (269 556);} + + pin16Thin { + id 9216; + type cellUniverse; + cells (268 556);} + + pin24Thin { + id 9224; + type cellUniverse; + cells (264 556);} + + pin31Thin { + id 9231; + type cellUniverse; + cells (267 556);} + + LowerRodGTThin { + id 9232; + type cellUniverse; + cells (275 556);} + + UpperRodGTThin { + id 9233; + type cellUniverse; + cells (475 556);} + + // Axial stacks of universes to make up full pins + + // 3.1 % + fuelPin31 { + id 31; + type cellUniverse; + cells ( 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124);} + + // 2.4 % + fuelPin24 { + id 24; + type cellUniverse; + cells ( 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149);} + + //1.6 % + fuelPin16 { + id 16; + type cellUniverse; + cells ( 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174);} + + //burnable absorber + BP { + id 10; + type cellUniverse; + cells (218 219 220 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252);} + + // guide tube, with CR + GuideTubeRodded { + id 12; + type cellUniverse; + cells (175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197);} + + //control rod, fully retracted + GuideTubeEmpty { + id 13; + type cellUniverse; + cells (353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374);} + + //instr. tube + instrumentTube { + id 14; + type cellUniverse; + cells (198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217);} + + + // control rod, partially inserted + GuideTubePartial { + id 15; + type cellUniverse; + cells (375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399); + + } + + + + // Lattices w/o grid + // Names represent AE + A0E24 { + id 1424; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 12 24 24 12 24 24 12 24 24 24 24 24 + 24 24 24 12 24 24 24 24 24 24 24 24 24 12 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 12 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 14 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 12 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 12 24 24 24 24 24 24 24 24 24 12 24 24 24 + 24 24 24 24 24 12 24 24 12 24 24 12 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + // assembly with sleeves at different heights + A0E24Sleeve { + id 14240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2019 + );} + + + A0E16 { + id 1416; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 12 16 16 12 16 16 12 16 16 16 16 16 + 16 16 16 12 16 16 16 16 16 16 16 16 16 12 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 12 16 16 12 16 16 12 16 16 12 16 16 12 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 12 16 16 12 16 16 14 16 16 12 16 16 12 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 12 16 16 12 16 16 12 16 16 12 16 16 12 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 12 16 16 16 16 16 16 16 16 16 12 16 16 16 + 16 16 16 16 16 12 16 16 12 16 16 12 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } + + A0E16Sleeve { + id 14160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2020 + ); + } + + A0E31 { + id 1431; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A0E31Sleeve { + id 14310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2021 + ); + } + + + A6BE31B { + id 60316; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + + A6BE31BSleeve { + id 603160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2022 + ); + } + + A6BE31T { + id 603112; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31TSleeve { + id 6031120; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2023 + ); + } + + A6BE31R { + id 60313; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31RSleeve { + id 603130; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2024 + ); + } + + A6BE31L { + id 60319; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31LSleeve { + id 603190; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2025 + ); + } + + A15BE31BR { + id 15315; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BRSleeve { + id 153150; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2026 + ); + } + + A15BE31BL { + id 15317; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BLSleeve { + id 153170; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2027 + ); + } + + A15BE31TR { + id 15311; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TRSleeve { + id 153110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2028 + ); + } + + A15BE31TL { + id 153111; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TLSleeve { + id 1531110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2029 + ); + } + + A16BE31 { + id 1631; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 14 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A16BE31Sleeve { + id 16310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2030 + ); + } + + A20BE31 { + id 2031; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 12 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 14 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 12 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A20BE31Sleeve { + id 20310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2031 + ); + } + + A12BE24 { + id 1224; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 12 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 14 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 12 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A12BE24Sleeve { + id 12240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2032 + ); + } + + A16BE24 { + id 1624; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 14 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A16BE24Sleeve { + id 16240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2033 + ); + } + + // Unrodded assemblies + A0E24U { + id 2424; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 13 24 24 13 24 24 13 24 24 24 24 24 + 24 24 24 13 24 24 24 24 24 24 24 24 24 13 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 13 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 14 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 13 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 13 24 24 24 24 24 24 24 24 24 13 24 24 24 + 24 24 24 24 24 13 24 24 13 24 24 13 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A0E24USleeve { + id 24240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2034 + );} + + A0E16U { + id 2416; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 13 16 16 13 16 16 13 16 16 16 16 16 + 16 16 16 13 16 16 16 16 16 16 16 16 16 13 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 13 16 16 13 16 16 13 16 16 13 16 16 13 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 13 16 16 13 16 16 14 16 16 13 16 16 13 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 13 16 16 13 16 16 13 16 16 13 16 16 13 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 13 16 16 16 16 16 16 16 16 16 13 16 16 16 + 16 16 16 16 16 13 16 16 13 16 16 13 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } + + // sleeved + A0E16USleeve { + id 24160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2035 + ); + } + + A0E31U { + id 2431; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A0E31USleeve { + id 24310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2036 + ); + } + + + A6BE31BU { + id 70316; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + + A6BE31BUSleeve { + id 703160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2037 + ); + } + + A6BE31TU { + id 703112; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31TUSleeve { + id 7031120; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2038 + ); + } + + A6BE31RU { + id 70313; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31RUSleeve { + id 703130; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2039 + ); + } + + A6BE31LU { + id 70319; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31LUSleeve { + id 703190; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2040 + ); + } + + A15BE31BRU { + id 25315; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BRUSleeve { + id 253150; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2041 + ); + } + + A15BE31BLU { + id 25317; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BLUSleeve { + id 253170; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2042 + ); + } + + A15BE31TRU { + id 25311; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TRUSleeve { + id 253110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2043 + ); + } + + A15BE31TLU { + id 253111; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TLUSleeve { + id 2531110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2044 + ); + } + + A16BE31U { + id 2631; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 14 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A16BE31USleeve { + id 26310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2045 + ); + } + + A20BE31U { + id 3031; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 13 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 14 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 13 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A20BE31USleeve { + id 30310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2046 + ); + } + + A12BE24U { + id 2224; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 13 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 14 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 13 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A12BE24USleeve { + id 22240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2047 + ); + } + + A16BE24U { + id 2624; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 14 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A16BE24USleeve { + id 26240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2048 + ); + } + + A0E24DBank { + id 1425; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 15 24 24 15 24 24 15 24 24 24 24 24 + 24 24 24 15 24 24 24 24 24 24 24 24 24 15 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 15 24 24 15 24 24 15 24 24 15 24 24 15 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 15 24 24 15 24 24 14 24 24 15 24 24 15 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 15 24 24 15 24 24 15 24 24 15 24 24 15 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 15 24 24 24 24 24 24 24 24 24 15 24 24 24 + 24 24 24 24 24 15 24 24 15 24 24 15 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + // assembly with sleeves at different heights + A0E24SleeveDBank { + id 14250; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2049 + );} + + A0E16DBank { + id 1417; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 15 16 16 15 16 16 15 16 16 16 16 16 + 16 16 16 15 16 16 16 16 16 16 16 16 16 15 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 15 16 16 15 16 16 15 16 16 15 16 16 15 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 15 16 16 15 16 16 14 16 16 15 16 16 15 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 15 16 16 15 16 16 15 16 16 15 16 16 15 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 15 16 16 16 16 16 16 16 16 16 15 16 16 16 + 16 16 16 16 16 15 16 16 15 16 16 15 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } + + A0E16SleeveDBank { + id 14170; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2050 + ); + } + + + leftBaffleUni { + id 5222; + type cellUniverse; + cells (52 53 54);} + + + rightBaffleUni { + id 5223; + type cellUniverse; + cells (55 56 57);} + + topBaffleUni { + id 5224; + type cellUniverse; + cells (58 59 60);} + + bottomBaffleUni { + id 5225; + type cellUniverse; + cells (61 62 63);} + + + topLeft { + id 5226; + type cellUniverse; + cells (64 65 66 67 68);} + + topRight { + id 5227; + type cellUniverse; + cells ( 69 70 71 72 73);} + + BottomLeft { + id 5228; + type cellUniverse; + cells ( 74 75 76 77 78);} + + BottomRight { + id 5229; + type cellUniverse; + cells ( 79 80 81 82 83);} + + + SQTL { + id 1500; + type cellUniverse; + cells (84 85 86 87);} + + + SQTR { + id 1600; + type cellUniverse; + cells (88 89 90 91);} + + SQBL { + id 1700; + type cellUniverse; + cells (92 93 94 95);} + + SQBR { + id 1800; + type cellUniverse; + cells (96 97 98 99);} + + + latCore { + id 9999; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (21.50364 21.50364 0.0); + shape (17 17 0); + padMat Water; + map ( + 1001 1001 1001 1001 1800 5224 5224 5224 5224 5224 5224 5224 1700 1001 1001 1001 1001 + 1001 1001 1800 5224 5229 24310 7031120 24310 7031120 24310 7031120 24310 5228 5224 1700 1001 1001 + 1001 1800 5229 24310 14310 26310 14160 30310 14160 30310 14160 26310 14310 24310 5228 1700 1001 + 1001 5222 24310 2531110 26240 14160 26240 14160 26240 14160 26240 14160 26240 25311 24310 5223 1001 + 1800 5229 14310 26240 14250 26240 24160 22240 14160 22240 24160 26240 14250 26240 14310 5228 1700 + 5222 24310 26310 14160 26240 24160 22240 24160 22240 24160 22240 24160 26240 14160 26310 24310 5223 + 5222 703190 14160 26240 24160 22240 14160 22240 14160 22240 14160 22240 24160 26240 14160 703130 5223 + 5222 24310 30310 14160 22240 24160 22240 24160 26240 24160 22240 24160 22240 14160 30310 24310 5223 + 5222 703190 14160 26240 14160 22240 14160 26240 14170 26240 14160 22240 14160 26240 14160 703130 5223 + 5222 24310 30310 14160 22240 24160 22240 24160 26240 24160 22240 24160 22240 14160 30310 24310 5223 + 5222 703190 14160 26240 24160 22240 14160 22240 14160 22240 14160 22240 24160 26240 14160 703130 5223 + 5222 24310 26310 14160 26240 24160 22240 24160 22240 24160 22240 24160 26240 14160 26310 24310 5223 + 1600 5227 14310 26240 14250 26240 24160 22240 14160 22240 24160 26240 14250 26240 14310 5226 1500 + 1001 5222 24310 253170 26240 14160 26240 14160 26240 14160 26240 14160 26240 253150 24310 5223 1001 + 1001 1600 5227 24310 14310 26310 14160 30310 14160 30310 14160 26310 14310 24310 5226 1500 1001 + 1001 1001 1600 5225 5227 24310 703160 24310 703160 24310 703160 24310 5226 5225 1500 1001 1001 + 1001 1001 1001 1001 1600 5225 5225 5225 5225 5225 5225 5225 1500 1001 1001 1001 1001 ); } + +! Note partial rodded assemblies end with a 1, i.e., 14170 and 14250 + + coreAndStructures { + id 8888; + type cellUniverse; + cells (7 8 9 10 11 12 13 14 15 16 17);} + + + + } +} + + +viz { + bmpZ { + type bmp; + output imgXY; + what material; + centre (-17.13 240.69 167.74); + width (50 50); + axis z; + res (1000 1000); + } + bmpYZ { + type bmp; + output imgYZ; + what material; + centre (0.0 0.0 232.0); + width (100.0 200.0); + axis x; + res (1000 2000); + } +} + + +nuclearData { + handles { + ce {type aceNeutronDatabase; aceLibrary $SCONE_ACE; ures 0; } + } + + materials { + + // Note that commented nuclide densities are included in the specification + // but are not available in the JEFF-3.11 data library + + Air { + temp 566; + composition { + 18036.06 7.8730E-09; + 18038.06 1.4844E-09; + 18040.06 2.3506E-06; + 6012.06 6.7539E-08; + //6013.06 7.5658E-10; + 7014.06 1.9680E-04; + 7015.06 7.2354E-07; + 8016.06 5.2866E-05; + 8017.06 2.0084E-08; + //8018.06 1.0601E-07; + } + } + + SS304 { + temp 566; + composition { + 24050.06 7.6778E-04; + 24052.06 1.4806E-02; + 24053.06 1.6789E-03; + 24054.06 4.1791E-04; + 26054.06 3.4620E-03; + 26056.06 5.4345E-02; + 26057.06 1.2551E-03; + 26058.06 1.6703E-04; + 25055.06 1.7604E-03; + 28058.06 5.6089E-03; + 28060.06 2.1605E-03; + 28061.06 9.3917E-05; + 28062.06 2.9945E-04; + 28064.06 7.6261E-05; + 14028.06 9.5281E-04; + 14029.06 4.8381E-05; + 14030.06 3.1893E-05; } + } + + Helium { + temp 566; + composition { + 2003.06 4.8089E-10; + 2004.06 2.4044E-04; } + } + + BorosilicateGlass { + temp 566; + composition { + 13027.06 1.7352E-03; + 5010.06 9.6506E-04; + 5011.06 3.9189E-03; + 8016.06 4.6514E-02; + 8017.06 1.7671E-05; + //8018.06 9.3268E-05; + 14028.06 1.6926E-02; + 14029.06 8.5944E-04; + 14030.06 5.6654E-04; } + } + + Water { + temp 566; + moder {1001.06 (lwj3.11 lwj3.09); } + composition { + 5010.06 7.9714E-06; + 5011.06 3.2247E-05; + 1001.06 4.9456E-02; + 1002.06 7.7035E-06; + 8016.06 2.4673E-02; + 8017.06 9.3734E-06; + //8018.06 4.9474E-05; + } + } + + Zircaloy { + temp 566; + composition { + 24050.06 3.2962E-06; + 24052.06 6.3564E-05; + 24053.06 7.2076E-06; + 24054.06 1.7941E-06; + 26054.06 8.6698E-06; + 26056.06 1.3610E-04; + 26057.06 3.1431E-06; + 26058.06 4.1829E-07; + 8016.06 3.0744E-04; + 8017.06 1.1680E-07; + //8018.03 6.1648E-07; + 50112.06 4.6735E-06; + 50114.06 3.1799E-06; + 50115.06 1.6381E-06; + 50116.06 7.0055E-05; + 50117.06 3.7003E-05; + 50118.06 1.1669E-04; + 50119.06 4.1387E-05; + 50120.06 1.5697E-04; + 50122.06 2.2308E-05; + 50124.06 2.7897E-05; + 40090.06 2.1828E-02; + 40091.06 4.7601E-03; + 40092.06 7.2759E-03; + 40094.06 7.3734E-03; + 40096.06 1.1879E-03; } + } + + Inconel{ + temp 566; + composition { + 24050.06 7.8239E-04; + 24052.06 1.5088E-02; + 24053.06 1.7108E-03; + 24054.06 4.2586E-04; + 26054.06 1.4797E-03; + 26056.06 2.3229E-02; + 26057.06 5.3645E-04; + 26058.06 7.1392E-05; + 25055.06 7.8201E-04; + 28058.06 2.9320E-02; + 28060.06 1.1294E-02; + 28061.06 4.9094E-04; + 28062.06 1.5653E-03; + 28064.06 3.9864E-04; + 14028.06 5.6757E-04; + 14029.06 2.8820E-05; + 14030.06 1.8998E-05; } + } + + B4C{ + temp 566; + composition { + 5010.06 1.5206E-02; + 5011.06 6.1514E-02; + 6012.06 1.8972E-02; + //6013.06 2.1252E-04; + } + } + + Ag-In-Cd{ + temp 566; + composition { + 47107.06 2.3523E-02; + 47109.06 2.1854E-02; + 48106.06 3.3882E-05; + 48108.06 2.4166E-05; + 48110.06 3.3936E-04; + 48111.06 3.4821E-04; + 48112.06 6.5611E-04; + 48113.06 3.3275E-04; + 48114.06 7.8252E-04; + 48116.06 2.0443E-04; + 49113.06 3.4219E-04; + 49115.06 7.6511E-03; } + } + + UO2-16 { + temp 566; + tms 1; + composition { + 8016.03 4.5897E-02; + 8017.03 1.7436E-05; + //8018.03 9.2032E-05; + 92234.03 3.0131E-06; + 92235.03 3.7503E-04; + 92238.03 2.2625E-02;} + } + + UO2-24 { + temp 566; + tms 1; + composition { + 8016.03 4.5830E-02; + 8017.03 1.7411E-05; + //8018.03 9.1898E-05; + 92234.03 4.4842E-06; + 92235.03 5.5814E-04; + 92238.03 2.2407E-02;} + } + + UO2-31 { + temp 566; + tms 1; + composition { + 8016.03 4.5853E-02; + 8017.03 1.7420E-05; + //8018.03 9.1942E-05; + 92234.03 5.7987E-06; + 92235.03 7.2175E-04; + 92238.03 2.2253E-02;} + } + + UO2-32 { + temp 566; + tms 1; + composition { + 8016.03 4.6029E-02; + 8017.03 1.7487E-05; + //8018.03 9.2296E-05; + 92234.03 5.9959E-06; + 92235.03 7.4630E-04; + 92238.03 2.2317E-02; + } + } + + UO2-34 { + temp 566; + tms 1; + composition { + 8016.03 4.6110E-02; + 8017.03 1.7517E-05; + //8018.03 9.2459E-05; + 92234.03 6.4018E-06; + 92235.03 7.9681E-04; + 92238.03 2.2307E-02;} + } + + // vanadium51 was stated twice in carbonsteel below + // in the beavrs pdf - typo? + CarbonSteel { + temp 566; + composition { + 13027.06 4.3523E-05; + 5010.06 2.5833E-06; + 5011.06 1.0450E-05; + 6012.06 1.0442E-03; + //6013.06 1.1697E-05 ; + 20040.06 1.7043E-05; + 20042.06 1.1375E-07; + 20043.06 2.3734E-08; + 20044.06 3.6673E-07; + 20046.06 7.0322E-10; + 20048.06 3.2875E-08; + 24050.06 1.3738E-05; + 24052.06 2.6493E-04; + 24053.06 3.0041E-05; + 24054.06 7.4778E-06; + 29063.06 1.0223E-04; + 29065.06 4.5608E-05; + 26054.06 4.7437E-03; + 26056.06 7.4465E-02; + 26057.06 1.7197E-03; + 26058.06 2.2886E-04; + 25055.06 6.4126E-04; + 42100.06 2.9814E-05; + 42092.06 4.4822E-05; + 42094.06 2.8110E-05; + 42095.06 4.8567E-05; + 42096.06 5.1015E-05; + 42097.06 2.9319E-05; + 42098.06 7.4327E-05; + 41093.06 5.0559E-06; + 28058.06 4.0862E-04; + 28060.06 1.5740E-04; + 28061.06 6.8420E-06; + 28062.06 2.1815E-05; + 28064.06 5.5557E-06; + 15031.06 3.7913E-05; + 16032.06 3.4808E-05; + 16033.06 2.7420E-07; + 16034.06 1.5368E-06; + 16036.06 5.3398E-09; + 14028.06 6.1702E-04; + 14029.06 3.1330E-05; + 14030.06 2.0653E-05; + 22046.06 1.2144E-06; + 22047.06 1.0952E-06; + 22048.06 1.0851E-05; + 22049.06 7.9634E-07; + 22050.06 7.6249E-07; + //23050.06 1.1526E-07; + 23051.06 4.5989E-05; + } + } + + SupportPlateSS { + temp 566; + composition { + 24050.06 3.5223E-04; + 24052.06 6.7924E-03; + 24053.06 7.7020E-04; + 24054.06 1.9172E-04; + 26054.06 1.5882E-03; + 26056.06 2.4931E-02; + 26057.06 5.7578E-04; + 26058.06 7.6625E-05; + 25055.06 8.0762E-04; + 28058.06 2.5731E-03; + 28060.06 9.9117E-04; + 28061.06 4.3085E-05; + 28062.06 1.3738E-04; + 28064.06 3.4985E-05; + 14028.06 4.3711E-04; + 14029.06 2.2195E-05; + 14030.06 1.4631E-05;} + } + + SupportPlateBW { + temp 566; + moder {1001.06 (lwj3.11 lwj3.09); } + composition { + 5010.06 1.0559E-05; + 5011.06 4.2716E-05; + 1001.06 6.5512E-02; + 1002.06 1.0204E-05; + 8016.06 3.2683E-02; + 8017.06 1.2416E-05; + //8018.06 6.5535E-05; + } + } + + +} +} From 4533140b2d1433496eb0e8aed6627a4603d04474 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Mon, 21 Jul 2025 17:59:04 +0100 Subject: [PATCH 03/27] Added distance calculation to some tallyMaps --- .../TallyMaps/Maps1D/Tests/spaceMap_test.f90 | 21 ++++++++++ Tallies/TallyMaps/Maps1D/spaceMap_class.f90 | 41 +++++++++++++++++++ Tallies/TallyMaps/Tests/multiMap_test.f90 | 19 +++++++++ Tallies/TallyMaps/multiMap_class.f90 | 31 ++++++++++++-- Tallies/TallyMaps/tallyMap_inter.f90 | 31 ++++++++++++-- 5 files changed, 135 insertions(+), 8 deletions(-) diff --git a/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 b/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 index e48ca9284..89c0dcbf7 100644 --- a/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 +++ b/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 @@ -148,6 +148,27 @@ subroutine testUnstructuredGrid(this) @assertEqual(RES, idx) end subroutine testUnstructuredGrid + + !! + !! Test distance calculation + !! +@Test(testParameters={getParameters()}) + subroutine testDistance(this) + class(test_spaceMap), intent(inout) :: this + real(defReal),dimension(2),parameter :: POS = [0.5_defReal, -10.1_defReal] + real(defReal),dimension(2),parameter :: MU = [-0.01_defReal, 0.2_defReal] + real(defReal),dimension(2),parameter :: RES = [50.0_defReal, HALF] + real(defReal), dimension(2) :: d + type(particleState),dimension(2) :: states + real(defReal), parameter :: TOL = 1.0E-7 + + states % r(this % dir) = POS + states % dir(this % dir) = MU + d = this % map_unstruct % distance(states) + + @assertEqual(RES, d, TOL) + + end subroutine testDistance !! !! Test bin output diff --git a/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 b/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 index b053a4e96..0dc7ae8a9 100644 --- a/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 +++ b/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 @@ -62,6 +62,7 @@ module spaceMap_class procedure :: init procedure :: bins procedure :: map + procedure :: distance procedure :: getAxisName procedure :: print procedure :: kill @@ -219,6 +220,46 @@ elemental function map(self,state) result(idx) if (idx == valueOutsideArray) idx = 0 end function map + + !! + !! Compute particle's distance to boundary + !! + !! See tallyMap for specification + !! + elemental function distance(self, state) result(d) + class(spaceMap), intent(in) :: self + class(particleState), intent(in) :: state + real(defReal) :: d + integer(shortInt) :: idx + real(defReal) :: r, u, rMin, rMax, rNext + + d = INF + r = state % r(self % dir) + u = state % dir(self % dir) + idx = self % binBounds % search(r) + + ! Out of bounds: either above or below + if (idx == valueOutsideArray) then + rMin = self % binBounds % bin(1) + rMax = self % binBounds % bin(self % N + 1) + + if (r < rMin) then + if (u > ZERO) d = (rMin - r) / u + else + if (u < ZERO) d = (rMax - r) / u + end if + + ! In bounds: travelling left or right? + else + + if (u > ZERO) idx = idx + 1 + rNext = self % binBounds % bin(idx) + + d = (rNext - r) / u + + end if + + end function distance !! !! Return string that describes variable used to divide event space diff --git a/Tallies/TallyMaps/Tests/multiMap_test.f90 b/Tallies/TallyMaps/Tests/multiMap_test.f90 index 661e8607d..2c1c524cd 100644 --- a/Tallies/TallyMaps/Tests/multiMap_test.f90 +++ b/Tallies/TallyMaps/Tests/multiMap_test.f90 @@ -107,6 +107,25 @@ subroutine testMapping(this) end subroutine testMapping + !! + !! Test distance calculation + !! + subroutine testDistance(this) + class(test_multiMap), intent(inout) :: this + real(defReal),dimension(3),parameter :: POS = [1.3_defReal, 8.0_defReal, 0.1_defReal] + real(defReal),dimension(3),parameter :: MU = [HALF, -ONE, -TWO] + real(defReal),parameter :: RES = 1.4_defReal + real(defReal) :: d + type(particleState) :: state + real(defReal), parameter :: TOL = 1.0E-7 + + state % r = POS + state % dir = MU + d = this % map % distance(state) + + @assertEqual(RES, d, TOL) + + end subroutine testDistance diff --git a/Tallies/TallyMaps/multiMap_class.f90 b/Tallies/TallyMaps/multiMap_class.f90 index a29c220db..3a1eaf43a 100644 --- a/Tallies/TallyMaps/multiMap_class.f90 +++ b/Tallies/TallyMaps/multiMap_class.f90 @@ -1,10 +1,11 @@ module multiMap_class use numPrecision - use genericProcedures, only : fatalError - use dictionary_class, only : dictionary - use outputFile_class, only : outputFile - use particle_class, only : particleState + use universalVariables, only : INF + use genericProcedures, only : fatalError + use dictionary_class, only : dictionary + use outputFile_class, only : outputFile + use particle_class, only : particleState use tallyMap_inter, only : tallyMap use tallyMap1D_inter, only : tallyMap1D @@ -52,6 +53,7 @@ module multiMap_class procedure :: dimensions procedure :: getAxisName procedure :: map + procedure :: distance procedure :: print procedure :: kill end type multiMap @@ -171,6 +173,27 @@ elemental function map(self, state) result(idx) end do end function map + + !! + !! Compute particle's distance to boundary + !! + !! See tallyMap for specification + !! + elemental function distance(self, state) result(d) + class(multiMap), intent(in) :: self + class(particleState), intent(in) :: state + real(defReal) :: d + integer(shortInt) :: i + real(defReal) :: d0 + + d = INF + + do i = 1, size(self % maps) + d0 = self % maps(i) % slot % distance(state) + d = min(d, d0) + end do + + end function distance !! !! Add information about division axis to the output file diff --git a/Tallies/TallyMaps/tallyMap_inter.f90 b/Tallies/TallyMaps/tallyMap_inter.f90 index 849c5bb5e..62f1b0dc7 100644 --- a/Tallies/TallyMaps/tallyMap_inter.f90 +++ b/Tallies/TallyMaps/tallyMap_inter.f90 @@ -1,9 +1,10 @@ module tallyMap_inter use numPrecision - use particle_class, only : particleState - use dictionary_class, only : dictionary - use outputFile_class, only : outputFile + use universalVariables, only : INF + use particle_class, only : particleState + use dictionary_class, only : dictionary + use outputFile_class, only : outputFile implicit none private @@ -32,13 +33,14 @@ module tallyMap_inter procedure(getAxisName),deferred :: getAxisName procedure :: binArrayShape procedure(map),deferred :: map + procedure :: distance procedure(print),deferred :: print procedure :: kill end type tallyMap ! Procedures extendable in subclasses public :: kill - + public :: distance abstract interface @@ -178,6 +180,27 @@ elemental subroutine kill(self) end subroutine kill + !! + !! Returns distance to tally map bounds in space + !! + !! Args: + !! particleState + !! + !! Result: + !! distance to nearest spatial tally boundary + !! + !! NOTE: + !! For certain maps, this is nonsensical. These should not overwrite + !! this distance. + !! + elemental function distance(self, state) result(d) + class(tallyMap), intent(in) :: self + class(particleState), intent(in) :: state + real(defReal) :: d + + d = INF + + end function distance end module tallyMap_inter From 6de594362bf2f5761d8334b4e5a7d8af2869472c Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 25 Jul 2025 19:56:14 +0100 Subject: [PATCH 04/27] Added piecewise constant fields Field which have values that are piecewise constant. Endowed with a distance calculation. Added a simple version which allows a lattice to be specified. --- Geometry/Fields/CMakeLists.txt | 1 + .../Fields/PieceConstantFields/CMakeLists.txt | 6 + .../Tests/cartesianField_test.f90 | 89 ++++ .../cartesianField_class.f90 | 382 ++++++++++++++++++ .../pieceConstantField_inter.f90 | 166 ++++++++ 5 files changed, 644 insertions(+) create mode 100644 Geometry/Fields/PieceConstantFields/CMakeLists.txt create mode 100644 Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 create mode 100644 Geometry/Fields/PieceConstantFields/cartesianField_class.f90 create mode 100644 Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 diff --git a/Geometry/Fields/CMakeLists.txt b/Geometry/Fields/CMakeLists.txt index edb182848..16dc30d76 100644 --- a/Geometry/Fields/CMakeLists.txt +++ b/Geometry/Fields/CMakeLists.txt @@ -1,5 +1,6 @@ add_subdirectory(ScalarFields) add_subdirectory(VectorFields) +add_subdirectory(PieceConstantFields) add_sources(./field_inter.f90) diff --git a/Geometry/Fields/PieceConstantFields/CMakeLists.txt b/Geometry/Fields/PieceConstantFields/CMakeLists.txt new file mode 100644 index 000000000..dd90e7975 --- /dev/null +++ b/Geometry/Fields/PieceConstantFields/CMakeLists.txt @@ -0,0 +1,6 @@ + +add_sources( ./pieceConstantField_inter.f90 + ./cartesianField_class.f90) + +add_unit_tests( ./Tests/cartesianField_test.f90) + diff --git a/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 b/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 new file mode 100644 index 000000000..783740753 --- /dev/null +++ b/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 @@ -0,0 +1,89 @@ +module cartesianField_test + + use numPrecision + use dictionary_class, only : dictionary + use dictParser_func, only : charToDict + use particle_class, only : particle + use field_inter, only : field + use pieceConstantField_inter, only : pieceConstantField, pieceConstantField_CptrCast + use cartesianField_class, only : cartesianField, cartesianField_TptrCast + use funit + + implicit none + character(*), parameter :: FIELD_DEF = "type cartesianField; origin (1.0 2.0 1.0); pitch (1.0 2.0 0.5); & + & materials (all); shape (3 2 3); all (1 2 3 1 2 3 4 5 6 4 5 6 7 8 9 7 8 9 ); default -6.2;" + +contains + + !! + !! Test Cartesian Field + !! +@Test + subroutine test_cartesianField() + type(cartesianField), target :: fieldT + class(field), pointer :: ref + class(pieceConstantField), pointer :: ptr + type(cartesianField), pointer :: ptr2 + type(dictionary) :: dict + type(particle) :: p + real(defReal), parameter :: TOL = 1.0E-7_defReal + + ! Test invalid pointers + ref => null() + + ptr => pieceConstantField_CptrCast(ref) + ptr2 => cartesianField_TptrCast(ref) + @assertFalse(associated(ptr)) + @assertFalse(associated(ptr2)) + + ! Test valid pointers + ref => fieldT + + ptr => pieceConstantField_CptrCast(ref) + ptr2 => cartesianField_TptrCast(ref) + + @assertTrue(associated(ptr, fieldT)) + @assertTrue(associated(ptr2, fieldT)) + + ! Initialise field + call charToDict(dict, FIELD_DEF) + + call fieldT % init(dict) + + ! Check values at different points + ! Inside region x = 2, y = 1, z = 1 + call p % point([1.0_defReal, 0.0_defReal, 0.0_defReal]) + call p % teleport([1.0_defReal, 1.0_defReal, 0.4_defReal]) + @assertEqual(8.0_defReal, fieldT % at(p), TOL) + + ! Inside region x = 1, y = 2, z = 3 + call p % point([1.0_defReal, 0.0_defReal, 0.0_defReal]) + call p % teleport([-0.4_defReal, 2.2_defReal, 1.3_defReal]) + @assertEqual(1.0_defReal, fieldT % at(p), TOL) + + ! Outside the field + call p % teleport([-8.5_defReal, 4.5_defReal, 0.9_defReal]) + @assertEqual(-6.2_defReal, fieldT % at(p), TOL) + + ! Check distances to the field + ! Inside, pointing along x + call p % point([1.0_defReal, 0.0_defReal, 0.0_defReal]) + call p % teleport([1.0_defReal, 3.5_defReal, 0.9_defReal]) + @assertEqual(0.5_defReal, fieldT % distance(p), TOL) + + ! Inside, at an angle + call p % point([-sqrt(2.0_defReal)/2, sqrt(2.0_defReal)/2, 0.0_defReal]) + call p % teleport([0.9_defReal, 1.0_defReal, 0.4_defReal]) + @assertEqual(0.4_defReal * sqrt(2.0_defReal), fieldT % distance(p), TOL) + + ! Outside, at an angle + call p % point([-sqrt(2.0_defReal)/2, -sqrt(2.0_defReal)/2, 0.0_defReal]) + call p % teleport([2.0_defReal, 4.5_defReal, 1.0_defReal]) + @assertEqual(1.0_defReal/sqrt(2.0_defReal), fieldT % distance(p), TOL) + + ! Kill + call fieldT % kill() + + end subroutine test_cartesianField + +end module cartesianField_test diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 new file mode 100644 index 000000000..096a9895e --- /dev/null +++ b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 @@ -0,0 +1,382 @@ +module cartesianField_class + + use numPrecision + use universalVariables + use genericProcedures, only : fatalError, numToChar, swap + use field_inter, only : field + use pieceConstantField_inter, only : pieceConstantField + use particle_class, only : particle + use dictionary_class, only : dictionary + use box_class, only : box + use materialMenu_mod, only : mm_matIdx => matIdx + + implicit none + private + + !! + !! Public Pointer Cast + !! + public :: cartesianField_TptrCast + + integer(shortInt), parameter :: ALL_MATS = -1 + + !! + !! Piecewise constant field constructed from a lattice-like grid. + !! Values of the field are piecewise constant. + !! + !! Similar to a Cartesian lattice. Centre is placed at origin. + !! Can include materials. If applying the values uniformly to all materials, can use + !! the keyword 'all', i.e., materials (all); + !! + !! Example dictionary: + !! + !! myField { + !! type cartesianField; + !! origin (x0 y0 z0); + !! shape (Nx Ny Nz); + !! pitch (Px Py Pz); + !! materials (fuel coolant); + !! ! Make up to size Nx * Ny * Nz, ascending first in x, then y, then z + !! fuel ( + !! 100 92 3.14 ... + !! ); + !! coolant ( + !! 7 6 -2 ... + !! ); + !! # default 8.0; # + !! + !! } + !! + type, public, extends(pieceConstantField) :: cartesianField + private + real(defReal), dimension(3) :: pitch = ZERO + integer(shortInt), dimension(3) :: sizeN = 0 + real(defReal), dimension(3) :: corner = ZERO + real(defReal), dimension(3) :: a_bar = ZERO + type(box) :: outline + integer(shortInt) :: outLocalID = 0 + + integer(shortInt) :: nMat = 0 + integer(shortInt), dimension(:), allocatable :: matIdxs + contains + ! Superclass procedures + procedure :: init + procedure :: at + procedure :: distance + procedure :: kill + + procedure, private :: getLocalID + end type cartesianField + +contains + + !! + !! Initialisation + !! + subroutine init(self, dict) + class(cartesianField), intent(inout) :: self + class(dictionary), intent(in) :: dict + type(dictionary) :: tempDict + integer(shortInt) :: N, i, j, k, idx0 + integer(shortInt), dimension(:), allocatable :: tempI + real(defReal), dimension(:), allocatable :: temp + real(defReal), dimension(3) :: origin + real(defReal), dimension(:,:), allocatable :: tempMap + character(nameLen), dimension(:), allocatable :: mats + character(100), parameter :: Here = 'init (cartesianField_class.f90)' + + ! Load pitch + call dict % get(temp, 'pitch') + N = size(temp) + + if (N /= 3) then + call fatalError(Here, 'Pitch must have size 3. Has: '//numToChar(N)) + end if + self % pitch = temp + + ! Load origin + call dict % get(temp, 'origin') + N = size(temp) + + if (N /= 3) then + call fatalError(Here, 'Origin must have size 3. Has: '//numToChar(N)) + end if + origin = temp + + ! Load Size + call dict % get(tempI, 'shape') + N = size(tempI) + + if (N /= 3) then + call fatalError(Here, 'Shape must have size 3. Has: '//numToChar(N)) + else if (any(tempI < 0)) then + call fatalError(Here, 'Shape contains -ve entries') + end if + self % sizeN = tempI + + ! Detect reduced Z dimension + if (self % sizeN(3) == 0) then + self % sizeN(3) = 1 + self % pitch(3) = TWO * INF + end if + + ! Check X & Y for 0 size + if (any( self % sizeN == 0)) call fatalError(Here, 'Shape in X and Y axis cannot be 0.') + + ! Check for invalid pitch + if (any(self % pitch < 10 * SURF_TOL)) then + call fatalError(Here, 'Pitch size must be larger than: '//numToChar( 10 * SURF_TOL)) + end if + + ! Calculate halfwidth and corner + self % a_bar = self % pitch * HALF - SURF_TOL + self % corner = origin -(self % sizeN * HALF * self % pitch) + + ! Build outline box + call tempDict % init(4) + call tempDict % store('type', 'box') + call tempDict % store('id', 1) + call tempDict % store('origin', origin) + call tempDict % store('halfwidth', abs(self % corner - origin)) + call self % outline % init(tempDict) + + ! Construct fill array + ! Detect how many materials are present + self % nMat = dict % getSize('materials') + + call dict % get(mats, 'materials') + + if (any(mats == 'all') .and. self % nMat > 1) call fatalError(Here, 'Material "all" '//& + 'can only be used by itself and is a reserved name') + + allocate(self % matIdxs(self % nMat)) + if (dict % isPresent('all')) then + self % matIdxs = ALL_MATS + else + do i = 1, self % nMat + self % matIdxs(i) = mm_matIdx(mats(i)) + end do + end if + + ! Size field value array + self % outLocalID = product(self % sizeN) + 1 + self % N = product(self % sizeN * self % nMat) + 1 + allocate(self % val(self % N)) + + ! Read field values for each material + idx0 = 0 + do i = 1, size(mats) + + call dict % get(temp, mats(i)) + + ! Flip array up-down for more natural input + ! Reshape into rank 2 array + tempMap = reshape(temp, [self % sizeN(1), self % sizeN(2) * self % sizeN(3)]) + N = size(tempMap, 2) + do j = 1, N/2 + call swap(tempMap(:,j), tempMap(:,N - j + 1)) + end do + + ! Build fill array + N = size(tempMap, 1) + do j = 1, size(tempMap, 2) + do k = 1, N + self % val(idx0 + k + (j-1) * N) = tempMap(k, j) + end do + end do + + ! Increment starting position + idx0 = idx0 + size(temp) + + end do + + ! Set default value when not in the field + call dict % getOrDefault(self % val(self % N), 'default', -INF) + + end subroutine init + + !! + !! Get value of the field at the co-ordinate point + !! + !! See pieceConstantField for details + !! + function at(self, p) result(val) + class(cartesianField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal) :: val + integer(shortInt) :: idx, localID + + localID = self % getLocalID(p % rGlobal(), p % dirGlobal()) + + if (localID == self % outLocalID) then + val = self % val(self % N) + return + + end if + + ! Compare against material idx + if (self % matIdxs(1) /= ALL_MATS) then + idx = findloc(self % matIdxs, p % matIdx(), 1) + localID = localID + (idx - 1) * product(self % sizeN) + end if + + val = self % val(localID) + + end function at + + !! + !! Get distance to the next element of the field at the co-ordinate point and direction + !! + !! See pieceConstantField for details + !! + function distance(self, p) result(d) + class(cartesianField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal) :: d + real(defReal) :: test_d + integer(shortInt) :: localID, temp, base, ax, i + integer(shortInt), dimension(3) :: ijk + real(defReal), dimension(3) :: bounds, r_bar, u + + localID = self % getLocalID(p % rGlobal(), p % dirGlobal()) + + ! Catch case if particle is outside the lattice + if (localID == self % outLocalID) then + d = self % outline % distance(p % rGlobal(), p % dirGlobal()) + return + + end if + + ! Compute ijk of localID + temp = localID - 1 + + base = temp / self % sizeN(1) + ijk(1) = temp - self % sizeN(1) * base + 1 + + temp = base + base = temp / self % sizeN(2) + ijk(2) = temp - self % sizeN(2) * base + 1 + + ijk(3) = base + 1 + + ! Find position wrt lattice cell centre + ! Need to use localID to properly handle under and overshoots + u = p % dirGlobal() + r_bar = p % rGlobal() - self % corner + r_bar = r_bar - (ijk - HALF) * self % pitch + + ! Select surfaces in the direction of the particle + bounds = sign(self % pitch * HALF, u) + + ! Find minimum distance + ! Relay on IEEE 754 standard (for floating point numbers) + ! 0.0/0.0 = NaN and (NaN < A = false; for every A) + ! A/0.0 = Infinity (if A > 0.0) + ! + ! Provide default axis to ensure no out of bounds array access if + ! all distances happen to be infinite + d = INF + ax = 1 + do i = 1, 3 + ! Nominator and denominator will have the same sign (by earlier bounds selection) + test_d = (bounds(i) - r_bar(i)) / u(i) + + if (test_d < d) then + d = test_d + ax = i + end if + end do + + ! Cap distance value + d = max(ZERO, d) + d = min(INF, d) + + end function distance + + !! + !! Clean-up + !! + elemental subroutine kill(self) + class(cartesianField), intent(inout) :: self + + call self % killSuper() + + self % pitch = ZERO + self % sizeN = 0 + self % nMat = 0 + self % corner = ZERO + self % a_bar = ZERO + self % outLocalID = 0 + call self % outline % kill() + + end subroutine kill + + !! + !! Find the local integer ID in the field given position and direction + !! + function getLocalID(self, r, u) result(localID) + class(cartesianField), intent(in) :: self + real(defReal), dimension(3) :: r + real(defReal), dimension(3) :: u + integer(shortInt) :: localID + real(defReal), dimension(3) :: r_bar + integer(shortInt), dimension(3) :: ijk + integer(shortInt) :: i, inc + + ijk = floor((r - self % corner) / self % pitch) + 1 + + ! Get position wrt middle of the lattice cell + r_bar = r - self % corner - ijk * self % pitch + HALF * self % pitch + + ! Check if position is within surface tolerance + ! If it is, push it to next cell + do i = 1, 3 + if (abs(r_bar(i)) > self % a_bar(i) .and. r_bar(i)*u(i) > ZERO) then + + ! Select increment. Ternary expression + if (u(i) < ZERO) then + inc = -1 + else + inc = 1 + end if + + ijk(i) = ijk(i) + inc + end if + end do + + if (any(ijk <= 0 .or. ijk > self % sizeN)) then ! Point is outside lattice + localID = self % outLocalID + + else + localID = ijk(1) + self % sizeN(1) * (ijk(2)-1 + self % sizeN(2) * (ijk(3)-1)) + + end if + + + end function getLocalID + + !! + !! Cast field pointer to cartesianField pointer + !! + !! Args: + !! source [in] -> source pointer of class field + !! + !! Result: + !! Null is source is not of cartesianField + !! Pointer to source if source is cartesianField type + !! + pure function cartesianField_TptrCast(source) result(ptr) + class(field), pointer, intent(in) :: source + type(cartesianField), pointer :: ptr + + select type (source) + type is (cartesianField) + ptr => source + + class default + ptr => null() + end select + + end function cartesianField_TptrCast + +end module cartesianField_class diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 new file mode 100644 index 000000000..6a9bf3f27 --- /dev/null +++ b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 @@ -0,0 +1,166 @@ +module pieceConstantField_inter + + use numPrecision + use genericProcedures, only : fatalError, numToChar + use field_inter, only : field + use particle_class, only : particle + use dictionary_class, only : dictionary + + implicit none + private + + !! + !! Public Pointer Cast + !! + public :: pieceConstantField_CptrCast + + !! + !! Piecewise constant field. Values of the field are piecewise constant. + !! Provides a distance calculation to neighbouring elements, allowing surface + !! tracking to be used. + !! + !! Access to field is via coordList to allow more fancy fields to be defined + !! (e.g. assign value to each uniqueID etc.) + !! + !! Interface: + !! field interface + !! at -> Return scalar value given position coordinates and index of value + !! distance -> Return distance to next element of the field + !! setValue -> Sets value of field at a given index + !! getMaxValue -> Returns the maximum field value + !! + type, public, abstract, extends(field) :: pieceConstantField + real(defReal), dimension(:), allocatable :: val + integer(shortInt) :: N = 0 + contains + procedure(at), deferred :: at + procedure(distance), deferred :: distance + + procedure :: setValue + procedure :: getMaxValue + + procedure :: killSuper + end type pieceConstantField + + abstract interface + + !! + !! Get value of the field at the co-ordinate point + !! + !! Args: + !! coords [in] -> Coordinates of the position in the geometry + !! + !! Result: + !! Value of the scalar field. Real number. + !! + function at(self, p) result(val) + import :: pieceConstantField, particle, defReal + class(pieceConstantField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal) :: val + end function at + + !! + !! Get distance to the next element of the field at the co-ordinate point and direction + !! + !! Args: + !! coords [in] -> Coordinates of the position in the geometry + !! + !! Result: + !! Distance to the next element of the field. Real number. + !! + function distance(self, p) result(d) + import :: pieceConstantField, particle, defReal + class(pieceConstantField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal) :: d + end function distance + + end interface + +contains + + !! + !! Cast field pointer to pieceConstantField pointer + !! + !! Args: + !! source [in] -> source pointer of class field + !! + !! Result: + !! Null is source is not of pieceConstantField + !! Pointer to source if source is pieceConstantField class + !! + pure function pieceConstantField_CptrCast(source) result(ptr) + class(field), pointer, intent(in) :: source + class(pieceConstantField), pointer :: ptr + + select type (source) + class is (pieceConstantField) + ptr => source + + class default + ptr => null() + end select + + end function pieceConstantField_CptrCast + + !! + !! Sets the value of a field at a given index. + !! May be used to update the field. + !! + !! Args: + !! val [in] -> Value to input + !! idx [in] -> Index of the field to overwrite + !! + !! Errors: + !! If the values of the field are not allocated + !! If the index is out of bounds + !! + subroutine setValue(self, val, idx) + class(pieceConstantField), intent(inout) :: self + real(defReal), intent(in) :: val + integer(shortInt), intent(in) :: idx + character(100), parameter :: Here = 'setValue_idx (pieceConstantField_class.f90)' + + if (.not. allocated(self % val)) call fatalError(Here,& + 'The values of the field have not been allocated') + + if (idx < 1 .or. idx > self % N) call fatalError(Here,& + 'Invalid index to overwrite: '//numToChar(idx)& + //'. Field has size: '//numToChar(self % N)) + + self % val(idx) = val + + end subroutine setValue + + !! + !! Returns the value of the maximum value of the field. + !! This may be useful, e.g., in ensuring the majorant is correct. + !! + !! Errors: + !! If the values of the field are not allocated + !! + function getMaxValue(self) result(val) + class(pieceConstantField), intent(inout) :: self + real(defReal) :: val + character(100), parameter :: Here = 'getMaxValue (pieceConstantField_class.f90)' + + if (.not. allocated(self % val)) call fatalError(Here,& + 'The values of the field have not been allocated') + + val = maxval(self % val) + + end function getMaxValue + + !! + !! Kills elements of the superclass + !! + elemental subroutine killSuper(self) + class(pieceConstantField), intent(inout) :: self + + if (allocated(self % val)) deallocate(self % val) + self % N = 0 + + end subroutine killSuper + +end module pieceConstantField_inter From 1a63bfa32221b10a406ce8c3d94f676f5c5b835b Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 1 Aug 2025 16:14:14 +0100 Subject: [PATCH 05/27] PieceConstant fields take coordList --- .../Tests/cartesianField_test.f90 | 12 +++++----- .../cartesianField_class.f90 | 22 +++++++++---------- .../pieceConstantField_inter.f90 | 20 ++++++++--------- Tallies/TallyMaps/CMakeLists.txt | 2 +- 4 files changed, 28 insertions(+), 28 deletions(-) diff --git a/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 b/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 index 783740753..2c8df5c02 100644 --- a/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 +++ b/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 @@ -54,32 +54,32 @@ subroutine test_cartesianField() ! Inside region x = 2, y = 1, z = 1 call p % point([1.0_defReal, 0.0_defReal, 0.0_defReal]) call p % teleport([1.0_defReal, 1.0_defReal, 0.4_defReal]) - @assertEqual(8.0_defReal, fieldT % at(p), TOL) + @assertEqual(8.0_defReal, fieldT % at(p % coords), TOL) ! Inside region x = 1, y = 2, z = 3 call p % point([1.0_defReal, 0.0_defReal, 0.0_defReal]) call p % teleport([-0.4_defReal, 2.2_defReal, 1.3_defReal]) - @assertEqual(1.0_defReal, fieldT % at(p), TOL) + @assertEqual(1.0_defReal, fieldT % at(p % coords), TOL) ! Outside the field call p % teleport([-8.5_defReal, 4.5_defReal, 0.9_defReal]) - @assertEqual(-6.2_defReal, fieldT % at(p), TOL) + @assertEqual(-6.2_defReal, fieldT % at(p % coords), TOL) ! Check distances to the field ! Inside, pointing along x call p % point([1.0_defReal, 0.0_defReal, 0.0_defReal]) call p % teleport([1.0_defReal, 3.5_defReal, 0.9_defReal]) - @assertEqual(0.5_defReal, fieldT % distance(p), TOL) + @assertEqual(0.5_defReal, fieldT % distance(p % coords), TOL) ! Inside, at an angle call p % point([-sqrt(2.0_defReal)/2, sqrt(2.0_defReal)/2, 0.0_defReal]) call p % teleport([0.9_defReal, 1.0_defReal, 0.4_defReal]) - @assertEqual(0.4_defReal * sqrt(2.0_defReal), fieldT % distance(p), TOL) + @assertEqual(0.4_defReal * sqrt(2.0_defReal), fieldT % distance(p % coords), TOL) ! Outside, at an angle call p % point([-sqrt(2.0_defReal)/2, -sqrt(2.0_defReal)/2, 0.0_defReal]) call p % teleport([2.0_defReal, 4.5_defReal, 1.0_defReal]) - @assertEqual(1.0_defReal/sqrt(2.0_defReal), fieldT % distance(p), TOL) + @assertEqual(1.0_defReal/sqrt(2.0_defReal), fieldT % distance(p % coords), TOL) ! Kill call fieldT % kill() diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 index 096a9895e..255fe4345 100644 --- a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 @@ -5,7 +5,7 @@ module cartesianField_class use genericProcedures, only : fatalError, numToChar, swap use field_inter, only : field use pieceConstantField_inter, only : pieceConstantField - use particle_class, only : particle + use coord_class, only : coordList use dictionary_class, only : dictionary use box_class, only : box use materialMenu_mod, only : mm_matIdx => matIdx @@ -200,13 +200,13 @@ end subroutine init !! !! See pieceConstantField for details !! - function at(self, p) result(val) + function at(self, coords) result(val) class(cartesianField), intent(in) :: self - class(particle), intent(in) :: p + class(coordList), intent(in) :: coords real(defReal) :: val integer(shortInt) :: idx, localID - localID = self % getLocalID(p % rGlobal(), p % dirGlobal()) + localID = self % getLocalID(coords % lvl(1) % r, coords % lvl(1) % dir) if (localID == self % outLocalID) then val = self % val(self % N) @@ -216,7 +216,7 @@ function at(self, p) result(val) ! Compare against material idx if (self % matIdxs(1) /= ALL_MATS) then - idx = findloc(self % matIdxs, p % matIdx(), 1) + idx = findloc(self % matIdxs, coords % matIdx, 1) localID = localID + (idx - 1) * product(self % sizeN) end if @@ -229,20 +229,20 @@ end function at !! !! See pieceConstantField for details !! - function distance(self, p) result(d) + function distance(self, coords) result(d) class(cartesianField), intent(in) :: self - class(particle), intent(in) :: p + class(coordList), intent(in) :: coords real(defReal) :: d real(defReal) :: test_d integer(shortInt) :: localID, temp, base, ax, i integer(shortInt), dimension(3) :: ijk real(defReal), dimension(3) :: bounds, r_bar, u - localID = self % getLocalID(p % rGlobal(), p % dirGlobal()) + localID = self % getLocalID(coords % lvl(1) % r, coords % lvl(1) % dir) ! Catch case if particle is outside the lattice if (localID == self % outLocalID) then - d = self % outline % distance(p % rGlobal(), p % dirGlobal()) + d = self % outline % distance(coords % lvl(1) % r, coords % lvl(1) % dir) return end if @@ -261,8 +261,8 @@ function distance(self, p) result(d) ! Find position wrt lattice cell centre ! Need to use localID to properly handle under and overshoots - u = p % dirGlobal() - r_bar = p % rGlobal() - self % corner + u = coords % lvl(1) % dir + r_bar = coords % lvl(1) % r - self % corner r_bar = r_bar - (ijk - HALF) * self % pitch ! Select surfaces in the direction of the particle diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 index 6a9bf3f27..09c1ba638 100644 --- a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 +++ b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 @@ -3,7 +3,7 @@ module pieceConstantField_inter use numPrecision use genericProcedures, only : fatalError, numToChar use field_inter, only : field - use particle_class, only : particle + use coord_class, only : coordList use dictionary_class, only : dictionary implicit none @@ -24,7 +24,7 @@ module pieceConstantField_inter !! !! Interface: !! field interface - !! at -> Return scalar value given position coordinates and index of value + !! at -> Return scalar value given particle !! distance -> Return distance to next element of the field !! setValue -> Sets value of field at a given index !! getMaxValue -> Returns the maximum field value @@ -45,7 +45,7 @@ module pieceConstantField_inter abstract interface !! - !! Get value of the field at the co-ordinate point + !! Get value of the field at the given coordinates !! !! Args: !! coords [in] -> Coordinates of the position in the geometry @@ -53,15 +53,15 @@ module pieceConstantField_inter !! Result: !! Value of the scalar field. Real number. !! - function at(self, p) result(val) - import :: pieceConstantField, particle, defReal + function at(self, coords) result(val) + import :: pieceConstantField, coordList, defReal class(pieceConstantField), intent(in) :: self - class(particle), intent(in) :: p + class(coordList), intent(in) :: coords real(defReal) :: val end function at !! - !! Get distance to the next element of the field at the co-ordinate point and direction + !! Get distance to the next element of the field at the given coordinates !! !! Args: !! coords [in] -> Coordinates of the position in the geometry @@ -69,10 +69,10 @@ end function at !! Result: !! Distance to the next element of the field. Real number. !! - function distance(self, p) result(d) - import :: pieceConstantField, particle, defReal + function distance(self, coords) result(d) + import :: pieceConstantField, coordList, defReal class(pieceConstantField), intent(in) :: self - class(particle), intent(in) :: p + class(coordList), intent(in) :: coords real(defReal) :: d end function distance diff --git a/Tallies/TallyMaps/CMakeLists.txt b/Tallies/TallyMaps/CMakeLists.txt index 0ac9ee1d0..cf177fbe6 100644 --- a/Tallies/TallyMaps/CMakeLists.txt +++ b/Tallies/TallyMaps/CMakeLists.txt @@ -12,7 +12,7 @@ add_sources(./tallyMap_inter.f90 ./Maps1D/homogMatMap_class.f90 ./Maps1D/weightMap_class.f90 ./Maps1D/cellMap_class.f90 - ./Maps1D/radialMap_class.f90 + ./Maps1D/radialMap_class.f90 ./Maps1D/collNumMap_class.f90 ./Maps1D/directionMap_class.f90 ) From 53a35b54fd6b5c0e66e9c7af57ab15f54806c899 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 1 Aug 2025 18:37:17 +0100 Subject: [PATCH 06/27] Silly BEAVRS fix... --- InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP b/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP index bd4ad8531..95f3efdfb 100644 --- a/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP +++ b/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP @@ -232,16 +232,6 @@ geometry { NS3 { type simpleCell; id 12; surfaces (-4 5 -10 11); filltype mat; material SS304;} NS4 { type simpleCell; id 13; surfaces (-4 5 10 -11); filltype mat; material SS304;} -<<<<<<< HEAD - // Water in the arc between neutron shields - outerWaterSeg1 {type simpleCell; id 14; surfaces (-4 5 ); filltype mat; material Water;} - outerWater2 {type simpleCell; id 15; surfaces (-5 6 ); filltype mat; material Water;} - - // Outer core - coreBarrel { type simpleCell; id 16; surfaces (-6 7); filltype mat; material SS304;} - core {type simpleCell; id 17; surfaces (-5); filltype uni; universe 9999;} - -======= // Water in the radial sliver between neutron shields and core waterSliver1 {type simpleCell; id 14; surfaces (6 -5 -8 9); filltype mat; material Water;} waterSliver2 {type simpleCell; id 15; surfaces (6 -5 8 -9); filltype mat; material Water;} @@ -257,7 +247,6 @@ geometry { // Outer core coreBarrel { type simpleCell; id 22; surfaces (-6 7); filltype mat; material SS304;} core {type simpleCell; id 23; surfaces (-7); filltype uni; universe 9999;} ->>>>>>> 8531673e715792a098906c8d2f88bb4d7eab1bf3 // Gridded pins From 8eaabadafcc61f38aa44c90d9a63e998666ef86f Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 1 Aug 2025 18:43:41 +0100 Subject: [PATCH 07/27] Fixes to silly things --- InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP | 4834 ++++++++--------- Tallies/TallyMaps/CMakeLists.txt | 2 +- .../TallyMaps/Maps1D/Tests/spaceMap_test.f90 | 21 - Tallies/TallyMaps/Maps1D/spaceMap_class.f90 | 41 - Tallies/TallyMaps/Tests/multiMap_test.f90 | 19 - Tallies/TallyMaps/multiMap_class.f90 | 31 +- Tallies/TallyMaps/tallyMap_inter.f90 | 31 +- 7 files changed, 2426 insertions(+), 2553 deletions(-) diff --git a/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP b/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP index 95f3efdfb..daf0857fb 100644 --- a/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP +++ b/InputFiles/Benchmarks/BEAVRS/BEAVRS_HZP @@ -1,2417 +1,2417 @@ -!! -!! 3D BEAVRS benchmark -!! At HZP, the D bank of rods is partially inserted up -!! to 115 steps inserted / 113 steps withdrawn. -!! A step corresponds to an increment of 1.58193cm -!! -type eigenPhysicsPackage; - -pop 1000000; -active 50; -inactive 250; -XSdata ce; -dataType ce; - -collisionOperator { neutronCE {type neutronCEstd;}} - -transportOperator { - !type transportOperatorDT; - type transportOperatorHT; cache 1; - } - -inactiveTally { - shannon { - type shannonEntropyClerk; - map {type multiMap; - maps (xax yax zax); - xax { type spaceMap; grid lin; min -161.2773; max 161.2773; N 15; axis x;} - yax { type spaceMap; grid lin; min -161.2773; max 161.2773; N 15; axis y;} - zax { type spaceMap; grid lin; min 36.748; max 402.508; N 15; axis z;} - } - cycles 200; - } - -} - -activeTally { - pinFissRadial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} - map {type multiMap; maps (xax yax); - xax {type spaceMap; axis x; grid lin; N 255; min -161.2773; max 161.2773; } - yax {type spaceMap; axis y; grid lin; N 255; min -161.2773; max 161.2773; } - } - } - assemblyFissRadial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} - map {type multiMap; maps (xax yax); - xax {type spaceMap; axis x; grid lin; N 15; min -161.2773; max 161.2773; } - yax {type spaceMap; axis y; grid lin; N 15; min -161.2773; max 161.2773; } - } - } - fissionAxial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} - map {type spaceMap; axis z; grid lin; N 60; min 36.748; max 402.508;} - } - fissionYZ { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} - map {type multiMap; maps (yax zax); - yax {type spaceMap; axis y; grid lin; N 255; min -161.2773; max 161.2773; } - zax {type spaceMap; axis z; grid lin; N 60; min 36.748; max 402.508;} - } - } -} - -geometry { - type geometryStd; - boundary ( 0 0 0 0 0 0); - graph {type shrunk;} - - surfaces { - - // thickness specifications for RPV and RPV liner - outerRPV { id 1; type zTruncCylinder; radius 241.3; origin (0.0 0.0 230.0); halfwidth 230; } - innerRPV { id 2; type zCylinder; radius 219.710; origin (0.0 0.0 0.0); } - innerRPVLiner { id 3; type zCylinder; radius 219.150; origin (0.0 0.0 0.0); } - - // thickness specifications for neutron shield - outerBoundNS { id 4; type zCylinder; radius 201.630; origin (0.0 0.0 0.0); } - innerBoundNS { id 5; type zCylinder; radius 194.84; origin (0.0 0.0 0.0); } - - // thickness specifications for core barrel - outerCoreBarrel { id 6; type zCylinder; radius 193.675; origin (0.0 0.0 0.0); } - innerCoreBarrel { id 7; type zCylinder; radius 187.96; origin (0.0 0.0 0.0); } - - // four planes that intersect to bound the Neutron shield panel - P1 { id 8; type plane; coeffs (-0.48480962025 0.87461970714 0.0 0.0);} - P2 { id 9; type plane; coeffs (-0.87461970714 0.48480962025 0.0 0.0);} - P3 { id 10; type plane; coeffs (-0.87461970714 -0.48480962025 0.0 0.0);} - P4 { id 11; type plane; coeffs (-0.48480962025 -0.87461970714 0.0 0.0);} - - // bounding widths for baffle on various sides - // right & left refers to the side of the reactor that it is on - // close/away refers to its location in relation to the LATTICE it is a part of - // (NOT the reactor itself) - rightClose { id 50; type plane; coeffs (1.0 0.0 0.0 8.36662);} - rightAway { id 51; type plane; coeffs (1.0 0.0 0.0 10.58912);} - leftClose { id 52; type plane; coeffs (-1.0 0.0 0.0 8.36662);} - leftAway { id 53; type plane; coeffs (-1.0 0.0 0.0 10.58912);} - bottomClose { id 54; type plane; coeffs (0.0 -1.0 0.0 8.36662);} - bottomAway { id 55; type plane; coeffs (0.0 -1.0 0.0 10.58912);} - topClose { id 56; type plane; coeffs (0.0 1.0 0.0 8.36662);} - topAway { id 57; type plane; coeffs (0.0 1.0 0.0 10.58912);} - - // thickness specifications for grid with thickness of 0.0198cm (Inconel) - pinThickGridInner { id 90; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.61015 0.61015 0.0); } - pinThickGridOuter { id 91; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.62992 0.62992 0.0); } - - // thickness specifications for grid with thickness of 0.0194cm (Zircaloy) - pinThinGridInner { id 92; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.61049 0.61049 0.0); } - pinThinGridOuter { id 93; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.62992 0.62992 0.0); } - - // inner and outer surfaces of assembly sleeves (both SS and Zircaloy) - assemblySleeveInner { id 94; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (10.70864 10.70864 0.0); } - assemblySleeveOuter { id 95; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (10.74798 10.74798 0.0); } - - - // Axial planes across core height - // Names are based on axial heights - plane460 { id 100; type plane; coeffs (0.0 0.0 1.0 460.0 ); } - plane431p876 { id 101; type plane; coeffs (0.0 0.0 1.0 431.876); } - plane423p049 { id 102; type plane; coeffs (0.0 0.0 1.0 423.049); } - plane421p532 { id 103; type plane; coeffs (0.0 0.0 1.0 421.532); } - plane419p704 { id 104; type plane; coeffs (0.0 0.0 1.0 419.704); } - plane417p164 { id 105; type plane; coeffs (0.0 0.0 1.0 417.164); } - plane415p164 { id 106; type plane; coeffs (0.0 0.0 1.0 415.164); } - plane411p806 { id 107; type plane; coeffs (0.0 0.0 1.0 411.806); } - plane403p778 { id 108; type plane; coeffs (0.0 0.0 1.0 403.778); } - plane402p508 { id 109; type plane; coeffs (0.0 0.0 1.0 402.508); } - plane401p238 { id 110; type plane; coeffs (0.0 0.0 1.0 401.238); } - plane364p725 { id 111; type plane; coeffs (0.0 0.0 1.0 364.725); } - plane359p01 { id 112; type plane; coeffs (0.0 0.0 1.0 359.01 ); } - plane312p528 { id 113; type plane; coeffs (0.0 0.0 1.0 312.528); } - plane306p813 { id 114; type plane; coeffs (0.0 0.0 1.0 306.813); } - plane260p331 { id 115; type plane; coeffs (0.0 0.0 1.0 260.331); } - plane254p616 { id 116; type plane; coeffs (0.0 0.0 1.0 254.616); } - plane208p134 { id 117; type plane; coeffs (0.0 0.0 1.0 208.134); } - plane202p419 { id 118; type plane; coeffs (0.0 0.0 1.0 202.419); } - plane155p937 { id 119; type plane; coeffs (0.0 0.0 1.0 155.937); } - plane150p222 { id 120; type plane; coeffs (0.0 0.0 1.0 150.222); } - plane143p428 { id 121; type plane; coeffs (0.0 0.0 1.0 143.428); } - plane103p74 { id 122; type plane; coeffs (0.0 0.0 1.0 103.74 ); } - plane98p025 { id 123; type plane; coeffs (0.0 0.0 1.0 98.025 ); } - plane41p828 { id 124; type plane; coeffs (0.0 0.0 1.0 41.828 ); } - plane40p558 { id 125; type plane; coeffs (0.0 0.0 1.0 40.558 ); } - plane40p52 { id 126; type plane; coeffs (0.0 0.0 1.0 40.52 ); } - plane39p958 { id 127; type plane; coeffs (0.0 0.0 1.0 39.958 ); } - plane38p66 { id 128; type plane; coeffs (0.0 0.0 1.0 38.66 ); } - plane37p1621 { id 129; type plane; coeffs (0.0 0.0 1.0 37.1621); } - plane36p748 { id 130; type plane; coeffs (0.0 0.0 1.0 36.748 ); } - plane35 { id 131; type plane; coeffs (0.0 0.0 1.0 35.0 ); } - plane20 { id 132; type plane; coeffs (0.0 0.0 1.0 20.0 ); } - plane0 { id 133; type plane; coeffs (0.0 0.0 1.0 0.0 ); } - - planeSteelBottom { id 134; type plane; coeffs (0.0 0.0 1.0 400.638); } - planeCRLowerBottom { id 135; type plane; coeffs (0.0 0.0 1.0 402.508); } // same as 109 on withdrawal - planeCRUpperBottom { id 136; type plane; coeffs (0.0 0.0 1.0 504.108); } // out of core on withdrawal - - plane322p1861 {id 137; type plane; coeffs (0 0 1 322.18609);} - plane220p586 {id 138; type plane; coeffs (0 0 1 220.5861);} - plane218p716 {id 139; type plane; coeffs (0 0 1 218.71609);} - - } - - cells { - - // assembly wrappers and surrounding water at various heights - wrapper1 {type simpleCell; id 2001; surfaces (94 -95 129 -126); filltype mat; material SS304;} - wrapper2 {type simpleCell; id 2002; surfaces (94 -95 123 -122); filltype mat; material Zircaloy;} - wrapper3 {type simpleCell; id 2003; surfaces (94 -95 120 -119); filltype mat; material Zircaloy;} - wrapper4 {type simpleCell; id 2004; surfaces (94 -95 118 -117); filltype mat; material Zircaloy;} - wrapper5 {type simpleCell; id 2005; surfaces (94 -95 116 -115); filltype mat; material Zircaloy;} - wrapper6 {type simpleCell; id 2006; surfaces (94 -95 114 -113); filltype mat; material Zircaloy;} - wrapper7 {type simpleCell; id 2007; surfaces (94 -95 112 -111); filltype mat; material Zircaloy;} - wrapper8 {type simpleCell; id 2008; surfaces (94 -95 107 -106); filltype mat; material SS304;} - - assemWater0 {type simpleCell; id 2009; surfaces (94 -129); filltype mat; material Water;} - assemWater1 {type simpleCell; id 2010; surfaces (94 -95 126 -123); filltype mat; material Water;} - assemWater2 {type simpleCell; id 2011; surfaces (94 -95 122 -120); filltype mat; material Water;} - assemWater3 {type simpleCell; id 2012; surfaces (94 -95 119 -118); filltype mat; material Water;} - assemWater4 {type simpleCell; id 2013; surfaces (94 -95 117 -116); filltype mat; material Water;} - assemWater5 {type simpleCell; id 2014; surfaces (94 -95 115 -114); filltype mat; material Water;} - assemWater6 {type simpleCell; id 2015; surfaces (94 -95 113 -112); filltype mat; material Water;} - assemWater7 {type simpleCell; id 2016; surfaces (94 -95 111 -107); filltype mat; material Water;} - assemWater8 {type simpleCell; id 2017; surfaces (94 -95 106); filltype mat; material Water;} - assemWaterEx {type simpleCell; id 2018; surfaces (95); filltype mat; material Water;} - - // assemblies inside the wrappers - assem1424 {type simpleCell; id 2019; surfaces (-94); filltype uni; universe 1424;} - assem1416 {type simpleCell; id 2020; surfaces (-94); filltype uni; universe 1416;} - assem1431 {type simpleCell; id 2021; surfaces (-94); filltype uni; universe 1431;} - assem60316 {type simpleCell; id 2022; surfaces (-94); filltype uni; universe 60316;} - assem603112 {type simpleCell; id 2023; surfaces (-94); filltype uni; universe 603112;} - assem60313 {type simpleCell; id 2024; surfaces (-94); filltype uni; universe 60313;} - assem60319 {type simpleCell; id 2025; surfaces (-94); filltype uni; universe 60319;} - assem15315 {type simpleCell; id 2026; surfaces (-94); filltype uni; universe 15315;} - assem15317 {type simpleCell; id 2027; surfaces (-94); filltype uni; universe 15317;} - assem15311 {type simpleCell; id 2028; surfaces (-94); filltype uni; universe 15311;} - assem153111 {type simpleCell; id 2029; surfaces (-94); filltype uni; universe 153111;} - assem1631 {type simpleCell; id 2030; surfaces (-94); filltype uni; universe 1631;} - assem2031 {type simpleCell; id 2031; surfaces (-94); filltype uni; universe 2031;} - assem1224 {type simpleCell; id 2032; surfaces (-94); filltype uni; universe 1224;} - assem1624 {type simpleCell; id 2033; surfaces (-94); filltype uni; universe 1624;} - - // unrodded assemblies in wrappers - assem2424 {type simpleCell; id 2034; surfaces (-94); filltype uni; universe 2424;} - assem2416 {type simpleCell; id 2035; surfaces (-94); filltype uni; universe 2416;} - assem2431 {type simpleCell; id 2036; surfaces (-94); filltype uni; universe 2431;} - assem70316 {type simpleCell; id 2037; surfaces (-94); filltype uni; universe 70316;} - assem703112 {type simpleCell; id 2038; surfaces (-94); filltype uni; universe 703112;} - assem70313 {type simpleCell; id 2039; surfaces (-94); filltype uni; universe 70313;} - assem70319 {type simpleCell; id 2040; surfaces (-94); filltype uni; universe 70319;} - assem25315 {type simpleCell; id 2041; surfaces (-94); filltype uni; universe 25315;} - assem25317 {type simpleCell; id 2042; surfaces (-94); filltype uni; universe 25317;} - assem25311 {type simpleCell; id 2043; surfaces (-94); filltype uni; universe 25311;} - assem253111 {type simpleCell; id 2044; surfaces (-94); filltype uni; universe 253111;} - assem2631 {type simpleCell; id 2045; surfaces (-94); filltype uni; universe 2631;} - assem3031 {type simpleCell; id 2046; surfaces (-94); filltype uni; universe 3031;} - assem2224 {type simpleCell; id 2047; surfaces (-94); filltype uni; universe 2224;} - assem2624 {type simpleCell; id 2048; surfaces (-94); filltype uni; universe 2624;} - - // rodded assemblies in wrappers - assem1425 {type simpleCell; id 2049; surfaces (-94); filltype uni; universe 1425;} - assem1417 {type simpleCell; id 2050; surfaces (-94); filltype uni; universe 1417;} - - // pin grids - thick at the top and bottom, thin in fuelled region - thickGrid {type simpleCell; id 555; surfaces (90 ); filltype mat; material Inconel;} - thinGrid {type simpleCell; id 556; surfaces (92 ); filltype mat; material Zircaloy;} - - // Don't need to bound PV by 1 since it is the bounding surface of the geometry. - pressureVessel { type simpleCell; id 7; surfaces (2); filltype mat; material CarbonSteel;} - RPVLiner { type simpleCell; id 8; surfaces (-2 3); filltype mat; material SS304;} - outerWater1 {type simpleCell; id 9; surfaces (-3 4 ); filltype mat; material Water;} - - // Neutron shields - NS1 { type simpleCell; id 10; surfaces (-4 5 -8 9); filltype mat; material SS304;} - NS2 { type simpleCell; id 11; surfaces (-4 5 8 -9); filltype mat; material SS304;} - NS3 { type simpleCell; id 12; surfaces (-4 5 -10 11); filltype mat; material SS304;} - NS4 { type simpleCell; id 13; surfaces (-4 5 10 -11); filltype mat; material SS304;} - - // Water in the radial sliver between neutron shields and core - waterSliver1 {type simpleCell; id 14; surfaces (6 -5 -8 9); filltype mat; material Water;} - waterSliver2 {type simpleCell; id 15; surfaces (6 -5 8 -9); filltype mat; material Water;} - waterSliver3 {type simpleCell; id 16; surfaces (6 -5 -10 11); filltype mat; material Water;} - waterSliver4 {type simpleCell; id 17; surfaces (6 -5 10 -11); filltype mat; material Water;} - - // Water in the arc between neutron shields - outerWaterSeg1 {type simpleCell; id 18; surfaces (-4 6 8 11); filltype mat; material Water;} - outerWaterSeg2 {type simpleCell; id 19; surfaces (-4 6 -8 -11); filltype mat; material Water;} - outerWaterSeg3 {type simpleCell; id 20; surfaces (-4 6 -9 10); filltype mat; material Water;} - outerWaterSeg4 {type simpleCell; id 21; surfaces (-4 6 9 -10); filltype mat; material Water;} - - // Outer core - coreBarrel { type simpleCell; id 22; surfaces (-6 7); filltype mat; material SS304;} - core {type simpleCell; id 23; surfaces (-7); filltype uni; universe 9999;} - - // Gridded pins - - // THICK GRID - // 2.4% in grid - grid24Thick {type simpleCell; id 253; surfaces (-90); filltype uni; universe 24000;} - // guide tube in grid - gridGTThick {type simpleCell; id 254; surfaces (-90); filltype uni; universe 12000;} - // 3.1% in grid - grid31Thick {type simpleCell; id 255; surfaces (-90); filltype uni; universe 31000;} - // 1.6 % in grid - grid16Thick {type simpleCell; id 256; surfaces (-90); filltype uni; universe 16000;} - // instrumentation tube in grid - gridITThick {type simpleCell; id 257; surfaces (-90); filltype uni; universe 14000;} - // empty GT at dashpot in grid - gridGTDPThick {type simpleCell; id 258; surfaces (-90); filltype uni; universe 1010;} - // pin upper fuel plenum in grid - gridFPPThick {type simpleCell; id 259; surfaces (-90); filltype uni; universe 1008;} - // stainless steel in guide tube in grid - gridSSGThick {type simpleCell; id 260; surfaces (-90); filltype uni; universe 1023;} - // stainless steel in dash pot in grid - gridSSDPThick {type simpleCell; id 261; surfaces (-90); filltype uni; universe 1024;} - // BP plenum in grid - gridBPPThick {type simpleCell; id 262; surfaces (-90); filltype uni; universe 1012;} - // Lower rodded GT in grid - gridLRGTThick {type simpleCell; id 263; surfaces (-90); filltype uni; universe 1014;} - // Upper rodded GT in grid - gridURGTThick {type simpleCell; id 463; surfaces (-90); filltype uni; universe 1013;} - - // THIN GRID - // 2.4% in grid - grid24Thin {type simpleCell; id 264; surfaces (-92); filltype uni; universe 24000;} - // guide tube in grid - gridGTThin {type simpleCell; id 265; surfaces (-92); filltype uni; universe 12000;} - // burnable poison in grid - gridBPThin {type simpleCell; id 266; surfaces (-92); filltype uni; universe 1000;} - // 3.1% in grid - grid31Thin {type simpleCell; id 267; surfaces (-92); filltype uni; universe 31000;} - // 1.6 % in grid - grid16Thin {type simpleCell; id 268; surfaces (-92); filltype uni; universe 16000;} - // instrumentation tube in grid - gridITThin {type simpleCell; id 269; surfaces (-92); filltype uni; universe 14000;} - // empty GT at dashpot in grid - gridGTDPThin {type simpleCell; id 270; surfaces (-92); filltype uni; universe 1010;} - // pin upper fuel plenum in grid - gridFPPThin {type simpleCell; id 271; surfaces (-92); filltype uni; universe 1008;} - // stainless steel in guide tube in grid - gridSSGTThin {type simpleCell; id 272; surfaces (-92); filltype uni; universe 1023;} - // stainless steel in dash pot in grid - gridSSDPThin {type simpleCell; id 273; surfaces (-92); filltype uni; universe 1024;} - // BP plenum in grid - gridBPPThin {type simpleCell; id 274; surfaces (-92); filltype uni; universe 1012;} - // Lower rodded GT in grid (not used when rods fully withdrawn) - gridLRGTThin {type simpleCell; id 275; surfaces (-92); filltype uni; universe 1014;} - // Upper rodded GT in grid (not used when rods fully withdrawn) - gridURGTThin {type simpleCell; id 475; surfaces (-92); filltype uni; universe 1013;} - - - // 3.1% enriched pins, axial layering - 31FP460 {type simpleCell; id 100; surfaces ( 101); filltype uni; universe 1001;} - 31FP431 {type simpleCell; id 101; surfaces (-101 102); filltype uni; universe 1003;} - 31FP423 {type simpleCell; id 102; surfaces (-102 104); filltype uni; universe 1001;} - 31FP419 {type simpleCell; id 103; surfaces (-104 105); filltype uni; universe 1006;} - 31FP417 {type simpleCell; id 104; surfaces (-105 106); filltype uni; universe 1008;} - 31FP415 {type simpleCell; id 105; surfaces (-106 107); filltype uni; universe 1017;} - 31FP411 {type simpleCell; id 106; surfaces (-107 109); filltype uni; universe 1008;} - 31FP402 {type simpleCell; id 107; surfaces (-109 111); filltype uni; universe 31000;} - 31FP364 {type simpleCell; id 108; surfaces (-111 112); filltype uni; universe 9231;} - 31FP359 {type simpleCell; id 109; surfaces (-112 113); filltype uni; universe 31000;} - 31FP312 {type simpleCell; id 110; surfaces (-113 114); filltype uni; universe 9231;} - 31FP306 {type simpleCell; id 111; surfaces (-114 115); filltype uni; universe 31000;} - 31FP260 {type simpleCell; id 112; surfaces (-115 116); filltype uni; universe 9231;} - 31FP254 {type simpleCell; id 113; surfaces (-116 117); filltype uni; universe 31000;} - 31FP208 {type simpleCell; id 114; surfaces (-117 118); filltype uni; universe 9231;} - 31FP202 {type simpleCell; id 115; surfaces (-118 119); filltype uni; universe 31000;} - 31FP155 {type simpleCell; id 116; surfaces (-119 120); filltype uni; universe 9231;} - 31FP150 {type simpleCell; id 117; surfaces (-120 122); filltype uni; universe 31000;} - 31FP103 {type simpleCell; id 118; surfaces (-122 123); filltype uni; universe 9231;} - 31FP98 {type simpleCell; id 119; surfaces (-123 126); filltype uni; universe 31000;} - 31FP4052 {type simpleCell; id 120; surfaces (-126 129); filltype uni; universe 1131;} - 31FP37 {type simpleCell; id 121; surfaces (-129 130); filltype uni; universe 31000;} - 31FP36 {type simpleCell; id 122; surfaces (-130 131); filltype uni; universe 1006;} - 31FP35 {type simpleCell; id 123; surfaces (-131 132); filltype uni; universe 1003;} - 31FP20 {type simpleCell; id 124; surfaces (-132 ); filltype uni; universe 1001;} - - - //2.4% enriched pins, axial layering - 24FP460 {type simpleCell; id 125; surfaces ( 101); filltype uni; universe 1001;} - 24FP431 {type simpleCell; id 126; surfaces (-101 102); filltype uni; universe 1003;} - 24FP423 {type simpleCell; id 127; surfaces (-102 104); filltype uni; universe 1001;} - 24FP419 {type simpleCell; id 128; surfaces (-104 105); filltype uni; universe 1006;} - 24FP417 {type simpleCell; id 129; surfaces (-105 106); filltype uni; universe 1008;} - 24FP415 {type simpleCell; id 130; surfaces (-106 107); filltype uni; universe 1017;} - 24FP411 {type simpleCell; id 131; surfaces (-107 109); filltype uni; universe 1008;} - 24FP402 {type simpleCell; id 132; surfaces (-109 111); filltype uni; universe 24000;} - 24FP364 {type simpleCell; id 133; surfaces (-111 112); filltype uni; universe 9224;} - 24FP359 {type simpleCell; id 134; surfaces (-112 113); filltype uni; universe 24000;} - 24FP312 {type simpleCell; id 135; surfaces (-113 114); filltype uni; universe 9224;} - 24FP306 {type simpleCell; id 136; surfaces (-114 115); filltype uni; universe 24000;} - 24FP260 {type simpleCell; id 137; surfaces (-115 116); filltype uni; universe 9224;} - 24FP254 {type simpleCell; id 138; surfaces (-116 117); filltype uni; universe 24000;} - 24FP208 {type simpleCell; id 139; surfaces (-117 118); filltype uni; universe 9224;} - 24FP202 {type simpleCell; id 140; surfaces (-118 119); filltype uni; universe 24000;} - 24FP155 {type simpleCell; id 141; surfaces (-119 120); filltype uni; universe 9224;} - 24FP150 {type simpleCell; id 142; surfaces (-120 122); filltype uni; universe 24000;} - 24FP103 {type simpleCell; id 143; surfaces (-122 123); filltype uni; universe 9224;} - 24FP98 {type simpleCell; id 144; surfaces (-123 126); filltype uni; universe 24000;} - 24FP4052 {type simpleCell; id 145; surfaces (-126 129); filltype uni; universe 1124;} - 24FP37 {type simpleCell; id 146; surfaces (-129 130); filltype uni; universe 24000;} - 24FP36 {type simpleCell; id 147; surfaces (-130 131); filltype uni; universe 1006;} - 24FP35 {type simpleCell; id 148; surfaces (-131 132); filltype uni; universe 1003;} - 24FP20 {type simpleCell; id 149; surfaces (-132); filltype uni; universe 1001;} - - //1.6% enriched pins, axial layering - 16FP460 {type simpleCell; id 150; surfaces ( 101); filltype uni; universe 1001;} - 16FP431 {type simpleCell; id 151; surfaces (-101 102); filltype uni; universe 1003;} - 16FP423 {type simpleCell; id 152; surfaces (-102 104); filltype uni; universe 1001;} - 16FP419 {type simpleCell; id 153; surfaces (-104 105); filltype uni; universe 1006;} - 16FP417 {type simpleCell; id 154; surfaces (-105 106); filltype uni; universe 1008;} - 16FP415 {type simpleCell; id 155; surfaces (-106 107); filltype uni; universe 1017;} - 16FP411 {type simpleCell; id 156; surfaces (-107 109); filltype uni; universe 1008;} - 16FP402 {type simpleCell; id 157; surfaces (-109 111); filltype uni; universe 16000;} - 16FP364 {type simpleCell; id 158; surfaces (-111 112); filltype uni; universe 9216;} - 16FP359 {type simpleCell; id 159; surfaces (-112 113); filltype uni; universe 16000;} - 16FP312 {type simpleCell; id 160; surfaces (-113 114); filltype uni; universe 9216;} - 16FP306 {type simpleCell; id 161; surfaces (-114 115); filltype uni; universe 16000;} - 16FP260 {type simpleCell; id 162; surfaces (-115 116); filltype uni; universe 9216;} - 16FP254 {type simpleCell; id 163; surfaces (-116 117); filltype uni; universe 16000;} - 16FP208 {type simpleCell; id 164; surfaces (-117 118); filltype uni; universe 9216;} - 16FP202 {type simpleCell; id 165; surfaces (-118 119); filltype uni; universe 16000;} - 16FP155 {type simpleCell; id 166; surfaces (-119 120); filltype uni; universe 9216;} - 16FP150 {type simpleCell; id 167; surfaces (-120 122); filltype uni; universe 16000;} - 16FP103 {type simpleCell; id 168; surfaces (-122 123); filltype uni; universe 9216;} - 16FP98 {type simpleCell; id 169; surfaces (-123 126); filltype uni; universe 16000;} - 16FP4052 {type simpleCell; id 170; surfaces (-126 129); filltype uni; universe 1116;} - 16FP37 {type simpleCell; id 171; surfaces (-129 130); filltype uni; universe 16000;} - 16FP36 {type simpleCell; id 172; surfaces (-130 131); filltype uni; universe 1006;} - 16FP35 {type simpleCell; id 173; surfaces (-131 132); filltype uni; universe 1003;} - 16FP20 {type simpleCell; id 174; surfaces (-132); filltype uni; universe 1001;} - - - //guide tube, with CR, axial layering - GC460 {type simpleCell; id 175; surfaces ( 101); filltype uni; universe 1014;} - GC431 {type simpleCell; id 176; surfaces (-101 106); filltype uni; universe 1014;} // Nozzle/support plate BW? Replaced just with rod - GC415 {type simpleCell; id 177; surfaces (-106 107); filltype uni; universe 1018;} // Rodded w/ grid - GC411 {type simpleCell; id 178; surfaces (-107 109); filltype uni; universe 1014;} - GC402 {type simpleCell; id 179; surfaces (-109 134); filltype uni; universe 1015;} - GC400 {type simpleCell; id 180; surfaces (-134 111); filltype uni; universe 12000;} - GC364 {type simpleCell; id 181; surfaces (-111 112); filltype uni; universe 9112;} - GC359 {type simpleCell; id 182; surfaces (-112 113); filltype uni; universe 12000;} - GC312 {type simpleCell; id 183; surfaces (-113 114); filltype uni; universe 9112;} - GC306 {type simpleCell; id 184; surfaces (-114 115); filltype uni; universe 12000;} - GC260 {type simpleCell; id 185; surfaces (-115 116); filltype uni; universe 9112;} - GC254 {type simpleCell; id 186; surfaces (-116 117); filltype uni; universe 12000;} - GC208 {type simpleCell; id 187; surfaces (-117 118); filltype uni; universe 9112;} - GC202 {type simpleCell; id 188; surfaces (-118 119); filltype uni; universe 12000;} - GC155 {type simpleCell; id 189; surfaces (-119 120); filltype uni; universe 9112;} - GC150 {type simpleCell; id 190; surfaces (-120 122); filltype uni; universe 12000;} - GC103 {type simpleCell; id 191; surfaces (-122 123); filltype uni; universe 9112;} - GC98 {type simpleCell; id 192; surfaces (-123 126); filltype uni; universe 1010;} - GC4052 {type simpleCell; id 193; surfaces (-126 127); filltype uni; universe 12000;} - GC39 {type simpleCell; id 194; surfaces (-127 129); filltype uni; universe 1019;} - GC37 {type simpleCell; id 195; surfaces (-129 131); filltype uni; universe 1010;} - GC35 {type simpleCell; id 196; surfaces (-131 132); filltype uni; universe 1005;} - GC20 {type simpleCell; id 197; surfaces (-132); filltype uni; universe 1001;} - - - // instrumentation tube, axial layering - IT460 {type simpleCell; id 198; surfaces ( 102); filltype uni; universe 1001;} - IT423 {type simpleCell; id 199; surfaces (-102 106); filltype uni; universe 14000;} - IT415 {type simpleCell; id 200; surfaces (-106 107); filltype uni; universe 1114;} - IT411 {type simpleCell; id 201; surfaces (-107 111); filltype uni; universe 14000;} - IT364 {type simpleCell; id 202; surfaces (-111 112); filltype uni; universe 9114;} - IT359 {type simpleCell; id 203; surfaces (-112 113); filltype uni; universe 14000;} - IT312 {type simpleCell; id 204; surfaces (-113 114); filltype uni; universe 9114;} - IT306 {type simpleCell; id 205; surfaces (-114 115); filltype uni; universe 14000;} - IT260 {type simpleCell; id 206; surfaces (-115 116); filltype uni; universe 9114;} - IT254 {type simpleCell; id 207; surfaces (-116 117); filltype uni; universe 14000;} - IT208 {type simpleCell; id 208; surfaces (-117 118); filltype uni; universe 9114;} - IT202 {type simpleCell; id 209; surfaces (-118 119); filltype uni; universe 14000;} - IT155 {type simpleCell; id 210; surfaces (-119 120); filltype uni; universe 9114;} - IT150 {type simpleCell; id 211; surfaces (-120 122); filltype uni; universe 14000;} - IT103 {type simpleCell; id 212; surfaces (-122 123); filltype uni; universe 9114;} - IT98 {type simpleCell; id 213; surfaces (-123 126); filltype uni; universe 14000;} - IT4052 {type simpleCell; id 214; surfaces (-126 129); filltype uni; universe 1114;} - IT37 {type simpleCell; id 215; surfaces (-129 131); filltype uni; universe 14000;} - IT35 {type simpleCell; id 216; surfaces (-131 132); filltype uni; universe 1005;} - IT20 {type simpleCell; id 217; surfaces (-132 ); filltype uni; universe 1011;} - - - // burnable absorber, axial layering - BA460 {type simpleCell; id 218; surfaces ( 101); filltype uni; universe 1001;} - BA431 {type simpleCell; id 219; surfaces (-101 102); filltype uni; universe 1002;} - BA423 {type simpleCell; id 220; surfaces (-102 103); filltype uni; universe 1023;} - BA421 {type simpleCell; id 230; surfaces (-103 106); filltype uni; universe 1012;} - BA415 {type simpleCell; id 231; surfaces (-106 107); filltype uni; universe 1027;} - BA411 {type simpleCell; id 232; surfaces (-107 110); filltype uni; universe 1012;} - BA401 {type simpleCell; id 233; surfaces (-110 111); filltype uni; universe 1000;} - BA364 {type simpleCell; id 234; surfaces (-111 112); filltype uni; universe 1110;} - BA359 {type simpleCell; id 235; surfaces (-112 113); filltype uni; universe 1000;} - BA312 {type simpleCell; id 236; surfaces (-113 114); filltype uni; universe 1110;} - BA306 {type simpleCell; id 237; surfaces (-114 115); filltype uni; universe 1000;} - BA260 {type simpleCell; id 238; surfaces (-115 116); filltype uni; universe 1110;} - BA254 {type simpleCell; id 239; surfaces (-116 117); filltype uni; universe 1000;} - BA208 {type simpleCell; id 240; surfaces (-117 118); filltype uni; universe 1110;} - BA202 {type simpleCell; id 241; surfaces (-118 119); filltype uni; universe 1000;} - BA155 {type simpleCell; id 242; surfaces (-119 120); filltype uni; universe 1110;} - BA150 {type simpleCell; id 243; surfaces (-120 122); filltype uni; universe 1000;} - BA103 {type simpleCell; id 244; surfaces (-122 123); filltype uni; universe 1110;} - BA98 {type simpleCell; id 245; surfaces (-123 125); filltype uni; universe 1000;} - BA4055 {type simpleCell; id 246; surfaces (-125 126); filltype uni; universe 1023;} - BA4052 {type simpleCell; id 247; surfaces (-126 127); filltype uni; universe 1021;} - BA39 {type simpleCell; id 248; surfaces (-127 128); filltype uni; universe 1025;} - BA38 {type simpleCell; id 249; surfaces (-128 129); filltype uni; universe 1019;} - BA37 {type simpleCell; id 250; surfaces (-129 131); filltype uni; universe 1010;} - BA35 {type simpleCell; id 251; surfaces (-131 132); filltype uni; universe 1005;} - BA20 {type simpleCell; id 252; surfaces (-132 ); filltype uni; universe 1001;} - - //guide tube, no CR, axial layering - GT460 {type simpleCell; id 353; surfaces ( 101); filltype uni; universe 1001;} - GT431 {type simpleCell; id 354; surfaces (-101 102); filltype uni; universe 1005;} - GT423 {type simpleCell; id 355; surfaces (-102 106); filltype uni; universe 12000;} - GT415 {type simpleCell; id 356; surfaces (-106 107); filltype uni; universe 1112;} - GT411 {type simpleCell; id 357; surfaces (-107 111); filltype uni; universe 12000;} - GT364 {type simpleCell; id 358; surfaces (-111 112); filltype uni; universe 9112;} - GT359 {type simpleCell; id 359; surfaces (-112 113); filltype uni; universe 12000;} - GT312 {type simpleCell; id 360; surfaces (-113 114); filltype uni; universe 9112;} - GT306 {type simpleCell; id 361; surfaces (-114 115); filltype uni; universe 12000;} - GT260 {type simpleCell; id 362; surfaces (-115 116); filltype uni; universe 9112;} - GT254 {type simpleCell; id 363; surfaces (-116 117); filltype uni; universe 12000;} - GT208 {type simpleCell; id 364; surfaces (-117 118); filltype uni; universe 9112;} - GT202 {type simpleCell; id 365; surfaces (-118 119); filltype uni; universe 12000;} - GT155 {type simpleCell; id 366; surfaces (-119 120); filltype uni; universe 9112;} - GT150 {type simpleCell; id 367; surfaces (-120 122); filltype uni; universe 12000;} - GT103 {type simpleCell; id 368; surfaces (-122 123); filltype uni; universe 9112;} - GT98 {type simpleCell; id 369; surfaces (-123 126); filltype uni; universe 1010;} - GT4052 {type simpleCell; id 370; surfaces (-126 127); filltype uni; universe 12000;} - GT39 {type simpleCell; id 371; surfaces (-127 129); filltype uni; universe 1019;} - GT37 {type simpleCell; id 372; surfaces (-129 131); filltype uni; universe 1010;} - GT35 {type simpleCell; id 373; surfaces (-131 132); filltype uni; universe 1005;} - GT20 {type simpleCell; id 374; surfaces (-132); filltype uni; universe 1001;} - - //guide tube, partially inserted CR, axial layering - // Note: universe is basically a combo of fully and partially inserted rods - GP460 {type simpleCell; id 375; surfaces ( 101); filltype uni; universe 1013;} - GP431 {type simpleCell; id 376; surfaces (-101 102); filltype uni; universe 1013;} - GP423 {type simpleCell; id 377; surfaces (-102 106); filltype uni; universe 1013;} - GP415 {type simpleCell; id 378; surfaces (-106 107); filltype uni; universe 1133;} - GP411 {type simpleCell; id 379; surfaces (-107 111); filltype uni; universe 1013;} - GP364 {type simpleCell; id 380; surfaces (-111 112); filltype uni; universe 9233;} - GP359 {type simpleCell; id 381; surfaces (-112 137); filltype uni; universe 1013;} - GP322 {type simpleCell; id 382; surfaces (-137 113); filltype uni; universe 1014;} - GP312 {type simpleCell; id 383; surfaces (-113 114); filltype uni; universe 9232;} - GP306 {type simpleCell; id 384; surfaces (-114 115); filltype uni; universe 1014;} - GP260 {type simpleCell; id 385; surfaces (-115 116); filltype uni; universe 9232;} - GP254 {type simpleCell; id 386; surfaces (-116 138); filltype uni; universe 1014;} - GP220 {type simpleCell; id 387; surfaces (-138 139); filltype uni; universe 1023;} - GP219 {type simpleCell; id 388; surfaces (-139 117); filltype uni; universe 12000;} - GP208 {type simpleCell; id 389; surfaces (-117 118); filltype uni; universe 9112;} - GP202 {type simpleCell; id 390; surfaces (-118 119); filltype uni; universe 12000;} - GP155 {type simpleCell; id 391; surfaces (-119 120); filltype uni; universe 9112;} - GP150 {type simpleCell; id 392; surfaces (-120 122); filltype uni; universe 12000;} - GP103 {type simpleCell; id 393; surfaces (-122 123); filltype uni; universe 9112;} - GP98 {type simpleCell; id 394; surfaces (-123 126); filltype uni; universe 1010;} - GP4052 {type simpleCell; id 395; surfaces (-126 127); filltype uni; universe 12000;} - GP39 {type simpleCell; id 396; surfaces (-127 129); filltype uni; universe 1019;} - GP37 {type simpleCell; id 397; surfaces (-129 131); filltype uni; universe 1010;} - GP35 {type simpleCell; id 398; surfaces (-131 132); filltype uni; universe 1005;} - GP20 {type simpleCell; id 399; surfaces (-132); filltype uni; universe 1001;} - - // control rod, axial layering - // Used (probably with some modification) only when fully inserted - //CR460 {type simpleCell; id 448; surfaces (-120 121); filltype uni; universe 1002;} - //CR415 {type simpleCell; id 449; surfaces (-126 403); filltype uni; universe 1013;} - //CR403 {type simpleCell; id 450; surfaces (-403 402); filltype uni; universe 1015;} - //CR402 {type simpleCell; id 451; surfaces (-402 1430); filltype uni; universe 1013;} - //CR143 {type simpleCell; id 452; surfaces (-1430 41); filltype uni; universe 1014;} - //CR41 {type simpleCell; id 453; surfaces (-41 143); filltype uni; universe 1002;} - //CR39 {type simpleCell; id 454; surfaces (-143 147); filltype uni; universe 1001;} - //CR35 {type simpleCell; id 455; surfaces (-147 148); filltype uni; universe 1005;} - //CR20 {type simpleCell; id 456; surfaces (-148 149); filltype uni; universe 1001;} - - - - outsideLeftBaffle { type simpleCell; id 52; surfaces (-50); filltype mat; material Water;} - leftBaffle { type simpleCell; id 53; surfaces (50 -51); filltype mat; material SS304;} - insideLeftBaffle { type simpleCell; id 54; surfaces (51); filltype mat; material Water;} - - outsideRightBaffle { type simpleCell; id 55; surfaces (-52); filltype mat; material Water;} - RightBaffle { type simpleCell; id 56; surfaces (52 -53); filltype mat; material SS304;} - insideRightBaffle { type simpleCell; id 57; surfaces (53); filltype mat; material Water;} - - outsideTopBaffle { type simpleCell; id 58; surfaces (-54); filltype mat; material Water;} - TopBaffle { type simpleCell; id 59; surfaces (54 -55); filltype mat; material SS304;} - insideTopBaffle { type simpleCell; id 60; surfaces (55); filltype mat; material Water;} - - outsideBottomBaffle { type simpleCell; id 61; surfaces (-56); filltype mat; material Water;} - BottomBaffle { type simpleCell; id 62; surfaces (56 -57); filltype mat; material SS304;} - insideBottomBaffle { type simpleCell; id 63; surfaces (57); filltype mat; material Water;} - - topLeftCornerBaffle1 { type simpleCell; id 64; surfaces (52 -53 -57); filltype mat; material SS304;} - topLeftCornerBaffle2 { type simpleCell; id 65; surfaces (56 -57 -52); filltype mat; material SS304;} - topLeftCornerGap1 { type simpleCell; id 66; surfaces (57); filltype mat; material Water;} - topLeftCornerGap2 { type simpleCell; id 67; surfaces (53); filltype mat; material Water;} - topLeftMajorGap { type simpleCell; id 68; surfaces (-56 -52); filltype mat; material Water;} - - topRightCornerBaffle1 { type simpleCell; id 69; surfaces (-57 50 -51); filltype mat; material SS304;} - topRightCornerBaffle2 { type simpleCell; id 70; surfaces (-50 56 -57); filltype mat; material SS304;} - topRightCornerGap1 { type simpleCell; id 71; surfaces (57); filltype mat; material Water;} - topRightCornerGap2 { type simpleCell; id 72; surfaces (51); filltype mat; material Water;} - topRightMajorGap { type simpleCell; id 73; surfaces (-56 -50); filltype mat; material Water;} - - bottomLeftCornerBaffle1 { type simpleCell; id 74; surfaces (-55 52 -53); filltype mat; material SS304;} - bottomLeftCornerBaffle2 { type simpleCell; id 75; surfaces (-55 54 -52); filltype mat; material SS304;} - bottomLeftCornerGap1 { type simpleCell; id 76; surfaces (55); filltype mat; material Water;} - bottomLeftCornerGap2 { type simpleCell; id 77; surfaces (53); filltype mat; material Water;} - bottomLeftMajorGap { type simpleCell; id 78; surfaces (-54 -52); filltype mat; material Water;} - - bottomRightCornerBaffle1 { type simpleCell; id 79; surfaces (-51 50 -55); filltype mat; material SS304;} - bottomRightCornerBaffle2 { type simpleCell; id 80; surfaces (-55 54 -50); filltype mat; material SS304;} - bottomRightCornerGap1 { type simpleCell; id 81; surfaces (51); filltype mat; material Water;} - bottomRightCornerGap2 { type simpleCell; id 82; surfaces (55); filltype mat; material Water;} - bottomRightMajorGap { type simpleCell; id 83; surfaces (-50 -54); filltype mat; material Water;} - - - TLSG1 { type simpleCell; id 84; surfaces (-56 -52); filltype mat; material Water;} - TLSG2 { type simpleCell; id 85; surfaces (-56 52); filltype mat; material Water;} - TLSG3 { type simpleCell; id 86; surfaces (56 -52); filltype mat; material Water;} - topLeftSquare { type simpleCell; id 87; surfaces (56 52); filltype mat; material SS304;} - - TRSG1 { type simpleCell; id 88; surfaces (-56 50); filltype mat; material Water;} - TRSG2 { type simpleCell; id 89; surfaces (-56 -50); filltype mat; material Water;} - TRSG3 { type simpleCell; id 90; surfaces (56 -50); filltype mat; material Water;} - topRightSquare { type simpleCell; id 91; surfaces (56 50); filltype mat; material SS304;} - - BLSG1 { type simpleCell; id 92; surfaces (54 -52); filltype mat; material Water;} - BLSG2 { type simpleCell; id 93; surfaces (-54 52); filltype mat; material Water;} - BLSG3 { type simpleCell; id 94; surfaces (-54 -52); filltype mat; material Water;} - bottomLeftSquare { type simpleCell; id 95; surfaces (54 52); filltype mat; material SS304;} - - BRSG1 { type simpleCell; id 96; surfaces (-54 50); filltype mat; material Water;} - BRSG2 { type simpleCell; id 97; surfaces (54 -50); filltype mat; material Water;} - BRSG3 { type simpleCell; id 98; surfaces (-54 -50); filltype mat; material Water;} - bottomRightSquare { type simpleCell; id 99; surfaces (54 50); filltype mat; material SS304;} - } - - universes { - root { id 1; type rootUniverse; border 1; fill u<8888>; } - - // Pin universes - - //Burnable poison - pinBPaboveDP { id 1000; type pinUniverse; radii (0.21400 0.23051 0.24130 0.42672 0.43688 0.48387 0.56134 0.60198 0.0); - fills (Air SS304 Helium BorosilicateGlass Helium SS304 Water Zircaloy Water);} - pinBPPlenumGeometry { id 1012; type pinUniverse; radii ( 0.21400 0.23051 0.43688 0.48387 0.50419 0.54610 0.0); - fills (Air SS304 Helium SS304 Water Zircaloy Water);} - - //guide tubes - pinGTaboveDP { id 12000; type pinUniverse; radii (0.56134 0.60198 0.0 ); fills (Water Zircaloy Water);} - pinGTatDP { id 1010; type pinUniverse; radii (0.50419 0.54610 0.0); fills (Water Zircaloy Water);} - - //INST Tube - pinIT { id 14000; type pinUniverse; radii (0.43688 0.48387 0.56134 0.60198 0.0 ); - fills (Air Zircaloy Water Zircaloy Water);} - pinBareInstrumentThimble { id 1011; type pinUniverse; radii (0.43688 0.48387 0.0); fills (Air Zircaloy Water);} - - // Fuel pins - pin16 { id 16000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); - fills (UO2-16 Helium Zircaloy Water);} - pin24 { id 24000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); - fills (UO2-24 Helium Zircaloy Water);} - pin31 { id 31000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); - fills (UO2-31 Helium Zircaloy Water);} - // Higher enrichments not used - //pin32 { id 32000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); - // fills (UO2-32 Helium Zircaloy Water);} - //pin34 { id 34000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); - // fills (UO2-34 Helium Zircaloy Water);} - - pinWater { id 1001; type pinUniverse; radii ( 0.0); fills (Water);} - - - // Solid pins, assumed radius to be that of a fuel pin (0.45720) - pinNozzle_SupportSteel { id 1003; type pinUniverse; radii ( 0.45720 0.0); fills (SupportPlateSS Water);} - pinSupportPlateBW { id 1005; type pinUniverse; radii ( 0.45720 0.0); fills (SupportPlateBW Water);} - pinZircaloy { id 1006; type pinUniverse; radii ( 0.45720 0.0); fills (Zircaloy Water);} - - - SSinDashPot { id 1024; type pinUniverse; radii (0.50419 0.54610 0.0); fills (SS304 Zircaloy Water);} - SSinGuideTube { id 1023; type pinUniverse; radii ( 0.56134 0.60198 0.0); fills (SS304 Zircaloy Water);} - SSnoGuideTube { id 1002; type pinUniverse; radii ( 0.56134 0.0); fills (SS304 Water);} - - - pinUpperFuelPlenum { id 1008; type pinUniverse; radii ( 0.06459 0.40005 0.45720 0.0); - fills (Inconel Helium Zircaloy Water);} - - // Control rod pins - pinControlRodUpper { id 1013; type pinUniverse; radii ( 0.37338 0.38608 0.48387 0.56134 0.60198 0.0); - fills (B4C Helium SS304 Water Zircaloy Water);} - pinControlRodLower { id 1014; type pinUniverse; radii ( 0.38227 0.38608 0.48387 0.56134 0.60198 0.0); - fills (Ag-In-Cd Helium SS304 Water Zircaloy Water);} - pinControlRodSpacer { id 1015; type pinUniverse; radii ( 0.37845 0.38608 0.48387 0.56134 0.60198 0.0); - fills (SS304 Helium SS304 Water Zircaloy Water);} - pinControlRodPlenum { id 1016; type pinUniverse; radii ( 0.06459 0.38608 0.48387 0.56134 0.60198 0.0); - fills (Inconel Helium SS304 Water Zircaloy Water);} - - // pins that have grids - fuelRodPlenumWithGridThick { - id 1017; - type cellUniverse; - cells ( 259 555);} - - GTRodThick { - id 1018; - type cellUniverse; - cells (263 555);} - - dashPotGuideTubeGridThick { - id 1019; - type cellUniverse; - cells ( 258 555);} - - dashPotGuideTubeGridThin { - id 1020; - type cellUniverse; - cells ( 270 556);} - - SSinGuideTubeThick { - id 1021; - type cellUniverse; - cells ( 260 555);} - - SSinGuideTubeThin { - id 1022; - type cellUniverse; - cells ( 272 556);} - - SSinDashPotThick { - id 1025; - type cellUniverse; - cells ( 261 555);} - - SSinDashPotThin { - id 1026; - type cellUniverse; - cells ( 273 556);} - - BPPlenumThick { - id 1027; - type cellUniverse; - cells ( 262 555);} - - BPPlenumThin { - id 1028; - type cellUniverse; - cells ( 274 556);} - - BPaboveDPThin { - id 1110; - type cellUniverse; - cells (266 556);} - - GTThick { - id 1112; - type cellUniverse; - cells (254 555);} - - ITThick { - id 1114; - type cellUniverse; - cells (257 555);} - - pin16Thick { - id 1116; - type cellUniverse; - cells (256 555);} - - pin24Thick { - id 1124; - type cellUniverse; - cells (253 555);} - - pin31Thick { - id 1131; - type cellUniverse; - cells (255 555);} - - LowerRodGTThick { - id 1132; - type cellUniverse; - cells (263 555);} - - UpperRodGTThick { - id 1133; - type cellUniverse; - cells (463 555);} - - BPThin { // Is this necessary given 1110, BPaboveDPThin??? - id 9110; - type cellUniverse; - cells (266 556);} - - GTThin { - id 9112; - type cellUniverse; - cells (265 556);} - - ITThin { - id 9114; - type cellUniverse; - cells (269 556);} - - pin16Thin { - id 9216; - type cellUniverse; - cells (268 556);} - - pin24Thin { - id 9224; - type cellUniverse; - cells (264 556);} - - pin31Thin { - id 9231; - type cellUniverse; - cells (267 556);} - - LowerRodGTThin { - id 9232; - type cellUniverse; - cells (275 556);} - - UpperRodGTThin { - id 9233; - type cellUniverse; - cells (475 556);} - - // Axial stacks of universes to make up full pins - - // 3.1 % - fuelPin31 { - id 31; - type cellUniverse; - cells ( 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124);} - - // 2.4 % - fuelPin24 { - id 24; - type cellUniverse; - cells ( 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149);} - - //1.6 % - fuelPin16 { - id 16; - type cellUniverse; - cells ( 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174);} - - //burnable absorber - BP { - id 10; - type cellUniverse; - cells (218 219 220 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252);} - - // guide tube, with CR - GuideTubeRodded { - id 12; - type cellUniverse; - cells (175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197);} - - //control rod, fully retracted - GuideTubeEmpty { - id 13; - type cellUniverse; - cells (353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374);} - - //instr. tube - instrumentTube { - id 14; - type cellUniverse; - cells (198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217);} - - - // control rod, partially inserted - GuideTubePartial { - id 15; - type cellUniverse; - cells (375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399); - - } - - - - // Lattices w/o grid - // Names represent AE - A0E24 { - id 1424; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 12 24 24 12 24 24 12 24 24 24 24 24 - 24 24 24 12 24 24 24 24 24 24 24 24 24 12 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 12 24 24 12 24 24 12 24 24 12 24 24 12 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 12 24 24 12 24 24 14 24 24 12 24 24 12 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 12 24 24 12 24 24 12 24 24 12 24 24 12 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 12 24 24 24 24 24 24 24 24 24 12 24 24 24 - 24 24 24 24 24 12 24 24 12 24 24 12 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } - - // assembly with sleeves at different heights - A0E24Sleeve { - id 14240; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2019 - );} - - - A0E16 { - id 1416; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 12 16 16 12 16 16 12 16 16 16 16 16 - 16 16 16 12 16 16 16 16 16 16 16 16 16 12 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 12 16 16 12 16 16 12 16 16 12 16 16 12 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 12 16 16 12 16 16 14 16 16 12 16 16 12 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 12 16 16 12 16 16 12 16 16 12 16 16 12 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 12 16 16 16 16 16 16 16 16 16 12 16 16 16 - 16 16 16 16 16 12 16 16 12 16 16 12 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } - - A0E16Sleeve { - id 14160; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2020 - ); - } - - A0E31 { - id 1431; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A0E31Sleeve { - id 14310; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2021 - ); - } - - - A6BE31B { - id 60316; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 12 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - - A6BE31BSleeve { - id 603160; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2022 - ); - } - - A6BE31T { - id 603112; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 12 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A6BE31TSleeve { - id 6031120; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2023 - ); - } - - A6BE31R { - id 60313; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 12 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 12 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 10 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A6BE31RSleeve { - id 603130; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2024 - ); - } - - A6BE31L { - id 60319; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 10 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 12 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 12 31 31 12 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A6BE31LSleeve { - id 603190; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2025 - ); - } - - A15BE31BR { - id 15315; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 14 31 31 10 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31BRSleeve { - id 153150; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2026 - ); - } - - A15BE31BL { - id 15317; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 10 31 31 14 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31BLSleeve { - id 153170; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2027 - ); - } - - A15BE31TR { - id 15311; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 14 31 31 10 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31TRSleeve { - id 153110; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2028 - ); - } - - A15BE31TL { - id 153111; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 10 31 31 14 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31TLSleeve { - id 1531110; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2029 - ); - } - - A16BE31 { - id 1631; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 14 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A16BE31Sleeve { - id 16310; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2030 - ); - } - - A20BE31 { - id 2031; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 12 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 12 31 31 14 31 31 12 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 12 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A20BE31Sleeve { - id 20310; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2031 - ); - } - - A12BE24 { - id 1224; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 10 24 24 12 24 24 10 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 12 24 24 12 24 24 14 24 24 12 24 24 12 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 10 24 24 12 24 24 10 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } - - A12BE24Sleeve { - id 12240; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2032 - ); - } - - A16BE24 { - id 1624; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 12 24 24 14 24 24 12 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } - - A16BE24Sleeve { - id 16240; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2033 - ); - } - - // Unrodded assemblies - A0E24U { - id 2424; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 13 24 24 13 24 24 13 24 24 24 24 24 - 24 24 24 13 24 24 24 24 24 24 24 24 24 13 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 13 24 24 13 24 24 13 24 24 13 24 24 13 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 13 24 24 13 24 24 14 24 24 13 24 24 13 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 13 24 24 13 24 24 13 24 24 13 24 24 13 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 13 24 24 24 24 24 24 24 24 24 13 24 24 24 - 24 24 24 24 24 13 24 24 13 24 24 13 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } - - A0E24USleeve { - id 24240; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2034 - );} - - A0E16U { - id 2416; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 13 16 16 13 16 16 13 16 16 16 16 16 - 16 16 16 13 16 16 16 16 16 16 16 16 16 13 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 13 16 16 13 16 16 13 16 16 13 16 16 13 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 13 16 16 13 16 16 14 16 16 13 16 16 13 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 13 16 16 13 16 16 13 16 16 13 16 16 13 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 13 16 16 16 16 16 16 16 16 16 13 16 16 16 - 16 16 16 16 16 13 16 16 13 16 16 13 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } - - // sleeved - A0E16USleeve { - id 24160; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2035 - ); - } - - A0E31U { - id 2431; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A0E31USleeve { - id 24310; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2036 - ); - } - - - A6BE31BU { - id 70316; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 13 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - - A6BE31BUSleeve { - id 703160; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2037 - ); - } - - A6BE31TU { - id 703112; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 13 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A6BE31TUSleeve { - id 7031120; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2038 - ); - } - - A6BE31RU { - id 70313; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 13 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 13 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 10 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A6BE31RUSleeve { - id 703130; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2039 - ); - } - - A6BE31LU { - id 70319; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 10 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 13 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 13 31 31 13 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A6BE31LUSleeve { - id 703190; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2040 - ); - } - - A15BE31BRU { - id 25315; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 14 31 31 10 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31BRUSleeve { - id 253150; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2041 - ); - } - - A15BE31BLU { - id 25317; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 10 31 31 14 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31BLUSleeve { - id 253170; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2042 - ); - } - - A15BE31TRU { - id 25311; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 14 31 31 10 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31TRUSleeve { - id 253110; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2043 - ); - } - - A15BE31TLU { - id 253111; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 10 31 31 14 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A15BE31TLUSleeve { - id 2531110; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2044 - ); - } - - A16BE31U { - id 2631; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 14 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A16BE31USleeve { - id 26310; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2045 - ); - } - - A20BE31U { - id 3031; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 13 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 13 31 31 14 31 31 13 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 10 31 31 10 31 31 13 31 31 10 31 31 10 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 - 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 - 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } - - A20BE31USleeve { - id 30310; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2046 - ); - } - - A12BE24U { - id 2224; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 10 24 24 13 24 24 10 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 13 24 24 13 24 24 14 24 24 13 24 24 13 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 10 24 24 13 24 24 10 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } - - A12BE24USleeve { - id 22240; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2047 - ); - } - - A16BE24U { - id 2624; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 13 24 24 14 24 24 13 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 - 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } - - A16BE24USleeve { - id 26240; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2048 - ); - } - - A0E24DBank { - id 1425; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 15 24 24 15 24 24 15 24 24 24 24 24 - 24 24 24 15 24 24 24 24 24 24 24 24 24 15 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 15 24 24 15 24 24 15 24 24 15 24 24 15 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 15 24 24 15 24 24 14 24 24 15 24 24 15 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 15 24 24 15 24 24 15 24 24 15 24 24 15 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 15 24 24 24 24 24 24 24 24 24 15 24 24 24 - 24 24 24 24 24 15 24 24 15 24 24 15 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 - 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } - - // assembly with sleeves at different heights - A0E24SleeveDBank { - id 14250; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2049 - );} - - A0E16DBank { - id 1417; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (1.26 1.26 0.0); - shape (17 17 0); - padMat Water; - map ( - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 15 16 16 15 16 16 15 16 16 16 16 16 - 16 16 16 15 16 16 16 16 16 16 16 16 16 15 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 15 16 16 15 16 16 15 16 16 15 16 16 15 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 15 16 16 15 16 16 14 16 16 15 16 16 15 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 15 16 16 15 16 16 15 16 16 15 16 16 15 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 15 16 16 16 16 16 16 16 16 16 15 16 16 16 - 16 16 16 16 16 15 16 16 15 16 16 15 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 - 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } - - A0E16SleeveDBank { - id 14170; - type cellUniverse; - cells ( - 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 - 2016 2017 2018 2050 - ); - } - - - leftBaffleUni { - id 5222; - type cellUniverse; - cells (52 53 54);} - - - rightBaffleUni { - id 5223; - type cellUniverse; - cells (55 56 57);} - - topBaffleUni { - id 5224; - type cellUniverse; - cells (58 59 60);} - - bottomBaffleUni { - id 5225; - type cellUniverse; - cells (61 62 63);} - - - topLeft { - id 5226; - type cellUniverse; - cells (64 65 66 67 68);} - - topRight { - id 5227; - type cellUniverse; - cells ( 69 70 71 72 73);} - - BottomLeft { - id 5228; - type cellUniverse; - cells ( 74 75 76 77 78);} - - BottomRight { - id 5229; - type cellUniverse; - cells ( 79 80 81 82 83);} - - - SQTL { - id 1500; - type cellUniverse; - cells (84 85 86 87);} - - - SQTR { - id 1600; - type cellUniverse; - cells (88 89 90 91);} - - SQBL { - id 1700; - type cellUniverse; - cells (92 93 94 95);} - - SQBR { - id 1800; - type cellUniverse; - cells (96 97 98 99);} - - - latCore { - id 9999; - type latUniverse; - origin (0.0 0.0 0.0); - pitch (21.50364 21.50364 0.0); - shape (17 17 0); - padMat Water; - map ( - 1001 1001 1001 1001 1800 5224 5224 5224 5224 5224 5224 5224 1700 1001 1001 1001 1001 - 1001 1001 1800 5224 5229 24310 7031120 24310 7031120 24310 7031120 24310 5228 5224 1700 1001 1001 - 1001 1800 5229 24310 14310 26310 14160 30310 14160 30310 14160 26310 14310 24310 5228 1700 1001 - 1001 5222 24310 2531110 26240 14160 26240 14160 26240 14160 26240 14160 26240 25311 24310 5223 1001 - 1800 5229 14310 26240 14250 26240 24160 22240 14160 22240 24160 26240 14250 26240 14310 5228 1700 - 5222 24310 26310 14160 26240 24160 22240 24160 22240 24160 22240 24160 26240 14160 26310 24310 5223 - 5222 703190 14160 26240 24160 22240 14160 22240 14160 22240 14160 22240 24160 26240 14160 703130 5223 - 5222 24310 30310 14160 22240 24160 22240 24160 26240 24160 22240 24160 22240 14160 30310 24310 5223 - 5222 703190 14160 26240 14160 22240 14160 26240 14170 26240 14160 22240 14160 26240 14160 703130 5223 - 5222 24310 30310 14160 22240 24160 22240 24160 26240 24160 22240 24160 22240 14160 30310 24310 5223 - 5222 703190 14160 26240 24160 22240 14160 22240 14160 22240 14160 22240 24160 26240 14160 703130 5223 - 5222 24310 26310 14160 26240 24160 22240 24160 22240 24160 22240 24160 26240 14160 26310 24310 5223 - 1600 5227 14310 26240 14250 26240 24160 22240 14160 22240 24160 26240 14250 26240 14310 5226 1500 - 1001 5222 24310 253170 26240 14160 26240 14160 26240 14160 26240 14160 26240 253150 24310 5223 1001 - 1001 1600 5227 24310 14310 26310 14160 30310 14160 30310 14160 26310 14310 24310 5226 1500 1001 - 1001 1001 1600 5225 5227 24310 703160 24310 703160 24310 703160 24310 5226 5225 1500 1001 1001 - 1001 1001 1001 1001 1600 5225 5225 5225 5225 5225 5225 5225 1500 1001 1001 1001 1001 ); } - -! Note partial rodded assemblies end with a 1, i.e., 14170 and 14250 - - coreAndStructures { - id 8888; - type cellUniverse; - cells (7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23);} - - - - } -} - - -viz { - bmpZ { - type bmp; - output imgXY; - what material; - centre (0.0 0.0 232.0); - !width (50 50); - axis z; - res (2000 2000); - } - bmpYZ { - type bmp; - output imgYZ; - what material; - centre (0.0 0.0 232.0); - width (100.0 200.0); - axis x; - res (1000 2000); - } -} - - -nuclearData { - handles { - ce {type aceNeutronDatabase; aceLibrary $SCONE_ACE; ures 0; } - } - - materials { - - // Note that commented nuclide densities are included in the specification - // but are not available in the JEFF-3.11 data library - - Air { - temp 566; - composition { - 18036.06 7.8730E-09; - 18038.06 1.4844E-09; - 18040.06 2.3506E-06; - 6012.06 6.7539E-08; - //6013.06 7.5658E-10; - 7014.06 1.9680E-04; - 7015.06 7.2354E-07; - 8016.06 5.2866E-05; - 8017.06 2.0084E-08; - //8018.06 1.0601E-07; - } - } - - SS304 { - temp 566; - composition { - 24050.06 7.6778E-04; - 24052.06 1.4806E-02; - 24053.06 1.6789E-03; - 24054.06 4.1791E-04; - 26054.06 3.4620E-03; - 26056.06 5.4345E-02; - 26057.06 1.2551E-03; - 26058.06 1.6703E-04; - 25055.06 1.7604E-03; - 28058.06 5.6089E-03; - 28060.06 2.1605E-03; - 28061.06 9.3917E-05; - 28062.06 2.9945E-04; - 28064.06 7.6261E-05; - 14028.06 9.5281E-04; - 14029.06 4.8381E-05; - 14030.06 3.1893E-05; } - } - - Helium { - temp 566; - composition { - 2003.06 4.8089E-10; - 2004.06 2.4044E-04; } - } - - BorosilicateGlass { - temp 566; - composition { - 13027.06 1.7352E-03; - 5010.06 9.6506E-04; - 5011.06 3.9189E-03; - 8016.06 4.6514E-02; - 8017.06 1.7671E-05; - //8018.06 9.3268E-05; - 14028.06 1.6926E-02; - 14029.06 8.5944E-04; - 14030.06 5.6654E-04; } - } - - Water { - temp 566; - moder {1001.06 (lwj3.11 lwj3.09); } - composition { - 5010.06 7.9714E-06; - 5011.06 3.2247E-05; - 1001.06 4.9456E-02; - 1002.06 7.7035E-06; - 8016.06 2.4673E-02; - 8017.06 9.3734E-06; - //8018.06 4.9474E-05; - } - } - - Zircaloy { - temp 566; - composition { - 24050.06 3.2962E-06; - 24052.06 6.3564E-05; - 24053.06 7.2076E-06; - 24054.06 1.7941E-06; - 26054.06 8.6698E-06; - 26056.06 1.3610E-04; - 26057.06 3.1431E-06; - 26058.06 4.1829E-07; - 8016.06 3.0744E-04; - 8017.06 1.1680E-07; - //8018.03 6.1648E-07; - 50112.06 4.6735E-06; - 50114.06 3.1799E-06; - 50115.06 1.6381E-06; - 50116.06 7.0055E-05; - 50117.06 3.7003E-05; - 50118.06 1.1669E-04; - 50119.06 4.1387E-05; - 50120.06 1.5697E-04; - 50122.06 2.2308E-05; - 50124.06 2.7897E-05; - 40090.06 2.1828E-02; - 40091.06 4.7601E-03; - 40092.06 7.2759E-03; - 40094.06 7.3734E-03; - 40096.06 1.1879E-03; } - } - - Inconel{ - temp 566; - composition { - 24050.06 7.8239E-04; - 24052.06 1.5088E-02; - 24053.06 1.7108E-03; - 24054.06 4.2586E-04; - 26054.06 1.4797E-03; - 26056.06 2.3229E-02; - 26057.06 5.3645E-04; - 26058.06 7.1392E-05; - 25055.06 7.8201E-04; - 28058.06 2.9320E-02; - 28060.06 1.1294E-02; - 28061.06 4.9094E-04; - 28062.06 1.5653E-03; - 28064.06 3.9864E-04; - 14028.06 5.6757E-04; - 14029.06 2.8820E-05; - 14030.06 1.8998E-05; } - } - - B4C{ - temp 566; - composition { - 5010.06 1.5206E-02; - 5011.06 6.1514E-02; - 6012.06 1.8972E-02; - //6013.06 2.1252E-04; - } - } - - Ag-In-Cd{ - temp 566; - composition { - 47107.06 2.3523E-02; - 47109.06 2.1854E-02; - 48106.06 3.3882E-05; - 48108.06 2.4166E-05; - 48110.06 3.3936E-04; - 48111.06 3.4821E-04; - 48112.06 6.5611E-04; - 48113.06 3.3275E-04; - 48114.06 7.8252E-04; - 48116.06 2.0443E-04; - 49113.06 3.4219E-04; - 49115.06 7.6511E-03; } - } - - UO2-16 { - temp 566; - tms 1; - composition { - 8016.03 4.5897E-02; - 8017.03 1.7436E-05; - //8018.03 9.2032E-05; - 92234.03 3.0131E-06; - 92235.03 3.7503E-04; - 92238.03 2.2625E-02;} - } - - UO2-24 { - temp 566; - tms 1; - composition { - 8016.03 4.5830E-02; - 8017.03 1.7411E-05; - //8018.03 9.1898E-05; - 92234.03 4.4842E-06; - 92235.03 5.5814E-04; - 92238.03 2.2407E-02;} - } - - UO2-31 { - temp 566; - tms 1; - composition { - 8016.03 4.5853E-02; - 8017.03 1.7420E-05; - //8018.03 9.1942E-05; - 92234.03 5.7987E-06; - 92235.03 7.2175E-04; - 92238.03 2.2253E-02;} - } - - UO2-32 { - temp 566; - tms 1; - composition { - 8016.03 4.6029E-02; - 8017.03 1.7487E-05; - //8018.03 9.2296E-05; - 92234.03 5.9959E-06; - 92235.03 7.4630E-04; - 92238.03 2.2317E-02; - } - } - - UO2-34 { - temp 566; - tms 1; - composition { - 8016.03 4.6110E-02; - 8017.03 1.7517E-05; - //8018.03 9.2459E-05; - 92234.03 6.4018E-06; - 92235.03 7.9681E-04; - 92238.03 2.2307E-02;} - } - - // vanadium51 was stated twice in carbonsteel below - // in the beavrs pdf - typo? - CarbonSteel { - temp 566; - composition { - 13027.06 4.3523E-05; - 5010.06 2.5833E-06; - 5011.06 1.0450E-05; - 6012.06 1.0442E-03; - //6013.06 1.1697E-05 ; - 20040.06 1.7043E-05; - 20042.06 1.1375E-07; - 20043.06 2.3734E-08; - 20044.06 3.6673E-07; - 20046.06 7.0322E-10; - 20048.06 3.2875E-08; - 24050.06 1.3738E-05; - 24052.06 2.6493E-04; - 24053.06 3.0041E-05; - 24054.06 7.4778E-06; - 29063.06 1.0223E-04; - 29065.06 4.5608E-05; - 26054.06 4.7437E-03; - 26056.06 7.4465E-02; - 26057.06 1.7197E-03; - 26058.06 2.2886E-04; - 25055.06 6.4126E-04; - 42100.06 2.9814E-05; - 42092.06 4.4822E-05; - 42094.06 2.8110E-05; - 42095.06 4.8567E-05; - 42096.06 5.1015E-05; - 42097.06 2.9319E-05; - 42098.06 7.4327E-05; - 41093.06 5.0559E-06; - 28058.06 4.0862E-04; - 28060.06 1.5740E-04; - 28061.06 6.8420E-06; - 28062.06 2.1815E-05; - 28064.06 5.5557E-06; - 15031.06 3.7913E-05; - 16032.06 3.4808E-05; - 16033.06 2.7420E-07; - 16034.06 1.5368E-06; - 16036.06 5.3398E-09; - 14028.06 6.1702E-04; - 14029.06 3.1330E-05; - 14030.06 2.0653E-05; - 22046.06 1.2144E-06; - 22047.06 1.0952E-06; - 22048.06 1.0851E-05; - 22049.06 7.9634E-07; - 22050.06 7.6249E-07; - //23050.06 1.1526E-07; - 23051.06 4.5989E-05; - } - } - - SupportPlateSS { - temp 566; - composition { - 24050.06 3.5223E-04; - 24052.06 6.7924E-03; - 24053.06 7.7020E-04; - 24054.06 1.9172E-04; - 26054.06 1.5882E-03; - 26056.06 2.4931E-02; - 26057.06 5.7578E-04; - 26058.06 7.6625E-05; - 25055.06 8.0762E-04; - 28058.06 2.5731E-03; - 28060.06 9.9117E-04; - 28061.06 4.3085E-05; - 28062.06 1.3738E-04; - 28064.06 3.4985E-05; - 14028.06 4.3711E-04; - 14029.06 2.2195E-05; - 14030.06 1.4631E-05;} - } - - SupportPlateBW { - temp 566; - moder {1001.06 (lwj3.11 lwj3.09); } - composition { - 5010.06 1.0559E-05; - 5011.06 4.2716E-05; - 1001.06 6.5512E-02; - 1002.06 1.0204E-05; - 8016.06 3.2683E-02; - 8017.06 1.2416E-05; - //8018.06 6.5535E-05; - } - } - - -} -} +!! +!! 3D BEAVRS benchmark +!! At HZP, the D bank of rods is partially inserted up +!! to 115 steps inserted / 113 steps withdrawn. +!! A step corresponds to an increment of 1.58193cm +!! +type eigenPhysicsPackage; + +pop 1000000; +active 50; +inactive 250; +XSdata ce; +dataType ce; + +collisionOperator { neutronCE {type neutronCEstd;}} + +transportOperator { + !type transportOperatorDT; + type transportOperatorHT; cache 1; + } + +inactiveTally { + shannon { + type shannonEntropyClerk; + map {type multiMap; + maps (xax yax zax); + xax { type spaceMap; grid lin; min -161.2773; max 161.2773; N 15; axis x;} + yax { type spaceMap; grid lin; min -161.2773; max 161.2773; N 15; axis y;} + zax { type spaceMap; grid lin; min 36.748; max 402.508; N 15; axis z;} + } + cycles 200; + } + +} + +activeTally { + pinFissRadial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type multiMap; maps (xax yax); + xax {type spaceMap; axis x; grid lin; N 255; min -161.2773; max 161.2773; } + yax {type spaceMap; axis y; grid lin; N 255; min -161.2773; max 161.2773; } + } + } + assemblyFissRadial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type multiMap; maps (xax yax); + xax {type spaceMap; axis x; grid lin; N 15; min -161.2773; max 161.2773; } + yax {type spaceMap; axis y; grid lin; N 15; min -161.2773; max 161.2773; } + } + } + fissionAxial { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type spaceMap; axis z; grid lin; N 60; min 36.748; max 402.508;} + } + fissionYZ { type collisionClerk; response (fission); fission { type macroResponse; MT -6;} + map {type multiMap; maps (yax zax); + yax {type spaceMap; axis y; grid lin; N 255; min -161.2773; max 161.2773; } + zax {type spaceMap; axis z; grid lin; N 60; min 36.748; max 402.508;} + } + } +} + +geometry { + type geometryStd; + boundary ( 0 0 0 0 0 0); + graph {type shrunk;} + + surfaces { + + // thickness specifications for RPV and RPV liner + outerRPV { id 1; type zTruncCylinder; radius 241.3; origin (0.0 0.0 230.0); halfwidth 230; } + innerRPV { id 2; type zCylinder; radius 219.710; origin (0.0 0.0 0.0); } + innerRPVLiner { id 3; type zCylinder; radius 219.150; origin (0.0 0.0 0.0); } + + // thickness specifications for neutron shield + outerBoundNS { id 4; type zCylinder; radius 201.630; origin (0.0 0.0 0.0); } + innerBoundNS { id 5; type zCylinder; radius 194.84; origin (0.0 0.0 0.0); } + + // thickness specifications for core barrel + outerCoreBarrel { id 6; type zCylinder; radius 193.675; origin (0.0 0.0 0.0); } + innerCoreBarrel { id 7; type zCylinder; radius 187.96; origin (0.0 0.0 0.0); } + + // four planes that intersect to bound the Neutron shield panel + P1 { id 8; type plane; coeffs (-0.48480962025 0.87461970714 0.0 0.0);} + P2 { id 9; type plane; coeffs (-0.87461970714 0.48480962025 0.0 0.0);} + P3 { id 10; type plane; coeffs (-0.87461970714 -0.48480962025 0.0 0.0);} + P4 { id 11; type plane; coeffs (-0.48480962025 -0.87461970714 0.0 0.0);} + + // bounding widths for baffle on various sides + // right & left refers to the side of the reactor that it is on + // close/away refers to its location in relation to the LATTICE it is a part of + // (NOT the reactor itself) + rightClose { id 50; type plane; coeffs (1.0 0.0 0.0 8.36662);} + rightAway { id 51; type plane; coeffs (1.0 0.0 0.0 10.58912);} + leftClose { id 52; type plane; coeffs (-1.0 0.0 0.0 8.36662);} + leftAway { id 53; type plane; coeffs (-1.0 0.0 0.0 10.58912);} + bottomClose { id 54; type plane; coeffs (0.0 -1.0 0.0 8.36662);} + bottomAway { id 55; type plane; coeffs (0.0 -1.0 0.0 10.58912);} + topClose { id 56; type plane; coeffs (0.0 1.0 0.0 8.36662);} + topAway { id 57; type plane; coeffs (0.0 1.0 0.0 10.58912);} + + // thickness specifications for grid with thickness of 0.0198cm (Inconel) + pinThickGridInner { id 90; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.61015 0.61015 0.0); } + pinThickGridOuter { id 91; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.62992 0.62992 0.0); } + + // thickness specifications for grid with thickness of 0.0194cm (Zircaloy) + pinThinGridInner { id 92; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.61049 0.61049 0.0); } + pinThinGridOuter { id 93; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (0.62992 0.62992 0.0); } + + // inner and outer surfaces of assembly sleeves (both SS and Zircaloy) + assemblySleeveInner { id 94; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (10.70864 10.70864 0.0); } + assemblySleeveOuter { id 95; type zSquareCylinder; origin (0.0 0.0 0.0); halfwidth (10.74798 10.74798 0.0); } + + + // Axial planes across core height + // Names are based on axial heights + plane460 { id 100; type plane; coeffs (0.0 0.0 1.0 460.0 ); } + plane431p876 { id 101; type plane; coeffs (0.0 0.0 1.0 431.876); } + plane423p049 { id 102; type plane; coeffs (0.0 0.0 1.0 423.049); } + plane421p532 { id 103; type plane; coeffs (0.0 0.0 1.0 421.532); } + plane419p704 { id 104; type plane; coeffs (0.0 0.0 1.0 419.704); } + plane417p164 { id 105; type plane; coeffs (0.0 0.0 1.0 417.164); } + plane415p164 { id 106; type plane; coeffs (0.0 0.0 1.0 415.164); } + plane411p806 { id 107; type plane; coeffs (0.0 0.0 1.0 411.806); } + plane403p778 { id 108; type plane; coeffs (0.0 0.0 1.0 403.778); } + plane402p508 { id 109; type plane; coeffs (0.0 0.0 1.0 402.508); } + plane401p238 { id 110; type plane; coeffs (0.0 0.0 1.0 401.238); } + plane364p725 { id 111; type plane; coeffs (0.0 0.0 1.0 364.725); } + plane359p01 { id 112; type plane; coeffs (0.0 0.0 1.0 359.01 ); } + plane312p528 { id 113; type plane; coeffs (0.0 0.0 1.0 312.528); } + plane306p813 { id 114; type plane; coeffs (0.0 0.0 1.0 306.813); } + plane260p331 { id 115; type plane; coeffs (0.0 0.0 1.0 260.331); } + plane254p616 { id 116; type plane; coeffs (0.0 0.0 1.0 254.616); } + plane208p134 { id 117; type plane; coeffs (0.0 0.0 1.0 208.134); } + plane202p419 { id 118; type plane; coeffs (0.0 0.0 1.0 202.419); } + plane155p937 { id 119; type plane; coeffs (0.0 0.0 1.0 155.937); } + plane150p222 { id 120; type plane; coeffs (0.0 0.0 1.0 150.222); } + plane143p428 { id 121; type plane; coeffs (0.0 0.0 1.0 143.428); } + plane103p74 { id 122; type plane; coeffs (0.0 0.0 1.0 103.74 ); } + plane98p025 { id 123; type plane; coeffs (0.0 0.0 1.0 98.025 ); } + plane41p828 { id 124; type plane; coeffs (0.0 0.0 1.0 41.828 ); } + plane40p558 { id 125; type plane; coeffs (0.0 0.0 1.0 40.558 ); } + plane40p52 { id 126; type plane; coeffs (0.0 0.0 1.0 40.52 ); } + plane39p958 { id 127; type plane; coeffs (0.0 0.0 1.0 39.958 ); } + plane38p66 { id 128; type plane; coeffs (0.0 0.0 1.0 38.66 ); } + plane37p1621 { id 129; type plane; coeffs (0.0 0.0 1.0 37.1621); } + plane36p748 { id 130; type plane; coeffs (0.0 0.0 1.0 36.748 ); } + plane35 { id 131; type plane; coeffs (0.0 0.0 1.0 35.0 ); } + plane20 { id 132; type plane; coeffs (0.0 0.0 1.0 20.0 ); } + plane0 { id 133; type plane; coeffs (0.0 0.0 1.0 0.0 ); } + + planeSteelBottom { id 134; type plane; coeffs (0.0 0.0 1.0 400.638); } + planeCRLowerBottom { id 135; type plane; coeffs (0.0 0.0 1.0 402.508); } // same as 109 on withdrawal + planeCRUpperBottom { id 136; type plane; coeffs (0.0 0.0 1.0 504.108); } // out of core on withdrawal + + plane322p1861 {id 137; type plane; coeffs (0 0 1 322.18609);} + plane220p586 {id 138; type plane; coeffs (0 0 1 220.5861);} + plane218p716 {id 139; type plane; coeffs (0 0 1 218.71609);} + + } + + cells { + + // assembly wrappers and surrounding water at various heights + wrapper1 {type simpleCell; id 2001; surfaces (94 -95 129 -126); filltype mat; material SS304;} + wrapper2 {type simpleCell; id 2002; surfaces (94 -95 123 -122); filltype mat; material Zircaloy;} + wrapper3 {type simpleCell; id 2003; surfaces (94 -95 120 -119); filltype mat; material Zircaloy;} + wrapper4 {type simpleCell; id 2004; surfaces (94 -95 118 -117); filltype mat; material Zircaloy;} + wrapper5 {type simpleCell; id 2005; surfaces (94 -95 116 -115); filltype mat; material Zircaloy;} + wrapper6 {type simpleCell; id 2006; surfaces (94 -95 114 -113); filltype mat; material Zircaloy;} + wrapper7 {type simpleCell; id 2007; surfaces (94 -95 112 -111); filltype mat; material Zircaloy;} + wrapper8 {type simpleCell; id 2008; surfaces (94 -95 107 -106); filltype mat; material SS304;} + + assemWater0 {type simpleCell; id 2009; surfaces (94 -129); filltype mat; material Water;} + assemWater1 {type simpleCell; id 2010; surfaces (94 -95 126 -123); filltype mat; material Water;} + assemWater2 {type simpleCell; id 2011; surfaces (94 -95 122 -120); filltype mat; material Water;} + assemWater3 {type simpleCell; id 2012; surfaces (94 -95 119 -118); filltype mat; material Water;} + assemWater4 {type simpleCell; id 2013; surfaces (94 -95 117 -116); filltype mat; material Water;} + assemWater5 {type simpleCell; id 2014; surfaces (94 -95 115 -114); filltype mat; material Water;} + assemWater6 {type simpleCell; id 2015; surfaces (94 -95 113 -112); filltype mat; material Water;} + assemWater7 {type simpleCell; id 2016; surfaces (94 -95 111 -107); filltype mat; material Water;} + assemWater8 {type simpleCell; id 2017; surfaces (94 -95 106); filltype mat; material Water;} + assemWaterEx {type simpleCell; id 2018; surfaces (95); filltype mat; material Water;} + + // assemblies inside the wrappers + assem1424 {type simpleCell; id 2019; surfaces (-94); filltype uni; universe 1424;} + assem1416 {type simpleCell; id 2020; surfaces (-94); filltype uni; universe 1416;} + assem1431 {type simpleCell; id 2021; surfaces (-94); filltype uni; universe 1431;} + assem60316 {type simpleCell; id 2022; surfaces (-94); filltype uni; universe 60316;} + assem603112 {type simpleCell; id 2023; surfaces (-94); filltype uni; universe 603112;} + assem60313 {type simpleCell; id 2024; surfaces (-94); filltype uni; universe 60313;} + assem60319 {type simpleCell; id 2025; surfaces (-94); filltype uni; universe 60319;} + assem15315 {type simpleCell; id 2026; surfaces (-94); filltype uni; universe 15315;} + assem15317 {type simpleCell; id 2027; surfaces (-94); filltype uni; universe 15317;} + assem15311 {type simpleCell; id 2028; surfaces (-94); filltype uni; universe 15311;} + assem153111 {type simpleCell; id 2029; surfaces (-94); filltype uni; universe 153111;} + assem1631 {type simpleCell; id 2030; surfaces (-94); filltype uni; universe 1631;} + assem2031 {type simpleCell; id 2031; surfaces (-94); filltype uni; universe 2031;} + assem1224 {type simpleCell; id 2032; surfaces (-94); filltype uni; universe 1224;} + assem1624 {type simpleCell; id 2033; surfaces (-94); filltype uni; universe 1624;} + + // unrodded assemblies in wrappers + assem2424 {type simpleCell; id 2034; surfaces (-94); filltype uni; universe 2424;} + assem2416 {type simpleCell; id 2035; surfaces (-94); filltype uni; universe 2416;} + assem2431 {type simpleCell; id 2036; surfaces (-94); filltype uni; universe 2431;} + assem70316 {type simpleCell; id 2037; surfaces (-94); filltype uni; universe 70316;} + assem703112 {type simpleCell; id 2038; surfaces (-94); filltype uni; universe 703112;} + assem70313 {type simpleCell; id 2039; surfaces (-94); filltype uni; universe 70313;} + assem70319 {type simpleCell; id 2040; surfaces (-94); filltype uni; universe 70319;} + assem25315 {type simpleCell; id 2041; surfaces (-94); filltype uni; universe 25315;} + assem25317 {type simpleCell; id 2042; surfaces (-94); filltype uni; universe 25317;} + assem25311 {type simpleCell; id 2043; surfaces (-94); filltype uni; universe 25311;} + assem253111 {type simpleCell; id 2044; surfaces (-94); filltype uni; universe 253111;} + assem2631 {type simpleCell; id 2045; surfaces (-94); filltype uni; universe 2631;} + assem3031 {type simpleCell; id 2046; surfaces (-94); filltype uni; universe 3031;} + assem2224 {type simpleCell; id 2047; surfaces (-94); filltype uni; universe 2224;} + assem2624 {type simpleCell; id 2048; surfaces (-94); filltype uni; universe 2624;} + + // rodded assemblies in wrappers + assem1425 {type simpleCell; id 2049; surfaces (-94); filltype uni; universe 1425;} + assem1417 {type simpleCell; id 2050; surfaces (-94); filltype uni; universe 1417;} + + // pin grids - thick at the top and bottom, thin in fuelled region + thickGrid {type simpleCell; id 555; surfaces (90 ); filltype mat; material Inconel;} + thinGrid {type simpleCell; id 556; surfaces (92 ); filltype mat; material Zircaloy;} + + // Don't need to bound PV by 1 since it is the bounding surface of the geometry. + pressureVessel { type simpleCell; id 7; surfaces (2); filltype mat; material CarbonSteel;} + RPVLiner { type simpleCell; id 8; surfaces (-2 3); filltype mat; material SS304;} + outerWater1 {type simpleCell; id 9; surfaces (-3 4 ); filltype mat; material Water;} + + // Neutron shields + NS1 { type simpleCell; id 10; surfaces (-4 5 -8 9); filltype mat; material SS304;} + NS2 { type simpleCell; id 11; surfaces (-4 5 8 -9); filltype mat; material SS304;} + NS3 { type simpleCell; id 12; surfaces (-4 5 -10 11); filltype mat; material SS304;} + NS4 { type simpleCell; id 13; surfaces (-4 5 10 -11); filltype mat; material SS304;} + + // Water in the radial sliver between neutron shields and core + waterSliver1 {type simpleCell; id 14; surfaces (6 -5 -8 9); filltype mat; material Water;} + waterSliver2 {type simpleCell; id 15; surfaces (6 -5 8 -9); filltype mat; material Water;} + waterSliver3 {type simpleCell; id 16; surfaces (6 -5 -10 11); filltype mat; material Water;} + waterSliver4 {type simpleCell; id 17; surfaces (6 -5 10 -11); filltype mat; material Water;} + + // Water in the arc between neutron shields + outerWaterSeg1 {type simpleCell; id 18; surfaces (-4 6 8 11); filltype mat; material Water;} + outerWaterSeg2 {type simpleCell; id 19; surfaces (-4 6 -8 -11); filltype mat; material Water;} + outerWaterSeg3 {type simpleCell; id 20; surfaces (-4 6 -9 10); filltype mat; material Water;} + outerWaterSeg4 {type simpleCell; id 21; surfaces (-4 6 9 -10); filltype mat; material Water;} + + // Outer core + coreBarrel { type simpleCell; id 22; surfaces (-6 7); filltype mat; material SS304;} + core {type simpleCell; id 23; surfaces (-7); filltype uni; universe 9999;} + + // Gridded pins + + // THICK GRID + // 2.4% in grid + grid24Thick {type simpleCell; id 253; surfaces (-90); filltype uni; universe 24000;} + // guide tube in grid + gridGTThick {type simpleCell; id 254; surfaces (-90); filltype uni; universe 12000;} + // 3.1% in grid + grid31Thick {type simpleCell; id 255; surfaces (-90); filltype uni; universe 31000;} + // 1.6 % in grid + grid16Thick {type simpleCell; id 256; surfaces (-90); filltype uni; universe 16000;} + // instrumentation tube in grid + gridITThick {type simpleCell; id 257; surfaces (-90); filltype uni; universe 14000;} + // empty GT at dashpot in grid + gridGTDPThick {type simpleCell; id 258; surfaces (-90); filltype uni; universe 1010;} + // pin upper fuel plenum in grid + gridFPPThick {type simpleCell; id 259; surfaces (-90); filltype uni; universe 1008;} + // stainless steel in guide tube in grid + gridSSGThick {type simpleCell; id 260; surfaces (-90); filltype uni; universe 1023;} + // stainless steel in dash pot in grid + gridSSDPThick {type simpleCell; id 261; surfaces (-90); filltype uni; universe 1024;} + // BP plenum in grid + gridBPPThick {type simpleCell; id 262; surfaces (-90); filltype uni; universe 1012;} + // Lower rodded GT in grid + gridLRGTThick {type simpleCell; id 263; surfaces (-90); filltype uni; universe 1014;} + // Upper rodded GT in grid + gridURGTThick {type simpleCell; id 463; surfaces (-90); filltype uni; universe 1013;} + + // THIN GRID + // 2.4% in grid + grid24Thin {type simpleCell; id 264; surfaces (-92); filltype uni; universe 24000;} + // guide tube in grid + gridGTThin {type simpleCell; id 265; surfaces (-92); filltype uni; universe 12000;} + // burnable poison in grid + gridBPThin {type simpleCell; id 266; surfaces (-92); filltype uni; universe 1000;} + // 3.1% in grid + grid31Thin {type simpleCell; id 267; surfaces (-92); filltype uni; universe 31000;} + // 1.6 % in grid + grid16Thin {type simpleCell; id 268; surfaces (-92); filltype uni; universe 16000;} + // instrumentation tube in grid + gridITThin {type simpleCell; id 269; surfaces (-92); filltype uni; universe 14000;} + // empty GT at dashpot in grid + gridGTDPThin {type simpleCell; id 270; surfaces (-92); filltype uni; universe 1010;} + // pin upper fuel plenum in grid + gridFPPThin {type simpleCell; id 271; surfaces (-92); filltype uni; universe 1008;} + // stainless steel in guide tube in grid + gridSSGTThin {type simpleCell; id 272; surfaces (-92); filltype uni; universe 1023;} + // stainless steel in dash pot in grid + gridSSDPThin {type simpleCell; id 273; surfaces (-92); filltype uni; universe 1024;} + // BP plenum in grid + gridBPPThin {type simpleCell; id 274; surfaces (-92); filltype uni; universe 1012;} + // Lower rodded GT in grid (not used when rods fully withdrawn) + gridLRGTThin {type simpleCell; id 275; surfaces (-92); filltype uni; universe 1014;} + // Upper rodded GT in grid (not used when rods fully withdrawn) + gridURGTThin {type simpleCell; id 475; surfaces (-92); filltype uni; universe 1013;} + + + // 3.1% enriched pins, axial layering + 31FP460 {type simpleCell; id 100; surfaces ( 101); filltype uni; universe 1001;} + 31FP431 {type simpleCell; id 101; surfaces (-101 102); filltype uni; universe 1003;} + 31FP423 {type simpleCell; id 102; surfaces (-102 104); filltype uni; universe 1001;} + 31FP419 {type simpleCell; id 103; surfaces (-104 105); filltype uni; universe 1006;} + 31FP417 {type simpleCell; id 104; surfaces (-105 106); filltype uni; universe 1008;} + 31FP415 {type simpleCell; id 105; surfaces (-106 107); filltype uni; universe 1017;} + 31FP411 {type simpleCell; id 106; surfaces (-107 109); filltype uni; universe 1008;} + 31FP402 {type simpleCell; id 107; surfaces (-109 111); filltype uni; universe 31000;} + 31FP364 {type simpleCell; id 108; surfaces (-111 112); filltype uni; universe 9231;} + 31FP359 {type simpleCell; id 109; surfaces (-112 113); filltype uni; universe 31000;} + 31FP312 {type simpleCell; id 110; surfaces (-113 114); filltype uni; universe 9231;} + 31FP306 {type simpleCell; id 111; surfaces (-114 115); filltype uni; universe 31000;} + 31FP260 {type simpleCell; id 112; surfaces (-115 116); filltype uni; universe 9231;} + 31FP254 {type simpleCell; id 113; surfaces (-116 117); filltype uni; universe 31000;} + 31FP208 {type simpleCell; id 114; surfaces (-117 118); filltype uni; universe 9231;} + 31FP202 {type simpleCell; id 115; surfaces (-118 119); filltype uni; universe 31000;} + 31FP155 {type simpleCell; id 116; surfaces (-119 120); filltype uni; universe 9231;} + 31FP150 {type simpleCell; id 117; surfaces (-120 122); filltype uni; universe 31000;} + 31FP103 {type simpleCell; id 118; surfaces (-122 123); filltype uni; universe 9231;} + 31FP98 {type simpleCell; id 119; surfaces (-123 126); filltype uni; universe 31000;} + 31FP4052 {type simpleCell; id 120; surfaces (-126 129); filltype uni; universe 1131;} + 31FP37 {type simpleCell; id 121; surfaces (-129 130); filltype uni; universe 31000;} + 31FP36 {type simpleCell; id 122; surfaces (-130 131); filltype uni; universe 1006;} + 31FP35 {type simpleCell; id 123; surfaces (-131 132); filltype uni; universe 1003;} + 31FP20 {type simpleCell; id 124; surfaces (-132 ); filltype uni; universe 1001;} + + + //2.4% enriched pins, axial layering + 24FP460 {type simpleCell; id 125; surfaces ( 101); filltype uni; universe 1001;} + 24FP431 {type simpleCell; id 126; surfaces (-101 102); filltype uni; universe 1003;} + 24FP423 {type simpleCell; id 127; surfaces (-102 104); filltype uni; universe 1001;} + 24FP419 {type simpleCell; id 128; surfaces (-104 105); filltype uni; universe 1006;} + 24FP417 {type simpleCell; id 129; surfaces (-105 106); filltype uni; universe 1008;} + 24FP415 {type simpleCell; id 130; surfaces (-106 107); filltype uni; universe 1017;} + 24FP411 {type simpleCell; id 131; surfaces (-107 109); filltype uni; universe 1008;} + 24FP402 {type simpleCell; id 132; surfaces (-109 111); filltype uni; universe 24000;} + 24FP364 {type simpleCell; id 133; surfaces (-111 112); filltype uni; universe 9224;} + 24FP359 {type simpleCell; id 134; surfaces (-112 113); filltype uni; universe 24000;} + 24FP312 {type simpleCell; id 135; surfaces (-113 114); filltype uni; universe 9224;} + 24FP306 {type simpleCell; id 136; surfaces (-114 115); filltype uni; universe 24000;} + 24FP260 {type simpleCell; id 137; surfaces (-115 116); filltype uni; universe 9224;} + 24FP254 {type simpleCell; id 138; surfaces (-116 117); filltype uni; universe 24000;} + 24FP208 {type simpleCell; id 139; surfaces (-117 118); filltype uni; universe 9224;} + 24FP202 {type simpleCell; id 140; surfaces (-118 119); filltype uni; universe 24000;} + 24FP155 {type simpleCell; id 141; surfaces (-119 120); filltype uni; universe 9224;} + 24FP150 {type simpleCell; id 142; surfaces (-120 122); filltype uni; universe 24000;} + 24FP103 {type simpleCell; id 143; surfaces (-122 123); filltype uni; universe 9224;} + 24FP98 {type simpleCell; id 144; surfaces (-123 126); filltype uni; universe 24000;} + 24FP4052 {type simpleCell; id 145; surfaces (-126 129); filltype uni; universe 1124;} + 24FP37 {type simpleCell; id 146; surfaces (-129 130); filltype uni; universe 24000;} + 24FP36 {type simpleCell; id 147; surfaces (-130 131); filltype uni; universe 1006;} + 24FP35 {type simpleCell; id 148; surfaces (-131 132); filltype uni; universe 1003;} + 24FP20 {type simpleCell; id 149; surfaces (-132); filltype uni; universe 1001;} + + //1.6% enriched pins, axial layering + 16FP460 {type simpleCell; id 150; surfaces ( 101); filltype uni; universe 1001;} + 16FP431 {type simpleCell; id 151; surfaces (-101 102); filltype uni; universe 1003;} + 16FP423 {type simpleCell; id 152; surfaces (-102 104); filltype uni; universe 1001;} + 16FP419 {type simpleCell; id 153; surfaces (-104 105); filltype uni; universe 1006;} + 16FP417 {type simpleCell; id 154; surfaces (-105 106); filltype uni; universe 1008;} + 16FP415 {type simpleCell; id 155; surfaces (-106 107); filltype uni; universe 1017;} + 16FP411 {type simpleCell; id 156; surfaces (-107 109); filltype uni; universe 1008;} + 16FP402 {type simpleCell; id 157; surfaces (-109 111); filltype uni; universe 16000;} + 16FP364 {type simpleCell; id 158; surfaces (-111 112); filltype uni; universe 9216;} + 16FP359 {type simpleCell; id 159; surfaces (-112 113); filltype uni; universe 16000;} + 16FP312 {type simpleCell; id 160; surfaces (-113 114); filltype uni; universe 9216;} + 16FP306 {type simpleCell; id 161; surfaces (-114 115); filltype uni; universe 16000;} + 16FP260 {type simpleCell; id 162; surfaces (-115 116); filltype uni; universe 9216;} + 16FP254 {type simpleCell; id 163; surfaces (-116 117); filltype uni; universe 16000;} + 16FP208 {type simpleCell; id 164; surfaces (-117 118); filltype uni; universe 9216;} + 16FP202 {type simpleCell; id 165; surfaces (-118 119); filltype uni; universe 16000;} + 16FP155 {type simpleCell; id 166; surfaces (-119 120); filltype uni; universe 9216;} + 16FP150 {type simpleCell; id 167; surfaces (-120 122); filltype uni; universe 16000;} + 16FP103 {type simpleCell; id 168; surfaces (-122 123); filltype uni; universe 9216;} + 16FP98 {type simpleCell; id 169; surfaces (-123 126); filltype uni; universe 16000;} + 16FP4052 {type simpleCell; id 170; surfaces (-126 129); filltype uni; universe 1116;} + 16FP37 {type simpleCell; id 171; surfaces (-129 130); filltype uni; universe 16000;} + 16FP36 {type simpleCell; id 172; surfaces (-130 131); filltype uni; universe 1006;} + 16FP35 {type simpleCell; id 173; surfaces (-131 132); filltype uni; universe 1003;} + 16FP20 {type simpleCell; id 174; surfaces (-132); filltype uni; universe 1001;} + + + //guide tube, with CR, axial layering + GC460 {type simpleCell; id 175; surfaces ( 101); filltype uni; universe 1014;} + GC431 {type simpleCell; id 176; surfaces (-101 106); filltype uni; universe 1014;} // Nozzle/support plate BW? Replaced just with rod + GC415 {type simpleCell; id 177; surfaces (-106 107); filltype uni; universe 1018;} // Rodded w/ grid + GC411 {type simpleCell; id 178; surfaces (-107 109); filltype uni; universe 1014;} + GC402 {type simpleCell; id 179; surfaces (-109 134); filltype uni; universe 1015;} + GC400 {type simpleCell; id 180; surfaces (-134 111); filltype uni; universe 12000;} + GC364 {type simpleCell; id 181; surfaces (-111 112); filltype uni; universe 9112;} + GC359 {type simpleCell; id 182; surfaces (-112 113); filltype uni; universe 12000;} + GC312 {type simpleCell; id 183; surfaces (-113 114); filltype uni; universe 9112;} + GC306 {type simpleCell; id 184; surfaces (-114 115); filltype uni; universe 12000;} + GC260 {type simpleCell; id 185; surfaces (-115 116); filltype uni; universe 9112;} + GC254 {type simpleCell; id 186; surfaces (-116 117); filltype uni; universe 12000;} + GC208 {type simpleCell; id 187; surfaces (-117 118); filltype uni; universe 9112;} + GC202 {type simpleCell; id 188; surfaces (-118 119); filltype uni; universe 12000;} + GC155 {type simpleCell; id 189; surfaces (-119 120); filltype uni; universe 9112;} + GC150 {type simpleCell; id 190; surfaces (-120 122); filltype uni; universe 12000;} + GC103 {type simpleCell; id 191; surfaces (-122 123); filltype uni; universe 9112;} + GC98 {type simpleCell; id 192; surfaces (-123 126); filltype uni; universe 1010;} + GC4052 {type simpleCell; id 193; surfaces (-126 127); filltype uni; universe 12000;} + GC39 {type simpleCell; id 194; surfaces (-127 129); filltype uni; universe 1019;} + GC37 {type simpleCell; id 195; surfaces (-129 131); filltype uni; universe 1010;} + GC35 {type simpleCell; id 196; surfaces (-131 132); filltype uni; universe 1005;} + GC20 {type simpleCell; id 197; surfaces (-132); filltype uni; universe 1001;} + + + // instrumentation tube, axial layering + IT460 {type simpleCell; id 198; surfaces ( 102); filltype uni; universe 1001;} + IT423 {type simpleCell; id 199; surfaces (-102 106); filltype uni; universe 14000;} + IT415 {type simpleCell; id 200; surfaces (-106 107); filltype uni; universe 1114;} + IT411 {type simpleCell; id 201; surfaces (-107 111); filltype uni; universe 14000;} + IT364 {type simpleCell; id 202; surfaces (-111 112); filltype uni; universe 9114;} + IT359 {type simpleCell; id 203; surfaces (-112 113); filltype uni; universe 14000;} + IT312 {type simpleCell; id 204; surfaces (-113 114); filltype uni; universe 9114;} + IT306 {type simpleCell; id 205; surfaces (-114 115); filltype uni; universe 14000;} + IT260 {type simpleCell; id 206; surfaces (-115 116); filltype uni; universe 9114;} + IT254 {type simpleCell; id 207; surfaces (-116 117); filltype uni; universe 14000;} + IT208 {type simpleCell; id 208; surfaces (-117 118); filltype uni; universe 9114;} + IT202 {type simpleCell; id 209; surfaces (-118 119); filltype uni; universe 14000;} + IT155 {type simpleCell; id 210; surfaces (-119 120); filltype uni; universe 9114;} + IT150 {type simpleCell; id 211; surfaces (-120 122); filltype uni; universe 14000;} + IT103 {type simpleCell; id 212; surfaces (-122 123); filltype uni; universe 9114;} + IT98 {type simpleCell; id 213; surfaces (-123 126); filltype uni; universe 14000;} + IT4052 {type simpleCell; id 214; surfaces (-126 129); filltype uni; universe 1114;} + IT37 {type simpleCell; id 215; surfaces (-129 131); filltype uni; universe 14000;} + IT35 {type simpleCell; id 216; surfaces (-131 132); filltype uni; universe 1005;} + IT20 {type simpleCell; id 217; surfaces (-132 ); filltype uni; universe 1011;} + + + // burnable absorber, axial layering + BA460 {type simpleCell; id 218; surfaces ( 101); filltype uni; universe 1001;} + BA431 {type simpleCell; id 219; surfaces (-101 102); filltype uni; universe 1002;} + BA423 {type simpleCell; id 220; surfaces (-102 103); filltype uni; universe 1023;} + BA421 {type simpleCell; id 230; surfaces (-103 106); filltype uni; universe 1012;} + BA415 {type simpleCell; id 231; surfaces (-106 107); filltype uni; universe 1027;} + BA411 {type simpleCell; id 232; surfaces (-107 110); filltype uni; universe 1012;} + BA401 {type simpleCell; id 233; surfaces (-110 111); filltype uni; universe 1000;} + BA364 {type simpleCell; id 234; surfaces (-111 112); filltype uni; universe 1110;} + BA359 {type simpleCell; id 235; surfaces (-112 113); filltype uni; universe 1000;} + BA312 {type simpleCell; id 236; surfaces (-113 114); filltype uni; universe 1110;} + BA306 {type simpleCell; id 237; surfaces (-114 115); filltype uni; universe 1000;} + BA260 {type simpleCell; id 238; surfaces (-115 116); filltype uni; universe 1110;} + BA254 {type simpleCell; id 239; surfaces (-116 117); filltype uni; universe 1000;} + BA208 {type simpleCell; id 240; surfaces (-117 118); filltype uni; universe 1110;} + BA202 {type simpleCell; id 241; surfaces (-118 119); filltype uni; universe 1000;} + BA155 {type simpleCell; id 242; surfaces (-119 120); filltype uni; universe 1110;} + BA150 {type simpleCell; id 243; surfaces (-120 122); filltype uni; universe 1000;} + BA103 {type simpleCell; id 244; surfaces (-122 123); filltype uni; universe 1110;} + BA98 {type simpleCell; id 245; surfaces (-123 125); filltype uni; universe 1000;} + BA4055 {type simpleCell; id 246; surfaces (-125 126); filltype uni; universe 1023;} + BA4052 {type simpleCell; id 247; surfaces (-126 127); filltype uni; universe 1021;} + BA39 {type simpleCell; id 248; surfaces (-127 128); filltype uni; universe 1025;} + BA38 {type simpleCell; id 249; surfaces (-128 129); filltype uni; universe 1019;} + BA37 {type simpleCell; id 250; surfaces (-129 131); filltype uni; universe 1010;} + BA35 {type simpleCell; id 251; surfaces (-131 132); filltype uni; universe 1005;} + BA20 {type simpleCell; id 252; surfaces (-132 ); filltype uni; universe 1001;} + + //guide tube, no CR, axial layering + GT460 {type simpleCell; id 353; surfaces ( 101); filltype uni; universe 1001;} + GT431 {type simpleCell; id 354; surfaces (-101 102); filltype uni; universe 1005;} + GT423 {type simpleCell; id 355; surfaces (-102 106); filltype uni; universe 12000;} + GT415 {type simpleCell; id 356; surfaces (-106 107); filltype uni; universe 1112;} + GT411 {type simpleCell; id 357; surfaces (-107 111); filltype uni; universe 12000;} + GT364 {type simpleCell; id 358; surfaces (-111 112); filltype uni; universe 9112;} + GT359 {type simpleCell; id 359; surfaces (-112 113); filltype uni; universe 12000;} + GT312 {type simpleCell; id 360; surfaces (-113 114); filltype uni; universe 9112;} + GT306 {type simpleCell; id 361; surfaces (-114 115); filltype uni; universe 12000;} + GT260 {type simpleCell; id 362; surfaces (-115 116); filltype uni; universe 9112;} + GT254 {type simpleCell; id 363; surfaces (-116 117); filltype uni; universe 12000;} + GT208 {type simpleCell; id 364; surfaces (-117 118); filltype uni; universe 9112;} + GT202 {type simpleCell; id 365; surfaces (-118 119); filltype uni; universe 12000;} + GT155 {type simpleCell; id 366; surfaces (-119 120); filltype uni; universe 9112;} + GT150 {type simpleCell; id 367; surfaces (-120 122); filltype uni; universe 12000;} + GT103 {type simpleCell; id 368; surfaces (-122 123); filltype uni; universe 9112;} + GT98 {type simpleCell; id 369; surfaces (-123 126); filltype uni; universe 1010;} + GT4052 {type simpleCell; id 370; surfaces (-126 127); filltype uni; universe 12000;} + GT39 {type simpleCell; id 371; surfaces (-127 129); filltype uni; universe 1019;} + GT37 {type simpleCell; id 372; surfaces (-129 131); filltype uni; universe 1010;} + GT35 {type simpleCell; id 373; surfaces (-131 132); filltype uni; universe 1005;} + GT20 {type simpleCell; id 374; surfaces (-132); filltype uni; universe 1001;} + + //guide tube, partially inserted CR, axial layering + // Note: universe is basically a combo of fully and partially inserted rods + GP460 {type simpleCell; id 375; surfaces ( 101); filltype uni; universe 1013;} + GP431 {type simpleCell; id 376; surfaces (-101 102); filltype uni; universe 1013;} + GP423 {type simpleCell; id 377; surfaces (-102 106); filltype uni; universe 1013;} + GP415 {type simpleCell; id 378; surfaces (-106 107); filltype uni; universe 1133;} + GP411 {type simpleCell; id 379; surfaces (-107 111); filltype uni; universe 1013;} + GP364 {type simpleCell; id 380; surfaces (-111 112); filltype uni; universe 9233;} + GP359 {type simpleCell; id 381; surfaces (-112 137); filltype uni; universe 1013;} + GP322 {type simpleCell; id 382; surfaces (-137 113); filltype uni; universe 1014;} + GP312 {type simpleCell; id 383; surfaces (-113 114); filltype uni; universe 9232;} + GP306 {type simpleCell; id 384; surfaces (-114 115); filltype uni; universe 1014;} + GP260 {type simpleCell; id 385; surfaces (-115 116); filltype uni; universe 9232;} + GP254 {type simpleCell; id 386; surfaces (-116 138); filltype uni; universe 1014;} + GP220 {type simpleCell; id 387; surfaces (-138 139); filltype uni; universe 1023;} + GP219 {type simpleCell; id 388; surfaces (-139 117); filltype uni; universe 12000;} + GP208 {type simpleCell; id 389; surfaces (-117 118); filltype uni; universe 9112;} + GP202 {type simpleCell; id 390; surfaces (-118 119); filltype uni; universe 12000;} + GP155 {type simpleCell; id 391; surfaces (-119 120); filltype uni; universe 9112;} + GP150 {type simpleCell; id 392; surfaces (-120 122); filltype uni; universe 12000;} + GP103 {type simpleCell; id 393; surfaces (-122 123); filltype uni; universe 9112;} + GP98 {type simpleCell; id 394; surfaces (-123 126); filltype uni; universe 1010;} + GP4052 {type simpleCell; id 395; surfaces (-126 127); filltype uni; universe 12000;} + GP39 {type simpleCell; id 396; surfaces (-127 129); filltype uni; universe 1019;} + GP37 {type simpleCell; id 397; surfaces (-129 131); filltype uni; universe 1010;} + GP35 {type simpleCell; id 398; surfaces (-131 132); filltype uni; universe 1005;} + GP20 {type simpleCell; id 399; surfaces (-132); filltype uni; universe 1001;} + + // control rod, axial layering + // Used (probably with some modification) only when fully inserted + //CR460 {type simpleCell; id 448; surfaces (-120 121); filltype uni; universe 1002;} + //CR415 {type simpleCell; id 449; surfaces (-126 403); filltype uni; universe 1013;} + //CR403 {type simpleCell; id 450; surfaces (-403 402); filltype uni; universe 1015;} + //CR402 {type simpleCell; id 451; surfaces (-402 1430); filltype uni; universe 1013;} + //CR143 {type simpleCell; id 452; surfaces (-1430 41); filltype uni; universe 1014;} + //CR41 {type simpleCell; id 453; surfaces (-41 143); filltype uni; universe 1002;} + //CR39 {type simpleCell; id 454; surfaces (-143 147); filltype uni; universe 1001;} + //CR35 {type simpleCell; id 455; surfaces (-147 148); filltype uni; universe 1005;} + //CR20 {type simpleCell; id 456; surfaces (-148 149); filltype uni; universe 1001;} + + + + outsideLeftBaffle { type simpleCell; id 52; surfaces (-50); filltype mat; material Water;} + leftBaffle { type simpleCell; id 53; surfaces (50 -51); filltype mat; material SS304;} + insideLeftBaffle { type simpleCell; id 54; surfaces (51); filltype mat; material Water;} + + outsideRightBaffle { type simpleCell; id 55; surfaces (-52); filltype mat; material Water;} + RightBaffle { type simpleCell; id 56; surfaces (52 -53); filltype mat; material SS304;} + insideRightBaffle { type simpleCell; id 57; surfaces (53); filltype mat; material Water;} + + outsideTopBaffle { type simpleCell; id 58; surfaces (-54); filltype mat; material Water;} + TopBaffle { type simpleCell; id 59; surfaces (54 -55); filltype mat; material SS304;} + insideTopBaffle { type simpleCell; id 60; surfaces (55); filltype mat; material Water;} + + outsideBottomBaffle { type simpleCell; id 61; surfaces (-56); filltype mat; material Water;} + BottomBaffle { type simpleCell; id 62; surfaces (56 -57); filltype mat; material SS304;} + insideBottomBaffle { type simpleCell; id 63; surfaces (57); filltype mat; material Water;} + + topLeftCornerBaffle1 { type simpleCell; id 64; surfaces (52 -53 -57); filltype mat; material SS304;} + topLeftCornerBaffle2 { type simpleCell; id 65; surfaces (56 -57 -52); filltype mat; material SS304;} + topLeftCornerGap1 { type simpleCell; id 66; surfaces (57); filltype mat; material Water;} + topLeftCornerGap2 { type simpleCell; id 67; surfaces (53); filltype mat; material Water;} + topLeftMajorGap { type simpleCell; id 68; surfaces (-56 -52); filltype mat; material Water;} + + topRightCornerBaffle1 { type simpleCell; id 69; surfaces (-57 50 -51); filltype mat; material SS304;} + topRightCornerBaffle2 { type simpleCell; id 70; surfaces (-50 56 -57); filltype mat; material SS304;} + topRightCornerGap1 { type simpleCell; id 71; surfaces (57); filltype mat; material Water;} + topRightCornerGap2 { type simpleCell; id 72; surfaces (51); filltype mat; material Water;} + topRightMajorGap { type simpleCell; id 73; surfaces (-56 -50); filltype mat; material Water;} + + bottomLeftCornerBaffle1 { type simpleCell; id 74; surfaces (-55 52 -53); filltype mat; material SS304;} + bottomLeftCornerBaffle2 { type simpleCell; id 75; surfaces (-55 54 -52); filltype mat; material SS304;} + bottomLeftCornerGap1 { type simpleCell; id 76; surfaces (55); filltype mat; material Water;} + bottomLeftCornerGap2 { type simpleCell; id 77; surfaces (53); filltype mat; material Water;} + bottomLeftMajorGap { type simpleCell; id 78; surfaces (-54 -52); filltype mat; material Water;} + + bottomRightCornerBaffle1 { type simpleCell; id 79; surfaces (-51 50 -55); filltype mat; material SS304;} + bottomRightCornerBaffle2 { type simpleCell; id 80; surfaces (-55 54 -50); filltype mat; material SS304;} + bottomRightCornerGap1 { type simpleCell; id 81; surfaces (51); filltype mat; material Water;} + bottomRightCornerGap2 { type simpleCell; id 82; surfaces (55); filltype mat; material Water;} + bottomRightMajorGap { type simpleCell; id 83; surfaces (-50 -54); filltype mat; material Water;} + + + TLSG1 { type simpleCell; id 84; surfaces (-56 -52); filltype mat; material Water;} + TLSG2 { type simpleCell; id 85; surfaces (-56 52); filltype mat; material Water;} + TLSG3 { type simpleCell; id 86; surfaces (56 -52); filltype mat; material Water;} + topLeftSquare { type simpleCell; id 87; surfaces (56 52); filltype mat; material SS304;} + + TRSG1 { type simpleCell; id 88; surfaces (-56 50); filltype mat; material Water;} + TRSG2 { type simpleCell; id 89; surfaces (-56 -50); filltype mat; material Water;} + TRSG3 { type simpleCell; id 90; surfaces (56 -50); filltype mat; material Water;} + topRightSquare { type simpleCell; id 91; surfaces (56 50); filltype mat; material SS304;} + + BLSG1 { type simpleCell; id 92; surfaces (54 -52); filltype mat; material Water;} + BLSG2 { type simpleCell; id 93; surfaces (-54 52); filltype mat; material Water;} + BLSG3 { type simpleCell; id 94; surfaces (-54 -52); filltype mat; material Water;} + bottomLeftSquare { type simpleCell; id 95; surfaces (54 52); filltype mat; material SS304;} + + BRSG1 { type simpleCell; id 96; surfaces (-54 50); filltype mat; material Water;} + BRSG2 { type simpleCell; id 97; surfaces (54 -50); filltype mat; material Water;} + BRSG3 { type simpleCell; id 98; surfaces (-54 -50); filltype mat; material Water;} + bottomRightSquare { type simpleCell; id 99; surfaces (54 50); filltype mat; material SS304;} + } + + universes { + root { id 1; type rootUniverse; border 1; fill u<8888>; } + + // Pin universes + + //Burnable poison + pinBPaboveDP { id 1000; type pinUniverse; radii (0.21400 0.23051 0.24130 0.42672 0.43688 0.48387 0.56134 0.60198 0.0); + fills (Air SS304 Helium BorosilicateGlass Helium SS304 Water Zircaloy Water);} + pinBPPlenumGeometry { id 1012; type pinUniverse; radii ( 0.21400 0.23051 0.43688 0.48387 0.50419 0.54610 0.0); + fills (Air SS304 Helium SS304 Water Zircaloy Water);} + + //guide tubes + pinGTaboveDP { id 12000; type pinUniverse; radii (0.56134 0.60198 0.0 ); fills (Water Zircaloy Water);} + pinGTatDP { id 1010; type pinUniverse; radii (0.50419 0.54610 0.0); fills (Water Zircaloy Water);} + + //INST Tube + pinIT { id 14000; type pinUniverse; radii (0.43688 0.48387 0.56134 0.60198 0.0 ); + fills (Air Zircaloy Water Zircaloy Water);} + pinBareInstrumentThimble { id 1011; type pinUniverse; radii (0.43688 0.48387 0.0); fills (Air Zircaloy Water);} + + // Fuel pins + pin16 { id 16000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + fills (UO2-16 Helium Zircaloy Water);} + pin24 { id 24000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + fills (UO2-24 Helium Zircaloy Water);} + pin31 { id 31000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + fills (UO2-31 Helium Zircaloy Water);} + // Higher enrichments not used + //pin32 { id 32000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + // fills (UO2-32 Helium Zircaloy Water);} + //pin34 { id 34000; type pinUniverse; radii (0.39218 0.40005 0.45720 0.0); + // fills (UO2-34 Helium Zircaloy Water);} + + pinWater { id 1001; type pinUniverse; radii ( 0.0); fills (Water);} + + + // Solid pins, assumed radius to be that of a fuel pin (0.45720) + pinNozzle_SupportSteel { id 1003; type pinUniverse; radii ( 0.45720 0.0); fills (SupportPlateSS Water);} + pinSupportPlateBW { id 1005; type pinUniverse; radii ( 0.45720 0.0); fills (SupportPlateBW Water);} + pinZircaloy { id 1006; type pinUniverse; radii ( 0.45720 0.0); fills (Zircaloy Water);} + + + SSinDashPot { id 1024; type pinUniverse; radii (0.50419 0.54610 0.0); fills (SS304 Zircaloy Water);} + SSinGuideTube { id 1023; type pinUniverse; radii ( 0.56134 0.60198 0.0); fills (SS304 Zircaloy Water);} + SSnoGuideTube { id 1002; type pinUniverse; radii ( 0.56134 0.0); fills (SS304 Water);} + + + pinUpperFuelPlenum { id 1008; type pinUniverse; radii ( 0.06459 0.40005 0.45720 0.0); + fills (Inconel Helium Zircaloy Water);} + + // Control rod pins + pinControlRodUpper { id 1013; type pinUniverse; radii ( 0.37338 0.38608 0.48387 0.56134 0.60198 0.0); + fills (B4C Helium SS304 Water Zircaloy Water);} + pinControlRodLower { id 1014; type pinUniverse; radii ( 0.38227 0.38608 0.48387 0.56134 0.60198 0.0); + fills (Ag-In-Cd Helium SS304 Water Zircaloy Water);} + pinControlRodSpacer { id 1015; type pinUniverse; radii ( 0.37845 0.38608 0.48387 0.56134 0.60198 0.0); + fills (SS304 Helium SS304 Water Zircaloy Water);} + pinControlRodPlenum { id 1016; type pinUniverse; radii ( 0.06459 0.38608 0.48387 0.56134 0.60198 0.0); + fills (Inconel Helium SS304 Water Zircaloy Water);} + + // pins that have grids + fuelRodPlenumWithGridThick { + id 1017; + type cellUniverse; + cells ( 259 555);} + + GTRodThick { + id 1018; + type cellUniverse; + cells (263 555);} + + dashPotGuideTubeGridThick { + id 1019; + type cellUniverse; + cells ( 258 555);} + + dashPotGuideTubeGridThin { + id 1020; + type cellUniverse; + cells ( 270 556);} + + SSinGuideTubeThick { + id 1021; + type cellUniverse; + cells ( 260 555);} + + SSinGuideTubeThin { + id 1022; + type cellUniverse; + cells ( 272 556);} + + SSinDashPotThick { + id 1025; + type cellUniverse; + cells ( 261 555);} + + SSinDashPotThin { + id 1026; + type cellUniverse; + cells ( 273 556);} + + BPPlenumThick { + id 1027; + type cellUniverse; + cells ( 262 555);} + + BPPlenumThin { + id 1028; + type cellUniverse; + cells ( 274 556);} + + BPaboveDPThin { + id 1110; + type cellUniverse; + cells (266 556);} + + GTThick { + id 1112; + type cellUniverse; + cells (254 555);} + + ITThick { + id 1114; + type cellUniverse; + cells (257 555);} + + pin16Thick { + id 1116; + type cellUniverse; + cells (256 555);} + + pin24Thick { + id 1124; + type cellUniverse; + cells (253 555);} + + pin31Thick { + id 1131; + type cellUniverse; + cells (255 555);} + + LowerRodGTThick { + id 1132; + type cellUniverse; + cells (263 555);} + + UpperRodGTThick { + id 1133; + type cellUniverse; + cells (463 555);} + + BPThin { // Is this necessary given 1110, BPaboveDPThin??? + id 9110; + type cellUniverse; + cells (266 556);} + + GTThin { + id 9112; + type cellUniverse; + cells (265 556);} + + ITThin { + id 9114; + type cellUniverse; + cells (269 556);} + + pin16Thin { + id 9216; + type cellUniverse; + cells (268 556);} + + pin24Thin { + id 9224; + type cellUniverse; + cells (264 556);} + + pin31Thin { + id 9231; + type cellUniverse; + cells (267 556);} + + LowerRodGTThin { + id 9232; + type cellUniverse; + cells (275 556);} + + UpperRodGTThin { + id 9233; + type cellUniverse; + cells (475 556);} + + // Axial stacks of universes to make up full pins + + // 3.1 % + fuelPin31 { + id 31; + type cellUniverse; + cells ( 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124);} + + // 2.4 % + fuelPin24 { + id 24; + type cellUniverse; + cells ( 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149);} + + //1.6 % + fuelPin16 { + id 16; + type cellUniverse; + cells ( 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174);} + + //burnable absorber + BP { + id 10; + type cellUniverse; + cells (218 219 220 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252);} + + // guide tube, with CR + GuideTubeRodded { + id 12; + type cellUniverse; + cells (175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197);} + + //control rod, fully retracted + GuideTubeEmpty { + id 13; + type cellUniverse; + cells (353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374);} + + //instr. tube + instrumentTube { + id 14; + type cellUniverse; + cells (198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217);} + + + // control rod, partially inserted + GuideTubePartial { + id 15; + type cellUniverse; + cells (375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399); + + } + + + + // Lattices w/o grid + // Names represent AE + A0E24 { + id 1424; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 12 24 24 12 24 24 12 24 24 24 24 24 + 24 24 24 12 24 24 24 24 24 24 24 24 24 12 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 12 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 14 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 12 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 12 24 24 24 24 24 24 24 24 24 12 24 24 24 + 24 24 24 24 24 12 24 24 12 24 24 12 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + // assembly with sleeves at different heights + A0E24Sleeve { + id 14240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2019 + );} + + + A0E16 { + id 1416; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 12 16 16 12 16 16 12 16 16 16 16 16 + 16 16 16 12 16 16 16 16 16 16 16 16 16 12 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 12 16 16 12 16 16 12 16 16 12 16 16 12 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 12 16 16 12 16 16 14 16 16 12 16 16 12 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 12 16 16 12 16 16 12 16 16 12 16 16 12 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 12 16 16 16 16 16 16 16 16 16 12 16 16 16 + 16 16 16 16 16 12 16 16 12 16 16 12 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } + + A0E16Sleeve { + id 14160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2020 + ); + } + + A0E31 { + id 1431; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A0E31Sleeve { + id 14310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2021 + ); + } + + + A6BE31B { + id 60316; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + + A6BE31BSleeve { + id 603160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2022 + ); + } + + A6BE31T { + id 603112; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31TSleeve { + id 6031120; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2023 + ); + } + + A6BE31R { + id 60313; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 10 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31RSleeve { + id 603130; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2024 + ); + } + + A6BE31L { + id 60319; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 14 31 31 12 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31LSleeve { + id 603190; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2025 + ); + } + + A15BE31BR { + id 15315; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BRSleeve { + id 153150; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2026 + ); + } + + A15BE31BL { + id 15317; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BLSleeve { + id 153170; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2027 + ); + } + + A15BE31TR { + id 15311; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 12 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TRSleeve { + id 153110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2028 + ); + } + + A15BE31TL { + id 153111; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 12 31 31 12 31 31 12 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 12 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 12 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 12 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TLSleeve { + id 1531110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2029 + ); + } + + A16BE31 { + id 1631; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 14 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 12 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A16BE31Sleeve { + id 16310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2030 + ); + } + + A20BE31 { + id 2031; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 12 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 12 31 31 14 31 31 12 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 12 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A20BE31Sleeve { + id 20310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2031 + ); + } + + A12BE24 { + id 1224; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 12 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 12 24 24 12 24 24 14 24 24 12 24 24 12 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 12 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A12BE24Sleeve { + id 12240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2032 + ); + } + + A16BE24 { + id 1624; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 14 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 12 24 24 12 24 24 12 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A16BE24Sleeve { + id 16240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2033 + ); + } + + // Unrodded assemblies + A0E24U { + id 2424; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 13 24 24 13 24 24 13 24 24 24 24 24 + 24 24 24 13 24 24 24 24 24 24 24 24 24 13 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 13 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 14 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 13 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 13 24 24 24 24 24 24 24 24 24 13 24 24 24 + 24 24 24 24 24 13 24 24 13 24 24 13 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A0E24USleeve { + id 24240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2034 + );} + + A0E16U { + id 2416; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 13 16 16 13 16 16 13 16 16 16 16 16 + 16 16 16 13 16 16 16 16 16 16 16 16 16 13 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 13 16 16 13 16 16 13 16 16 13 16 16 13 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 13 16 16 13 16 16 14 16 16 13 16 16 13 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 13 16 16 13 16 16 13 16 16 13 16 16 13 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 13 16 16 16 16 16 16 16 16 16 13 16 16 16 + 16 16 16 16 16 13 16 16 13 16 16 13 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } + + // sleeved + A0E16USleeve { + id 24160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2035 + ); + } + + A0E31U { + id 2431; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A0E31USleeve { + id 24310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2036 + ); + } + + + A6BE31BU { + id 70316; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + + A6BE31BUSleeve { + id 703160; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2037 + ); + } + + A6BE31TU { + id 703112; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31TUSleeve { + id 7031120; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2038 + ); + } + + A6BE31RU { + id 70313; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 10 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31RUSleeve { + id 703130; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2039 + ); + } + + A6BE31LU { + id 70319; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 14 31 31 13 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A6BE31LUSleeve { + id 703190; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2040 + ); + } + + A15BE31BRU { + id 25315; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BRUSleeve { + id 253150; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2041 + ); + } + + A15BE31BLU { + id 25317; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31BLUSleeve { + id 253170; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2042 + ); + } + + A15BE31TRU { + id 25311; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 14 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 10 31 31 10 31 31 13 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TRUSleeve { + id 253110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2043 + ); + } + + A15BE31TLU { + id 253111; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 13 31 31 13 31 31 13 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 13 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 14 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 13 31 31 10 31 31 10 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 13 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A15BE31TLUSleeve { + id 2531110; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2044 + ); + } + + A16BE31U { + id 2631; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 14 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 13 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A16BE31USleeve { + id 26310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2045 + ); + } + + A20BE31U { + id 3031; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 13 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 13 31 31 14 31 31 13 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 10 31 31 10 31 31 13 31 31 10 31 31 10 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 10 31 31 31 31 31 31 31 31 31 10 31 31 31 + 31 31 31 31 31 10 31 31 10 31 31 10 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 + 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 31 ); } + + A20BE31USleeve { + id 30310; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2046 + ); + } + + A12BE24U { + id 2224; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 13 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 13 24 24 13 24 24 14 24 24 13 24 24 13 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 13 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A12BE24USleeve { + id 22240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2047 + ); + } + + A16BE24U { + id 2624; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 14 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 10 24 24 13 24 24 13 24 24 13 24 24 10 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 10 24 24 24 24 24 24 24 24 24 10 24 24 24 + 24 24 24 24 24 10 24 24 10 24 24 10 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + A16BE24USleeve { + id 26240; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2048 + ); + } + + A0E24DBank { + id 1425; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 15 24 24 15 24 24 15 24 24 24 24 24 + 24 24 24 15 24 24 24 24 24 24 24 24 24 15 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 15 24 24 15 24 24 15 24 24 15 24 24 15 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 15 24 24 15 24 24 14 24 24 15 24 24 15 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 15 24 24 15 24 24 15 24 24 15 24 24 15 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 15 24 24 24 24 24 24 24 24 24 15 24 24 24 + 24 24 24 24 24 15 24 24 15 24 24 15 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 + 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 24 ); } + + // assembly with sleeves at different heights + A0E24SleeveDBank { + id 14250; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2049 + );} + + A0E16DBank { + id 1417; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (1.26 1.26 0.0); + shape (17 17 0); + padMat Water; + map ( + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 15 16 16 15 16 16 15 16 16 16 16 16 + 16 16 16 15 16 16 16 16 16 16 16 16 16 15 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 15 16 16 15 16 16 15 16 16 15 16 16 15 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 15 16 16 15 16 16 14 16 16 15 16 16 15 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 15 16 16 15 16 16 15 16 16 15 16 16 15 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 15 16 16 16 16 16 16 16 16 16 15 16 16 16 + 16 16 16 16 16 15 16 16 15 16 16 15 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 + 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16); } + + A0E16SleeveDBank { + id 14170; + type cellUniverse; + cells ( + 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 + 2016 2017 2018 2050 + ); + } + + + leftBaffleUni { + id 5222; + type cellUniverse; + cells (52 53 54);} + + + rightBaffleUni { + id 5223; + type cellUniverse; + cells (55 56 57);} + + topBaffleUni { + id 5224; + type cellUniverse; + cells (58 59 60);} + + bottomBaffleUni { + id 5225; + type cellUniverse; + cells (61 62 63);} + + + topLeft { + id 5226; + type cellUniverse; + cells (64 65 66 67 68);} + + topRight { + id 5227; + type cellUniverse; + cells ( 69 70 71 72 73);} + + BottomLeft { + id 5228; + type cellUniverse; + cells ( 74 75 76 77 78);} + + BottomRight { + id 5229; + type cellUniverse; + cells ( 79 80 81 82 83);} + + + SQTL { + id 1500; + type cellUniverse; + cells (84 85 86 87);} + + + SQTR { + id 1600; + type cellUniverse; + cells (88 89 90 91);} + + SQBL { + id 1700; + type cellUniverse; + cells (92 93 94 95);} + + SQBR { + id 1800; + type cellUniverse; + cells (96 97 98 99);} + + + latCore { + id 9999; + type latUniverse; + origin (0.0 0.0 0.0); + pitch (21.50364 21.50364 0.0); + shape (17 17 0); + padMat Water; + map ( + 1001 1001 1001 1001 1800 5224 5224 5224 5224 5224 5224 5224 1700 1001 1001 1001 1001 + 1001 1001 1800 5224 5229 24310 7031120 24310 7031120 24310 7031120 24310 5228 5224 1700 1001 1001 + 1001 1800 5229 24310 14310 26310 14160 30310 14160 30310 14160 26310 14310 24310 5228 1700 1001 + 1001 5222 24310 2531110 26240 14160 26240 14160 26240 14160 26240 14160 26240 25311 24310 5223 1001 + 1800 5229 14310 26240 14250 26240 24160 22240 14160 22240 24160 26240 14250 26240 14310 5228 1700 + 5222 24310 26310 14160 26240 24160 22240 24160 22240 24160 22240 24160 26240 14160 26310 24310 5223 + 5222 703190 14160 26240 24160 22240 14160 22240 14160 22240 14160 22240 24160 26240 14160 703130 5223 + 5222 24310 30310 14160 22240 24160 22240 24160 26240 24160 22240 24160 22240 14160 30310 24310 5223 + 5222 703190 14160 26240 14160 22240 14160 26240 14170 26240 14160 22240 14160 26240 14160 703130 5223 + 5222 24310 30310 14160 22240 24160 22240 24160 26240 24160 22240 24160 22240 14160 30310 24310 5223 + 5222 703190 14160 26240 24160 22240 14160 22240 14160 22240 14160 22240 24160 26240 14160 703130 5223 + 5222 24310 26310 14160 26240 24160 22240 24160 22240 24160 22240 24160 26240 14160 26310 24310 5223 + 1600 5227 14310 26240 14250 26240 24160 22240 14160 22240 24160 26240 14250 26240 14310 5226 1500 + 1001 5222 24310 253170 26240 14160 26240 14160 26240 14160 26240 14160 26240 253150 24310 5223 1001 + 1001 1600 5227 24310 14310 26310 14160 30310 14160 30310 14160 26310 14310 24310 5226 1500 1001 + 1001 1001 1600 5225 5227 24310 703160 24310 703160 24310 703160 24310 5226 5225 1500 1001 1001 + 1001 1001 1001 1001 1600 5225 5225 5225 5225 5225 5225 5225 1500 1001 1001 1001 1001 ); } + +! Note partial rodded assemblies end with a 1, i.e., 14170 and 14250 + + coreAndStructures { + id 8888; + type cellUniverse; + cells (7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23);} + + + + } +} + + +viz { + bmpZ { + type bmp; + output imgXY; + what material; + centre (0.0 0.0 232.0); + !width (50 50); + axis z; + res (2000 2000); + } + bmpYZ { + type bmp; + output imgYZ; + what material; + centre (0.0 0.0 232.0); + width (100.0 200.0); + axis x; + res (1000 2000); + } +} + + +nuclearData { + handles { + ce {type aceNeutronDatabase; aceLibrary $SCONE_ACE; ures 0; } + } + + materials { + + // Note that commented nuclide densities are included in the specification + // but are not available in the JEFF-3.11 data library + + Air { + temp 566; + composition { + 18036.06 7.8730E-09; + 18038.06 1.4844E-09; + 18040.06 2.3506E-06; + 6012.06 6.7539E-08; + //6013.06 7.5658E-10; + 7014.06 1.9680E-04; + 7015.06 7.2354E-07; + 8016.06 5.2866E-05; + 8017.06 2.0084E-08; + //8018.06 1.0601E-07; + } + } + + SS304 { + temp 566; + composition { + 24050.06 7.6778E-04; + 24052.06 1.4806E-02; + 24053.06 1.6789E-03; + 24054.06 4.1791E-04; + 26054.06 3.4620E-03; + 26056.06 5.4345E-02; + 26057.06 1.2551E-03; + 26058.06 1.6703E-04; + 25055.06 1.7604E-03; + 28058.06 5.6089E-03; + 28060.06 2.1605E-03; + 28061.06 9.3917E-05; + 28062.06 2.9945E-04; + 28064.06 7.6261E-05; + 14028.06 9.5281E-04; + 14029.06 4.8381E-05; + 14030.06 3.1893E-05; } + } + + Helium { + temp 566; + composition { + 2003.06 4.8089E-10; + 2004.06 2.4044E-04; } + } + + BorosilicateGlass { + temp 566; + composition { + 13027.06 1.7352E-03; + 5010.06 9.6506E-04; + 5011.06 3.9189E-03; + 8016.06 4.6514E-02; + 8017.06 1.7671E-05; + //8018.06 9.3268E-05; + 14028.06 1.6926E-02; + 14029.06 8.5944E-04; + 14030.06 5.6654E-04; } + } + + Water { + temp 566; + moder {1001.06 (lwj3.11 lwj3.09); } + composition { + 5010.06 7.9714E-06; + 5011.06 3.2247E-05; + 1001.06 4.9456E-02; + 1002.06 7.7035E-06; + 8016.06 2.4673E-02; + 8017.06 9.3734E-06; + //8018.06 4.9474E-05; + } + } + + Zircaloy { + temp 566; + composition { + 24050.06 3.2962E-06; + 24052.06 6.3564E-05; + 24053.06 7.2076E-06; + 24054.06 1.7941E-06; + 26054.06 8.6698E-06; + 26056.06 1.3610E-04; + 26057.06 3.1431E-06; + 26058.06 4.1829E-07; + 8016.06 3.0744E-04; + 8017.06 1.1680E-07; + //8018.03 6.1648E-07; + 50112.06 4.6735E-06; + 50114.06 3.1799E-06; + 50115.06 1.6381E-06; + 50116.06 7.0055E-05; + 50117.06 3.7003E-05; + 50118.06 1.1669E-04; + 50119.06 4.1387E-05; + 50120.06 1.5697E-04; + 50122.06 2.2308E-05; + 50124.06 2.7897E-05; + 40090.06 2.1828E-02; + 40091.06 4.7601E-03; + 40092.06 7.2759E-03; + 40094.06 7.3734E-03; + 40096.06 1.1879E-03; } + } + + Inconel{ + temp 566; + composition { + 24050.06 7.8239E-04; + 24052.06 1.5088E-02; + 24053.06 1.7108E-03; + 24054.06 4.2586E-04; + 26054.06 1.4797E-03; + 26056.06 2.3229E-02; + 26057.06 5.3645E-04; + 26058.06 7.1392E-05; + 25055.06 7.8201E-04; + 28058.06 2.9320E-02; + 28060.06 1.1294E-02; + 28061.06 4.9094E-04; + 28062.06 1.5653E-03; + 28064.06 3.9864E-04; + 14028.06 5.6757E-04; + 14029.06 2.8820E-05; + 14030.06 1.8998E-05; } + } + + B4C{ + temp 566; + composition { + 5010.06 1.5206E-02; + 5011.06 6.1514E-02; + 6012.06 1.8972E-02; + //6013.06 2.1252E-04; + } + } + + Ag-In-Cd{ + temp 566; + composition { + 47107.06 2.3523E-02; + 47109.06 2.1854E-02; + 48106.06 3.3882E-05; + 48108.06 2.4166E-05; + 48110.06 3.3936E-04; + 48111.06 3.4821E-04; + 48112.06 6.5611E-04; + 48113.06 3.3275E-04; + 48114.06 7.8252E-04; + 48116.06 2.0443E-04; + 49113.06 3.4219E-04; + 49115.06 7.6511E-03; } + } + + UO2-16 { + temp 566; + tms 1; + composition { + 8016.03 4.5897E-02; + 8017.03 1.7436E-05; + //8018.03 9.2032E-05; + 92234.03 3.0131E-06; + 92235.03 3.7503E-04; + 92238.03 2.2625E-02;} + } + + UO2-24 { + temp 566; + tms 1; + composition { + 8016.03 4.5830E-02; + 8017.03 1.7411E-05; + //8018.03 9.1898E-05; + 92234.03 4.4842E-06; + 92235.03 5.5814E-04; + 92238.03 2.2407E-02;} + } + + UO2-31 { + temp 566; + tms 1; + composition { + 8016.03 4.5853E-02; + 8017.03 1.7420E-05; + //8018.03 9.1942E-05; + 92234.03 5.7987E-06; + 92235.03 7.2175E-04; + 92238.03 2.2253E-02;} + } + + UO2-32 { + temp 566; + tms 1; + composition { + 8016.03 4.6029E-02; + 8017.03 1.7487E-05; + //8018.03 9.2296E-05; + 92234.03 5.9959E-06; + 92235.03 7.4630E-04; + 92238.03 2.2317E-02; + } + } + + UO2-34 { + temp 566; + tms 1; + composition { + 8016.03 4.6110E-02; + 8017.03 1.7517E-05; + //8018.03 9.2459E-05; + 92234.03 6.4018E-06; + 92235.03 7.9681E-04; + 92238.03 2.2307E-02;} + } + + // vanadium51 was stated twice in carbonsteel below + // in the beavrs pdf - typo? + CarbonSteel { + temp 566; + composition { + 13027.06 4.3523E-05; + 5010.06 2.5833E-06; + 5011.06 1.0450E-05; + 6012.06 1.0442E-03; + //6013.06 1.1697E-05 ; + 20040.06 1.7043E-05; + 20042.06 1.1375E-07; + 20043.06 2.3734E-08; + 20044.06 3.6673E-07; + 20046.06 7.0322E-10; + 20048.06 3.2875E-08; + 24050.06 1.3738E-05; + 24052.06 2.6493E-04; + 24053.06 3.0041E-05; + 24054.06 7.4778E-06; + 29063.06 1.0223E-04; + 29065.06 4.5608E-05; + 26054.06 4.7437E-03; + 26056.06 7.4465E-02; + 26057.06 1.7197E-03; + 26058.06 2.2886E-04; + 25055.06 6.4126E-04; + 42100.06 2.9814E-05; + 42092.06 4.4822E-05; + 42094.06 2.8110E-05; + 42095.06 4.8567E-05; + 42096.06 5.1015E-05; + 42097.06 2.9319E-05; + 42098.06 7.4327E-05; + 41093.06 5.0559E-06; + 28058.06 4.0862E-04; + 28060.06 1.5740E-04; + 28061.06 6.8420E-06; + 28062.06 2.1815E-05; + 28064.06 5.5557E-06; + 15031.06 3.7913E-05; + 16032.06 3.4808E-05; + 16033.06 2.7420E-07; + 16034.06 1.5368E-06; + 16036.06 5.3398E-09; + 14028.06 6.1702E-04; + 14029.06 3.1330E-05; + 14030.06 2.0653E-05; + 22046.06 1.2144E-06; + 22047.06 1.0952E-06; + 22048.06 1.0851E-05; + 22049.06 7.9634E-07; + 22050.06 7.6249E-07; + //23050.06 1.1526E-07; + 23051.06 4.5989E-05; + } + } + + SupportPlateSS { + temp 566; + composition { + 24050.06 3.5223E-04; + 24052.06 6.7924E-03; + 24053.06 7.7020E-04; + 24054.06 1.9172E-04; + 26054.06 1.5882E-03; + 26056.06 2.4931E-02; + 26057.06 5.7578E-04; + 26058.06 7.6625E-05; + 25055.06 8.0762E-04; + 28058.06 2.5731E-03; + 28060.06 9.9117E-04; + 28061.06 4.3085E-05; + 28062.06 1.3738E-04; + 28064.06 3.4985E-05; + 14028.06 4.3711E-04; + 14029.06 2.2195E-05; + 14030.06 1.4631E-05;} + } + + SupportPlateBW { + temp 566; + moder {1001.06 (lwj3.11 lwj3.09); } + composition { + 5010.06 1.0559E-05; + 5011.06 4.2716E-05; + 1001.06 6.5512E-02; + 1002.06 1.0204E-05; + 8016.06 3.2683E-02; + 8017.06 1.2416E-05; + //8018.06 6.5535E-05; + } + } + + +} +} diff --git a/Tallies/TallyMaps/CMakeLists.txt b/Tallies/TallyMaps/CMakeLists.txt index cf177fbe6..0ac9ee1d0 100644 --- a/Tallies/TallyMaps/CMakeLists.txt +++ b/Tallies/TallyMaps/CMakeLists.txt @@ -12,7 +12,7 @@ add_sources(./tallyMap_inter.f90 ./Maps1D/homogMatMap_class.f90 ./Maps1D/weightMap_class.f90 ./Maps1D/cellMap_class.f90 - ./Maps1D/radialMap_class.f90 + ./Maps1D/radialMap_class.f90 ./Maps1D/collNumMap_class.f90 ./Maps1D/directionMap_class.f90 ) diff --git a/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 b/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 index 89c0dcbf7..e48ca9284 100644 --- a/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 +++ b/Tallies/TallyMaps/Maps1D/Tests/spaceMap_test.f90 @@ -148,27 +148,6 @@ subroutine testUnstructuredGrid(this) @assertEqual(RES, idx) end subroutine testUnstructuredGrid - - !! - !! Test distance calculation - !! -@Test(testParameters={getParameters()}) - subroutine testDistance(this) - class(test_spaceMap), intent(inout) :: this - real(defReal),dimension(2),parameter :: POS = [0.5_defReal, -10.1_defReal] - real(defReal),dimension(2),parameter :: MU = [-0.01_defReal, 0.2_defReal] - real(defReal),dimension(2),parameter :: RES = [50.0_defReal, HALF] - real(defReal), dimension(2) :: d - type(particleState),dimension(2) :: states - real(defReal), parameter :: TOL = 1.0E-7 - - states % r(this % dir) = POS - states % dir(this % dir) = MU - d = this % map_unstruct % distance(states) - - @assertEqual(RES, d, TOL) - - end subroutine testDistance !! !! Test bin output diff --git a/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 b/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 index 0dc7ae8a9..b053a4e96 100644 --- a/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 +++ b/Tallies/TallyMaps/Maps1D/spaceMap_class.f90 @@ -62,7 +62,6 @@ module spaceMap_class procedure :: init procedure :: bins procedure :: map - procedure :: distance procedure :: getAxisName procedure :: print procedure :: kill @@ -220,46 +219,6 @@ elemental function map(self,state) result(idx) if (idx == valueOutsideArray) idx = 0 end function map - - !! - !! Compute particle's distance to boundary - !! - !! See tallyMap for specification - !! - elemental function distance(self, state) result(d) - class(spaceMap), intent(in) :: self - class(particleState), intent(in) :: state - real(defReal) :: d - integer(shortInt) :: idx - real(defReal) :: r, u, rMin, rMax, rNext - - d = INF - r = state % r(self % dir) - u = state % dir(self % dir) - idx = self % binBounds % search(r) - - ! Out of bounds: either above or below - if (idx == valueOutsideArray) then - rMin = self % binBounds % bin(1) - rMax = self % binBounds % bin(self % N + 1) - - if (r < rMin) then - if (u > ZERO) d = (rMin - r) / u - else - if (u < ZERO) d = (rMax - r) / u - end if - - ! In bounds: travelling left or right? - else - - if (u > ZERO) idx = idx + 1 - rNext = self % binBounds % bin(idx) - - d = (rNext - r) / u - - end if - - end function distance !! !! Return string that describes variable used to divide event space diff --git a/Tallies/TallyMaps/Tests/multiMap_test.f90 b/Tallies/TallyMaps/Tests/multiMap_test.f90 index 2c1c524cd..661e8607d 100644 --- a/Tallies/TallyMaps/Tests/multiMap_test.f90 +++ b/Tallies/TallyMaps/Tests/multiMap_test.f90 @@ -107,25 +107,6 @@ subroutine testMapping(this) end subroutine testMapping - !! - !! Test distance calculation - !! - subroutine testDistance(this) - class(test_multiMap), intent(inout) :: this - real(defReal),dimension(3),parameter :: POS = [1.3_defReal, 8.0_defReal, 0.1_defReal] - real(defReal),dimension(3),parameter :: MU = [HALF, -ONE, -TWO] - real(defReal),parameter :: RES = 1.4_defReal - real(defReal) :: d - type(particleState) :: state - real(defReal), parameter :: TOL = 1.0E-7 - - state % r = POS - state % dir = MU - d = this % map % distance(state) - - @assertEqual(RES, d, TOL) - - end subroutine testDistance diff --git a/Tallies/TallyMaps/multiMap_class.f90 b/Tallies/TallyMaps/multiMap_class.f90 index 3a1eaf43a..a29c220db 100644 --- a/Tallies/TallyMaps/multiMap_class.f90 +++ b/Tallies/TallyMaps/multiMap_class.f90 @@ -1,11 +1,10 @@ module multiMap_class use numPrecision - use universalVariables, only : INF - use genericProcedures, only : fatalError - use dictionary_class, only : dictionary - use outputFile_class, only : outputFile - use particle_class, only : particleState + use genericProcedures, only : fatalError + use dictionary_class, only : dictionary + use outputFile_class, only : outputFile + use particle_class, only : particleState use tallyMap_inter, only : tallyMap use tallyMap1D_inter, only : tallyMap1D @@ -53,7 +52,6 @@ module multiMap_class procedure :: dimensions procedure :: getAxisName procedure :: map - procedure :: distance procedure :: print procedure :: kill end type multiMap @@ -173,27 +171,6 @@ elemental function map(self, state) result(idx) end do end function map - - !! - !! Compute particle's distance to boundary - !! - !! See tallyMap for specification - !! - elemental function distance(self, state) result(d) - class(multiMap), intent(in) :: self - class(particleState), intent(in) :: state - real(defReal) :: d - integer(shortInt) :: i - real(defReal) :: d0 - - d = INF - - do i = 1, size(self % maps) - d0 = self % maps(i) % slot % distance(state) - d = min(d, d0) - end do - - end function distance !! !! Add information about division axis to the output file diff --git a/Tallies/TallyMaps/tallyMap_inter.f90 b/Tallies/TallyMaps/tallyMap_inter.f90 index 62f1b0dc7..849c5bb5e 100644 --- a/Tallies/TallyMaps/tallyMap_inter.f90 +++ b/Tallies/TallyMaps/tallyMap_inter.f90 @@ -1,10 +1,9 @@ module tallyMap_inter use numPrecision - use universalVariables, only : INF - use particle_class, only : particleState - use dictionary_class, only : dictionary - use outputFile_class, only : outputFile + use particle_class, only : particleState + use dictionary_class, only : dictionary + use outputFile_class, only : outputFile implicit none private @@ -33,14 +32,13 @@ module tallyMap_inter procedure(getAxisName),deferred :: getAxisName procedure :: binArrayShape procedure(map),deferred :: map - procedure :: distance procedure(print),deferred :: print procedure :: kill end type tallyMap ! Procedures extendable in subclasses public :: kill - public :: distance + abstract interface @@ -180,27 +178,6 @@ elemental subroutine kill(self) end subroutine kill - !! - !! Returns distance to tally map bounds in space - !! - !! Args: - !! particleState - !! - !! Result: - !! distance to nearest spatial tally boundary - !! - !! NOTE: - !! For certain maps, this is nonsensical. These should not overwrite - !! this distance. - !! - elemental function distance(self, state) result(d) - class(tallyMap), intent(in) :: self - class(particleState), intent(in) :: state - real(defReal) :: d - - d = INF - - end function distance end module tallyMap_inter From a3247d42bcc068b84c7c0ca693e74aa66e5233e9 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Tue, 5 Aug 2025 13:34:39 +0100 Subject: [PATCH 08/27] First changes, not complete --- Geometry/geometryStd_class.f90 | 89 ++++++++++++++- Geometry/geometry_inter.f90 | 36 ++++++ .../aceDatabase/aceNeutronDatabase_class.f90 | 107 ++++++++++++++---- .../ceNeutronData/ceNeutronDatabase_inter.f90 | 36 ++++-- ParticleObjects/particle_class.f90 | 6 + SharedModules/universalVariables.f90 | 10 +- .../transportOperatorDT_class.f90 | 4 + .../transportOperatorHT_class.f90 | 12 +- .../transportOperatorST_class.f90 | 5 + 9 files changed, 263 insertions(+), 42 deletions(-) diff --git a/Geometry/geometryStd_class.f90 b/Geometry/geometryStd_class.f90 index 49fb71230..e053b1554 100644 --- a/Geometry/geometryStd_class.f90 +++ b/Geometry/geometryStd_class.f90 @@ -37,18 +37,22 @@ module geometryStd_class !! Sample Dictionary Input: !! geometry { !! type geometryStd; - !! + !! !! } !! !! Public Members: !! geom -> Representation of geometry by csg_class. Contains all surfaces, cells and universe !! as well as geometry graph and info about root uni and boundary surface. + !! temperatureField -> Field of temperatures overlaid on the geometry + !! densityField -> Field of densities overlaid on the geometry !! !! Interface: !! Geometry Interface !! type, public, extends(geometry) :: geometryStd type(csg) :: geom + class(pieceConstField), allocatable :: temperatureField + class(pieceConstField), allocatable :: densityField contains ! Superclass procedures @@ -62,6 +66,8 @@ module geometryStd_class procedure :: moveGlobal procedure :: teleport procedure :: activeMats + procedure :: getTemperature + procedure :: getDensity ! Private procedures procedure, private :: diveToMat @@ -81,10 +87,24 @@ subroutine init(self, dict, mats, silent) class(dictionary), intent(in) :: dict type(charMap), intent(in) :: mats logical(defBool), optional, intent(in) :: silent + class(dictionary), pointer :: tempDict ! Build the representation call self % geom % init(dict, mats, silent) + ! If present, build temperature and density fields + if (dict % isPresent('temperature')) then + tempDict => dict % getDictPtr('temperature') + allocate(self % temperatureField) + call self % temperatureField % init(tempDict) + end if + + if (dict % isPresent('density')) then + tempDict => dict % getDictPtr('density') + allocate(self % densityField) + call self % densityField % init(tempDict) + end if + end subroutine init !! @@ -94,6 +114,14 @@ elemental subroutine kill(self) class(geometryStd), intent(inout) :: self call self % geom % kill() + if allocated(self % temperatureField) then + call self % temperatureField % kill() + deallocate(self % temperatureField) + end if + if allocated(self % densityField) then + call self % densityField % kill() + deallocate(self % densityField) + end if end subroutine kill @@ -206,11 +234,20 @@ subroutine move_noCache(self, coords, maxDist, event) real(defReal) :: dist class(surface), pointer :: surf class(universe), pointer :: uni - character(100), parameter :: Here = 'move (geometryStd_class.f90)' + character(100), parameter :: Here = 'move_noCache (geometryStd_class.f90)' if (.not.coords % isPlaced()) then call fatalError(Here, 'Coordinate list is not placed in the geometry') end if + + ! Check fields + if (allocated(self % temperatureField)) then + maxDist = min(maxDist, self % temperatureField % distance(coords)) + end if + + if (allocated(self % densityField)) then + maxDist = min(maxDist, self % densityField % distance(coords)) + end if ! Find distance to the next surface call self % closestDist(dist, surfIdx, level, coords) @@ -248,6 +285,7 @@ subroutine move_noCache(self, coords, maxDist, event) end if + end subroutine move_noCache !! @@ -272,6 +310,15 @@ subroutine move_withCache(self, coords, maxDist, event, cache) if (.not.coords % isPlaced()) then call fatalError(Here, 'Coordinate list is not placed in the geometry') end if + + ! Check fields + if (allocated(self % temperatureField)) then + maxDist = min(maxDist, self % temperatureField % distance(coords)) + end if + + if (allocated(self % densityField)) then + maxDist = min(maxDist, self % densityField % distance(coords)) + end if ! Find distance to the next surface call self % closestDist_cache(dist, surfIdx, level, coords, cache) @@ -583,6 +630,44 @@ subroutine closestDist_cache(self, dist, surfIdx, lvl, coords, cache) end do end subroutine closestDist_cache + !! + !! Returns the local temperature, provided the temperatureField + !! has been allocated + !! + !! See geometry_inter for details + !! + function getTemperature(self, coords) result(T) + class(geometryStd), intent(in) :: self + type(coordList), intent(in) :: coords + real(defReal) :: T + + if (allocated(self % temperatureField)) then + T = self % temperatureField % at(coords) + else + T = -INF + end if + + end function getTemperature + + !! + !! Returns the local density, provided the densityField + !! has been allocated + !! + !! See geometry_inter for details + !! + function getDensity(self, coords) result(rho) + class(geometryStd), intent(in) :: self + type(coordList), intent(in) :: coords + real(defReal) :: rho + + if (allocated(self % densityField)) then + rho = self % densityField % at(coords) + else + rho = -INF + end if + + end function getDensity + !! !! Cast geometry pointer to geometryStd class pointer !! diff --git a/Geometry/geometry_inter.f90 b/Geometry/geometry_inter.f90 index 973007549..e68ebfcc2 100644 --- a/Geometry/geometry_inter.f90 +++ b/Geometry/geometry_inter.f90 @@ -43,6 +43,8 @@ module geometry_inter procedure(moveGlobal), deferred :: moveGlobal procedure(teleport), deferred :: teleport procedure(activeMats), deferred :: activeMats + procedure(getTemperature), deferred :: getTemperature + procedure(getDensity), deferred :: getDensity ! Common procedures procedure :: slicePlot @@ -262,6 +264,40 @@ function activeMats(self) result(matList) integer(shortInt), dimension(:), allocatable :: matList end function activeMats + !! + !! Returns the temperature at a position in space. + !! + !! Args: + !! coords + !! + !! Result: + !! Temperature at a given location. If this information has not been provided + !! to the geometry then a default result should be returned. + !! + function getTemperature(self, coords) result(T) + import :: geometry, coordList, defReal + class(geometry), intent(in) :: self + type(coordList), intent(in) :: coords + real(defReal) :: T + end function getTemperature + + !! + !! Returns the density at a position in space. + !! + !! Args: + !! coords + !! + !! Result: + !! Density at a given location. If this information has not been provided + !! to the geometry then a default result should be returned. + !! + function getDensity(self, coords) result(rho) + import :: geometry, coordList, defReal + class(geometry), intent(in) :: self + type(coordList), intent(in) :: coords + real(defReal) :: rho + end function getDensity + end interface contains diff --git a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 index afcf57989..2fb5762e8 100644 --- a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 +++ b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 @@ -364,25 +364,29 @@ end subroutine updateMajorantXS !! !! See ceNeutronDatabase for more details !! - subroutine updateTrackMatXS(self, E, matIdx, rand) + subroutine updateTrackMatXS(self, E, matIdx, rand, temp, rho) class(aceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx class(RNG), optional, intent(inout) :: rand + real(defReal), optional, intent(in) :: temp + real(defReal), optional, intent(in) :: rho associate (matCache => cache_materialCache(matIdx), & mat => self % materials(matIdx)) - ! Set new energy + ! Set new energy, temperature, and density factor matCache % E_track = E + if (present(temp)) then matCache % T_track = temp + if (present(rho)) then matCache % rho_track = rho if (mat % useTMS(E)) then ! The material tracking xs is the temperature majorant in the case of TMS - call self % updateTotalTempMajXS(E, matIdx) + call self % updateTotalTempMajXS(E, matIdx, temp, rho) else ! When TMS is not in use, the material tracking xs is equivalent to the total - call self % updateTotalMatXS(E, matIdx, rand) + call self % updateTotalMatXS(E, matIdx, temp, rho, rand) matCache % trackXS = matCache % xss % total end if @@ -402,12 +406,14 @@ end subroutine updateTrackMatXS !! E [in] -> Incident neutron energy for which temperature majorant is found !! matIdx [in] -> Index of material for which the material temperature majorant is found !! - subroutine updateTotalTempMajXS(self, E, matIdx) + subroutine updateTotalTempMajXS(self, E, matIdx, temp, rho) class(aceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho integer(shortInt) :: nucIdx, i - real(defReal) :: dens, corrFact, nucTempMaj + real(defReal) :: kT, dens, corrFact, nucTempMaj associate (matCache => cache_materialCache(matIdx), & mat => self % materials(matIdx)) @@ -415,6 +421,13 @@ subroutine updateTotalTempMajXS(self, E, matIdx) ! Clean current total XS matCache % trackXS = ZERO + ! Use imposed temperature if given + if (temp <= ZERO) + kT = mat % kT + else + kT = temp * kBoltzmannMeV + end if + ! loop through all nuclides in material and find sum of majorants do i = 1, size(mat % nuclides) @@ -422,7 +435,7 @@ subroutine updateTotalTempMajXS(self, E, matIdx) nucIdx = mat % nuclides(i) dens = mat % dens(i) - call self % updateTotalTempNucXS(E, mat % kT, nucIdx) + call self % updateTotalTempNucXS(E, kT, nucIdx) ! Sum nuclide majorants to find material majorant corrFact = cache_nuclideCache(nucIdx) % doppCorr @@ -431,6 +444,14 @@ subroutine updateTotalTempMajXS(self, E, matIdx) end do + ! Use imposed density scaling if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if + matCache % trackXS = matCache % trackXS * densityFactor + end associate end subroutine updateTotalTempMajXS @@ -441,13 +462,15 @@ end subroutine updateTotalTempMajXS !! !! See ceNeutronDatabase for more details !! - subroutine updateTotalMatXS(self, E, matIdx, rand) + subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) class(aceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), optional, intent(inout) :: rand integer(shortInt) :: i, nucIdx - real(defReal) :: dens + real(defReal) :: dens, kT, densityFactor associate (matCache => cache_materialCache(matIdx), & mat => self % materials(matIdx)) @@ -455,12 +478,28 @@ subroutine updateTotalMatXS(self, E, matIdx, rand) ! Set new energy and clean current total XS matCache % E_tot = E matCache % xss % total = ZERO + matCache % T = temp + matCache % rho = rho + + ! Use imposed temperature if given + if (temp <= ZERO) + kT = mat % kT + else + kT = temp * kBoltzmannMeV + end if + + ! Use imposed density scaling if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if if (mat % useTMS(E)) then ! When TMS is in use, the total xs is retrieved sampling the nuclides' relative ! energies given the temperature difference between material temperature and ! temperature of the nuclides' base cross sections - call self % updateRelEnMacroXSs(E, matIdx, rand) + call self % updateRelEnMacroXSs(E, matIdx, rand, kT, densityFactor) else ! Construct total macro XS @@ -470,13 +509,15 @@ subroutine updateTotalMatXS(self, E, matIdx, rand) ! Update if needed if (cache_nuclideCache(nucIdx) % E_tot /= E) then - call self % updateTotalNucXS(E, nucIdx, mat % kT, rand) + call self % updateTotalNucXS(E, nucIdx, kT, rand) end if ! Add microscopic XSs matCache % xss % total = matCache % xss % total + & dens * cache_nuclideCache(nucIdx) % xss % total end do + + matCache % xss % total = matCache % xss % total * densityFactor end if @@ -490,25 +531,41 @@ end subroutine updateTotalMatXS !! !! See ceNeutronDatabase for more details !! - subroutine updateMacroXSs(self, E, matIdx, rand) + subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) class(aceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), optional, intent(inout) :: rand integer(shortInt) :: i, nucIdx - real(defReal) :: dens + real(defReal) :: dens, kT, densityFactor associate(mat => self % materials(matIdx), & matCache => cache_materialCache(matIdx)) ! Clean current xss call matCache % xss % clean() + + ! Use imposed temperature if given + if (temp <= ZERO) + kT = mat % kT + else + kT = temp * kBoltzmannMeV + end if + + ! Use imposed density scaling if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if if (mat % useTMS(E)) then ! When TMS is in use, the xss are retrieved sampling the nuclides' relative ! energies given the temperature difference between material temperature and ! temperature of the nuclides' base cross sections - call self % updateRelEnMacroXSs(E, matIdx, rand) + call self % updateRelEnMacroXSs(E, matIdx, rand, kT, densityFactor) else @@ -523,11 +580,11 @@ subroutine updateMacroXSs(self, E, matIdx, rand) ! Update if needed if (cache_nuclideCache(nucIdx) % E_tail /= E .or. cache_nuclideCache(nucIdx) % E_tot /= E) then - call self % updateMicroXSs(E, nucIdx, mat % kT, rand) + call self % updateMicroXSs(E, nucIdx, kT, rand) end if ! Add microscopic XSs - call matCache % xss % add(cache_nuclideCache(nucIdx) % xss, dens) + call matCache % xss % add(cache_nuclideCache(nucIdx) % xss, dens * densityFactor) end do end if @@ -545,11 +602,13 @@ end subroutine updateMacroXSs !! E [in] -> Incident neutron energy for which the relative energy xss are found !! matIdx [in] -> Index of material for which the relative energy xss are found !! - subroutine updateRelEnMacroXSs(self, E, matIdx, rand) + subroutine updateRelEnMacroXSs(self, E, matIdx, rand, kT, densityFactor) class(aceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx class(RNG), optional, intent(inout) :: rand + real(defReal), intent(in) :: kT + real(defReal), intent(in) :: densityFactor integer(shortInt) :: i, nucIdx real(defReal) :: dens, nuckT, A, deltakT, eRel, eMin, & eMax, doppCorr @@ -572,7 +631,7 @@ subroutine updateRelEnMacroXSs(self, E, matIdx, rand) nucIdx = mat % nuclides(i) nuckT = self % nuclides(nucIdx) % getkT() A = self % nuclides(nucIdx) % getMass() - deltakT = mat % kT - nuckT + deltakT = kT - nuckT eRel = relativeEnergy_constXS(E, A, deltakT, rand) @@ -590,11 +649,11 @@ subroutine updateRelEnMacroXSs(self, E, matIdx, rand) ! Update if needed if (nucCache % E_tail /= eRel .or. nucCache % E_tot /= eRel) then - call self % updateMicroXSs(eRel, nucIdx, mat % kT, rand) + call self % updateMicroXSs(eRel, nucIdx, kT, rand) end if ! Add microscopic XSs - call matCache % xssRel % add(nucCache % xss, dens * doppCorr) + call matCache % xssRel % add(nucCache % xss, dens * doppCorr * densityFactor) end associate @@ -941,12 +1000,12 @@ subroutine init(self, dict, ptr, silent ) ! is bounded by Sab temperatures if (mat % nuclides(j) % sabMix) then sabT = self % nuclides(nucIdxs(j)) % getSabTBounds() - kT = mat % T * kBoltzmann / joulesPerMeV + kT = mat % T * kBoltzmannMev if ((kT < sabT(1)) .or. (kT > sabT(2))) call fatalError(Here,& 'Material temperature must be bounded by the provided S(alpha,beta) data. '//& - 'The material temperature is '//numToChar(kT * joulesPerMeV / kBoltzmann)//& - 'K while the data bounds are '//numToChar(sabT(1) * joulesPerMeV / kBoltzmann)//& - 'K and '//numToChar(sabT(2) * joulesPerMeV / kBoltzmann)//'K.') + 'The material temperature is '//numToChar(kT * / kBoltzmannMeV)//& + 'K while the data bounds are '//numToChar(sabT(1) * / kBoltzmannMeV)//& + 'K and '//numToChar(sabT(2) / kBoltzmannMeV)//'K.') end if end do diff --git a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 index afff78c01..16b509d65 100644 --- a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 +++ b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 @@ -67,7 +67,7 @@ module ceNeutronDatabase_inter procedure(updateTotalMatXS), deferred :: updateTrackMatXS procedure(updateTotalMatXS), deferred :: updateTotalMatXS procedure(updateMacroXSs), deferred :: updateMacroXSs - procedure(updateTotalXS), deferred :: updateTotalNucXS + procedure(updateTotalNucXS), deferred :: updateTotalNucXS procedure(updateMicroXSs), deferred :: updateMicroXSs procedure(updateTotalTempNucXS), deferred :: updateTotalTempNucXS procedure(energyBounds), deferred :: energyBounds @@ -131,11 +131,13 @@ end subroutine updateTrackMatXS !! matIdx [in] -> material index that needs to be updated !! rand [inout] -> random number generator !! - subroutine updateTotalMatXS(self, E, matIdx, rand) + subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) import :: ceNeutronDatabase, defReal, shortInt, RNG class(ceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), optional, intent(inout) :: rand end subroutine updateTotalMatXS @@ -173,11 +175,13 @@ end subroutine updateMajorantXS !! matIdx [in] -> material index that needs to be updated !! rand [inout] -> random number generator !! - subroutine updateMacroXSs(self, E, matIdx, rand) + subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) import :: ceNeutronDatabase, defReal, shortInt, RNG class(ceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), optional, intent(inout) :: rand end subroutine updateMacroXSs @@ -196,14 +200,14 @@ end subroutine updateMacroXSs !! kT [in] -> thermal energy of material [MeV] !! rand [inout] -> random number generator !! - subroutine updateTotalXS(self, E, nucIdx, kT, rand) + subroutine updateTotalNucXS(self, E, nucIdx, kT, rand) import :: ceNeutronDatabase, defReal, shortInt, RNG class(ceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: nucIdx real(defReal), intent(in) :: kT class(RNG), optional, intent(inout) :: rand - end subroutine updateTotalXS + end subroutine updateTotalNucXS !! !! Make sure that the microscopic XSs for the nuclide with nucIdx are set @@ -309,7 +313,9 @@ function getTrackingXS(self, p, matIdx, what) result(xs) case (TRACKING_XS) ! READ ONLY - read from previously updated cache - if (p % E == trackingCache(1) % E) then + if (p % E == trackingCache(1) % E .and. & + p % T == trackingCache(1) % T .and. & + p % rho == trackingCache(1) % rho) then xs = trackingCache(1) % xs return else @@ -322,8 +328,10 @@ function getTrackingXS(self, p, matIdx, what) result(xs) end select ! Update Cache - trackingCache(1) % E = p % E - trackingCache(1) % xs = xs + trackingCache(1) % E = p % E + trackingCache(1) % T = p % T + trackingCache(1) % rho = p % rho + trackingCache(1) % xs = xs end function getTrackingXS @@ -358,7 +366,11 @@ function getTrackMatXS(self, p, matIdx) result(xs) end if ! Check Cache and update if needed - if (materialCache(matIdx) % E_track /= p % E) call self % updateTrackMatXS(p % E, matIdx, p % pRNG) + if (materialCache(matIdx) % E_track /= p % E .or. & + materialCache(matIdx) % T_track /= p % T .or. & + materialCache(matIdx) % rho_track /= p % rho) then + call self % updateTrackMatXS(p % E, matIdx, p % pRNG, p % T, p % rho) + end if ! Return Cross-Section xs = materialCache(matIdx) % trackXS @@ -393,7 +405,11 @@ function getTotalMatXS(self, p, matIdx) result(xs) end if ! Check Cache and update if needed - if (materialCache(matIdx) % E_tot /= p % E) call self % updateTotalMatXS(p % E, matIdx, p % pRNG) + if (materialCache(matIdx) % E_tot /= p % E .or. & + materialCache(matIdx) % T_tot /= p % T .or. & + materialCache(matIdx) % rho_tot /= p % rho) then + call self % updateTotalMatXS(p % E, matIdx, p % pRNG, p % T, p % rho) + end if ! Return Cross-Section xs = materialCache(matIdx) % xss % total diff --git a/ParticleObjects/particle_class.f90 b/ParticleObjects/particle_class.f90 index f5b21c484..5914a5b55 100644 --- a/ParticleObjects/particle_class.f90 +++ b/ParticleObjects/particle_class.f90 @@ -97,6 +97,10 @@ module particle_class real(defReal) :: w ! Particle Weight real(defReal) :: time ! Particle time point + ! Information passed from geometry + real(defReal) :: T = -INF ! Local temperature + real(defReal) :: rho = -INF ! Local density scaling + ! Particle flags real(defReal) :: w0 ! Particle initial weight (for implicit, variance reduction...) logical(defBool) :: isDead @@ -727,6 +731,8 @@ elemental subroutine kill_particleState(self) self % uniqueID = -1 self % collisionN = 0 self % broodID = 0 + self % T = -INF + self % rho = -INF end subroutine kill_particleState diff --git a/SharedModules/universalVariables.f90 b/SharedModules/universalVariables.f90 index f80847173..04d4b61ec 100644 --- a/SharedModules/universalVariables.f90 +++ b/SharedModules/universalVariables.f90 @@ -75,17 +75,19 @@ module universalVariables integer(shortInt), parameter :: MATERIAL_XS = 1, & MAJORANT_XS = 2, & TRACKING_XS = 3 + + ! Unit conversion + real(defReal), parameter :: joulesPerMeV = 1.60218e-13 ,& ! Convert MeV to J + shakesPerS = 1.0e-8 ! Convert shakes to s ! Physical constants ! Neutron mass and speed of light in vacuum from from https://physics.nist.gov/cuu/Constants/index.html real(defReal), parameter :: neutronMass = 939.56542194_defReal, & ! Neutron mass in MeV (m*c^2) lightSpeed = 2.99792458e10_defReal, & ! Light speed in cm/s kBoltzmann = 1.380649e-23_defReal, & ! Bolztmann constant in J/K - energyPerFission = 200.0_defReal ! MeV + energyPerFission = 200.0_defReal, & ! MeV + kBoltzmannMeV = kBoltzmann / joulesPerMeV - ! Unit conversion - real(defReal), parameter :: joulesPerMeV = 1.60218e-13 ,& ! Convert MeV to J - shakesPerS = 1.0e-8 ! Convert shakes to s ! Global name variables used to define specific geometry or field types character(nameLen), parameter :: nameUFS = 'uniFissSites' diff --git a/TransportOperator/transportOperatorDT_class.f90 b/TransportOperator/transportOperatorDT_class.f90 index f07b4808e..edf81f3c0 100644 --- a/TransportOperator/transportOperatorDT_class.f90 +++ b/TransportOperator/transportOperatorDT_class.f90 @@ -93,6 +93,10 @@ subroutine deltaTracking(self, p, tally, thisCycle, nextCycle) end select + ! Get local conditions + p % T = self % geom % getTemperature(p % coords) + p % rho = self % geom % getDensity(p % coords) + ! Obtain the local cross-section sigmaT = self % xsData % getTrackMatXS(p, p % matIdx()) diff --git a/TransportOperator/transportOperatorHT_class.f90 b/TransportOperator/transportOperatorHT_class.f90 index 7cab0395f..54f3a8999 100644 --- a/TransportOperator/transportOperatorHT_class.f90 +++ b/TransportOperator/transportOperatorHT_class.f90 @@ -108,7 +108,6 @@ subroutine deltaTracking(self, p, tally, thisCycle, nextCycle) p % isDead = .true. return - ! Check for void case(VOID_MAT) call tally % reportInColl(p, .true.) @@ -129,6 +128,10 @@ subroutine deltaTracking(self, p, tally, thisCycle, nextCycle) end select + ! Get local conditions + p % T = self % geom % getTemperature(p % coords) + p % rho = self % geom % getDensity(p % coords) + ! Obtain the local cross-section sigmaT = self % xsData % getTrackMatXS(p, p % matIdx()) @@ -166,6 +169,11 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) dist = INFINITY else + + ! Get local conditions + p % T = self % geom % getTemperature(p % coords) + p % rho = self % geom % getDensity(p % coords) + sigmaT = self % xsData % getTrackingXS(p, p % matIdx(), MATERIAL_XS) dist = -log( p % pRNG % get()) / sigmaT @@ -177,7 +185,7 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) ! Save state before movement call p % savePrePath() - ! Move to the next stop. NOTE: "move" resets dist to distanced moved! + ! Move to the next stop. NOTE: "move" resets dist to distance moved! call self % geom % move(p % coords, dist, event) ! Send tally report for a path moved diff --git a/TransportOperator/transportOperatorST_class.f90 b/TransportOperator/transportOperatorST_class.f90 index fb7e1dbbb..237b11e99 100644 --- a/TransportOperator/transportOperatorST_class.f90 +++ b/TransportOperator/transportOperatorST_class.f90 @@ -63,6 +63,11 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) dist = INFINITY else + + ! Get local conditions + p % T = self % geom % getTemperature(p % coords) + p % rho = self % geom % getDensity(p % coords) + sigmaT = self % xsData % getTrackingXS(p, p % matIdx(), MATERIAL_XS) dist = -log( p % pRNG % get()) / sigmaT From 187136442969c3f598a1044c87867901b3385842 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Tue, 12 Aug 2025 12:26:52 +0100 Subject: [PATCH 09/27] Tweaks to data --- DataStructures/linkedList_class.f90 | 1 - .../aceDatabase/aceNeutronDatabase_class.f90 | 44 ++++-- .../ceNeutronData/ceNeutronCache_mod.f90 | 14 +- .../ceNeutronData/ceNeutronDatabase_inter.f90 | 8 +- .../ceNeutronData/ceNeutronMaterial_class.f90 | 136 ++++++++++++++---- .../baseMgNeutronDatabase_class.f90 | 22 ++- NuclearData/nuclearDatabase_inter.f90 | 16 +++ ParticleObjects/particle_class.f90 | 2 - 8 files changed, 186 insertions(+), 57 deletions(-) diff --git a/DataStructures/linkedList_class.f90 b/DataStructures/linkedList_class.f90 index 4a242f2ed..6a4d7b71a 100644 --- a/DataStructures/linkedList_class.f90 +++ b/DataStructures/linkedList_class.f90 @@ -147,7 +147,6 @@ end function get_shortInt !! subroutine kill_shortInt(self) class(linkedIntList), intent(inout) :: self - integer(shortInt) :: i class(intNode), pointer :: resNode ! Traverse the list and nullify pointers diff --git a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 index 2fb5762e8..d5885083c 100644 --- a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 +++ b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 @@ -101,6 +101,7 @@ module aceNeutronDatabase_class procedure :: getReaction procedure :: init procedure :: activate + procedure :: initMajorant ! ceNeutronDatabase Procedures procedure :: energyBounds @@ -116,7 +117,6 @@ module aceNeutronDatabase_class ! class Procedures procedure :: initUrr procedure :: initDBRC - procedure :: initMajorant procedure :: updateTotalTempMajXS procedure :: updateRelEnMacroXSs procedure :: makeNuclideName @@ -364,13 +364,13 @@ end subroutine updateMajorantXS !! !! See ceNeutronDatabase for more details !! - subroutine updateTrackMatXS(self, E, matIdx, rand, temp, rho) + subroutine updateTrackMatXS(self, E, matIdx, temp, rho, rand) class(aceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx - class(RNG), optional, intent(inout) :: rand real(defReal), optional, intent(in) :: temp real(defReal), optional, intent(in) :: rho + class(RNG), optional, intent(inout) :: rand associate (matCache => cache_materialCache(matIdx), & mat => self % materials(matIdx)) @@ -499,7 +499,7 @@ subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) ! When TMS is in use, the total xs is retrieved sampling the nuclides' relative ! energies given the temperature difference between material temperature and ! temperature of the nuclides' base cross sections - call self % updateRelEnMacroXSs(E, matIdx, rand, kT, densityFactor) + call self % updateRelEnMacroXSs(E, matIdx, kT, densityFactor, rand) else ! Construct total macro XS @@ -565,7 +565,7 @@ subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) ! When TMS is in use, the xss are retrieved sampling the nuclides' relative ! energies given the temperature difference between material temperature and ! temperature of the nuclides' base cross sections - call self % updateRelEnMacroXSs(E, matIdx, rand, kT, densityFactor) + call self % updateRelEnMacroXSs(E, matIdx, kT, densityFactor, rand) else @@ -602,13 +602,13 @@ end subroutine updateMacroXSs !! E [in] -> Incident neutron energy for which the relative energy xss are found !! matIdx [in] -> Index of material for which the relative energy xss are found !! - subroutine updateRelEnMacroXSs(self, E, matIdx, rand, kT, densityFactor) + subroutine updateRelEnMacroXSs(self, E, matIdx, kT, densityFactor, rand) class(aceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx - class(RNG), optional, intent(inout) :: rand real(defReal), intent(in) :: kT real(defReal), intent(in) :: densityFactor + class(RNG), optional, intent(inout) :: rand integer(shortInt) :: i, nucIdx real(defReal) :: dens, nuckT, A, deltakT, eRel, eMin, & eMax, doppCorr @@ -632,6 +632,10 @@ subroutine updateRelEnMacroXSs(self, E, matIdx, rand, kT, densityFactor) nuckT = self % nuclides(nucIdx) % getkT() A = self % nuclides(nucIdx) % getMass() deltakT = kT - nuckT + + ! Catch negative dkT - perhaps due to input field values + if (deltakT < ZERO) call fatalError(Here,& + 'Invalid input temperatureL '//numToChar(kT/kBoltzmannMeV)) eRel = relativeEnergy_constXS(E, A, deltakT, rand) @@ -776,6 +780,10 @@ subroutine updateTotalTempNucXS(self, E, kT, nucIdx) A = nuc % getMass() deltakT = kT - nuckT + ! Catch negative dkT - perhaps due to input field values + if (deltakT < ZERO) call fatalError(Here,& + 'Invalid input temperatureL '//numToChar(kT/kBoltzmannMeV)) + ! Check if an update is required if (nucCache % E_maj /= E .or. nucCache % deltakT /= deltakT) then @@ -1003,8 +1011,8 @@ subroutine init(self, dict, ptr, silent ) kT = mat % T * kBoltzmannMev if ((kT < sabT(1)) .or. (kT > sabT(2))) call fatalError(Here,& 'Material temperature must be bounded by the provided S(alpha,beta) data. '//& - 'The material temperature is '//numToChar(kT * / kBoltzmannMeV)//& - 'K while the data bounds are '//numToChar(sabT(1) * / kBoltzmannMeV)//& + 'The material temperature is '//numToChar(kT / kBoltzmannMeV)//& + 'K while the data bounds are '//numToChar(sabT(1) / kBoltzmannMeV)//& 'K and '//numToChar(sabT(2) / kBoltzmannMeV)//'K.') end if @@ -1253,20 +1261,32 @@ end subroutine activate !! !! See nuclearDatabase documentation for details !! - subroutine initMajorant(self, loud) + subroutine initMajorant(self, loud, scaleDensity) class(aceNeutronDatabase), intent(inout) :: self logical(defBool), intent(in) :: loud + real(defReal), intent(in), optional :: scaleDensity real(defReal), dimension(:), allocatable :: tmpGrid integer(shortInt) :: i, j, k, matIdx, nNuc, nucIdx, isDone, & sizeGrid, eIdx, nucIdxLast, eIdxLast, & urrIdx type(intMap) :: nucSet real(defReal) :: eRef, eNuc, E, maj, trackXS, dens, urrMaj, & - nucXS, f, eMax, eMin + nucXS, f, eMax, eMin, densityFactor class(RNG), allocatable :: rand integer(shortInt), parameter :: IN_SET = 1, NOT_PRESENT = 0 real(defReal), parameter :: NUDGE = 1.0e-06_defReal + ! Check scaleDensity is present and sensible + if (present(scaleDensity)) then + if (scaleDensity < ONE) then + densityFactor = ONE + else + densityFactor = scaleDensity + end if + else + densityFactor = ONE + end if + ! Find the size of the unionised energy grid (with duplicates) ! Initialise size sizeGrid = 0 @@ -1467,7 +1487,7 @@ subroutine initMajorant(self, loud) ! Loop over nuclides to check and correct for ures do k = 1, size(self % materials(matIdx) % nuclides) - dens = self % materials(matIdx) % dens(k) + dens = self % materials(matIdx) % dens(k) * densityFactor nucIdx = self % materials(matIdx) % nuclides(k) associate (nuc => self % nuclides(nucIdx)) diff --git a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 index 935df7300..60fc91187 100644 --- a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 +++ b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 @@ -41,14 +41,18 @@ module ceNeutronCache_mod !! type, public :: cacheMatDat real(defReal) :: E_tot = ZERO + real(defReal) :: T_tot = ZERO + real(defReal) :: rho_tot = ZERO real(defReal) :: E_tail = ZERO real(defReal) :: f = ZERO integer(shortInt) :: idx = 0 type(neutronMacroXSs) :: xss ! Tracking data - real(defReal) :: E_track = ZERO - real(defReal) :: trackXS = ZERO + real(defReal) :: E_track = ZERO + real(defReal) :: trackXS = ZERO + real(defReal) :: T_track = ZERO + real(defReal) :: rho_track = ZERO ! TMS data real(defReal) :: E_rel = ZERO @@ -97,8 +101,10 @@ module ceNeutronCache_mod !! xs -> value of the cross section !! type, public :: cacheSingleXS - real(defReal) :: E = ZERO - real(defReal) :: xs = ZERO + real(defReal) :: E = ZERO + real(defReal) :: xs = ZERO + real(defReal) :: T = ZERO + real(defReal) :: rho = ZERO end type cacheSingleXS !! diff --git a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 index 16b509d65..5d25138e8 100644 --- a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 +++ b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 @@ -109,11 +109,13 @@ end subroutine energyBounds !! matIdx [in] -> material index that needs to be updated !! rand [inout] -> random number generator !! - subroutine updateTrackMatXS(self, E, matIdx, rand) + subroutine updateTrackMatXS(self, E, matIdx, temp, rho, rand) import :: ceNeutronDatabase, defReal, shortInt, RNG class(ceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), optional, intent(inout) :: rand end subroutine updateTrackMatXS @@ -369,7 +371,7 @@ function getTrackMatXS(self, p, matIdx) result(xs) if (materialCache(matIdx) % E_track /= p % E .or. & materialCache(matIdx) % T_track /= p % T .or. & materialCache(matIdx) % rho_track /= p % rho) then - call self % updateTrackMatXS(p % E, matIdx, p % pRNG, p % T, p % rho) + call self % updateTrackMatXS(p % E, matIdx, p % T, p % rho, p % pRNG) end if ! Return Cross-Section @@ -408,7 +410,7 @@ function getTotalMatXS(self, p, matIdx) result(xs) if (materialCache(matIdx) % E_tot /= p % E .or. & materialCache(matIdx) % T_tot /= p % T .or. & materialCache(matIdx) % rho_tot /= p % rho) then - call self % updateTotalMatXS(p % E, matIdx, p % pRNG, p % T, p % rho) + call self % updateTotalMatXS(p % E, matIdx, p % T, p % rho, p % pRNG) end if ! Return Cross-Section diff --git a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 index e0c1ea7ec..456df5d07 100644 --- a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 +++ b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 @@ -114,7 +114,7 @@ subroutine getMacroXSs_byP(self, xss, p) character(100), parameter :: Here = 'getMacroXSs_byP (ceNeutronMaterial_class.f90)' if (.not.p % isMG) then - call self % getMacroXSs(xss, p % E, p % pRNG) + call self % getMacroXSs(xss, p % E, p % temp, p % rho, p % pRNG) else call fatalError(Here,'MG neutron given to CE data') @@ -233,18 +233,23 @@ end subroutine set !! Errors: !! fatalError if E is out-of-bounds for the stored data !! - subroutine getMacroXSs_byE(self, xss, E, rand) + subroutine getMacroXSs_byE(self, xss, E, temp, rho, rand) class(ceNeutronMaterial), intent(in) :: self type(neutronMacroXSs), intent(out) :: xss real(defReal), intent(in) :: E + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), intent(inout) :: rand - ! Check Cache and update if needed - if (materialCache(self % matIdx) % E_tail /= E .or. materialCache(self % matIdx) % E_tot /= E) then - call self % data % updateMacroXSs(E, self % matIdx, rand) - end if + associate( cache => materialCache(self % matIdx)) + ! Check Cache and update if needed + if (cache % E_tail /= E .or. cache % E_tot /= E .or.& + cache % T_tot /= temp .or. cache % rho_tot /= rho) then + call self % data % updateMacroXSs(E, self % matIdx, temp, rho, rand) + end if - xss = materialCache(self % matIdx) % xss + xss = cache % xss + end associate end subroutine getMacroXSs_byE @@ -306,46 +311,67 @@ end function useTMS !! fatalError if sampling fails for some reason (E.G. random number > 1) !! fatalError if E is out-of-bounds of the present data !! - subroutine sampleNuclide(self, E, rand, nucIdx, eOut) + subroutine sampleNuclide(self, E, rand, nucIdx, eOut, temp, rho) class(ceNeutronMaterial), intent(in) :: self real(defReal), intent(in) :: E class(RNG), intent(inout) :: rand integer(shortInt), intent(out) :: nucIdx real(defReal), intent(out) :: eOut + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(ceNeutronNuclide), pointer :: nuc integer(shortInt) :: i real(defReal) :: P_acc, eMin, eMax, A, eRel, & - trackMatXS, totNucXS, dens + trackMatXS, totNucXS, dens, & + kT, densityFactor character(100), parameter :: Here = 'sampleNuclide (ceNeutronMaterial_class.f90)' ! Get material tracking XS - if (E /= materialCache(self % matIdx) % E_track) then - call self % data % updateTrackMatXS(E, self % matIdx, rand) + if (E /= materialCache(self % matIdx) % E_track .or. & + temp /= materialCache(self % matIdx) % T_track .or. & + rho /= materialCache(self % matIdx) % rho_track) then + call self % data % updateTrackMatXS(E, self % matIdx, temp, rho, rand) end if trackMatXS = materialCache(self % matIdx) % trackXS * rand % get() + + ! Used imposed density scaling if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if + + ! Use imposed temperature if given + if (temp <= ZERO) + kT = self % kT + else + kT = temp * kBoltzmannMeV + end if ! Loop over nuclides do i = 1,size(self % nuclides) nucIdx = self % nuclides(i) - dens = self % dens(i) + dens = self % dens(i) * densityFactor associate (nucCache => nuclideCache(nucIdx)) - + ! Retrieve nuclide XS from cache if (self % useTMS(E)) then ! If the material is using TMS, the nuclide temperature majorant is needed ! The check for the right values stored in cache happens inside the subroutine - call self % data % updateTotalTempNucXS(E, self % kT, nucIdx) + call self % data % updateTotalTempNucXS(E, kT, nucIdx) totNucXS = nucCache % tempMajXS * nucCache % doppCorr else ! Update nuclide cache if needed - if (E /= nucCache % E_tot) call self % data % updateTotalNucXS(E, nucIdx, self % kT, rand) + if (E /= nucCache % E_tot .or. temp /= nucCache % T_tot) then + call self % data % updateTotalNucXS(E, nucIdx, kT, rand) + end if totNucXS = nucCache % xss % total end if @@ -377,7 +403,7 @@ subroutine sampleNuclide(self, E, rand, nucIdx, eOut) if (eMax < eRel) eRel = eMax ! Get relative energy nuclide cross section - call self % data % updateTotalNucXS(eRel, nucIdx, self % kT, rand) + call self % data % updateTotalNucXS(eRel, nucIdx, kT, rand) ! Calculate acceptance probability using ratio of relative energy xs to temperature majorant P_acc = nucCache % xss % total * nucCache % doppCorr / totNucXS @@ -426,13 +452,15 @@ end subroutine sampleNuclide !! fatalError if E is out-of-bounds of the present data !! Returns nucIdx <= if material is not fissile !! - function sampleFission(self, E, rand) result(nucIdx) + function sampleFission(self, E, temp, rho, rand) result(nucIdx) class(ceNeutronMaterial), intent(in) :: self real(defReal), intent(in) :: E + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), intent(inout) :: rand class(ceNeutronNuclide), pointer :: nuc integer(shortInt) :: nucIdx, i - real(defReal) :: xs, doppCorr, A, nuckT, deltakT + real(defReal) :: xs, doppCorr, A, nuckT, deltakT, kT, densityFactor character(100), parameter :: Here = 'sampleFission (ceNeutronMaterial_class.f90)' ! Short-cut for nonFissile material @@ -441,11 +469,25 @@ function sampleFission(self, E, rand) result(nucIdx) return end if + ! Used imposed density scaling if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if + + ! Use imposed temperature if given + if (temp <= ZERO) + kT = self % kT + else + kT = temp * kBoltzmannMeV + end if + ! Calculate material macroscopic nuFission ! The cache is updated without checking the energy to get the correct results with TMS ! The relative energy flag cached is cleaned to make sure cross sections are updated materialCache(self % matIdx) % E_rel = ZERO - call self % data % updateMacroXSs(E, self % matIdx, rand) + call self % data % updateMacroXSs(E, self % matIdx, temp, rho, rand) xs = materialCache(self % matIdx) % xss % nuFission * rand % get() @@ -462,7 +504,7 @@ function sampleFission(self, E, rand) result(nucIdx) A = nuc % getMass() nuckT = nuc % getkT() - deltakT = self % kT - nuckT + deltakT = kT - nuckT doppCorr = dopplerCorrectionFactor(E, A, deltakT) else @@ -472,7 +514,7 @@ function sampleFission(self, E, rand) result(nucIdx) ! The nuclide cache should be at the right energy after updating the material ! In the case of TMS where the macro xss are at a relative energy, the nuclide ! xss to be used are at the relative energy just sampled - xs = xs - nuclideCache(nucIdx) % xss % nuFission * self % dens(i) * doppCorr + xs = xs - nuclideCache(nucIdx) % xss % nuFission * self % dens(i) * doppCorr * densityFactor if (xs < ZERO) return @@ -501,9 +543,11 @@ end function sampleFission !! fatalError if E is out-of-bounds of the present data !! Returns nucIdx <= if material is a pure-absorber (with fission as absorbtion) !! - function sampleScatter(self, E, rand) result(nucIdx) + function sampleScatter(self, E, temp, rho, rand) result(nucIdx) class(ceNeutronMaterial), intent(in) :: self real(defReal), intent(in) :: E + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), intent(inout) :: rand class(ceNeutronNuclide), pointer :: nuc integer(shortInt) :: nucIdx, i @@ -514,10 +558,24 @@ function sampleScatter(self, E, rand) result(nucIdx) ! The cache is updated without checking the energy to get the correct results with TMS ! The relative energy flag cached is cleaned to make sure cross sections are updated materialCache(self % matIdx) % E_rel = ZERO - call self % data % updateMacroXSs(E, self % matIdx, rand) + call self % data % updateMacroXSs(E, self % matIdx, temp, rho, rand) xs = rand % get() * (materialCache(self % matIdx) % xss % elasticScatter + & materialCache(self % matIdx) % xss % inelasticScatter) + + ! Used imposed density scaling if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if + + ! Use imposed temperature if given + if (temp <= ZERO) + kT = self % kT + else + kT = temp * kBoltzmannMeV + end if ! Loop over all nuclides do i = 1,size(self % nuclides) @@ -533,7 +591,7 @@ function sampleScatter(self, E, rand) result(nucIdx) A = nuc % getMass() nuckT = nuc % getkT() - deltakT = self % kT - nuckT + deltakT = kT - nuckT doppCorr = dopplerCorrectionFactor(E, A, deltakT) else @@ -544,7 +602,8 @@ function sampleScatter(self, E, rand) result(nucIdx) ! In the case of TMS where the macro xss are at a relative energy, the nuclide ! xss to be used are at the relative energy just sampled xs = xs - (nuclideCache(nucIdx) % xss % elasticScatter + & - nuclideCache(nucIdx) % xss % inelasticScatter ) * self % dens(i) * doppCorr + nuclideCache(nucIdx) % xss % inelasticScatter ) & + * self % dens(i) * doppCorr * densityFactor if (xs < ZERO) return @@ -573,25 +632,41 @@ end function sampleScatter !! fatalError if E is out-of-bounds of the present data !! Returns nucIdx <= if material is a pure-capture (with fission as scattering) !! - function sampleScatterWithFission(self, E, rand) result(nucIdx) + function sampleScatterWithFission(self, E, temp, rho, rand) result(nucIdx) class(ceNeutronMaterial), intent(in) :: self real(defReal), intent(in) :: E + real(defReal), intent(in) :: temp + real(defReal), intent(in) :: rho class(RNG), intent(inout) :: rand class(ceNeutronNuclide), pointer :: nuc integer(shortInt) :: nucIdx, i - real(defReal) :: xs, doppCorr, A, nuckT, deltakT + real(defReal) :: xs, doppCorr, A, nuckT, deltakT, kT, densityFactor character(100), parameter :: Here = 'sampleScatterWithFission (ceNeutronMaterial_class.f90)' ! Calculate material macroscopic cross section of all scattering and fission ! The cache is updated without checking the energy to get the correct results with TMS ! The relative energy flag cached is cleaned to make sure cross sections are updated materialCache(self % matIdx) % E_rel = ZERO - call self % data % updateMacroXSs(E, self % matIdx, rand) + call self % data % updateMacroXSs(E, self % matIdx, temp, rho, rand) xs = rand % get() * (materialCache(self % matIdx) % xss % elasticScatter + & materialCache(self % matIdx) % xss % inelasticScatter + & materialCache(self % matIdx) % xss % fission) + ! Used imposed density scaling if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if + + ! Use imposed temperature if given + if (temp <= ZERO) + kT = self % kT + else + kT = temp * kBoltzmannMeV + end if + ! Loop over all nuclides do i = 1,size(self % nuclides) @@ -606,7 +681,7 @@ function sampleScatterWithFission(self, E, rand) result(nucIdx) A = nuc % getMass() nuckT = nuc % getkT() - deltakT = self % kT - nuckT + deltakT = kT - nuckT doppCorr = dopplerCorrectionFactor(E, A, deltakT) else @@ -618,7 +693,8 @@ function sampleScatterWithFission(self, E, rand) result(nucIdx) ! xss to be used are at the relative energy just sampled xs = xs - (nuclideCache(nucIdx) % xss % elasticScatter + & nuclideCache(nucIdx) % xss % inelasticScatter + & - nuclideCache(nucIdx) % xss % fission) * self % dens(i) * doppCorr + nuclideCache(nucIdx) % xss % fission) * & + self % dens(i) * doppCorr * densityFactor if (xs < ZERO) return diff --git a/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 b/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 index 587a9ecbc..7f145e5fd 100644 --- a/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 +++ b/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 @@ -73,9 +73,9 @@ module baseMgNeutronDatabase_class procedure :: kill procedure :: init procedure :: activate + procedure :: initMajorant ! Local interface - procedure :: initMajorant procedure :: nGroups end type baseMgNeutronDatabase @@ -380,7 +380,7 @@ subroutine init(self, dict, ptr, silent) self % nG = self % mats(1) % nGroups() do i = 2,nMat if(self % nG /= self % mats(i) % nGroups()) then - call fatalError(Here,'Inconsistant # of groups in materials in matIdx'//numToChar(i)) + call fatalError(Here,'Inconsistent # of groups in materials in matIdx '//numToChar(i)) end if end do @@ -428,13 +428,25 @@ end subroutine activate !! !! See nuclearDatabase documentation for details !! - subroutine initMajorant(self, loud) + subroutine initMajorant(self, loud, scaleDensity) class(baseMgNeutronDatabase), intent(inout) :: self logical(defBool), intent(in) :: loud + real(defReal), optional, intent(in) :: scaleDensity integer(shortInt) :: g, i, idx - real(defReal) :: xs + real(defReal) :: xs, densityFactor integer(shortInt), parameter :: TOTAL_XS = 1 + ! Scale density + if (present(scaleDensity)) then + if (scaleDensity < ONE) then + densityFactor = ONE + else + densityFactor = scaleDensity + end if + else + densityFactor = ONE + end if + ! Allocate majorant allocate (self % majorant(self % nG)) @@ -445,7 +457,7 @@ subroutine initMajorant(self, loud) idx = self % activeMats(i) xs = max(xs, self % mats(idx) % data(TOTAL_XS, g)) end do - self % majorant(g) = xs + self % majorant(g) = xs * densityFactor end do if (loud) print '(A)', 'MG unionised majorant cross section calculation completed' diff --git a/NuclearData/nuclearDatabase_inter.f90 b/NuclearData/nuclearDatabase_inter.f90 index d1e25113a..42db160b6 100644 --- a/NuclearData/nuclearDatabase_inter.f90 +++ b/NuclearData/nuclearDatabase_inter.f90 @@ -35,6 +35,7 @@ module nuclearDatabase_inter contains procedure(init), deferred :: init procedure(activate), deferred :: activate + procedure(initMajorant), deferred :: initMajorant procedure(getTrackingXS), deferred :: getTrackingXS procedure(getTrackMatXS), deferred :: getTrackMatXS procedure(getTotalMatXS), deferred :: getTotalMatXS @@ -85,6 +86,21 @@ subroutine activate(self, activeMat, silent) logical(defBool), optional, intent(in) :: silent end subroutine activate + !! + !! Constructs the majorant cross section. + !! Can be called repeatedly to update the majorant subject + !! to changes in the geometry. + !! + !! Optionally can scale the density. scaleDensity should be + !! the relative (to input) density of the highest density material. + !! + subroutine initMajorant(self, loud, scaleDensity) + import :: nuclearDatabase, defBool, defReal + class(nuclearDatabase), intent(inout) :: self + logical(defBool), intent(in) :: loud + real(defReal), optional, intent(in) :: scaleDensity + end subroutine initMajorant + !! !! Return value of tracking XS for a particle and a given request !! diff --git a/ParticleObjects/particle_class.f90 b/ParticleObjects/particle_class.f90 index 5914a5b55..050bff57a 100644 --- a/ParticleObjects/particle_class.f90 +++ b/ParticleObjects/particle_class.f90 @@ -731,8 +731,6 @@ elemental subroutine kill_particleState(self) self % uniqueID = -1 self % collisionN = 0 self % broodID = 0 - self % T = -INF - self % rho = -INF end subroutine kill_particleState From 7235f621237aad97b21c4023ff2c1c99d21a02a9 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sat, 16 Aug 2025 21:49:36 +0100 Subject: [PATCH 10/27] Something is broken :/ --- .../neutronCEimp_class.f90 | 32 +- .../neutronCEstd_class.f90 | 26 +- .../Fields/PieceConstantFields/CMakeLists.txt | 1 + .../cartesianField_class.f90 | 16 +- .../pieceConstantFieldFactory_func.f90 | 58 ++++ .../pieceConstantField_inter.f90 | 6 +- Geometry/Surfaces/Tests/hexagon_test.f90 | 302 +++++++++++++++++ Geometry/Surfaces/gyroid_class.f90 | 239 ++++++++++++++ Geometry/Surfaces/torus_class.f90 | 310 ++++++++++++++++++ Geometry/geometryStd_class.f90 | 73 +++-- Geometry/geometry_inter.f90 | 17 + .../Tests/aceNeutronDatabase_iTest.f90 | 4 +- .../aceDatabase/aceNeutronDatabase_class.f90 | 64 ++-- .../ceNeutronData/ceNeutronCache_mod.f90 | 1 + .../ceNeutronData/ceNeutronDatabase_inter.f90 | 15 +- .../ceNeutronData/ceNeutronMaterial_class.f90 | 32 +- .../testNeutronDatabase_class.f90 | 13 + .../Source/fissionSource_class.f90 | 2 +- PhysicsPackages/eigenPhysicsPackage_class.f90 | 5 + SharedModules/universalVariables.f90 | 5 +- .../transportOperatorST_class.f90 | 7 +- 21 files changed, 1137 insertions(+), 91 deletions(-) create mode 100644 Geometry/Fields/PieceConstantFields/pieceConstantFieldFactory_func.f90 create mode 100644 Geometry/Surfaces/Tests/hexagon_test.f90 create mode 100644 Geometry/Surfaces/gyroid_class.f90 create mode 100644 Geometry/Surfaces/torus_class.f90 diff --git a/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 b/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 index ea42f32ad..8cdc3b62e 100644 --- a/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 +++ b/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 @@ -2,7 +2,7 @@ module neutronCEimp_class use numPrecision use endfConstants - use universalVariables, only : nameUFS, nameWW, REJECTED + use universalVariables, only : nameUFS, nameWW, REJECTED, kBoltzmannMev use genericProcedures, only : fatalError, rotateVector, numToChar use dictionary_class, only : dictionary use RNG_class, only : RNG @@ -230,7 +230,7 @@ subroutine sampleCollision(self, p, tally, collDat, thisCycle, nextCycle) class(particleDungeon),intent(inout) :: thisCycle class(particleDungeon),intent(inout) :: nextCycle type(neutronMicroXSs) :: microXSs - real(defReal) :: r + real(defReal) :: r, kT character(100),parameter :: Here = 'sampleCollision (neutronCEimp_class.f90)' ! Verify that particle is CE neutron @@ -247,7 +247,7 @@ subroutine sampleCollision(self, p, tally, collDat, thisCycle, nextCycle) if(.not.associated(self % mat)) call fatalError(Here, 'Material is not ceNeutronMaterial') ! Select collision nuclide - call self % mat % sampleNuclide(p % E, p % pRNG, collDat % nucIdx, collDat % E) + call self % mat % sampleNuclide(p % E, p % pRNG, collDat % nucIdx, collDat % E, p % T, p % rho) ! If nuclide was rejected in TMS loop return to tracking if (collDat % nucIdx == REJECTED) then @@ -259,7 +259,12 @@ subroutine sampleCollision(self, p, tally, collDat, thisCycle, nextCycle) if (.not.associated(self % mat)) call fatalError(Here, 'Failed to retrieve CE Neutron Nuclide') ! Select Main reaction channel - call self % nuc % getMicroXSs(microXss, collDat % E, self % mat % kT, p % pRNG) + if (p % T <= ZERO) then + kT = self % mat % kT + else + kT = p % T * kBoltzmannMeV + end if + call self % nuc % getMicroXSs(microXss, collDat % E, kT, p % pRNG) r = p % pRNG % get() collDat % MT = microXss % invert(r) @@ -282,7 +287,7 @@ subroutine implicit(self, p, tally, collDat, thisCycle, nextCycle) integer(shortInt) :: n, i real(defReal) :: wgt, rand1, E_out, mu, phi real(defReal) :: sig_nufiss, sig_tot, k_eff, & - sig_scatter, totalElastic + sig_scatter, totalElastic, kT logical(defBool) :: fiss_and_implicit character(100),parameter :: Here = 'implicit (neutronCEimp_class.f90)' @@ -297,7 +302,12 @@ subroutine implicit(self, p, tally, collDat, thisCycle, nextCycle) rand1 = p % pRNG % get() ! Random number to sample sites ! Retrieve cross section at the energy used for reaction sampling - call self % nuc % getMicroXSs(microXSs, collDat % E, self % mat % kT, p % pRNG) + if (p % T <= ZERO) then + kT = self % mat % kT + else + kT = p % T * kBoltzmannMeV + end if + call self % nuc % getMicroXSs(microXSs, collDat % E, kT, p % pRNG) sig_nufiss = microXSs % nuFission sig_tot = microXSs % total @@ -402,7 +412,7 @@ subroutine fission(self, p, tally, collDat, thisCycle, nextCycle) real(defReal),dimension(3) :: r, dir, val integer(shortInt) :: n, i real(defReal) :: wgt, rand1, E_out, mu, phi - real(defReal) :: sig_nufiss, sig_fiss, k_eff + real(defReal) :: sig_nufiss, sig_fiss, k_eff, kT character(100),parameter :: Here = 'fission (neutronCEimp_class.f90)' if (.not.self % implicitSites) then @@ -413,7 +423,12 @@ subroutine fission(self, p, tally, collDat, thisCycle, nextCycle) rand1 = p % pRNG % get() ! Random number to sample sites ! Retrieve cross section at the energy used for reaction sampling - call self % nuc % getMicroXSs(microXSs, collDat % E, self % mat % kT, p % pRNG) + if (p % T <= ZERO) then + kT = self % mat % kT + else + kT = p % T * kBoltzmannMeV + end if + call self % nuc % getMicroXSs(microXSs, collDat % E, kT, p % pRNG) sig_nufiss = microXSs % nuFission sig_fiss = microXSs % fission @@ -501,6 +516,7 @@ subroutine elastic(self, p, tally, collDat, thisCycle, nextCycle) else collDat % kT = self % nuc % getkT() end if + if (p % T > ZERO) collDat % kT = p % T * kBoltzmannMeV ! Check is DBRC is on hasDBRC = self % nuc % hasDBRC() diff --git a/CollisionOperator/CollisionProcessors/neutronCEstd_class.f90 b/CollisionOperator/CollisionProcessors/neutronCEstd_class.f90 index dba85ee80..8f6fbb065 100644 --- a/CollisionOperator/CollisionProcessors/neutronCEstd_class.f90 +++ b/CollisionOperator/CollisionProcessors/neutronCEstd_class.f90 @@ -2,7 +2,7 @@ module neutronCEstd_class use numPrecision use endfConstants - use universalVariables, only : REJECTED + use universalVariables, only : REJECTED, kBoltzmannMeV use genericProcedures, only : fatalError, rotateVector, numToChar use dictionary_class, only : dictionary use RNG_class, only : RNG @@ -150,7 +150,7 @@ subroutine sampleCollision(self, p, tally, collDat, thisCycle, nextCycle) class(particleDungeon),intent(inout) :: thisCycle class(particleDungeon),intent(inout) :: nextCycle type(neutronMicroXSs) :: microXSs - real(defReal) :: r + real(defReal) :: r, kT character(100),parameter :: Here = 'sampleCollision (neutronCEstd_class.f90)' ! Verify that particle is CE neutron @@ -164,10 +164,11 @@ subroutine sampleCollision(self, p, tally, collDat, thisCycle, nextCycle) ! Verify and load material pointer self % mat => ceNeutronMaterial_CptrCast(self % xsData % getMaterial(p % matIdx())) - if (.not.associated(self % mat)) call fatalError(Here, 'Material is not ceNeutronMaterial') + if (.not.associated(self % mat)) call fatalError(Here, 'Material is not ceNeutronMaterial: '& + //numToChar(p % matIdx())) ! Select collision nuclide - call self % mat % sampleNuclide(p % E, p % pRNG, collDat % nucIdx, collDat % E) + call self % mat % sampleNuclide(p % E, p % pRNG, collDat % nucIdx, collDat % E, p % T, p % rho) ! If nuclide was rejected in TMS loop return to tracking if (collDat % nucIdx == REJECTED) then @@ -179,7 +180,12 @@ subroutine sampleCollision(self, p, tally, collDat, thisCycle, nextCycle) if (.not.associated(self % nuc)) call fatalError(Here, 'Failed to retrieve CE Neutron Nuclide') ! Select Main reaction channel - call self % nuc % getMicroXSs(microXss, collDat % E, self % mat % kT, p % pRNG) + if (p % T <= ZERO) then + kT = self % mat % kT + else + kT = p % T * kBoltzmannMeV + end if + call self % nuc % getMicroXSs(microXss, collDat % E, kT, p % pRNG) r = p % pRNG % get() collDat % MT = microXss % invert(r) @@ -201,7 +207,7 @@ subroutine implicit(self, p, tally, collDat, thisCycle, nextCycle) real(defReal),dimension(3) :: r, dir integer(shortInt) :: n, i real(defReal) :: wgt, w0, rand1, E_out, mu, phi - real(defReal) :: sig_nufiss, sig_tot, k_eff + real(defReal) :: sig_nufiss, sig_tot, k_eff, kT character(100),parameter :: Here = 'implicit (neutronCEstd_class.f90)' ! Generate fission sites if nuclide is fissile @@ -214,7 +220,12 @@ subroutine implicit(self, p, tally, collDat, thisCycle, nextCycle) rand1 = p % pRNG % get() ! Random number to sample sites ! Retrieve cross section at the energy used for reaction sampling - call self % nuc % getMicroXSs(microXSs, collDat % E, self % mat % kT, p % pRNG) + if (p % T <= ZERO) then + kT = self % mat % kT + else + kT = p % T * kBoltzmannMeV + end if + call self % nuc % getMicroXSs(microXSs, collDat % E, kT, p % pRNG) sig_nufiss = microXSs % nuFission sig_tot = microXSs % total @@ -322,6 +333,7 @@ subroutine elastic(self, p, tally, collDat, thisCycle, nextCycle) else collDat % kT = self % nuc % getkT() end if + if (p % T > ZERO) collDat % kT = p % T * kBoltzmannMeV ! Check is DBRC is on hasDBRC = self % nuc % hasDBRC() diff --git a/Geometry/Fields/PieceConstantFields/CMakeLists.txt b/Geometry/Fields/PieceConstantFields/CMakeLists.txt index dd90e7975..64cde1d7d 100644 --- a/Geometry/Fields/PieceConstantFields/CMakeLists.txt +++ b/Geometry/Fields/PieceConstantFields/CMakeLists.txt @@ -1,5 +1,6 @@ add_sources( ./pieceConstantField_inter.f90 + ./pieceConstantFieldFactory_func.f90 ./cartesianField_class.f90) add_unit_tests( ./Tests/cartesianField_test.f90) diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 index 255fe4345..2e5309e5c 100644 --- a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 @@ -190,9 +190,10 @@ subroutine init(self, dict) end do + ! Set default value when not in the field call dict % getOrDefault(self % val(self % N), 'default', -INF) - + end subroutine init !! @@ -215,9 +216,14 @@ function at(self, coords) result(val) end if ! Compare against material idx - if (self % matIdxs(1) /= ALL_MATS) then + ! Ensure material is present + if (any(self % matIdxs == coords % matIdx)) then idx = findloc(self % matIdxs, coords % matIdx, 1) localID = localID + (idx - 1) * product(self % sizeN) + else if (self % matIdxs(1) == ALL_MATS) then + localID = localID + else + localID = self % outLocalID end if val = self % val(localID) @@ -246,6 +252,12 @@ function distance(self, coords) result(d) return end if + + ! Catch case if particle is in an excluded material + if ((.not. any(coords % matIdx == self % matIdxs)) .and. self % matIdxs(1) /= ALL_MATS) then + d = INF + return + end if ! Compute ijk of localID temp = localID - 1 diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantFieldFactory_func.f90 b/Geometry/Fields/PieceConstantFields/pieceConstantFieldFactory_func.f90 new file mode 100644 index 000000000..31b30f847 --- /dev/null +++ b/Geometry/Fields/PieceConstantFields/pieceConstantFieldFactory_func.f90 @@ -0,0 +1,58 @@ +!! +!! Module to build pieceConstantField +!! +module pieceConstantFieldFactory_func + + use numPrecision + use errors_mod, only : fatalError + use dictionary_class, only : dictionary + + use pieceConstantField_inter, only : pieceConstantField + use cartesianField_class, only : cartesianField + + implicit none + private + + ! List that contains all acceptable types of pieceConstantFields + ! It is printed if type was unrecognised + ! NOTE: + ! For now it is necessary to adjust trailing blanks so all enteries have the same length + character(nameLen),dimension(*),parameter :: AVAILABLE_fields = [ 'cartesianField'] + + public :: new_pieceConstantField + +contains + + !! + !! Allocate new allocatable pieceConstantField to a specific type + !! If new is allocated it deallocates it + !! + subroutine new_pieceConstantField(new, dict) + class(pieceConstantField),allocatable, intent(inout):: new + class(dictionary), intent(in) :: dict + character(nameLen) :: type + character(100),parameter :: Here = 'new_pieceConstantField (pieceConstantFieldFactory_func.f90)' + + if(allocated(new)) deallocate(new) + + ! Obtain string that specifies type to be built + call dict % get(type,'type') + + ! Allocate approperiate subclass of pieceConstantField + select case(type) + case('cartesianField') + allocate( cartesianField :: new) + + case default + print *, AVAILABLE_fields + call fatalError(Here, 'Unrecognised type pieceConstantField: ' // trim(type)) + + end select + + ! Initialise new pieceConstantField + call new % init(dict) + + end subroutine new_pieceConstantField + + +end module pieceConstantFieldFactory_func diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 index 09c1ba638..29e5aea77 100644 --- a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 +++ b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 @@ -141,9 +141,9 @@ end subroutine setValue !! If the values of the field are not allocated !! function getMaxValue(self) result(val) - class(pieceConstantField), intent(inout) :: self - real(defReal) :: val - character(100), parameter :: Here = 'getMaxValue (pieceConstantField_class.f90)' + class(pieceConstantField), intent(in) :: self + real(defReal) :: val + character(100), parameter :: Here = 'getMaxValue (pieceConstantField_class.f90)' if (.not. allocated(self % val)) call fatalError(Here,& 'The values of the field have not been allocated') diff --git a/Geometry/Surfaces/Tests/hexagon_test.f90 b/Geometry/Surfaces/Tests/hexagon_test.f90 new file mode 100644 index 000000000..af614eed5 --- /dev/null +++ b/Geometry/Surfaces/Tests/hexagon_test.f90 @@ -0,0 +1,302 @@ +module hexagon_test + use numPrecision + use universalVariables + use dictionary_class, only : dictionary + use hexagon_class, only : hexagon, flatType, pointType + use funit + + implicit none + + !! + !! Test parameter wrapper around AN INTEGER (bit of boilerplate) + !! + !! + @testParameter(constructor=newParam) + type, extends (AbstractTestParameter) :: dirParam + integer(shortInt) :: dir + contains + procedure :: toString + end type dirParam + + !! + !! Cylinder Test case + !! + @TestCase(constructor=newTestCase) + type, extends(ParameterizedTestCase) :: test_hexagon + integer(shortInt) :: axis + integer(shortInt) :: orient + integer(shortInt), dimension(2) :: plane + type(hexagon) :: surf + contains + procedure :: tearDown + end type test_hexagon + +contains + + !! + !! Test parameter constructor + !! + function newParam(i) result(param) + integer(shortInt), intent(in) :: i + type (dirParam) :: param + + param % dir = i + + end function newParam + + !! + !! Print parameter to string for more verbose description + !! + function toString(this) result(string) + class (dirParam), intent(in) :: this + character(:), allocatable :: string + + select case(this % dir) + case(X_AXIS) + string = 'xHexagon' + case(Y_AXIS) + string = 'yHexagon' + case(Z_AXIS) + string = 'zHexagon' + case default + string ="Unknown" + end select + end function toString + + !! + !! Build new test_hexagon test case + !! Given integer direction X_AXIS, Y_AXIS or Z_AXIS + !! + !! axis p1 p2 + !! Origin 2.0, 1.0, 2.0 + !! Halfwidths 2.0, 3.0 + !! ID 75 + !! + function newTestCase(dir) result(tst) + type(dirParam), intent(in) :: dir + type(test_hexagon) :: tst + type(dictionary) :: dict + character(nameLen) :: type + real(defReal), dimension(3) :: origin, hw + + ! Select type of hexagon and axis + select case(dir % dir) + case(X_AXIS) + tst % axis = X_AXIS + tst % plane = [Y_AXIS, Z_AXIS] + type = 'xHexagon' + + case(Y_AXIS) + tst % axis = Y_AXIS + tst % plane = [X_AXIS, Z_AXIS] + type = 'yHexagon' + + case(Z_AXIS) + tst % axis = Z_AXIS + tst % plane = [X_AXIS, Y_AXIS] + type = 'zHexagon' + + case default + print *, "Should not happen. Wrong direction in testcase constructor" + error stop + + end select + + ! Set origin & halfwidth + origin = TWO + origin(tst % plane(1)) = ONE + origin(tst % plane(2)) = TWO + + hw = TWO + + ! Build surface + call dict % init(4) + call dict % store('id', 75) + call dict % store('type', type) + call dict % store('origin', origin) + call dict % store('halfwidth', hw) + call tst % surf % init(dict) + + end function newTestCase + + !! + !! Deconstruct the test case + !! + subroutine tearDown(this) + class(test_hexagon), intent(inout) :: this + + call this % surf % kill() + + end subroutine tearDown + +!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> +!! Proper tests begin here +!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> + + !! + !! Test Misc functionality + !! + !! Directions must be given as integers for pFUnit parser to work + !! +@Test(cases = [1, 2, 3]) + subroutine testMisc(this) + class(test_hexagon), intent(inout) :: this + real(defReal), dimension(6) :: aabb, ref + character(nameLen) :: name + real(defReal), parameter :: TOL = 1.0E-6_defReal + + ! Test ID + @assertEqual(75, this % surf % id()) + + ! Change ID + call this % surf % setID(1) + @assertEqual(1, this % surf % id()) + + ! Name + select case(this % axis) + case(X_AXIS) + name = 'xHexagon' + case(Y_AXIS) + name = 'yHexagon' + case(Z_AXIS) + name = 'zHexagon' + end select + @assertEqual(name, this % surf % myType()) + + ! Bounding Box + + end subroutine testMisc + + !! + !! Test boundary conditions + !! +@Test(cases=[1,2,3]) + subroutine testBC(this) + class(test_hexagon), intent(inout) :: this + integer(shortInt), dimension(6) :: BC + integer(shortInt) :: ax, p1, p2 + real(defReal), dimension(3) :: r, u, r_ref, u_ref + real(defReal), parameter :: TOL = 1.0E-6 + + ! Get axis and diffrent planar directions + ax = this % axis + p1 = this % plane(1) + p2 = this % plane(2) + + ! Set BC + BC = VACUUM_BC + BC(p1*2) = REFLECTIVE_BC + BC(p1*2-1) = VACUUM_BC + BC(p2*2) = PERIODIC_BC + BC(p2*2-1) = PERIODIC_BC + + end subroutine testBC + + !! + !! Test Halfspaces membership + !! +@Test(cases=[1,2,3]) + subroutine testHalfspace(this) + class(test_hexagon), intent(inout) :: this + integer(shortInt) :: ax, p1, p2 + real(defReal), dimension(3) :: r, u, u2 + real(defReal) :: eps + + ! Get axis and diffrent planar directions + ax = this % axis + p1 = this % plane(1) + p2 = this % plane(2) + + ! ** Well inside the square cylinder + r = ZERO + u = ZERO + u(p2) = ONE + r([p1, p2]) = [2.0_defReal, 0.0_defReal] + @assertFalse(this % surf % halfspace(r, u)) + + ! Different Quadrant + r([p1, p2]) = [-0.5_defReal, 2.0_defReal] + @assertFalse(this % surf % halfspace(r, u)) + + + end subroutine testHalfspace + + !! + !! Test distance calculation + !! +@Test(cases=[1, 2, 3]) + subroutine testDistance(this) + class(test_hexagon), intent(inout) :: this + integer(shortInt) :: ax, p1, p2 + real(defReal), dimension(3) :: r, u + real(defReal) :: ref + real(defReal), parameter :: TOL = 1.0E-7 + + ! Get axis and different planar directions + ax = this % axis + p1 = this % plane(1) + p2 = this % plane(2) + + !** Outside the hexagon + r = ZERO + r(p1) = -2.0_defReal + r(p2) = ZERO + + ! Direct hit + u([ax, p1, p2]) = [ONE, ONE, ZERO] + u = u/norm2(u) + ref = SQRT2 + @assertEqual(ref, this % surf % distance(r, u), ref * TOL) + + ! Moving away + @assertEqual(INF, this % surf % distance(r, -u)) + + ! Oblique Hit + u([ax, p1, p2]) = [ONE, ONE, ONE] + u = u/norm2(u) + ref = sqrt(3.0_defReal) + @assertEqual(ref, this % surf % distance(r, u), ref * TOL) + + ! Miss + u([ax, p1, p2]) = [ONE, ONE, -TWO] + u = u/norm2(u) + @assertEqual(INF, this % surf % distance(r, u)) + + end subroutine testDistance + + !! + !! Test Edge Cases + !! + !! Test unlikley cases to make sure that halfspace + distance + !! procedures allow particle to escape + !! +@Test(cases=[1, 2, 3]) + subroutine testEdgeCases(this) + class(test_hexagon), intent(inout) :: this + real(defReal), dimension(3) :: r, u + integer(shortInt) :: ax, p1, p2 + real(defReal) :: eps, d + logical(defBool) :: hs + + + end subroutine testEdgeCases + + !! + !! Test encountered problems + !! + !! Contains test related to bugs found at some point + !! TODO: Move some of this tests to main test procedures + !! +@Test(cases=[1]) + subroutine test_problems(this) + class(test_hexagon), intent(inout) :: this ! Ignore this + type(squareCylinder) :: surf + type(dictionary) :: dict + real(defReal), dimension(3) :: r, u + + + end subroutine test_problems + + + +end module hexagon_test diff --git a/Geometry/Surfaces/gyroid_class.f90 b/Geometry/Surfaces/gyroid_class.f90 new file mode 100644 index 000000000..147a08b5e --- /dev/null +++ b/Geometry/Surfaces/gyroid_class.f90 @@ -0,0 +1,239 @@ +module gyroid_class + + use numPrecision + use universalVariables + use genericProcedures, only : fatalError, numToChar, swap + use dictionary_class, only : dictionary + use surface_inter, only : surface, kill_super => kill + + implicit none + private + + !! + !! Gyroid surface, a type of triply periodic minimal surface + !! + !! Satisfies the equation: + !! f(x,y,z) = cos(2*pi*a*(x-x0)) * sin(2*pi*b*(y-y0)) + cos(2*pi*b*(y-y0)) * sin(2*pi*d*(z-z0)) + !! + cos(2*pi*d*(z-z0)) * sin(2*pi*a*(x-x0)) - c = 0 + !! + !! Sample Dictionary Input: + !! myGyroid { type fractal; id 92; origin (-1 -2 4.5); freq (1.0 -3.0 7); c 0.0; } + !! + !! Boundary Conditions: + !! Does not support boundary conditions. + !! + !! Private Members: + !! origin -> x, y, and z co-ordinates defining the centre + !! freq -> spatial frequencies in x, y, and z + !! c -> + !! BC -> Boundary conditions - not supported + !! + !! Interface: + !! surface interface + !! + type, public, extends(surface) :: gyroid + private + real(defReal), dimension(3) :: origin = ZERO + real(defReal), dimension(3) :: freq = ZERO + real(defReal) :: c = ZERO + integer(shortInt), dimension(6) :: BC = VACUUM_BC + + contains + ! Superclass procedures + procedure :: myType + procedure :: init + procedure :: boundingBox + procedure :: evaluate + procedure :: distance + procedure :: going + procedure :: kill + end type gyroid + + +contains + + !! + !! Return surface type name + !! + !! See surface_inter for more details + !! + pure function myType(self) result(str) + class(gyroid), intent(in) :: self + character(:), allocatable :: str + + str = 'gyroid' + + end function myType + + !! + !! Initialise box from a dictionary + !! + !! See surface_inter for more details + !! + !! Errors: + !! + subroutine init(self, dict) + class(gyroid), intent(inout) :: self + class(dictionary), intent(in) :: dict + integer(shortInt) :: id, N + real(defReal), dimension(:), allocatable :: temp + character(100), parameter :: Here = 'init (gyroid_class.f90)' + + ! Load id + call dict % get(id,'id') + if (id <= 0) call fatalError(Here, 'ID must be <=0. Is: '//numToChar(id)) + call self % setID(id) + + ! Load origin + call dict % get(temp,'origin') + N = size(temp) + if (N /= 3) call fatalError(Here,'origin must have size 3. Has: '//numToChar(N)) + self % origin = temp + + ! Load spatial frequencies + call dict % get(temp,'freq') + N = size(temp) + if (N /= 3) call fatalError(Here,'freq must have size 3. Has: '//numToChar(N)) + ! Scale by 2*pi for later simplicity + temp = temp * TWO_PI + self % freq = temp + + ! Load shift + call dict % get(self % c,'c') + + end subroutine init + + !! + !! Return axis-aligned bounding box for the surface + !! + !! See surface_inter for details + !! + pure function boundingBox(self) result(aabb) + class(gyroid), intent(in) :: self + real(defReal), dimension(6) :: aabb + + aabb(1:3) = -INF + aabb(4:6) = INF + + end function boundingBox + + !! + !! Evaluate surface expression c = F(r) + !! + !! See surface_inter for details + !! + pure function evaluate(self, r) result(f) + class(gyroid), intent(in) :: self + real(defReal), dimension(3), intent(in) :: r + real(defReal), dimension(3) :: rb + real(defReal) :: f + integer(shortInt) :: i + + ! Move to origin-frame and scale by frequency + rb = (r - self % origin) * self % freq + + f = cos(rb(1)) * sin(rb(2)) + & + cos(rb(2)) * sin(rb(3)) + & + cos(rb(3)) * sin(rb(1)) - self % c + + end function evaluate + + !! + !! Return distance to the surface + !! Not defined for the gyroid surface which should only be used with delta tracking. + !! + !! See surface_inter for details + !! + pure function distance(self, r, u) result(d) + class(gyroid), intent(in) :: self + real(defReal), dimension(3), intent(in) :: r + real(defReal), dimension(3), intent(in) :: u + real(defReal) :: d + real(defReal) :: tol, dSmall, dInc + integer(shortInt) :: it + real(defReal), dimension(3) :: rb, invFreq, coss, sins, grad + + ! Need to do a root-finding of some sort - so we iterate + dInc = INF + tol = SURF_TOL + + d = ZERO + + invFreq = TWO_PI / (self % freq) + dSmall = 0.01_defReal * dot_product(invFreq, u) + + r0 = r + it = 0 + + do while(dInc > tol .and. it < self % maxIt) + + it = it + 1 + + ! Move to origin-frame and scale by frequency + rb = (r0 - self % origin) * self % freq + + ! Evaluate the function + do i = 1, 3 + coss(i) = cos(rb(i)) + sins(i) = sin(rb(i)) + end do + + f = coss(1) * sins(2) + coss(2) * sins(3) + coss(3) * sins(1) - self % c + + ! Obtain the gradient + do i = 1, 3 + grad(i) = self % freq(i) * (coss(i) * coss(mod(i+1,3) + 1) - sins(i) * sins(mod(i,3) + 1) + end do + + ! How close are we? Should we use ray marching or Newton-Raphson? + + if (doNewton) then + + dInc = -f / dot_product(grad,u) + + + else + + + end if + + d = d + dInc + r0 = r0 + dInc * u + + end do + + end function distance + + !! + !! Returns TRUE if particle is going into +ve halfspace + !! Not defined for the gyroid surface which should only be used with delta tracking. + !! + !! See surface_inter for details + !! + pure function going(self, r, u) result(halfspace) + class(gyroid), intent(in) :: self + real(defReal), dimension(3), intent(in) :: r + real(defReal), dimension(3), intent(in) :: u + logical(defBool) :: halfspace + + halfspace = .false. + + end function going + + !! + !! Return to uninitialised state + !! + elemental subroutine kill(self) + class(gyroid), intent(inout) :: self + + ! Superclass + call kill_super(self) + + ! Local + self % origin = ZERO + self % freq = ZERO + self % c = ZERO + + end subroutine kill + +end module gyroid_class diff --git a/Geometry/Surfaces/torus_class.f90 b/Geometry/Surfaces/torus_class.f90 new file mode 100644 index 000000000..940c9c2f0 --- /dev/null +++ b/Geometry/Surfaces/torus_class.f90 @@ -0,0 +1,310 @@ +module torus_class + + use numPrecision + use universalVariables, only : SURF_TOL, INF, X_AXIS, Y_AXIS, Z_AXIS + use genericProcedures, only : fatalError, numToChar + use dictionary_class, only : dictionary + use surface_inter, only : kill_super => kill + + implicit none + private + + !! + !! Axis aligned elliptic torus + !! + !! F(r) = (ri - ri0)^2 / B^2 + (SQRT[(rj - rjo)^2 + (rk - rko)^2] - A)^2 / C^2 - 1 + !! + !! Where i,j,k (i /= j /= k) can be any of x,y & z axis + !! A is the major radius. B and C correspond to the minor radii which can + !! generally be eccentric. ri0, rj0, and rk0 are the origin of the torus + !! + !! Three diffrent types are avaliable + !! xTorus -> aligned with X-axis + !! yTorus -> aligned with Y-axis + !! zTorus -> aligned with Z-axis + !! + !! Surface tolerance: 2 * R * SURF_TOL ??? + !! + !! Sample dictionary input: + !! tor { type xTorus; // could be yTorus or zTorus as well + !! id 3; + !! origin (0.0 0.0 0.0); + !! coeffs (5 10 20; } // correspond to A B C above + !! + !! Private Members: + !! axis -> Index of an alignment axis in {X_AXIS, Y_AXIS, Z_AXIS} + !! plane -> Indices of axes in plane of torus {X_AXIS, Y_AXIS, Z_AXIS}\{axis} + !! origin -> Origin of the torus + !! r -> Toroidal radii A, B, and C + !! r_sq -> Square of radius r (r^2) + !! + !! Interface: + !! surface interface + !! + type, public, extends(surface) :: torus + private + integer(shortInt) :: axis = 0 + integer(shortInt), dimension(2) :: plane = [0, 0] + real(defReal), dimension(3) :: origin = ZERO + real(defReal), dimension(3) :: r = ZERO + real(defReal) :: r_sq = ZERO + contains + ! Superclass procedures + procedure :: myType + procedure :: init + procedure :: boundingBox + procedure :: evaluate + procedure :: distance + procedure :: going + procedure :: kill + + ! Local procedures + procedure :: build + + end type torus + +contains + + !! + !! Return surface type name + !! + !! See surface_inter for more details + !! + pure function myType(self) result(str) + class(torus), intent(in) :: self + character(:), allocatable :: str + + select case(self % axis) + case(X_AXIS) + str = 'xTorus' + + case(Y_AXIS) + str = 'yTorus' + + case(Z_AXIS) + str = 'zTorus' + + case default + str = 'unknown torus' + + end select + + end function myType + + !! + !! Initialise torus from a dictionary + !! + !! See surface_inter for more details + !! + !! Errors: + !! fatalError if radius or id < 0. + !! + subroutine init(self, dict) + class(torus), intent(inout) :: self + class(dictionary), intent(in) :: dict + integer(shortInt) :: id + real(defReal), dimension(:), allocatable :: origin, radii + character(nameLen) :: name + character(100), parameter :: Here = 'init (torus_class.f90)' + + ! Get from dictionary + call dict % get(id, 'id') + call dict % get(origin, 'origin') + call dict % get(radii, 'coeffs') + call dict % get(name, 'type') + + ! Ensure positive id + if (id <= 0) call fatalError(Here,'Surface id must be positive') + + ! Check origin size + if (size(origin) /= 3) then + call fatalError(Here,'Origin needs to have size 3. Has: '//numToChar(size(origin))) + end if + + ! Check radii size + if (size(radii) /= 3) then + call fatalError(Here,'coeffs needs to have size 3. Has: '//numToChar(size(radii))) + end if + + ! Ensure radii positivity + if (any(radii < 0)) call fatalError(Here,'Torus coeffs must be positive') + + ! Other necessary checks on radii? + + self % r = radii + self % origin = origin + call self % setID(id) + + ! Build torus + call self % build(name) + + ! Set surface tolerance + call self % setTol( TWO * self % r(1) * SURF_TOL) + + end subroutine init + + !! + !! Build torus from components + !! + !! Args: + !! id [in] -> Surface ID + !! type [in] -> Torus type {'xTorus', 'yTorus' or 'zTorus'} + !! + !! Errors: + !! fatalError if invalid torus type + !! + subroutine build(self, type) + class(torus), intent(inout) :: self + character(*), intent(in) :: type + character(100), parameter :: Here = 'build (torus_class.f90)' + + ! Select type of torus + select case(type) + case('xTorus') + self % axis = X_AXIS + self % plane = [Y_AXIS, Z_AXIS] + + case('yTorus') + self % axis = Y_AXIS + self % plane = [X_AXIS, Z_AXIS] + + case('zTorus') + self % axis = Z_AXIS + self % plane = [X_AXIS, Y_AXIS] + + case default + call fatalError(Here, 'Unknown type of torus: '//type) + + end select + + end subroutine build + + !! + !! Return axis-aligned bounding box for the surface + !! + !! See surface_inter for details + !! + pure function boundingBox(self) result(aabb) + class(torus), intent(in) :: self + real(defReal), dimension(6) :: aabb + + ! Top and bottom in a plane + aabb(self % plane) = self % origin(self % plane) - [self % r, self % r] + aabb(3 + self % plane) = self % origin(self % plane) + [self % r, self % r] + + ! Axis + aabb(self % axis) = -INF + aabb(3 + self % axis) = INF + + end function boundingBox + + !! + !! Evaluate surface expression c = F(r) + !! + !! See surface_inter for details + !! + pure function evaluate(self, r) result(c) + class(torus), intent(in) :: self + real(defReal), dimension(3), intent(in) :: r + real(defReal) :: c + + associate (x => r(self % axis), x0 => self % origin(self % axis), & + y => r(self % plane(1)), y0 => self % origin(self % plane(1)), & + z => r(self % plane(2)), z0 => self % origin(self % plane(2))) + c = (x - x0)**2 / self % r2(1) + & + (sqrt((y - y0)**2 + (z - z0)**2) - self % r(1)) / self % r(3) - 1 + + end associate + + end function evaluate + + !! + !! Return distance to the surface + !! + !! See surface_inter for details + !! + !! Solves quadratic intersection equation + !! ad^2 + 2kd + c = 0 + !! c = F(r) + !! k = (r1-x0)u1 + (r2-y0)u2 + !! a = u1^2 + u2^2 + !! + pure function distance(self, r, u) result(d) + class(torus), intent(in) :: self + real(defReal), dimension(3), intent(in) :: r + real(defReal), dimension(3), intent(in) :: u + real(defReal) :: d, a + real(defReal) :: c, k, delta + + ! Calculate quadratic components in the plane + c = self % evaluate(r) + k = dot_product(r(self % plane) - self % origin(self % plane) , u(self % plane)) + a = ONE - u(self % axis)**2 + delta = k*k - a*c ! Technically delta/4 + + ! Calculate the distance + if (delta < ZERO .or. a == ZERO) then ! No intersection + d = INF + + else if (abs(c) < self % surfTol()) then ! Point at a surface + if ( k >= ZERO) then + d = INF + else + d = -k + sqrt(delta) + d = d/a + end if + + else if (c < ZERO) then ! Point inside the surface + d = -k + sqrt(delta) + d = d/a + + else ! Point outside the surface + d = -k - sqrt(delta) + d = d/a + if (d <= ZERO) d = INF + + end if + + ! Cap distance at Infinity + d = min(d, INF) + + end function distance + + !! + !! Returns TRUE if particle is going into +ve halfspace + !! + !! See surface_inter for details + !! + pure function going(self, r, u) result(halfspace) + class(torus), intent(in) :: self + real(defReal), dimension(3), intent(in) :: r + real(defReal), dimension(3), intent(in) :: u + logical(defBool) :: halfspace + real(defReal), dimension(2) :: rp, up + + rp = r(self % plane) - self % origin(self % plane) + up = u(self % plane) + + halfspace = dot_product(rp , up ) >= ZERO + + end function going + + !! + !! Return to uninitialised state + !! + elemental subroutine kill(self) + class(torus), intent(inout) :: self + + ! Superclass + call kill_super(self) + + ! Local + self % axis = 0 + self % plane = 0 + self % origin = ZERO + self % r = ZERO + self % r_sq = ZERO + + end subroutine kill + +end module torus_class diff --git a/Geometry/geometryStd_class.f90 b/Geometry/geometryStd_class.f90 index e053b1554..4a141eef7 100644 --- a/Geometry/geometryStd_class.f90 +++ b/Geometry/geometryStd_class.f90 @@ -10,6 +10,9 @@ module geometryStd_class use csg_class, only : csg use universe_inter, only : universe use surface_inter, only : surface + + use pieceConstantField_inter, only : pieceConstantField + use pieceConstantFieldFactory_func, only : new_pieceConstantField ! Nuclear Data use materialMenu_mod, only : nMat @@ -51,8 +54,8 @@ module geometryStd_class !! type, public, extends(geometry) :: geometryStd type(csg) :: geom - class(pieceConstField), allocatable :: temperatureField - class(pieceConstField), allocatable :: densityField + class(pieceConstantField), allocatable :: temperatureField + class(pieceConstantField), allocatable :: densityField contains ! Superclass procedures @@ -68,6 +71,7 @@ module geometryStd_class procedure :: activeMats procedure :: getTemperature procedure :: getDensity + procedure :: getMaxDensityFactor ! Private procedures procedure, private :: diveToMat @@ -95,14 +99,12 @@ subroutine init(self, dict, mats, silent) ! If present, build temperature and density fields if (dict % isPresent('temperature')) then tempDict => dict % getDictPtr('temperature') - allocate(self % temperatureField) - call self % temperatureField % init(tempDict) + call new_pieceConstantField(self % temperatureField, tempDict) end if if (dict % isPresent('density')) then tempDict => dict % getDictPtr('density') - allocate(self % densityField) - call self % densityField % init(tempDict) + call new_pieceConstantField(self % densityField, tempDict) end if end subroutine init @@ -114,11 +116,11 @@ elemental subroutine kill(self) class(geometryStd), intent(inout) :: self call self % geom % kill() - if allocated(self % temperatureField) then + if (allocated(self % temperatureField)) then call self % temperatureField % kill() deallocate(self % temperatureField) end if - if allocated(self % densityField) then + if (allocated(self % densityField)) then call self % densityField % kill() deallocate(self % densityField) end if @@ -231,7 +233,7 @@ subroutine move_noCache(self, coords, maxDist, event) real(defReal), intent(inout) :: maxDist integer(shortInt), intent(out) :: event integer(shortInt) :: surfIdx, level - real(defReal) :: dist + real(defReal) :: dist, fieldDist class(surface), pointer :: surf class(universe), pointer :: uni character(100), parameter :: Here = 'move_noCache (geometryStd_class.f90)' @@ -240,19 +242,20 @@ subroutine move_noCache(self, coords, maxDist, event) call fatalError(Here, 'Coordinate list is not placed in the geometry') end if + ! Find distance to the next surface + call self % closestDist(dist, surfIdx, level, coords) + ! Check fields + fieldDist = INF if (allocated(self % temperatureField)) then - maxDist = min(maxDist, self % temperatureField % distance(coords)) + fieldDist = min(fieldDist, self % temperatureField % distance(coords)) end if if (allocated(self % densityField)) then - maxDist = min(maxDist, self % densityField % distance(coords)) + fieldDist = min(fieldDist, self % densityField % distance(coords)) end if - ! Find distance to the next surface - call self % closestDist(dist, surfIdx, level, coords) - - if (maxDist < dist) then ! Moves within cell + if (maxDist < dist .and. maxDist < fieldDist) then ! Moves within cell call coords % moveLocal(maxDist, coords % nesting) event = COLL_EV maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway @@ -270,6 +273,10 @@ subroutine move_noCache(self, coords, maxDist, event) ! Place back in geometry call self % placeCoord(coords) + else if (fieldDist < dist) then ! Stays within the same cell, but crosses field boundary + call coords % moveLocal(fieldDist, level) + event = FIELD_EV + else ! Crosses to different local cell ! Move to boundary at hit level call coords % moveLocal(dist, level) @@ -302,7 +309,7 @@ subroutine move_withCache(self, coords, maxDist, event, cache) integer(shortInt), intent(out) :: event type(distCache), intent(inout) :: cache integer(shortInt) :: surfIdx, level - real(defReal) :: dist + real(defReal) :: dist, fieldDist class(surface), pointer :: surf class(universe), pointer :: uni character(100), parameter :: Here = 'move_withCache (geometryStd_class.f90)' @@ -311,19 +318,20 @@ subroutine move_withCache(self, coords, maxDist, event, cache) call fatalError(Here, 'Coordinate list is not placed in the geometry') end if + ! Find distance to the next surface + call self % closestDist_cache(dist, surfIdx, level, coords, cache) + ! Check fields + fieldDist = INF if (allocated(self % temperatureField)) then - maxDist = min(maxDist, self % temperatureField % distance(coords)) + fieldDist = min(fieldDist, self % temperatureField % distance(coords)) end if if (allocated(self % densityField)) then - maxDist = min(maxDist, self % densityField % distance(coords)) + fieldDist = min(fieldDist, self % densityField % distance(coords)) end if - ! Find distance to the next surface - call self % closestDist_cache(dist, surfIdx, level, coords, cache) - - if (maxDist < dist) then ! Moves within cell + if (maxDist < dist .and. maxDist < fieldDist) then ! Moves within cell call coords % moveLocal(maxDist, coords % nesting) event = COLL_EV maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway @@ -343,6 +351,10 @@ subroutine move_withCache(self, coords, maxDist, event, cache) ! Place back in geometry call self % placeCoord(coords) + else if (fieldDist < dist) then ! Stays within the same cell, but crosses field boundary + call coords % moveLocal(fieldDist, level) + event = FIELD_EV + else ! Crosses to different local cell ! Move to boundary at hit level call coords % moveLocal(dist, level) @@ -667,6 +679,23 @@ function getDensity(self, coords) result(rho) end if end function getDensity + + !! + !! Returns the maximum density scaling factor across the geometry + !! + !! See geometry_inter for details + !! + function getMaxDensityFactor(self) result(rho) + class(geometryStd), intent(in) :: self + real(defReal) :: rho + + if (allocated(self % densityField)) then + rho = max(ONE, self % densityField % getMaxValue()) + else + rho = ONE + end if + + end function getMaxDensityFactor !! !! Cast geometry pointer to geometryStd class pointer diff --git a/Geometry/geometry_inter.f90 b/Geometry/geometry_inter.f90 index e68ebfcc2..bc3f9c630 100644 --- a/Geometry/geometry_inter.f90 +++ b/Geometry/geometry_inter.f90 @@ -45,6 +45,7 @@ module geometry_inter procedure(activeMats), deferred :: activeMats procedure(getTemperature), deferred :: getTemperature procedure(getDensity), deferred :: getDensity + procedure(getMaxDensityFactor), deferred :: getMaxDensityFactor ! Common procedures procedure :: slicePlot @@ -297,6 +298,22 @@ function getDensity(self, coords) result(rho) type(coordList), intent(in) :: coords real(defReal) :: rho end function getDensity + + !! + !! Returns the maximum density scaling factor across the system. + !! Used for updating the majorant, for example. + !! + !! Args: + !! + !! Result: + !! Maximum density scaling factor. If there is no density + !! scaling then the result is ONE + !! + function getMaxDensityFactor(self) result(rho) + import :: geometry, defReal + class(geometry), intent(in) :: self + real(defReal) :: rho + end function getMaxDensityFactor end interface diff --git a/NuclearData/ceNeutronData/aceDatabase/Tests/aceNeutronDatabase_iTest.f90 b/NuclearData/ceNeutronData/aceDatabase/Tests/aceNeutronDatabase_iTest.f90 index 4c410b77e..80d9475ca 100644 --- a/NuclearData/ceNeutronData/aceDatabase/Tests/aceNeutronDatabase_iTest.f90 +++ b/NuclearData/ceNeutronData/aceDatabase/Tests/aceNeutronDatabase_iTest.f90 @@ -238,7 +238,7 @@ subroutine test_aceNeutronDatabase() ! ! Water mat => ceNeutronMaterial_TptrCast( data % getMaterial(1)) - call mat % getMacroXSs(macroXss, 3.6E-1_defReal, p % pRNG) + call mat % getMacroXSs(macroXss, 3.6E-1_defReal, p % T, p % rho, p % pRNG) ! Absent XSs @assertEqual(ZERO, macroXSs % fission) @@ -250,7 +250,7 @@ subroutine test_aceNeutronDatabase() @assertEqual(ONE, 2.198066842597500e-06_defReal/ macroXSs % capture, TOL) ! Water with some inelastic collisions - call mat % getMacroXSs(macroXss, 6.525_defReal, p % pRNG) + call mat % getMacroXSs(macroXss, 6.525_defReal, p % T, p % rho, p % pRNG) @assertEqual(ONE, macroXSs % inelasticScatter/1.903667536E-04_defReal, TOL) diff --git a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 index d5885083c..433f9c0dc 100644 --- a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 +++ b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 @@ -336,7 +336,8 @@ subroutine updateMajorantXS(self, E, rand) maj % xs = self % majorant(idx+1) * f + (ONE - f) * self % majorant(idx) - else ! Compute majorant on the fly + ! Compute majorant on the fly - will fail if using a density map! + else maj % xs = ZERO @@ -346,7 +347,7 @@ subroutine updateMajorantXS(self, E, rand) ! Update if needed if (cache_materialCache(matIdx) % E_track /= E) then - call self % updateTrackMatXS(E, matIdx, rand) + call self % updateTrackMatXS(E, matIdx, rand = rand) end if maj % xs = max(maj % xs, cache_materialCache(matIdx) % trackXS) @@ -371,22 +372,34 @@ subroutine updateTrackMatXS(self, E, matIdx, temp, rho, rand) real(defReal), optional, intent(in) :: temp real(defReal), optional, intent(in) :: rho class(RNG), optional, intent(inout) :: rand + real(defReal) :: T, densityFactor associate (matCache => cache_materialCache(matIdx), & mat => self % materials(matIdx)) ! Set new energy, temperature, and density factor matCache % E_track = E - if (present(temp)) then matCache % T_track = temp - if (present(rho)) then matCache % rho_track = rho + if (present(temp)) then + T = temp + else + T = -INF + end if + matCache % T_track = T + + if (present(rho)) then + densityFactor = rho + else + densityFactor = -INF + end if + matCache % rho_track = densityFactor if (mat % useTMS(E)) then ! The material tracking xs is the temperature majorant in the case of TMS - call self % updateTotalTempMajXS(E, matIdx, temp, rho) + call self % updateTotalTempMajXS(E, matIdx, T, densityFactor) else ! When TMS is not in use, the material tracking xs is equivalent to the total - call self % updateTotalMatXS(E, matIdx, temp, rho, rand) + call self % updateTotalMatXS(E, matIdx, T, densityFactor, rand) matCache % trackXS = matCache % xss % total end if @@ -422,11 +435,13 @@ subroutine updateTotalTempMajXS(self, E, matIdx, temp, rho) matCache % trackXS = ZERO ! Use imposed temperature if given - if (temp <= ZERO) + if (temp <= ZERO) then kT = mat % kT else kT = temp * kBoltzmannMeV end if + matCache % T_track = kT / kBoltzmannMeV + matCache % rho_track = rho ! loop through all nuclides in material and find sum of majorants do i = 1, size(mat % nuclides) @@ -445,12 +460,9 @@ subroutine updateTotalTempMajXS(self, E, matIdx, temp, rho) end do ! Use imposed density scaling if given - if (rho <= ZERO) then - densityFactor = ONE - else - densityFactor = rho + if (rho > ZERO) then + matCache % trackXS = matCache % trackXS * rho end if - matCache % trackXS = matCache % trackXS * densityFactor end associate @@ -476,13 +488,13 @@ subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) mat => self % materials(matIdx)) ! Set new energy and clean current total XS - matCache % E_tot = E matCache % xss % total = ZERO - matCache % T = temp - matCache % rho = rho + matCache % E_tot = E + matCache % rho_tot = rho + matCache % T_tot = temp ! Use imposed temperature if given - if (temp <= ZERO) + if (temp <= ZERO) then kT = mat % kT else kT = temp * kBoltzmannMeV @@ -508,7 +520,8 @@ subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) nucIdx = mat % nuclides(i) ! Update if needed - if (cache_nuclideCache(nucIdx) % E_tot /= E) then + if (cache_nuclideCache(nucIdx) % E_tot /= E .or. & + cache_nuclideCache(nucIdx) % T_tot /= kT / kBoltzmannMeV) then call self % updateTotalNucXS(E, nucIdx, kT, rand) end if @@ -546,9 +559,11 @@ subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) ! Clean current xss call matCache % xss % clean() + matCache % T_tot = temp + matCache % rho_tot = rho ! Use imposed temperature if given - if (temp <= ZERO) + if (temp <= ZERO) then kT = mat % kT else kT = temp * kBoltzmannMeV @@ -579,7 +594,9 @@ subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) nucIdx = mat % nuclides(i) ! Update if needed - if (cache_nuclideCache(nucIdx) % E_tail /= E .or. cache_nuclideCache(nucIdx) % E_tot /= E) then + if (cache_nuclideCache(nucIdx) % E_tail /= E .or. & + cache_nuclideCache(nucIdx) % E_tot /= E .or. & + cache_nuclideCache(nucIdx) % T_tot /= kT / kBoltzmannMev) then call self % updateMicroXSs(E, nucIdx, kT, rand) end if @@ -631,11 +648,11 @@ subroutine updateRelEnMacroXSs(self, E, matIdx, kT, densityFactor, rand) nucIdx = mat % nuclides(i) nuckT = self % nuclides(nucIdx) % getkT() A = self % nuclides(nucIdx) % getMass() - deltakT = kT - nuckT + deltakT = mat % kT - nuckT ! Catch negative dkT - perhaps due to input field values if (deltakT < ZERO) call fatalError(Here,& - 'Invalid input temperatureL '//numToChar(kT/kBoltzmannMeV)) + 'Invalid input temperature: '//numToChar(kT/kBoltzmannMeV)) eRel = relativeEnergy_constXS(E, A, deltakT, rand) @@ -690,6 +707,7 @@ subroutine updateTotalNucXS(self, E, nucIdx, kT, rand) associate (nucCache => cache_nuclideCache(nucIdx), & nuc => self % nuclides(nucIdx) ) + nucCache % T_tot = kT / kBoltzmannMeV ! Check if the nuclide needs ures probability tables or S(a,b) at this energy if (nuc % needsUrr(E) .or. nuc % needsSabEl(E) .or. nuc % needsSabInel(E)) then call self % updateMicroXSs(E, nucIdx, kT, rand) @@ -779,6 +797,7 @@ subroutine updateTotalTempNucXS(self, E, kT, nucIdx) nuckT = nuc % getkT() A = nuc % getMass() deltakT = kT - nuckT + nucCache % T_tot = kT / kBoltzmann ! Catch negative dkT - perhaps due to input field values if (deltakT < ZERO) call fatalError(Here,& @@ -1454,6 +1473,7 @@ subroutine initMajorant(self, loud, scaleDensity) end if ! Allocate unionised majorant + if (allocated(self % majorant)) deallocate(self % majorant) allocate(self % majorant(size(self % eGridUnion))) ! Initialise RNG needed to call update XS routines. The initial seed doesn't @@ -1482,7 +1502,7 @@ subroutine initMajorant(self, loud, scaleDensity) matIdx = self % activeMat(j) ! Get material tracking cross section - call self % updateTrackMatXS(E, matIdx, rand) + call self % updateTrackMatXS(E, matIdx, rand = rand) trackXS = cache_materialCache(matIdx) % trackXS ! Loop over nuclides to check and correct for ures diff --git a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 index 60fc91187..c0c4bf2f6 100644 --- a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 +++ b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 @@ -78,6 +78,7 @@ module ceNeutronCache_mod type, public :: cacheNucDat real(defReal) :: E_tot = ZERO real(defReal) :: E_tail = ZERO + real(defReal) :: T_tot = ZERO real(defReal) :: f = ZERO integer(shortInt) :: idx = 0 type(neutronMicroXSs) :: xss diff --git a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 index 5d25138e8..b11688858 100644 --- a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 +++ b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 @@ -64,7 +64,7 @@ module ceNeutronDatabase_inter ! Procedures implemented by a specific CE Neutron Database procedure(updateMajorantXS), deferred :: updateMajorantXS - procedure(updateTotalMatXS), deferred :: updateTrackMatXS + procedure(updateTrackMatXS), deferred :: updateTrackMatXS procedure(updateTotalMatXS), deferred :: updateTotalMatXS procedure(updateMacroXSs), deferred :: updateMacroXSs procedure(updateTotalNucXS), deferred :: updateTotalNucXS @@ -114,8 +114,8 @@ subroutine updateTrackMatXS(self, E, matIdx, temp, rho, rand) class(ceNeutronDatabase), intent(in) :: self real(defReal), intent(in) :: E integer(shortInt), intent(in) :: matIdx - real(defReal), intent(in) :: temp - real(defReal), intent(in) :: rho + real(defReal), intent(in), optional :: temp + real(defReal), intent(in), optional :: rho class(RNG), optional, intent(inout) :: rand end subroutine updateTrackMatXS @@ -331,9 +331,10 @@ function getTrackingXS(self, p, matIdx, what) result(xs) ! Update Cache trackingCache(1) % E = p % E - trackingCache(1) % T = p % T - trackingCache(1) % rho = p % rho trackingCache(1) % xs = xs + ! Update cache due to field changes + trackingCache(1) % T = p % T + trackingCache(1) % rho = p % rho end function getTrackingXS @@ -355,6 +356,10 @@ function getTrackMatXS(self, p, matIdx) result(xs) real(defReal) :: xs character(100),parameter :: Here = 'getTrackMatXS (ceNeutronDatabase_inter.f90)' + ! Update tracking cache due to field changes + trackingCache(1) % T = p % T + trackingCache(1) % rho = p % rho + ! Check dynamic type of the particle if (p % isMG .or. p % type /= P_NEUTRON) then call fatalError(Here, 'Dynamic type of the partcle is not CE Neutron but:'//p % typeToChar()) diff --git a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 index 456df5d07..546c5e27f 100644 --- a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 +++ b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 @@ -114,7 +114,7 @@ subroutine getMacroXSs_byP(self, xss, p) character(100), parameter :: Here = 'getMacroXSs_byP (ceNeutronMaterial_class.f90)' if (.not.p % isMG) then - call self % getMacroXSs(xss, p % E, p % temp, p % rho, p % pRNG) + call self % getMacroXSs(xss, p % E, p % T, p % rho, p % pRNG) else call fatalError(Here,'MG neutron given to CE data') @@ -169,7 +169,7 @@ end subroutine setComposition !! IT IS NOT THREAD SAFE! !! !! NOTE: eUpperSab and eLowerURR are fed by the aceNeutronDatabase, and they are the - !! strictest (respecitvely highest and lowest) energy limits among all nuclides + !! strictest (respectively highest and lowest) energy limits among all nuclides !! in the material composition. !! !! Args: @@ -199,7 +199,7 @@ subroutine set(self, name, matIdx, database, fissile, hasTMS, temp, eUpperSab, e if (present(fissile)) self % fissile = fissile if (present(matIdx)) self % matIdx = matIdx if (present(hasTMS)) self % hasTMS = hasTMS - if (present(temp)) self % kT = (kBoltzmann * temp) / joulesPerMeV + if (present(temp)) self % kT = kBoltzmannMeV * temp if (present(eUpperSab)) then if (eUpperSab < ZERO) call fatalError (Here, 'Upper Sab energy limit of material '& @@ -329,25 +329,25 @@ subroutine sampleNuclide(self, E, rand, nucIdx, eOut, temp, rho) ! Get material tracking XS if (E /= materialCache(self % matIdx) % E_track .or. & temp /= materialCache(self % matIdx) % T_track .or. & - rho /= materialCache(self % matIdx) % rho_track) then + rho /= materialCache(self % matIdx) % rho_track) then call self % data % updateTrackMatXS(E, self % matIdx, temp, rho, rand) end if trackMatXS = materialCache(self % matIdx) % trackXS * rand % get() - ! Used imposed density scaling if given - if (rho <= ZERO) then - densityFactor = ONE - else - densityFactor = rho - end if - ! Use imposed temperature if given - if (temp <= ZERO) + if (temp <= ZERO) then kT = self % kT else kT = temp * kBoltzmannMeV end if + + ! Use imposed density if given + if (rho <= ZERO) then + densityFactor = ONE + else + densityFactor = rho + end if ! Loop over nuclides do i = 1,size(self % nuclides) @@ -477,7 +477,7 @@ function sampleFission(self, E, temp, rho, rand) result(nucIdx) end if ! Use imposed temperature if given - if (temp <= ZERO) + if (temp <= ZERO) then kT = self % kT else kT = temp * kBoltzmannMeV @@ -551,7 +551,7 @@ function sampleScatter(self, E, temp, rho, rand) result(nucIdx) class(RNG), intent(inout) :: rand class(ceNeutronNuclide), pointer :: nuc integer(shortInt) :: nucIdx, i - real(defReal) :: xs, doppCorr, A, nuckT, deltakT + real(defReal) :: xs, doppCorr, A, nuckT, deltakT, densityFactor, kT character(100), parameter :: Here = 'sampleScatter (ceNeutronMaterial_class.f90)' ! Calculate material macroscopic cross section of all scattering @@ -571,7 +571,7 @@ function sampleScatter(self, E, temp, rho, rand) result(nucIdx) end if ! Use imposed temperature if given - if (temp <= ZERO) + if (temp <= ZERO) then kT = self % kT else kT = temp * kBoltzmannMeV @@ -661,7 +661,7 @@ function sampleScatterWithFission(self, E, temp, rho, rand) result(nucIdx) end if ! Use imposed temperature if given - if (temp <= ZERO) + if (temp <= ZERO) then kT = self % kT else kT = temp * kBoltzmannMeV diff --git a/NuclearData/testNeutronData/testNeutronDatabase_class.f90 b/NuclearData/testNeutronData/testNeutronDatabase_class.f90 index e6032e73b..e2ab4c7f3 100644 --- a/NuclearData/testNeutronData/testNeutronDatabase_class.f90 +++ b/NuclearData/testNeutronData/testNeutronDatabase_class.f90 @@ -44,6 +44,7 @@ module testNeutronDatabase_class ! Superclass Interface procedure :: init procedure :: activate + procedure :: initMajorant procedure :: getTrackingXS procedure :: getTrackMatXS procedure :: getTotalMatXS @@ -162,6 +163,18 @@ subroutine activate(self, activeMat, silent) ! Do nothing end subroutine activate + + !! + !! + !! + subroutine initMajorant(self, loud, scaleDensity) + class(testNeutronDatabase), intent(inout) :: self + logical(defBool), intent(in) :: loud + real(defReal), intent(in), optional :: scaleDensity + + ! Do nothing + + end subroutine initMajorant !! !! Return value of Tracking XS for a particle and a given request diff --git a/ParticleObjects/Source/fissionSource_class.f90 b/ParticleObjects/Source/fissionSource_class.f90 index 3c2da3ca3..33847188b 100644 --- a/ParticleObjects/Source/fissionSource_class.f90 +++ b/ParticleObjects/Source/fissionSource_class.f90 @@ -224,7 +224,7 @@ function sampleParticle(self, rand) result(p) end if ! Get Nuclide - nucIdx = matCE % sampleFission(self % E, rand) + nucIdx = matCE % sampleFission(self % E, -ONE, -ONE, rand) ! Get reaction object fissCE => fissionCE_TptrCast(nucData % getReaction(N_FISSION, nucIdx)) diff --git a/PhysicsPackages/eigenPhysicsPackage_class.f90 b/PhysicsPackages/eigenPhysicsPackage_class.f90 index 13822191c..889f82cd8 100644 --- a/PhysicsPackages/eigenPhysicsPackage_class.f90 +++ b/PhysicsPackages/eigenPhysicsPackage_class.f90 @@ -382,6 +382,7 @@ subroutine init(self, dict) type(outputFile) :: test_out type(visualiser) :: viz class(field), pointer :: field + real(defReal) :: maxDensityScale character(100), parameter :: Here ='init (eigenPhysicsPackage_class.f90)' call cpu_time(self % CPU_time_start) @@ -455,6 +456,10 @@ subroutine init(self, dict) call ndReg_activate(self % particleType, nucData, self % geom % activeMats()) self % nucData => ndReg_get(self % particleType) + ! Update majorant in case of density scaling + maxDensityScale = self % geom % getMaxDensityFactor() + call self % nucData % initMajorant(.false., maxDensityScale) + ! Call visualisation if (dict % isPresent('viz')) then print *, "Initialising visualiser" diff --git a/SharedModules/universalVariables.f90 b/SharedModules/universalVariables.f90 index 04d4b61ec..208d4533d 100644 --- a/SharedModules/universalVariables.f90 +++ b/SharedModules/universalVariables.f90 @@ -25,10 +25,11 @@ module universalVariables NUDGE = 1.0e-8_defReal ! Distance to poke neutrons across boundaries for surface tracking ! Flags for different possible events in movement in geometry - integer(shortINt), parameter, public :: COLL_EV = 1, & + integer(shortInt), parameter, public :: COLL_EV = 1, & BOUNDARY_EV = 2, & CROSS_EV = 3, & - LOST_EV = 4 + LOST_EV = 4, & + FIELD_EV = 5 ! Create definitions for readability when dealing with positions relative to surfaces logical(defBool), parameter, public :: behind = .FALSE., & diff --git a/TransportOperator/transportOperatorST_class.f90 b/TransportOperator/transportOperatorST_class.f90 index 237b11e99..90f305fad 100644 --- a/TransportOperator/transportOperatorST_class.f90 +++ b/TransportOperator/transportOperatorST_class.f90 @@ -72,7 +72,12 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) dist = -log( p % pRNG % get()) / sigmaT ! Should never happen! Catches NaN distances - if (dist /= dist) call fatalError(Here, "Distance is NaN") + if (dist /= dist) then + print *, "Particle location: ", p % rGlobal() + print *, "Particle direction: ", p % dirGlobal() + print *, "Total XS: ", sigmaT + call fatalError(Here, "Distance is NaN") + end if end if From 6e354c363921ccc22138f7ea98af129eb5656b90 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Tue, 19 Aug 2025 23:32:23 +0100 Subject: [PATCH 11/27] Major fixes - not there yet --- .../cartesianField_class.f90 | 4 +- Geometry/coord_class.f90 | 2 +- Geometry/geometryStd_class.f90 | 35 ++++++++++------- .../aceDatabase/aceNeutronDatabase_class.f90 | 23 +++++------ .../ceNeutronData/ceNeutronCache_mod.f90 | 39 ++++++++++--------- .../ceNeutronData/ceNeutronDatabase_inter.f90 | 19 +++------ .../ceNeutronData/ceNeutronMaterial_class.f90 | 10 ++--- 7 files changed, 65 insertions(+), 67 deletions(-) diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 index 2e5309e5c..41689bd9b 100644 --- a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 @@ -190,7 +190,6 @@ subroutine init(self, dict) end do - ! Set default value when not in the field call dict % getOrDefault(self % val(self % N), 'default', -INF) @@ -300,8 +299,7 @@ function distance(self, coords) result(d) end do ! Cap distance value - d = max(ZERO, d) - d = min(INF, d) + if (d <= ZERO) d = INF end function distance diff --git a/Geometry/coord_class.f90 b/Geometry/coord_class.f90 index b578254b4..fe8376f9d 100644 --- a/Geometry/coord_class.f90 +++ b/Geometry/coord_class.f90 @@ -300,7 +300,7 @@ elemental subroutine takeAboveGeom(self) end subroutine takeAboveGeom !! - !! Decrease nestting to level n + !! Decrease nesting to level n !! !! Args: !! n [in] -> New nesting level diff --git a/Geometry/geometryStd_class.f90 b/Geometry/geometryStd_class.f90 index 4a141eef7..f299f7909 100644 --- a/Geometry/geometryStd_class.f90 +++ b/Geometry/geometryStd_class.f90 @@ -232,7 +232,7 @@ subroutine move_noCache(self, coords, maxDist, event) type(coordList), intent(inout) :: coords real(defReal), intent(inout) :: maxDist integer(shortInt), intent(out) :: event - integer(shortInt) :: surfIdx, level + integer(shortInt) :: surfIdx, level, level0 real(defReal) :: dist, fieldDist class(surface), pointer :: surf class(universe), pointer :: uni @@ -241,6 +241,8 @@ subroutine move_noCache(self, coords, maxDist, event) if (.not.coords % isPlaced()) then call fatalError(Here, 'Coordinate list is not placed in the geometry') end if + + level0 = coords % nesting ! Find distance to the next surface call self % closestDist(dist, surfIdx, level, coords) @@ -259,7 +261,12 @@ subroutine move_noCache(self, coords, maxDist, event) call coords % moveLocal(maxDist, coords % nesting) event = COLL_EV maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway - + + else if (fieldDist < dist .and. abs(fieldDist - dist) > 10*NUDGE) then ! Stays within the same cell, but crosses field boundary + call coords % moveLocal(fieldDist, level0) + event = FIELD_EV + maxDist = fieldDist + else if (surfIdx == self % geom % borderIdx .and. level == 1) then ! Hits domain boundary ! Move global to the boundary call coords % moveGlobal(dist) @@ -272,11 +279,7 @@ subroutine move_noCache(self, coords, maxDist, event) ! Place back in geometry call self % placeCoord(coords) - - else if (fieldDist < dist) then ! Stays within the same cell, but crosses field boundary - call coords % moveLocal(fieldDist, level) - event = FIELD_EV - + else ! Crosses to different local cell ! Move to boundary at hit level call coords % moveLocal(dist, level) @@ -308,7 +311,7 @@ subroutine move_withCache(self, coords, maxDist, event, cache) real(defReal), intent(inout) :: maxDist integer(shortInt), intent(out) :: event type(distCache), intent(inout) :: cache - integer(shortInt) :: surfIdx, level + integer(shortInt) :: surfIdx, level, level0 real(defReal) :: dist, fieldDist class(surface), pointer :: surf class(universe), pointer :: uni @@ -317,6 +320,8 @@ subroutine move_withCache(self, coords, maxDist, event, cache) if (.not.coords % isPlaced()) then call fatalError(Here, 'Coordinate list is not placed in the geometry') end if + + level0 = coords % nesting ! Find distance to the next surface call self % closestDist_cache(dist, surfIdx, level, coords, cache) @@ -331,12 +336,20 @@ subroutine move_withCache(self, coords, maxDist, event, cache) fieldDist = min(fieldDist, self % densityField % distance(coords)) end if + !if (fieldDist < ZERO) fieldDist = INF + if (maxDist < dist .and. maxDist < fieldDist) then ! Moves within cell call coords % moveLocal(maxDist, coords % nesting) event = COLL_EV maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway cache % lvl = 0 + else if (fieldDist < dist .and. abs(fieldDist - dist) > 10 * NUDGE) then ! Stays within the same cell, but crosses field boundary + call coords % moveLocal(fieldDist, level0) + event = FIELD_EV + maxDist = fieldDist + cache % dist(1:level0) = cache % dist(1:level0) - fieldDist + else if (surfIdx == self % geom % borderIdx .and. level == 1) then ! Hits domain boundary ! Move global to the boundary call coords % moveGlobal(dist) @@ -350,11 +363,7 @@ subroutine move_withCache(self, coords, maxDist, event, cache) ! Place back in geometry call self % placeCoord(coords) - - else if (fieldDist < dist) then ! Stays within the same cell, but crosses field boundary - call coords % moveLocal(fieldDist, level) - event = FIELD_EV - + else ! Crosses to different local cell ! Move to boundary at hit level call coords % moveLocal(dist, level) diff --git a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 index 433f9c0dc..e1b2ea65d 100644 --- a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 +++ b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 @@ -382,14 +382,14 @@ subroutine updateTrackMatXS(self, E, matIdx, temp, rho, rand) if (present(temp)) then T = temp else - T = -INF + T = -ONE end if matCache % T_track = T if (present(rho)) then densityFactor = rho else - densityFactor = -INF + densityFactor = -ONE end if matCache % rho_track = densityFactor @@ -440,8 +440,6 @@ subroutine updateTotalTempMajXS(self, E, matIdx, temp, rho) else kT = temp * kBoltzmannMeV end if - matCache % T_track = kT / kBoltzmannMeV - matCache % rho_track = rho ! loop through all nuclides in material and find sum of majorants do i = 1, size(mat % nuclides) @@ -491,7 +489,6 @@ subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) matCache % xss % total = ZERO matCache % E_tot = E matCache % rho_tot = rho - matCache % T_tot = temp ! Use imposed temperature if given if (temp <= ZERO) then @@ -520,8 +517,7 @@ subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) nucIdx = mat % nuclides(i) ! Update if needed - if (cache_nuclideCache(nucIdx) % E_tot /= E .or. & - cache_nuclideCache(nucIdx) % T_tot /= kT / kBoltzmannMeV) then + if (cache_nuclideCache(nucIdx) % E_tot /= E .or. matCache % T_tot /= temp) then call self % updateTotalNucXS(E, nucIdx, kT, rand) end if @@ -533,6 +529,8 @@ subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) matCache % xss % total = matCache % xss % total * densityFactor end if + + matCache % T_tot = temp end associate @@ -559,7 +557,6 @@ subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) ! Clean current xss call matCache % xss % clean() - matCache % T_tot = temp matCache % rho_tot = rho ! Use imposed temperature if given @@ -567,7 +564,7 @@ subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) kT = mat % kT else kT = temp * kBoltzmannMeV - end if + end if ! Use imposed density scaling if given if (rho <= ZERO) then @@ -596,7 +593,7 @@ subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) ! Update if needed if (cache_nuclideCache(nucIdx) % E_tail /= E .or. & cache_nuclideCache(nucIdx) % E_tot /= E .or. & - cache_nuclideCache(nucIdx) % T_tot /= kT / kBoltzmannMev) then + matCache % T_tot /= temp) then call self % updateMicroXSs(E, nucIdx, kT, rand) end if @@ -605,6 +602,8 @@ subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) end do end if + + matCache % T_tot = temp end associate @@ -648,7 +647,7 @@ subroutine updateRelEnMacroXSs(self, E, matIdx, kT, densityFactor, rand) nucIdx = mat % nuclides(i) nuckT = self % nuclides(nucIdx) % getkT() A = self % nuclides(nucIdx) % getMass() - deltakT = mat % kT - nuckT + deltakT = kT - nuckT ! Catch negative dkT - perhaps due to input field values if (deltakT < ZERO) call fatalError(Here,& @@ -707,7 +706,6 @@ subroutine updateTotalNucXS(self, E, nucIdx, kT, rand) associate (nucCache => cache_nuclideCache(nucIdx), & nuc => self % nuclides(nucIdx) ) - nucCache % T_tot = kT / kBoltzmannMeV ! Check if the nuclide needs ures probability tables or S(a,b) at this energy if (nuc % needsUrr(E) .or. nuc % needsSabEl(E) .or. nuc % needsSabInel(E)) then call self % updateMicroXSs(E, nucIdx, kT, rand) @@ -797,7 +795,6 @@ subroutine updateTotalTempNucXS(self, E, kT, nucIdx) nuckT = nuc % getkT() A = nuc % getMass() deltakT = kT - nuckT - nucCache % T_tot = kT / kBoltzmann ! Catch negative dkT - perhaps due to input field values if (deltakT < ZERO) call fatalError(Here,& diff --git a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 index c0c4bf2f6..93a6aa859 100644 --- a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 +++ b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 @@ -29,20 +29,24 @@ module ceNeutronCache_mod !! Structure that contains cached data for each CE Neutron Material !! !! Public Members: - !! E_tot -> Energy of the total XS in xss - !! E_tail -> Energy of all XSs in xss except total - !! f -> Interpolation factor for the nuclide at energy E_tot - !! idx -> Index on a nuclide grid for energy E_tot - !! xss -> Cached cross-section values - !! E_track -> Energy of the tracking xs - !! trackXS -> Cached tracking xs; this can be different to xss % total when using TMS - !! E_rel -> Base energy for which relative energy cross sections are found (for TMS) - !! xssRel -> Cached effective cross-section values at energy relative to E_rel (for TMS) + !! E_tot -> Energy of the total XS in xss + !! E_tail -> Energy of all XSs in xss except total + !! T_tot -> Temperature at which total XS was evaluated + !! rho_tot -> Density scaling at which total XS was evaluated + !! f -> Interpolation factor for the nuclide at energy E_tot + !! idx -> Index on a nuclide grid for energy E_tot + !! xss -> Cached cross-section values + !! E_track -> Energy of the tracking xs + !! T_track -> Temperature at which tracking XS was evaluated + !! rho_track -> Density scaling at which tracking XS was evaluated + !! trackXS -> Cached tracking xs; this can be different to xss % total when using TMS + !! E_rel -> Base energy for which relative energy cross sections are found (for TMS) + !! xssRel -> Cached effective cross-section values at energy relative to E_rel (for TMS) !! type, public :: cacheMatDat real(defReal) :: E_tot = ZERO - real(defReal) :: T_tot = ZERO - real(defReal) :: rho_tot = ZERO + real(defReal) :: T_tot = -ONE + real(defReal) :: rho_tot = -ONE real(defReal) :: E_tail = ZERO real(defReal) :: f = ZERO integer(shortInt) :: idx = 0 @@ -51,8 +55,8 @@ module ceNeutronCache_mod ! Tracking data real(defReal) :: E_track = ZERO real(defReal) :: trackXS = ZERO - real(defReal) :: T_track = ZERO - real(defReal) :: rho_track = ZERO + real(defReal) :: T_track = -ONE + real(defReal) :: rho_track = -ONE ! TMS data real(defReal) :: E_rel = ZERO @@ -78,7 +82,6 @@ module ceNeutronCache_mod type, public :: cacheNucDat real(defReal) :: E_tot = ZERO real(defReal) :: E_tail = ZERO - real(defReal) :: T_tot = ZERO real(defReal) :: f = ZERO integer(shortInt) :: idx = 0 type(neutronMicroXSs) :: xss @@ -98,14 +101,14 @@ module ceNeutronCache_mod !! Structure that contains a cross section value !! !! Public Members: - !! E -> energy of the cross section - !! xs -> value of the cross section + !! E -> energy of the cross section + !! xs -> value of the cross section + !! T -> temperature of the cross section + !! rho -> density scaling of the cross section !! type, public :: cacheSingleXS real(defReal) :: E = ZERO real(defReal) :: xs = ZERO - real(defReal) :: T = ZERO - real(defReal) :: rho = ZERO end type cacheSingleXS !! diff --git a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 index b11688858..d34509032 100644 --- a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 +++ b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 @@ -121,7 +121,7 @@ end subroutine updateTrackMatXS !! !! Make sure that totalXS of material with matIdx is at energy E - !! in ceNeutronChache + !! in ceNeutronCache !! !! ANY CHANGE in ceNeutronChache is POSSIBLE !! E.G. All material XSs may be updated to energy E @@ -315,9 +315,7 @@ function getTrackingXS(self, p, matIdx, what) result(xs) case (TRACKING_XS) ! READ ONLY - read from previously updated cache - if (p % E == trackingCache(1) % E .and. & - p % T == trackingCache(1) % T .and. & - p % rho == trackingCache(1) % rho) then + if (p % E == trackingCache(1) % E) then xs = trackingCache(1) % xs return else @@ -332,9 +330,6 @@ function getTrackingXS(self, p, matIdx, what) result(xs) ! Update Cache trackingCache(1) % E = p % E trackingCache(1) % xs = xs - ! Update cache due to field changes - trackingCache(1) % T = p % T - trackingCache(1) % rho = p % rho end function getTrackingXS @@ -356,13 +351,9 @@ function getTrackMatXS(self, p, matIdx) result(xs) real(defReal) :: xs character(100),parameter :: Here = 'getTrackMatXS (ceNeutronDatabase_inter.f90)' - ! Update tracking cache due to field changes - trackingCache(1) % T = p % T - trackingCache(1) % rho = p % rho - ! Check dynamic type of the particle if (p % isMG .or. p % type /= P_NEUTRON) then - call fatalError(Here, 'Dynamic type of the partcle is not CE Neutron but:'//p % typeToChar()) + call fatalError(Here, 'Dynamic type of the particle is not CE Neutron but:'//p % typeToChar()) end if ! Check that matIdx exists @@ -381,7 +372,7 @@ function getTrackMatXS(self, p, matIdx) result(xs) ! Return Cross-Section xs = materialCache(matIdx) % trackXS - + end function getTrackMatXS !! @@ -401,7 +392,7 @@ function getTotalMatXS(self, p, matIdx) result(xs) ! Check dynamic type of the particle if (p % isMG .or. p % type /= P_NEUTRON) then - call fatalError(Here, 'Dynamic type of the partcle is not CE Neutron but:'//p % typeToChar()) + call fatalError(Here, 'Dynamic type of the particle is not CE Neutron but:'//p % typeToChar()) end if ! Check that matIdx exists diff --git a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 index 546c5e27f..f9d57808f 100644 --- a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 +++ b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 @@ -327,11 +327,11 @@ subroutine sampleNuclide(self, E, rand, nucIdx, eOut, temp, rho) character(100), parameter :: Here = 'sampleNuclide (ceNeutronMaterial_class.f90)' ! Get material tracking XS - if (E /= materialCache(self % matIdx) % E_track .or. & - temp /= materialCache(self % matIdx) % T_track .or. & - rho /= materialCache(self % matIdx) % rho_track) then + !if (E /= materialCache(self % matIdx) % E_track .or. & + ! temp /= materialCache(self % matIdx) % T_track .or. & + ! rho /= materialCache(self % matIdx) % rho_track) then call self % data % updateTrackMatXS(E, self % matIdx, temp, rho, rand) - end if + !end if trackMatXS = materialCache(self % matIdx) % trackXS * rand % get() @@ -369,7 +369,7 @@ subroutine sampleNuclide(self, E, rand, nucIdx, eOut, temp, rho) else ! Update nuclide cache if needed - if (E /= nucCache % E_tot .or. temp /= nucCache % T_tot) then + if (E /= nucCache % E_tot .or. temp /= materialCache(self % matIdx) % T_tot) then call self % data % updateTotalNucXS(E, nucIdx, kT, rand) end if totNucXS = nucCache % xss % total From 57eef72a8bb57d29d730f975c604fd956d6db523 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sun, 24 Aug 2025 21:12:49 +0100 Subject: [PATCH 12/27] Temperature and density fields Can overlay temperature and density fields on the geometry. Supports both surface and delta tracking. --- .../collisionProcessor_inter.f90 | 2 +- .../cartesianField_class.f90 | 2 +- Geometry/Tests/geometryStd_iTest.f90 | 118 ++++++++++++++++++ Geometry/geometryStd_class.f90 | 26 +++- Geometry/geometry_inter.f90 | 19 ++- .../aceDatabase/aceNeutronDatabase_class.f90 | 22 +++- .../ceNeutronData/ceNeutronDatabase_inter.f90 | 20 +-- .../ceNeutronData/ceNeutronMaterial_class.f90 | 18 ++- .../baseMgNeutronDatabase_class.f90 | 6 +- NuclearData/nuclearDatabase_inter.f90 | 18 ++- .../testNeutronDatabase_class.f90 | 3 +- PhysicsPackages/eigenPhysicsPackage_class.f90 | 7 +- .../fixedSourcePhysicsPackage_class.f90 | 6 + docs/User Manual.rst | 53 +++++++- 14 files changed, 291 insertions(+), 29 deletions(-) diff --git a/CollisionOperator/CollisionProcessors/collisionProcessor_inter.f90 b/CollisionOperator/CollisionProcessors/collisionProcessor_inter.f90 index f14c3da75..ea6c61887 100644 --- a/CollisionOperator/CollisionProcessors/collisionProcessor_inter.f90 +++ b/CollisionOperator/CollisionProcessors/collisionProcessor_inter.f90 @@ -16,7 +16,7 @@ module collisionProcessor_inter private !! - !! Data package with all relevant data about the collision to move beetween customisable + !! Data package with all relevant data about the collision to move between customisable !! procedures !! type, public :: collisionData diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 index 41689bd9b..56fcedc71 100644 --- a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 @@ -192,7 +192,7 @@ subroutine init(self, dict) ! Set default value when not in the field call dict % getOrDefault(self % val(self % N), 'default', -INF) - + end subroutine init !! diff --git a/Geometry/Tests/geometryStd_iTest.f90 b/Geometry/Tests/geometryStd_iTest.f90 index 75def8e56..051ab87a9 100644 --- a/Geometry/Tests/geometryStd_iTest.f90 +++ b/Geometry/Tests/geometryStd_iTest.f90 @@ -7,6 +7,7 @@ module geometryStd_iTest use dictParser_func, only : fileToDict use coord_class, only : coordList use geometryStd_class, only : geometryStd + use materialMenu_mod, only : mm_init => init use funit implicit none @@ -294,5 +295,122 @@ subroutine test_tilted_cylinder() end subroutine test_tilted_cylinder + !! + !! Geometry integration test -> Fuel pin with imposed temperature and density fields + !! +@Test + subroutine test_field_geom() + type(geometryStd) :: geom + character(*), parameter :: path = './IntegrationTestFiles/Geometry/test_field' + type(charMap) :: mats + integer(shortInt) :: i, idx, event + type(dictionary) :: dict + character(nameLen) :: name + real(defReal), dimension(3) :: r, u, r_ref, u_ref + type(dictionary),pointer :: tempDict + type(coordList) :: coords + real(defReal) :: T, rho, maxDist + real(defReal), parameter :: TOL = 1.0E-7_defReal + character(nameLen), dimension(:), allocatable :: keys + + ! Load dictionary + call fileToDict(dict, path) + + ! Load materials + tempDict => dict % getDictPtr('nuclearData') + tempDict => tempDict % getDictPtr('materials') + call tempDict % keys(keys, 'dict') + do i = 1, size(keys) + call mats % add(keys(i), i) + end do + + ! Need to create material menu for the fields + call mm_init(tempDict) + + ! Build geometry + call geom % init(dict, mats, silent=.true.) + + ! Check field values at different points + r = [0.0_defReal, 0.0_defReal, 0.1_defReal] + u = [ZERO, ZERO, ONE] + call coords % init(r, u) + call geom % placeCoord(coords) + + ! Should be in the middle of the fuel + ! Density scaling should be the default value + ! Temperature should be that from the centre + T = geom % getTemperature(coords) + rho = geom % getDensity(coords) + + name = 'mox43' + idx = mats % get(name) + + @assertEqual(idx, coords % matIdx) + @assertEqual(510.0_defReal, T) + @assertEqual(-7.0_defReal, rho) + + ! Place elsewhere in the coolant + ! Temperature should be the default value + r = [0.62_defReal, 0.0_defReal, 190.0_defReal] + call coords % init(r, u) + call geom % placeCoord(coords) + T = geom % getTemperature(coords) + rho = geom % getDensity(coords) + + name = 'water' + idx = mats % get(name) + + @assertEqual(idx, coords % matIdx) + @assertEqual(-10.0_defReal, T) + @assertEqual(0.1_defReal, rho) + + ! Place in the clad + ! Both values should become their default + r = [0.0_defReal, 0.42_defReal, -50.0_defReal] + call coords % init(r, u) + call geom % placeCoord(coords) + T = geom % getTemperature(coords) + rho = geom % getDensity(coords) + + name = 'clad' + idx = mats % get(name) + + @assertEqual(idx, coords % matIdx) + @assertEqual(-10.0_defReal, T) + @assertEqual(-7.0_defReal, rho) + + ! Check distances at different points + + ! Pointing straight up, the distance should be to the next field element + r = [0.0_defReal, 0.0_defReal, 0.1_defReal] + u = [ZERO, ZERO, ONE] + call coords % init(r, u) + call geom % placeCoord(coords) + + r_ref = [0.0_defReal, 0.0_defReal, 20.0_defReal] + maxDist = 1000.0_defReal + call geom % move(coords, maxDist, event) + + @assertEqual(19.9_defReal, maxDist, TOL) + @assertEqual(FIELD_EV, event) + @assertEqual(r_ref, coords % lvl(1) % r, TOL) + + ! At the boundary, the event should be BOUNDARY_EV, even if the field + ! overlaps the boundary + r = [0.0_defReal, 0.0_defReal, -195.2_defReal] + u = [ZERO, ZERO, -ONE] + call coords % init(r, u) + call geom % placeCoord(coords) + + r_ref = [0.0_defReal, 0.0_defReal, -200.0_defReal] + maxDist = 1000.0_defReal + call geom % move(coords, maxDist, event) + + @assertEqual(4.8_defReal, maxDist, TOL) + @assertEqual(BOUNDARY_EV, event) + @assertEqual(r_ref, coords % lvl(1) % r, TOL) + + end subroutine test_field_geom + end module geometryStd_iTest diff --git a/Geometry/geometryStd_class.f90 b/Geometry/geometryStd_class.f90 index f299f7909..9efb4e063 100644 --- a/Geometry/geometryStd_class.f90 +++ b/Geometry/geometryStd_class.f90 @@ -32,6 +32,8 @@ module geometryStd_class !! Typical geometry of a MC Neutron Transport code composed of multiple nested !! universes. !! + !! Supports super-imposed temperature and density fields. + !! !! Boundary conditions in diffrent movement models are handeled: !! move -> explicitBC !! moveGlobal -> explicitBC @@ -41,6 +43,8 @@ module geometryStd_class !! geometry { !! type geometryStd; !! + !! #temperature # + !! #density # !! } !! !! Public Members: @@ -72,6 +76,7 @@ module geometryStd_class procedure :: getTemperature procedure :: getDensity procedure :: getMaxDensityFactor + procedure :: getMaxTemperature ! Private procedures procedure, private :: diveToMat @@ -262,6 +267,7 @@ subroutine move_noCache(self, coords, maxDist, event) event = COLL_EV maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway + ! This check is really awful - can we do something better? else if (fieldDist < dist .and. abs(fieldDist - dist) > 10*NUDGE) then ! Stays within the same cell, but crosses field boundary call coords % moveLocal(fieldDist, level0) event = FIELD_EV @@ -336,14 +342,13 @@ subroutine move_withCache(self, coords, maxDist, event, cache) fieldDist = min(fieldDist, self % densityField % distance(coords)) end if - !if (fieldDist < ZERO) fieldDist = INF - if (maxDist < dist .and. maxDist < fieldDist) then ! Moves within cell call coords % moveLocal(maxDist, coords % nesting) event = COLL_EV maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway cache % lvl = 0 + ! This check is really awful - can we do something better? else if (fieldDist < dist .and. abs(fieldDist - dist) > 10 * NUDGE) then ! Stays within the same cell, but crosses field boundary call coords % moveLocal(fieldDist, level0) event = FIELD_EV @@ -705,6 +710,23 @@ function getMaxDensityFactor(self) result(rho) end if end function getMaxDensityFactor + + !! + !! Returns the maximum temperature across the geometry + !! + !! See geometry_inter for details + !! + function getMaxTemperature(self) result(temp) + class(geometryStd), intent(in) :: self + real(defReal) :: temp + + if (allocated(self % temperatureField)) then + temp = self % temperatureField % getMaxValue() + else + temp = -ONE + end if + + end function getMaxTemperature !! !! Cast geometry pointer to geometryStd class pointer diff --git a/Geometry/geometry_inter.f90 b/Geometry/geometry_inter.f90 index bc3f9c630..911127b1d 100644 --- a/Geometry/geometry_inter.f90 +++ b/Geometry/geometry_inter.f90 @@ -46,6 +46,7 @@ module geometry_inter procedure(getTemperature), deferred :: getTemperature procedure(getDensity), deferred :: getDensity procedure(getMaxDensityFactor), deferred :: getMaxDensityFactor + procedure(getMaxTemperature), deferred :: getMaxTemperature ! Common procedures procedure :: slicePlot @@ -306,7 +307,7 @@ end function getDensity !! Args: !! !! Result: - !! Maximum density scaling factor. If there is no density + !! Maximum density scaling factor due to imposed field. If there is no density !! scaling then the result is ONE !! function getMaxDensityFactor(self) result(rho) @@ -314,6 +315,22 @@ function getMaxDensityFactor(self) result(rho) class(geometry), intent(in) :: self real(defReal) :: rho end function getMaxDensityFactor + + !! + !! Returns the maximum temperature in kelvin across the system. + !! Used for updating the majorant, for example. + !! + !! Args: + !! + !! Result: + !! Maximum temperature due to imposed field. If there is no temperature + !! field then the result is -ONE + !! + function getMaxTemperature(self) result(temp) + import :: geometry, defReal + class(geometry), intent(in) :: self + real(defReal) :: temp + end function getMaxTemperature end interface diff --git a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 index e1b2ea65d..8c5dd2a22 100644 --- a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 +++ b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 @@ -1277,9 +1277,10 @@ end subroutine activate !! !! See nuclearDatabase documentation for details !! - subroutine initMajorant(self, loud, scaleDensity) + subroutine initMajorant(self, loud, maxTemp, scaleDensity) class(aceNeutronDatabase), intent(inout) :: self logical(defBool), intent(in) :: loud + real(defReal), intent(in), optional :: maxTemp real(defReal), intent(in), optional :: scaleDensity real(defReal), dimension(:), allocatable :: tmpGrid integer(shortInt) :: i, j, k, matIdx, nNuc, nucIdx, isDone, & @@ -1287,11 +1288,22 @@ subroutine initMajorant(self, loud, scaleDensity) urrIdx type(intMap) :: nucSet real(defReal) :: eRef, eNuc, E, maj, trackXS, dens, urrMaj, & - nucXS, f, eMax, eMin, densityFactor + nucXS, f, eMax, eMin, densityFactor, broadenTemp class(RNG), allocatable :: rand integer(shortInt), parameter :: IN_SET = 1, NOT_PRESENT = 0 real(defReal), parameter :: NUDGE = 1.0e-06_defReal + ! Check maxTemp is present and sensible + if (present(maxTemp)) then + if (maxTemp < ZERO) then + broadenTemp = -ONE + else + broadenTemp = maxTemp + end if + else + broadenTemp = -ONE + end if + ! Check scaleDensity is present and sensible if (present(scaleDensity)) then if (scaleDensity < ONE) then @@ -1499,7 +1511,11 @@ subroutine initMajorant(self, loud, scaleDensity) matIdx = self % activeMat(j) ! Get material tracking cross section - call self % updateTrackMatXS(E, matIdx, rand = rand) + if (self % materials(matIdx) % hasTMS .and. broadenTemp > ZERO) then + call self % updateTrackMatXS(E, matIdx, temp = broadenTemp, rho = densityFactor, rand = rand) + else + call self % updateTrackMatXS(E, matIdx, rho = densityFactor, rand = rand) + end if trackXS = cache_materialCache(matIdx) % trackXS ! Loop over nuclides to check and correct for ures diff --git a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 index d34509032..f78a833f0 100644 --- a/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 +++ b/NuclearData/ceNeutronData/ceNeutronDatabase_inter.f90 @@ -97,9 +97,9 @@ end subroutine energyBounds !! !! Make sure that trackXS of material with matIdx is at energy E = E_track - !! in ceNeutronChache + !! in ceNeutronCache !! - !! The tracking xs correspons to the material total cross section unless TMS + !! The tracking xs corresponds to the material total cross section unless TMS !! is used. In that case, this is the material temperature majorant xs. !! !! Assume that call to this procedure implies that data is NOT up-to-date @@ -107,6 +107,8 @@ end subroutine energyBounds !! Args: !! E [in] -> required energy [MeV] !! matIdx [in] -> material index that needs to be updated + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! rand [inout] -> random number generator !! subroutine updateTrackMatXS(self, E, matIdx, temp, rho, rand) @@ -131,6 +133,8 @@ end subroutine updateTrackMatXS !! Args: !! E [in] -> required energy [MeV] !! matIdx [in] -> material index that needs to be updated + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! rand [inout] -> random number generator !! subroutine updateTotalMatXS(self, E, matIdx, temp, rho, rand) @@ -147,7 +151,7 @@ end subroutine updateTotalMatXS !! Make sure that the majorant of ALL Active materials is at energy E !! in ceNeutronChache !! - !! ANY CHANGE in ceNeutronChache is POSSIBLE + !! ANY CHANGE in ceNeutronCache is POSSIBLE !! E.G. All material XSs may be updated to energy E !! !! Assume that call to this procedure implies that data is NOT up-to-date @@ -167,7 +171,7 @@ end subroutine updateMajorantXS !! Make sure that the macroscopic XSs for the material with matIdx are set !! to energy E in ceNeutronCache !! - !! ANY CHANGE in ceNeutronChache is POSSIBLE + !! ANY CHANGE in ceNeutronCache is POSSIBLE !! E.G. Extra materials may be set to energy E as well !! !! Assume that call to this procedure implies that data is NOT up-to-date @@ -175,6 +179,8 @@ end subroutine updateMajorantXS !! Args: !! E [in] -> required energy [MeV] !! matIdx [in] -> material index that needs to be updated + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! rand [inout] -> random number generator !! subroutine updateMacroXSs(self, E, matIdx, temp, rho, rand) @@ -191,8 +197,8 @@ end subroutine updateMacroXSs !! Make sure that totalXS of nuclide with nucIdx is at energy E !! in ceNeutronChache !! - !! ANY CHANGE in ceNeutronChache is POSSIBLE - !! E.G. All nuclid XSs may be updated to energy E + !! ANY CHANGE in ceNeutronCache is POSSIBLE + !! E.G. All nuclide XSs may be updated to energy E !! !! Assume that call to this procedure implies that data is NOT up-to-date !! @@ -215,7 +221,7 @@ end subroutine updateTotalNucXS !! Make sure that the microscopic XSs for the nuclide with nucIdx are set !! to energy E in ceNeutronCache !! - !! ANY CHANGE in ceNeutronChache is POSSIBLE + !! ANY CHANGE in ceNeutronCache is POSSIBLE !! E.G. Extra nuclides may be set to energy E as well !! !! Assume that call to this procedure implies that data is NOT up-to-date diff --git a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 index f9d57808f..ddebf0345 100644 --- a/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 +++ b/NuclearData/ceNeutronData/ceNeutronMaterial_class.f90 @@ -228,6 +228,8 @@ end subroutine set !! Args: !! xss [out] -> Cross section package to store the data !! E [in] -> Requested energy [MeV] + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! rand [inout] -> Random Number Generator !! !! Errors: @@ -306,6 +308,8 @@ end function useTMS !! rand [inout] -> random number generator !! nucIdx [out] -> sampled nuclide index !! eOut [out] -> relative energy between neutron and target (may be /= E in case of TMS) + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! !! Errors: !! fatalError if sampling fails for some reason (E.G. random number > 1) @@ -327,11 +331,11 @@ subroutine sampleNuclide(self, E, rand, nucIdx, eOut, temp, rho) character(100), parameter :: Here = 'sampleNuclide (ceNeutronMaterial_class.f90)' ! Get material tracking XS - !if (E /= materialCache(self % matIdx) % E_track .or. & - ! temp /= materialCache(self % matIdx) % T_track .or. & - ! rho /= materialCache(self % matIdx) % rho_track) then + if (E /= materialCache(self % matIdx) % E_track .or. & + temp /= materialCache(self % matIdx) % T_track .or. & + rho /= materialCache(self % matIdx) % rho_track) then call self % data % updateTrackMatXS(E, self % matIdx, temp, rho, rand) - !end if + end if trackMatXS = materialCache(self % matIdx) % trackXS * rand % get() @@ -442,6 +446,8 @@ end subroutine sampleNuclide !! !! Args: !! E [in] -> incident energy [MeV] + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! rand [inout] -> random number generator !! !! Result: @@ -533,6 +539,8 @@ end function sampleFission !! !! Args: !! E [in] -> incident energy [MeV] + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! rand [inout] -> random number generator !! !! Result: @@ -622,6 +630,8 @@ end function sampleScatter !! !! Args: !! E [in] -> incident energy [MeV] + !! temp [in] -> local temperature in kelvin. Negative values should be ignored. + !! rho [in] -> local density scaling factor. Negative values should be ignored. !! rand [inout] -> random number generator !! !! Result: diff --git a/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 b/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 index 7f145e5fd..85e8cba1f 100644 --- a/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 +++ b/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 @@ -428,9 +428,10 @@ end subroutine activate !! !! See nuclearDatabase documentation for details !! - subroutine initMajorant(self, loud, scaleDensity) + subroutine initMajorant(self, loud, maxTemp, scaleDensity) class(baseMgNeutronDatabase), intent(inout) :: self logical(defBool), intent(in) :: loud + real(defReal), optional, intent(in) :: maxTemp real(defReal), optional, intent(in) :: scaleDensity integer(shortInt) :: g, i, idx real(defReal) :: xs, densityFactor @@ -447,6 +448,9 @@ subroutine initMajorant(self, loud, scaleDensity) densityFactor = ONE end if + ! Currently ignores maxTemp input + ! TODO: Update should there be a temperature model developed for MG XSs + ! Allocate majorant allocate (self % majorant(self % nG)) diff --git a/NuclearData/nuclearDatabase_inter.f90 b/NuclearData/nuclearDatabase_inter.f90 index 42db160b6..29c4fd870 100644 --- a/NuclearData/nuclearDatabase_inter.f90 +++ b/NuclearData/nuclearDatabase_inter.f90 @@ -91,13 +91,22 @@ end subroutine activate !! Can be called repeatedly to update the majorant subject !! to changes in the geometry. !! + !! Optionally can account for the temperature due to super-imposed + !! temperature fields. This should receive the maximum temperature in + !! the system. This is conservative and can be improved by creating a + !! material-wise maximum temperature input. + !! !! Optionally can scale the density. scaleDensity should be !! the relative (to input) density of the highest density material. + !! This is most naturally used with a super-imposed density field. + !! As for temperature, this is conservative and could be improved with + !! a material-wise density scaling factor. !! - subroutine initMajorant(self, loud, scaleDensity) + subroutine initMajorant(self, loud, maxTemp, scaleDensity) import :: nuclearDatabase, defBool, defReal class(nuclearDatabase), intent(inout) :: self logical(defBool), intent(in) :: loud + real(defReal), optional, intent(in) :: maxTemp real(defReal), optional, intent(in) :: scaleDensity end subroutine initMajorant @@ -106,7 +115,7 @@ end subroutine initMajorant !! !! Reads all relevant state information from the particle (e.g. E or G) !! It is the XS used to sample track length: it might be the same as the - !! material total XS, the majorant XS, or a temperature majorant + !! material total XS, the majorant XS, or a temperature majorant. !! !! Args: !! p [in] -> Particle at a given state @@ -117,8 +126,9 @@ end subroutine initMajorant !! Value of XS used to sample path length [1/cm] !! !! Errors: - !! Undefined behaviour if the state of the particle is invalid e.g. -ve energy - !! Undefined behavior if matIdx does not correspond to a defined material + !! Undefined behaviour if the state of the particle is invalid e.g. -ve energy. + !! Undefined behavior if matIdx does not correspond to a defined material. + !! Fatal error if incorrect 'what' option is provided. !! function getTrackingXS(self, p, matIdx, what) result(xs) import :: nuclearDatabase, particle, shortInt, defReal diff --git a/NuclearData/testNeutronData/testNeutronDatabase_class.f90 b/NuclearData/testNeutronData/testNeutronDatabase_class.f90 index e2ab4c7f3..e67c50efc 100644 --- a/NuclearData/testNeutronData/testNeutronDatabase_class.f90 +++ b/NuclearData/testNeutronData/testNeutronDatabase_class.f90 @@ -167,9 +167,10 @@ end subroutine activate !! !! !! - subroutine initMajorant(self, loud, scaleDensity) + subroutine initMajorant(self, loud, maxTemp, scaleDensity) class(testNeutronDatabase), intent(inout) :: self logical(defBool), intent(in) :: loud + real(defReal), intent(in), optional :: maxTemp real(defReal), intent(in), optional :: scaleDensity ! Do nothing diff --git a/PhysicsPackages/eigenPhysicsPackage_class.f90 b/PhysicsPackages/eigenPhysicsPackage_class.f90 index 889f82cd8..604917915 100644 --- a/PhysicsPackages/eigenPhysicsPackage_class.f90 +++ b/PhysicsPackages/eigenPhysicsPackage_class.f90 @@ -382,7 +382,7 @@ subroutine init(self, dict) type(outputFile) :: test_out type(visualiser) :: viz class(field), pointer :: field - real(defReal) :: maxDensityScale + real(defReal) :: maxDensityScale, maxTemperature character(100), parameter :: Here ='init (eigenPhysicsPackage_class.f90)' call cpu_time(self % CPU_time_start) @@ -456,9 +456,10 @@ subroutine init(self, dict) call ndReg_activate(self % particleType, nucData, self % geom % activeMats()) self % nucData => ndReg_get(self % particleType) - ! Update majorant in case of density scaling + ! Update majorant in case of density and temperature fields maxDensityScale = self % geom % getMaxDensityFactor() - call self % nucData % initMajorant(.false., maxDensityScale) + maxTemperature = self % geom % getMaxTemperature() + call self % nucData % initMajorant(.false., maxTemp = maxTemperature, scaleDensity = maxDensityScale) ! Call visualisation if (dict % isPresent('viz')) then diff --git a/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 b/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 index 855ccc7c1..a3892538a 100644 --- a/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 +++ b/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 @@ -312,6 +312,7 @@ subroutine init(self, dict) character(nameLen) :: nucData, energy, geomName type(outputFile) :: test_out type(visualiser) :: viz + real(defReal) :: maxTemperature, maxDensityScale character(100), parameter :: Here ='init (fixedSourcePhysicsPackage_class.f90)' call cpu_time(self % CPU_time_start) @@ -380,6 +381,11 @@ subroutine init(self, dict) ! Activate Nuclear Data *** All materials are active call ndReg_activate(self % particleType, nucData, self % geom % activeMats()) self % nucData => ndReg_get(self % particleType) + + ! Update majorant in case of density and temperature fields + maxDensityScale = self % geom % getMaxDensityFactor() + maxTemperature = self % geom % getMaxTemperature() + call self % nucData % initMajorant(.false., maxTemp = maxTemperature, scaleDensity = maxDensityScale) ! Call visualisation if (dict % isPresent('viz')) then diff --git a/docs/User Manual.rst b/docs/User Manual.rst index 85cd8a672..7eb82785c 100644 --- a/docs/User Manual.rst +++ b/docs/User Manual.rst @@ -406,6 +406,8 @@ A detailed description about the geometry modelling adopted in SCONE can be foun surfaces { } cells { } universes { } + temperature { } + density { } } At the moment, the only **geometry** type available is ``geometryStd``. As for the boundary @@ -441,6 +443,12 @@ Hence, an example of a geometry input could look like: :: For more details about the graph-like structure of the nested geometry see the relevant :ref:`section `. +The geometry optionally allows the use of ``temperature`` and ``density`` fields. These +are super-imposed fields which modify the temperature and densities given in nuclear data. +The temperature field specifies local temperatures in kelvin while the density field +specifies the local dimensionless factors by which material density should be scaled. +Both of these follow the syntax of a ``PieceConstantField``. + Surfaces ######## @@ -678,7 +686,7 @@ Example: :: 1 2 3 // x: 1-3, y: 2, z: 2 4 5 6 // x: 1-3, y: 1, z: 2 7 8 9 // x: 1-3, y: 2, z: 1 - 10 11 12 ) } // x: 1-3, y: 1, z: 1 + 10 11 12 ); } // x: 1-3, y: 1, z: 1 .. note:: The order of the elements in the lattice is different from other MC codes, e.g., @@ -693,6 +701,49 @@ Example: :: root { id 1000; type rootUniverse; border 10; fill u<1>; } +PieceConstantFields +################### + +These are fields which are piecewise constant and are endowed with a distance calculation to +compute the distance until the value of the field changes. These can be used for imposing +density and temperature distributions across the system in a convenient manner. + +Currently there is only one available PieceConstantField: + +* cartesianField. This is similar to a latUniverse: the value of the field varies over a regular + Cartesian lattice with a given shape and size. The field also allows specifying different values + in different materials, or uniformly across all materials. + + - shape: (x y z) array of integers, stating the numbers of x, y and z + elements of the field. For a 2D field, one of the entries has to be 0 + - pitch: (x y z) array with the x, y and z field pitches. In a 2D field, + the value entered in the third dimension is not used. [cm] + - origin (*optional*, default = (0.0 0.0 0.0)): (x y z) array with the + origin of the field. [cm] + - materials: list of material names, corresponding to materials in nuclearData. + Optionally, ``all`` can be used, applying the values of the field to all materials. + - names of each material: a map, named after every material present in the materials list. + The entries of the map are the values that the field takes in that material in that + element of the field. The order is: increasing x, increasing y and then increasing z. + - default: the value taken by the field when a point is either outside of the field or + in a material which is not included in the field. + +Example: :: + + temperature { type cartesianField; shape (3 2 2); pitch (1.0 1.0 1.5); + materials (uo2 water); + uo2 ( + 901 902 903 + 904 905 906 + 907 908 909 + 910 911 912 ); + water ( + 601 602 603 + 604 605 606 + 607 608 609 + 610 611 612); + default 302; } + Visualiser ---------- From fd22103d2bca2de17de89b8f5d55766be82c94ae Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sun, 24 Aug 2025 22:29:49 +0100 Subject: [PATCH 13/27] Added integrationTest data --- IntegrationTestFiles/Geometry/test_field | 69 ++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 IntegrationTestFiles/Geometry/test_field diff --git a/IntegrationTestFiles/Geometry/test_field b/IntegrationTestFiles/Geometry/test_field new file mode 100644 index 000000000..c8fe48932 --- /dev/null +++ b/IntegrationTestFiles/Geometry/test_field @@ -0,0 +1,69 @@ +boundary ( 2 2 2 2 0 0); +graph {type shrunk;} + +temperature { + type cartesianField; + materials (mox43); + origin (0 0 0); + shape (1 1 20); + pitch (1.26 1.26 20); + default -10; + mox43 ( + 330 350 370 390 410 430 450 470 490 510 530 550 570 590 610 630 650 670 690 710 + ); +} + +density { + type cartesianField; + materials (water); + origin (0 0 0); + shape (1 1 20); + pitch (1.27 1.27 20); + default -7; + water ( + 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2 + ); +} + +surfaces { + squareBound { id 1; type box; origin (0.0 0.0 0.0); halfwidth (0.63 0.63 200.0);} +} + +cells { +} + + +universes { + root { id 1; type rootUniverse; border 1; fill u<31>; } + pin31 { id 31; type pinUniverse; radii (0.4095 0.5400 0.0 ); fills (mox43 clad water);} + +} + + + + + +nuclearData { + materials { + + water { + temp 75675; + composition { + } + } + + clad { + temp 12345; + composition { + } + } + + mox43 { + temp 305; + tms 1; + composition { + } + } + +} +} From 4cb9a4bcbbf0deee646fe82f368d75b21c23ad1a Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Wed, 27 Aug 2025 16:16:26 +0100 Subject: [PATCH 14/27] Removing accidentally added files... --- Geometry/Surfaces/Tests/hexagon_test.f90 | 302 ---------------------- Geometry/Surfaces/gyroid_class.f90 | 239 ----------------- Geometry/Surfaces/torus_class.f90 | 310 ----------------------- 3 files changed, 851 deletions(-) delete mode 100644 Geometry/Surfaces/Tests/hexagon_test.f90 delete mode 100644 Geometry/Surfaces/gyroid_class.f90 delete mode 100644 Geometry/Surfaces/torus_class.f90 diff --git a/Geometry/Surfaces/Tests/hexagon_test.f90 b/Geometry/Surfaces/Tests/hexagon_test.f90 deleted file mode 100644 index af614eed5..000000000 --- a/Geometry/Surfaces/Tests/hexagon_test.f90 +++ /dev/null @@ -1,302 +0,0 @@ -module hexagon_test - use numPrecision - use universalVariables - use dictionary_class, only : dictionary - use hexagon_class, only : hexagon, flatType, pointType - use funit - - implicit none - - !! - !! Test parameter wrapper around AN INTEGER (bit of boilerplate) - !! - !! - @testParameter(constructor=newParam) - type, extends (AbstractTestParameter) :: dirParam - integer(shortInt) :: dir - contains - procedure :: toString - end type dirParam - - !! - !! Cylinder Test case - !! - @TestCase(constructor=newTestCase) - type, extends(ParameterizedTestCase) :: test_hexagon - integer(shortInt) :: axis - integer(shortInt) :: orient - integer(shortInt), dimension(2) :: plane - type(hexagon) :: surf - contains - procedure :: tearDown - end type test_hexagon - -contains - - !! - !! Test parameter constructor - !! - function newParam(i) result(param) - integer(shortInt), intent(in) :: i - type (dirParam) :: param - - param % dir = i - - end function newParam - - !! - !! Print parameter to string for more verbose description - !! - function toString(this) result(string) - class (dirParam), intent(in) :: this - character(:), allocatable :: string - - select case(this % dir) - case(X_AXIS) - string = 'xHexagon' - case(Y_AXIS) - string = 'yHexagon' - case(Z_AXIS) - string = 'zHexagon' - case default - string ="Unknown" - end select - end function toString - - !! - !! Build new test_hexagon test case - !! Given integer direction X_AXIS, Y_AXIS or Z_AXIS - !! - !! axis p1 p2 - !! Origin 2.0, 1.0, 2.0 - !! Halfwidths 2.0, 3.0 - !! ID 75 - !! - function newTestCase(dir) result(tst) - type(dirParam), intent(in) :: dir - type(test_hexagon) :: tst - type(dictionary) :: dict - character(nameLen) :: type - real(defReal), dimension(3) :: origin, hw - - ! Select type of hexagon and axis - select case(dir % dir) - case(X_AXIS) - tst % axis = X_AXIS - tst % plane = [Y_AXIS, Z_AXIS] - type = 'xHexagon' - - case(Y_AXIS) - tst % axis = Y_AXIS - tst % plane = [X_AXIS, Z_AXIS] - type = 'yHexagon' - - case(Z_AXIS) - tst % axis = Z_AXIS - tst % plane = [X_AXIS, Y_AXIS] - type = 'zHexagon' - - case default - print *, "Should not happen. Wrong direction in testcase constructor" - error stop - - end select - - ! Set origin & halfwidth - origin = TWO - origin(tst % plane(1)) = ONE - origin(tst % plane(2)) = TWO - - hw = TWO - - ! Build surface - call dict % init(4) - call dict % store('id', 75) - call dict % store('type', type) - call dict % store('origin', origin) - call dict % store('halfwidth', hw) - call tst % surf % init(dict) - - end function newTestCase - - !! - !! Deconstruct the test case - !! - subroutine tearDown(this) - class(test_hexagon), intent(inout) :: this - - call this % surf % kill() - - end subroutine tearDown - -!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> -!! Proper tests begin here -!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> - - !! - !! Test Misc functionality - !! - !! Directions must be given as integers for pFUnit parser to work - !! -@Test(cases = [1, 2, 3]) - subroutine testMisc(this) - class(test_hexagon), intent(inout) :: this - real(defReal), dimension(6) :: aabb, ref - character(nameLen) :: name - real(defReal), parameter :: TOL = 1.0E-6_defReal - - ! Test ID - @assertEqual(75, this % surf % id()) - - ! Change ID - call this % surf % setID(1) - @assertEqual(1, this % surf % id()) - - ! Name - select case(this % axis) - case(X_AXIS) - name = 'xHexagon' - case(Y_AXIS) - name = 'yHexagon' - case(Z_AXIS) - name = 'zHexagon' - end select - @assertEqual(name, this % surf % myType()) - - ! Bounding Box - - end subroutine testMisc - - !! - !! Test boundary conditions - !! -@Test(cases=[1,2,3]) - subroutine testBC(this) - class(test_hexagon), intent(inout) :: this - integer(shortInt), dimension(6) :: BC - integer(shortInt) :: ax, p1, p2 - real(defReal), dimension(3) :: r, u, r_ref, u_ref - real(defReal), parameter :: TOL = 1.0E-6 - - ! Get axis and diffrent planar directions - ax = this % axis - p1 = this % plane(1) - p2 = this % plane(2) - - ! Set BC - BC = VACUUM_BC - BC(p1*2) = REFLECTIVE_BC - BC(p1*2-1) = VACUUM_BC - BC(p2*2) = PERIODIC_BC - BC(p2*2-1) = PERIODIC_BC - - end subroutine testBC - - !! - !! Test Halfspaces membership - !! -@Test(cases=[1,2,3]) - subroutine testHalfspace(this) - class(test_hexagon), intent(inout) :: this - integer(shortInt) :: ax, p1, p2 - real(defReal), dimension(3) :: r, u, u2 - real(defReal) :: eps - - ! Get axis and diffrent planar directions - ax = this % axis - p1 = this % plane(1) - p2 = this % plane(2) - - ! ** Well inside the square cylinder - r = ZERO - u = ZERO - u(p2) = ONE - r([p1, p2]) = [2.0_defReal, 0.0_defReal] - @assertFalse(this % surf % halfspace(r, u)) - - ! Different Quadrant - r([p1, p2]) = [-0.5_defReal, 2.0_defReal] - @assertFalse(this % surf % halfspace(r, u)) - - - end subroutine testHalfspace - - !! - !! Test distance calculation - !! -@Test(cases=[1, 2, 3]) - subroutine testDistance(this) - class(test_hexagon), intent(inout) :: this - integer(shortInt) :: ax, p1, p2 - real(defReal), dimension(3) :: r, u - real(defReal) :: ref - real(defReal), parameter :: TOL = 1.0E-7 - - ! Get axis and different planar directions - ax = this % axis - p1 = this % plane(1) - p2 = this % plane(2) - - !** Outside the hexagon - r = ZERO - r(p1) = -2.0_defReal - r(p2) = ZERO - - ! Direct hit - u([ax, p1, p2]) = [ONE, ONE, ZERO] - u = u/norm2(u) - ref = SQRT2 - @assertEqual(ref, this % surf % distance(r, u), ref * TOL) - - ! Moving away - @assertEqual(INF, this % surf % distance(r, -u)) - - ! Oblique Hit - u([ax, p1, p2]) = [ONE, ONE, ONE] - u = u/norm2(u) - ref = sqrt(3.0_defReal) - @assertEqual(ref, this % surf % distance(r, u), ref * TOL) - - ! Miss - u([ax, p1, p2]) = [ONE, ONE, -TWO] - u = u/norm2(u) - @assertEqual(INF, this % surf % distance(r, u)) - - end subroutine testDistance - - !! - !! Test Edge Cases - !! - !! Test unlikley cases to make sure that halfspace + distance - !! procedures allow particle to escape - !! -@Test(cases=[1, 2, 3]) - subroutine testEdgeCases(this) - class(test_hexagon), intent(inout) :: this - real(defReal), dimension(3) :: r, u - integer(shortInt) :: ax, p1, p2 - real(defReal) :: eps, d - logical(defBool) :: hs - - - end subroutine testEdgeCases - - !! - !! Test encountered problems - !! - !! Contains test related to bugs found at some point - !! TODO: Move some of this tests to main test procedures - !! -@Test(cases=[1]) - subroutine test_problems(this) - class(test_hexagon), intent(inout) :: this ! Ignore this - type(squareCylinder) :: surf - type(dictionary) :: dict - real(defReal), dimension(3) :: r, u - - - end subroutine test_problems - - - -end module hexagon_test diff --git a/Geometry/Surfaces/gyroid_class.f90 b/Geometry/Surfaces/gyroid_class.f90 deleted file mode 100644 index 147a08b5e..000000000 --- a/Geometry/Surfaces/gyroid_class.f90 +++ /dev/null @@ -1,239 +0,0 @@ -module gyroid_class - - use numPrecision - use universalVariables - use genericProcedures, only : fatalError, numToChar, swap - use dictionary_class, only : dictionary - use surface_inter, only : surface, kill_super => kill - - implicit none - private - - !! - !! Gyroid surface, a type of triply periodic minimal surface - !! - !! Satisfies the equation: - !! f(x,y,z) = cos(2*pi*a*(x-x0)) * sin(2*pi*b*(y-y0)) + cos(2*pi*b*(y-y0)) * sin(2*pi*d*(z-z0)) - !! + cos(2*pi*d*(z-z0)) * sin(2*pi*a*(x-x0)) - c = 0 - !! - !! Sample Dictionary Input: - !! myGyroid { type fractal; id 92; origin (-1 -2 4.5); freq (1.0 -3.0 7); c 0.0; } - !! - !! Boundary Conditions: - !! Does not support boundary conditions. - !! - !! Private Members: - !! origin -> x, y, and z co-ordinates defining the centre - !! freq -> spatial frequencies in x, y, and z - !! c -> - !! BC -> Boundary conditions - not supported - !! - !! Interface: - !! surface interface - !! - type, public, extends(surface) :: gyroid - private - real(defReal), dimension(3) :: origin = ZERO - real(defReal), dimension(3) :: freq = ZERO - real(defReal) :: c = ZERO - integer(shortInt), dimension(6) :: BC = VACUUM_BC - - contains - ! Superclass procedures - procedure :: myType - procedure :: init - procedure :: boundingBox - procedure :: evaluate - procedure :: distance - procedure :: going - procedure :: kill - end type gyroid - - -contains - - !! - !! Return surface type name - !! - !! See surface_inter for more details - !! - pure function myType(self) result(str) - class(gyroid), intent(in) :: self - character(:), allocatable :: str - - str = 'gyroid' - - end function myType - - !! - !! Initialise box from a dictionary - !! - !! See surface_inter for more details - !! - !! Errors: - !! - subroutine init(self, dict) - class(gyroid), intent(inout) :: self - class(dictionary), intent(in) :: dict - integer(shortInt) :: id, N - real(defReal), dimension(:), allocatable :: temp - character(100), parameter :: Here = 'init (gyroid_class.f90)' - - ! Load id - call dict % get(id,'id') - if (id <= 0) call fatalError(Here, 'ID must be <=0. Is: '//numToChar(id)) - call self % setID(id) - - ! Load origin - call dict % get(temp,'origin') - N = size(temp) - if (N /= 3) call fatalError(Here,'origin must have size 3. Has: '//numToChar(N)) - self % origin = temp - - ! Load spatial frequencies - call dict % get(temp,'freq') - N = size(temp) - if (N /= 3) call fatalError(Here,'freq must have size 3. Has: '//numToChar(N)) - ! Scale by 2*pi for later simplicity - temp = temp * TWO_PI - self % freq = temp - - ! Load shift - call dict % get(self % c,'c') - - end subroutine init - - !! - !! Return axis-aligned bounding box for the surface - !! - !! See surface_inter for details - !! - pure function boundingBox(self) result(aabb) - class(gyroid), intent(in) :: self - real(defReal), dimension(6) :: aabb - - aabb(1:3) = -INF - aabb(4:6) = INF - - end function boundingBox - - !! - !! Evaluate surface expression c = F(r) - !! - !! See surface_inter for details - !! - pure function evaluate(self, r) result(f) - class(gyroid), intent(in) :: self - real(defReal), dimension(3), intent(in) :: r - real(defReal), dimension(3) :: rb - real(defReal) :: f - integer(shortInt) :: i - - ! Move to origin-frame and scale by frequency - rb = (r - self % origin) * self % freq - - f = cos(rb(1)) * sin(rb(2)) + & - cos(rb(2)) * sin(rb(3)) + & - cos(rb(3)) * sin(rb(1)) - self % c - - end function evaluate - - !! - !! Return distance to the surface - !! Not defined for the gyroid surface which should only be used with delta tracking. - !! - !! See surface_inter for details - !! - pure function distance(self, r, u) result(d) - class(gyroid), intent(in) :: self - real(defReal), dimension(3), intent(in) :: r - real(defReal), dimension(3), intent(in) :: u - real(defReal) :: d - real(defReal) :: tol, dSmall, dInc - integer(shortInt) :: it - real(defReal), dimension(3) :: rb, invFreq, coss, sins, grad - - ! Need to do a root-finding of some sort - so we iterate - dInc = INF - tol = SURF_TOL - - d = ZERO - - invFreq = TWO_PI / (self % freq) - dSmall = 0.01_defReal * dot_product(invFreq, u) - - r0 = r - it = 0 - - do while(dInc > tol .and. it < self % maxIt) - - it = it + 1 - - ! Move to origin-frame and scale by frequency - rb = (r0 - self % origin) * self % freq - - ! Evaluate the function - do i = 1, 3 - coss(i) = cos(rb(i)) - sins(i) = sin(rb(i)) - end do - - f = coss(1) * sins(2) + coss(2) * sins(3) + coss(3) * sins(1) - self % c - - ! Obtain the gradient - do i = 1, 3 - grad(i) = self % freq(i) * (coss(i) * coss(mod(i+1,3) + 1) - sins(i) * sins(mod(i,3) + 1) - end do - - ! How close are we? Should we use ray marching or Newton-Raphson? - - if (doNewton) then - - dInc = -f / dot_product(grad,u) - - - else - - - end if - - d = d + dInc - r0 = r0 + dInc * u - - end do - - end function distance - - !! - !! Returns TRUE if particle is going into +ve halfspace - !! Not defined for the gyroid surface which should only be used with delta tracking. - !! - !! See surface_inter for details - !! - pure function going(self, r, u) result(halfspace) - class(gyroid), intent(in) :: self - real(defReal), dimension(3), intent(in) :: r - real(defReal), dimension(3), intent(in) :: u - logical(defBool) :: halfspace - - halfspace = .false. - - end function going - - !! - !! Return to uninitialised state - !! - elemental subroutine kill(self) - class(gyroid), intent(inout) :: self - - ! Superclass - call kill_super(self) - - ! Local - self % origin = ZERO - self % freq = ZERO - self % c = ZERO - - end subroutine kill - -end module gyroid_class diff --git a/Geometry/Surfaces/torus_class.f90 b/Geometry/Surfaces/torus_class.f90 deleted file mode 100644 index 940c9c2f0..000000000 --- a/Geometry/Surfaces/torus_class.f90 +++ /dev/null @@ -1,310 +0,0 @@ -module torus_class - - use numPrecision - use universalVariables, only : SURF_TOL, INF, X_AXIS, Y_AXIS, Z_AXIS - use genericProcedures, only : fatalError, numToChar - use dictionary_class, only : dictionary - use surface_inter, only : kill_super => kill - - implicit none - private - - !! - !! Axis aligned elliptic torus - !! - !! F(r) = (ri - ri0)^2 / B^2 + (SQRT[(rj - rjo)^2 + (rk - rko)^2] - A)^2 / C^2 - 1 - !! - !! Where i,j,k (i /= j /= k) can be any of x,y & z axis - !! A is the major radius. B and C correspond to the minor radii which can - !! generally be eccentric. ri0, rj0, and rk0 are the origin of the torus - !! - !! Three diffrent types are avaliable - !! xTorus -> aligned with X-axis - !! yTorus -> aligned with Y-axis - !! zTorus -> aligned with Z-axis - !! - !! Surface tolerance: 2 * R * SURF_TOL ??? - !! - !! Sample dictionary input: - !! tor { type xTorus; // could be yTorus or zTorus as well - !! id 3; - !! origin (0.0 0.0 0.0); - !! coeffs (5 10 20; } // correspond to A B C above - !! - !! Private Members: - !! axis -> Index of an alignment axis in {X_AXIS, Y_AXIS, Z_AXIS} - !! plane -> Indices of axes in plane of torus {X_AXIS, Y_AXIS, Z_AXIS}\{axis} - !! origin -> Origin of the torus - !! r -> Toroidal radii A, B, and C - !! r_sq -> Square of radius r (r^2) - !! - !! Interface: - !! surface interface - !! - type, public, extends(surface) :: torus - private - integer(shortInt) :: axis = 0 - integer(shortInt), dimension(2) :: plane = [0, 0] - real(defReal), dimension(3) :: origin = ZERO - real(defReal), dimension(3) :: r = ZERO - real(defReal) :: r_sq = ZERO - contains - ! Superclass procedures - procedure :: myType - procedure :: init - procedure :: boundingBox - procedure :: evaluate - procedure :: distance - procedure :: going - procedure :: kill - - ! Local procedures - procedure :: build - - end type torus - -contains - - !! - !! Return surface type name - !! - !! See surface_inter for more details - !! - pure function myType(self) result(str) - class(torus), intent(in) :: self - character(:), allocatable :: str - - select case(self % axis) - case(X_AXIS) - str = 'xTorus' - - case(Y_AXIS) - str = 'yTorus' - - case(Z_AXIS) - str = 'zTorus' - - case default - str = 'unknown torus' - - end select - - end function myType - - !! - !! Initialise torus from a dictionary - !! - !! See surface_inter for more details - !! - !! Errors: - !! fatalError if radius or id < 0. - !! - subroutine init(self, dict) - class(torus), intent(inout) :: self - class(dictionary), intent(in) :: dict - integer(shortInt) :: id - real(defReal), dimension(:), allocatable :: origin, radii - character(nameLen) :: name - character(100), parameter :: Here = 'init (torus_class.f90)' - - ! Get from dictionary - call dict % get(id, 'id') - call dict % get(origin, 'origin') - call dict % get(radii, 'coeffs') - call dict % get(name, 'type') - - ! Ensure positive id - if (id <= 0) call fatalError(Here,'Surface id must be positive') - - ! Check origin size - if (size(origin) /= 3) then - call fatalError(Here,'Origin needs to have size 3. Has: '//numToChar(size(origin))) - end if - - ! Check radii size - if (size(radii) /= 3) then - call fatalError(Here,'coeffs needs to have size 3. Has: '//numToChar(size(radii))) - end if - - ! Ensure radii positivity - if (any(radii < 0)) call fatalError(Here,'Torus coeffs must be positive') - - ! Other necessary checks on radii? - - self % r = radii - self % origin = origin - call self % setID(id) - - ! Build torus - call self % build(name) - - ! Set surface tolerance - call self % setTol( TWO * self % r(1) * SURF_TOL) - - end subroutine init - - !! - !! Build torus from components - !! - !! Args: - !! id [in] -> Surface ID - !! type [in] -> Torus type {'xTorus', 'yTorus' or 'zTorus'} - !! - !! Errors: - !! fatalError if invalid torus type - !! - subroutine build(self, type) - class(torus), intent(inout) :: self - character(*), intent(in) :: type - character(100), parameter :: Here = 'build (torus_class.f90)' - - ! Select type of torus - select case(type) - case('xTorus') - self % axis = X_AXIS - self % plane = [Y_AXIS, Z_AXIS] - - case('yTorus') - self % axis = Y_AXIS - self % plane = [X_AXIS, Z_AXIS] - - case('zTorus') - self % axis = Z_AXIS - self % plane = [X_AXIS, Y_AXIS] - - case default - call fatalError(Here, 'Unknown type of torus: '//type) - - end select - - end subroutine build - - !! - !! Return axis-aligned bounding box for the surface - !! - !! See surface_inter for details - !! - pure function boundingBox(self) result(aabb) - class(torus), intent(in) :: self - real(defReal), dimension(6) :: aabb - - ! Top and bottom in a plane - aabb(self % plane) = self % origin(self % plane) - [self % r, self % r] - aabb(3 + self % plane) = self % origin(self % plane) + [self % r, self % r] - - ! Axis - aabb(self % axis) = -INF - aabb(3 + self % axis) = INF - - end function boundingBox - - !! - !! Evaluate surface expression c = F(r) - !! - !! See surface_inter for details - !! - pure function evaluate(self, r) result(c) - class(torus), intent(in) :: self - real(defReal), dimension(3), intent(in) :: r - real(defReal) :: c - - associate (x => r(self % axis), x0 => self % origin(self % axis), & - y => r(self % plane(1)), y0 => self % origin(self % plane(1)), & - z => r(self % plane(2)), z0 => self % origin(self % plane(2))) - c = (x - x0)**2 / self % r2(1) + & - (sqrt((y - y0)**2 + (z - z0)**2) - self % r(1)) / self % r(3) - 1 - - end associate - - end function evaluate - - !! - !! Return distance to the surface - !! - !! See surface_inter for details - !! - !! Solves quadratic intersection equation - !! ad^2 + 2kd + c = 0 - !! c = F(r) - !! k = (r1-x0)u1 + (r2-y0)u2 - !! a = u1^2 + u2^2 - !! - pure function distance(self, r, u) result(d) - class(torus), intent(in) :: self - real(defReal), dimension(3), intent(in) :: r - real(defReal), dimension(3), intent(in) :: u - real(defReal) :: d, a - real(defReal) :: c, k, delta - - ! Calculate quadratic components in the plane - c = self % evaluate(r) - k = dot_product(r(self % plane) - self % origin(self % plane) , u(self % plane)) - a = ONE - u(self % axis)**2 - delta = k*k - a*c ! Technically delta/4 - - ! Calculate the distance - if (delta < ZERO .or. a == ZERO) then ! No intersection - d = INF - - else if (abs(c) < self % surfTol()) then ! Point at a surface - if ( k >= ZERO) then - d = INF - else - d = -k + sqrt(delta) - d = d/a - end if - - else if (c < ZERO) then ! Point inside the surface - d = -k + sqrt(delta) - d = d/a - - else ! Point outside the surface - d = -k - sqrt(delta) - d = d/a - if (d <= ZERO) d = INF - - end if - - ! Cap distance at Infinity - d = min(d, INF) - - end function distance - - !! - !! Returns TRUE if particle is going into +ve halfspace - !! - !! See surface_inter for details - !! - pure function going(self, r, u) result(halfspace) - class(torus), intent(in) :: self - real(defReal), dimension(3), intent(in) :: r - real(defReal), dimension(3), intent(in) :: u - logical(defBool) :: halfspace - real(defReal), dimension(2) :: rp, up - - rp = r(self % plane) - self % origin(self % plane) - up = u(self % plane) - - halfspace = dot_product(rp , up ) >= ZERO - - end function going - - !! - !! Return to uninitialised state - !! - elemental subroutine kill(self) - class(torus), intent(inout) :: self - - ! Superclass - call kill_super(self) - - ! Local - self % axis = 0 - self % plane = 0 - self % origin = ZERO - self % r = ZERO - self % r_sq = ZERO - - end subroutine kill - -end module torus_class From e160db594f934210a4ef28f3c50ea91e397cc477 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 29 Aug 2025 11:38:34 +0100 Subject: [PATCH 15/27] Most of fieldMap with tweaks to fields --- .../cartesianField_class.f90 | 52 ++++-- .../pieceConstantField_inter.f90 | 114 ++++++++++++- Tallies/TallyMaps/Maps1D/fieldMap_class.f90 | 160 ++++++++++++++++++ 3 files changed, 302 insertions(+), 24 deletions(-) create mode 100644 Tallies/TallyMaps/Maps1D/fieldMap_class.f90 diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 index 56fcedc71..a23bb8ead 100644 --- a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 @@ -60,9 +60,10 @@ module cartesianField_class integer(shortInt), dimension(:), allocatable :: matIdxs contains ! Superclass procedures - procedure :: init + procedure :: init_dict procedure :: at procedure :: distance + procedure :: map procedure :: kill procedure, private :: getLocalID @@ -73,7 +74,7 @@ module cartesianField_class !! !! Initialisation !! - subroutine init(self, dict) + subroutine init_dict(self, dict) class(cartesianField), intent(inout) :: self class(dictionary), intent(in) :: dict type(dictionary) :: tempDict @@ -160,8 +161,8 @@ subroutine init(self, dict) ! Size field value array self % outLocalID = product(self % sizeN) + 1 - self % N = product(self % sizeN * self % nMat) + 1 - allocate(self % val(self % N)) + self % N = product(self % sizeN * self % nMat) + allocate(self % val(self % N + 1)) ! Read field values for each material idx0 = 0 @@ -193,7 +194,7 @@ subroutine init(self, dict) ! Set default value when not in the field call dict % getOrDefault(self % val(self % N), 'default', -INF) - end subroutine init + end subroutine init_dict !! !! Get value of the field at the co-ordinate point @@ -204,12 +205,29 @@ function at(self, coords) result(val) class(cartesianField), intent(in) :: self class(coordList), intent(in) :: coords real(defReal) :: val - integer(shortInt) :: idx, localID + integer(shortInt) :: localID - localID = self % getLocalID(coords % lvl(1) % r, coords % lvl(1) % dir) + localID = self % map (coords) + if (localID == 0) localID = self % outLocalID + val = self % val(localID) - if (localID == self % outLocalID) then - val = self % val(self % N) + end function at + + !! + !! Get index of the field at the co-ordinate point + !! + !! See pieceConstantField for details + !! + function map(self, coords) result(idx) + class(cartesianField), intent(in) :: self + class(coordList), intent(in) :: coords + integer(shortInt) :: idx + integer(shortInt) :: idx0 + + idx = self % getLocalID(coords % lvl(1) % r, coords % lvl(1) % dir) + + ! Outside the field + if (idx == 0) then return end if @@ -217,17 +235,15 @@ function at(self, coords) result(val) ! Compare against material idx ! Ensure material is present if (any(self % matIdxs == coords % matIdx)) then - idx = findloc(self % matIdxs, coords % matIdx, 1) - localID = localID + (idx - 1) * product(self % sizeN) + idx0 = findloc(self % matIdxs, coords % matIdx, 1) + idx = idx + (idx0 - 1) * product(self % sizeN) else if (self % matIdxs(1) == ALL_MATS) then - localID = localID + idx = idx else - localID = self % outLocalID + idx = 0 end if - - val = self % val(localID) - end function at + end function map !! !! Get distance to the next element of the field at the co-ordinate point and direction @@ -246,7 +262,7 @@ function distance(self, coords) result(d) localID = self % getLocalID(coords % lvl(1) % r, coords % lvl(1) % dir) ! Catch case if particle is outside the lattice - if (localID == self % outLocalID) then + if (localID == 0) then d = self % outline % distance(coords % lvl(1) % r, coords % lvl(1) % dir) return @@ -355,7 +371,7 @@ function getLocalID(self, r, u) result(localID) end do if (any(ijk <= 0 .or. ijk > self % sizeN)) then ! Point is outside lattice - localID = self % outLocalID + localID = 0 else localID = ijk(1) + self % sizeN(1) * (ijk(2)-1 + self % sizeN(2) * (ijk(3)-1)) diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 index 29e5aea77..7498f0501 100644 --- a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 +++ b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 @@ -24,26 +24,50 @@ module pieceConstantField_inter !! !! Interface: !! field interface - !! at -> Return scalar value given particle - !! distance -> Return distance to next element of the field - !! setValue -> Sets value of field at a given index - !! getMaxValue -> Returns the maximum field value + !! init -> Initialise from dictionary, which may contain a path + !! init_dict -> Initialises from a dictionary containing full description + !! init_file -> Initialises from a path to a full description + !! at -> Return scalar value given coordlist + !! map -> Returns field index given coordList + !! map_particle -> Returns field index given particle + !! distance -> Return distance to next element of the field + !! setValue -> Sets value of field at a given index + !! getMaxValue -> Returns the maximum field value + !! getSize -> Returns the size of the field !! type, public, abstract, extends(field) :: pieceConstantField real(defReal), dimension(:), allocatable :: val integer(shortInt) :: N = 0 contains - procedure(at), deferred :: at - procedure(distance), deferred :: distance + procedure(init_dict), deferred :: init_dict + procedure(at), deferred :: at + procedure(distance), deferred :: distance + procedure(map), deferred :: map + procedure :: init + procedure :: init_file + procedure :: map_particle procedure :: setValue procedure :: getMaxValue + procedure :: getSize procedure :: killSuper end type pieceConstantField abstract interface + !! + !! Initialise field from a dictionary + !! + !! Args: + !! dict [in] -> Dictionary describing field + !! + subroutine init_dict(self, dict) + import :: pieceConstantField, dictionary + class(pieceConstantField), intent(in) :: self + class(dictionary), intent(in) :: dict + end subroutine init_dict + !! !! Get value of the field at the given coordinates !! @@ -76,10 +100,63 @@ function distance(self, coords) result(d) real(defReal) :: d end function distance + !! + !! Get index of the field at the given coordinates + !! + !! Args: + !! coords [in] -> Coordinates of the position in the geometry + !! + !! Result: + !! Index into the field. Integer + !! + function map(self, coords) result(idx) + import :: pieceConstantField, coordList, shortInt + class(pieceConstantField), intent(in) :: self + class(coordList), intent(in) :: coords + integer(shortInt) :: idx + end function map + end interface contains + !! + !! Initialise field from a dictionary. This dictionary may contain + !! either the details of the field or a path to a further dictionary + !! + !! Args: + !! dict [in] -> Dictionary describing contents of field + !! + subroutine init(self, dict) + class(pieceConstantField), intent(inout) :: self + class(dictionary), intent(in) :: dict + character(pathLen) :: path + + if (dict % isPresent('path')) then + call dict % get(path, 'path') + call self % init_file(path) + else + call self % init_dict(dict) + end if + + end subroutine init_file + + !! + !! Initialise field from a file + !! + !! Args: + !! file [in] -> Path to a file containing the field definition + !! + subroutine init_file(self, path) + class(pieceConstantField), intent(inout) :: self + character(pathLen), intent(in) :: path + class(dictionary) :: dict + + call fileToDict(dict, path) + call self % init(dict) + + end subroutine init_file + !! !! Cast field pointer to pieceConstantField pointer !! @@ -132,6 +209,20 @@ subroutine setValue(self, val, idx) self % val(idx) = val end subroutine setValue + + !! + !! Returns the index of the field given a particle state. + !! + function map_particle(self, p) result(idx) + class(pieceConstantField), intent(in) :: self + type(particle), intent(in) :: p + integer(shortInt) :: idx + type(coordList) :: coords + + coords = p % coords + idx = self % map(coords) + + end function map_particle !! !! Returns the value of the maximum value of the field. @@ -152,6 +243,17 @@ function getMaxValue(self) result(val) end function getMaxValue + !! + !! Returns the size of the field. + !! + function getSize(self) result(N) + class(pieceConstantField), intent(in) :: self + integer(shortInt) :: N + + N = self % N + + end function getSize + !! !! Kills elements of the superclass !! diff --git a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 new file mode 100644 index 000000000..cfd92607a --- /dev/null +++ b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 @@ -0,0 +1,160 @@ +module fieldMap_class + + use numPrecision + use genericProcedures, only : fatalError, numToChar + use dictionary_class, only : dictionary + use particle_class, only : particleState + use outputFile_class, only : outputFile + use tallyMap1D_inter, only : tallyMap1D, kill_super => kill + + ! Geometry + use geometryStd_class, only : geometryStd, geometryStd_CptrCast + use geometry_inter, only : geometry + use geometryReg_mod, only : geomPtr, geomNum + use FIELDS + + implicit none + private + + !! + !! Map that wraps fields to locate a particle. Performs the field mapping, + !! returning the index that a particle occupies. + !! + !! Private Members: + !! default -> binIdx for cells not in binMap + !! Nbins -> Number of bins in the map + !! + !! Interface: + !! tallyMap Interface + !! + !! Sample Dictionary Input: + !! myMap { + !! type fieldMap; + !! + !! + !! } + !! + type, public,extends(tallyMap1D) :: fieldMap + private + integer(shortInt) :: default = 0 + integer(shortInt) :: Nbins = 0 + class(pieceConstantField) :: field + + contains + ! Superclass interface implementaction + procedure :: init + procedure :: bins + procedure :: map + procedure :: getAxisName + procedure :: print + procedure :: kill + + ! Class specific procedures + procedure :: build + + end type fieldMap + +contains + + !! + !! Initialise cell map from dictionary + !! + !! See tallyMap for specification + !! + subroutine init(self, dict) + class(fieldMap), intent(inout) :: self + class(dictionary), intent(in) :: dict + class(dictionary),pointer :: tempDict + + tempDict => dict % getDictPtr('field') + call self % field % init(tempDict) + self % Nbins = self % field % getSize() + + end subroutine init + + !! + !! Return total number of bins in the map/elements in the field + !! + !! See tallyMap for specification + !! + elemental function bins(self, D) result(N) + class(fieldMap), intent(in) :: self + integer(shortInt), intent(in) :: D + integer(shortInt) :: N + + if (D == 1 .or. D == 0) then + N = self % Nbins + else + N = 0 + end if + + end function bins + + !! + !! Map particle to a single bin. Return 0 for particle out of division + !! + !! See tallyMap for specification + !! + elemental function map(self,state) result(idx) + class(fieldMap), intent(in) :: self + class(particleState), intent(in) :: state + type(coordList) :: coords + integer(shortInt) :: idx + + call coords % assignPosition(state % r) + idx = self % field % map(coords) + + end function map + + !! + !! Return string that describes variable used to divide event space + !! + !! See tallyMap for specification + !! + function getAxisName(self) result(name) + class(fieldMap), intent(in) :: self + character(nameLen) :: name + + name = 'Field' + + end function getAxisName + + !! + !! Add information about division axis to the output file + !! + !! See tallyMap for specification + !! + subroutine print(self,out) + class(fieldMap), intent(in) :: self + class(outputFile), intent(inout) :: out + character(nameLen) :: name + integer(shortInt) :: i + + ! Name the array + name = trim(self % getAxisName()) // 'Bins' + + call out % startArray(name, [1, self % Nbins]) + + ! Print field indexes + do i = 1, self % Nbins + call out % addValue(numToChar(i)) + end do + + call out % endArray() + + end subroutine print + + !! + !! Return to uninitialised state + !! + elemental subroutine kill(self) + class(fieldMap), intent(inout) :: self + + call kill_super(self) + call self % field % kill() + self % Nbins = 0 + + end subroutine kill + + +end module fieldMap_class From 8f9efaf944c50621272b3010f45b9a333bedde79 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 29 Aug 2025 16:42:24 +0100 Subject: [PATCH 16/27] Finalise map for tallying on pieceConstant fields --- .../cartesianField_class.f90 | 24 ++-- .../pieceConstantField_inter.f90 | 14 +- IntegrationTestFiles/Geometry/densityField | 9 ++ IntegrationTestFiles/Geometry/test_field | 10 +- Tallies/TallyMaps/CMakeLists.txt | 4 +- .../TallyMaps/Maps1D/Tests/fieldMap_test.f90 | 120 ++++++++++++++++++ Tallies/TallyMaps/Maps1D/fieldMap_class.f90 | 46 +++++-- .../Maps1D/tallyMap1DFactory_func.f90 | 5 + 8 files changed, 192 insertions(+), 40 deletions(-) create mode 100644 IntegrationTestFiles/Geometry/densityField create mode 100644 Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 index a23bb8ead..763ed1e5b 100644 --- a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 @@ -160,7 +160,7 @@ subroutine init_dict(self, dict) end if ! Size field value array - self % outLocalID = product(self % sizeN) + 1 + self % outLocalID = product(self % sizeN) self % N = product(self % sizeN * self % nMat) allocate(self % val(self % N + 1)) @@ -192,7 +192,7 @@ subroutine init_dict(self, dict) end do ! Set default value when not in the field - call dict % getOrDefault(self % val(self % N), 'default', -INF) + call dict % getOrDefault(self % val(self % N + 1), 'default', -INF) end subroutine init_dict @@ -208,7 +208,7 @@ function at(self, coords) result(val) integer(shortInt) :: localID localID = self % map (coords) - if (localID == 0) localID = self % outLocalID + if (localID == 0) localID = self % N + 1 val = self % val(localID) end function at @@ -218,7 +218,7 @@ end function at !! !! See pieceConstantField for details !! - function map(self, coords) result(idx) + pure function map(self, coords) result(idx) class(cartesianField), intent(in) :: self class(coordList), intent(in) :: coords integer(shortInt) :: idx @@ -340,14 +340,14 @@ end subroutine kill !! !! Find the local integer ID in the field given position and direction !! - function getLocalID(self, r, u) result(localID) - class(cartesianField), intent(in) :: self - real(defReal), dimension(3) :: r - real(defReal), dimension(3) :: u - integer(shortInt) :: localID - real(defReal), dimension(3) :: r_bar - integer(shortInt), dimension(3) :: ijk - integer(shortInt) :: i, inc + pure function getLocalID(self, r, u) result(localID) + class(cartesianField), intent(in) :: self + real(defReal), dimension(3), intent(in) :: r + real(defReal), dimension(3), intent(in) :: u + integer(shortInt) :: localID + real(defReal), dimension(3) :: r_bar + integer(shortInt), dimension(3) :: ijk + integer(shortInt) :: i, inc ijk = floor((r - self % corner) / self % pitch) + 1 diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 index 7498f0501..68877bce5 100644 --- a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 +++ b/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 @@ -5,6 +5,8 @@ module pieceConstantField_inter use field_inter, only : field use coord_class, only : coordList use dictionary_class, only : dictionary + use particle_class, only : particle + use dictParser_func, only : fileToDict implicit none private @@ -64,8 +66,8 @@ module pieceConstantField_inter !! subroutine init_dict(self, dict) import :: pieceConstantField, dictionary - class(pieceConstantField), intent(in) :: self - class(dictionary), intent(in) :: dict + class(pieceConstantField), intent(inout) :: self + class(dictionary), intent(in) :: dict end subroutine init_dict !! @@ -109,7 +111,7 @@ end function distance !! Result: !! Index into the field. Integer !! - function map(self, coords) result(idx) + pure function map(self, coords) result(idx) import :: pieceConstantField, coordList, shortInt class(pieceConstantField), intent(in) :: self class(coordList), intent(in) :: coords @@ -139,7 +141,7 @@ subroutine init(self, dict) call self % init_dict(dict) end if - end subroutine init_file + end subroutine init !! !! Initialise field from a file @@ -150,7 +152,7 @@ end subroutine init_file subroutine init_file(self, path) class(pieceConstantField), intent(inout) :: self character(pathLen), intent(in) :: path - class(dictionary) :: dict + type(dictionary) :: dict call fileToDict(dict, path) call self % init(dict) @@ -211,7 +213,7 @@ subroutine setValue(self, val, idx) end subroutine setValue !! - !! Returns the index of the field given a particle state. + !! Returns the index of the field given a particle. !! function map_particle(self, p) result(idx) class(pieceConstantField), intent(in) :: self diff --git a/IntegrationTestFiles/Geometry/densityField b/IntegrationTestFiles/Geometry/densityField new file mode 100644 index 000000000..e4aa1ff0a --- /dev/null +++ b/IntegrationTestFiles/Geometry/densityField @@ -0,0 +1,9 @@ +type cartesianField; +materials (water); +origin (0 0 0); +shape (1 1 20); +pitch (1.27 1.27 20); +default -7; +water ( + 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2 +); diff --git a/IntegrationTestFiles/Geometry/test_field b/IntegrationTestFiles/Geometry/test_field index c8fe48932..7985149ff 100644 --- a/IntegrationTestFiles/Geometry/test_field +++ b/IntegrationTestFiles/Geometry/test_field @@ -14,15 +14,7 @@ temperature { } density { - type cartesianField; - materials (water); - origin (0 0 0); - shape (1 1 20); - pitch (1.27 1.27 20); - default -7; - water ( - 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2 - ); +file ./densityField; } surfaces { diff --git a/Tallies/TallyMaps/CMakeLists.txt b/Tallies/TallyMaps/CMakeLists.txt index 0ac9ee1d0..b804a9905 100644 --- a/Tallies/TallyMaps/CMakeLists.txt +++ b/Tallies/TallyMaps/CMakeLists.txt @@ -12,7 +12,8 @@ add_sources(./tallyMap_inter.f90 ./Maps1D/homogMatMap_class.f90 ./Maps1D/weightMap_class.f90 ./Maps1D/cellMap_class.f90 - ./Maps1D/radialMap_class.f90 + ./Maps1D/radialMap_class.f90 + ./Maps1D/fieldMap_class.f90 ./Maps1D/collNumMap_class.f90 ./Maps1D/directionMap_class.f90 ) @@ -27,5 +28,6 @@ add_unit_tests(./Tests/multiMap_test.f90 ./Maps1D/Tests/homogMatMap_test.f90 ./Maps1D/Tests/radialMap_test.f90 ./Maps1D/Tests/cellMap_test.f90 + ./Maps1D/Tests/fieldMap_test.f90 ./Maps1D/Tests/collNumMap_test.f90 ./Maps1D/Tests/directionMap_test.f90) diff --git a/Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 b/Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 new file mode 100644 index 000000000..81b99321f --- /dev/null +++ b/Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 @@ -0,0 +1,120 @@ +module fieldMap_test + use numPrecision + use funit + use particle_class, only : particleState + use dictionary_class, only : dictionary + use dictParser_func, only : charToDict + use charMap_class, only : charMap + use outputFile_class, only : outputFile + use fieldMap_class, only : fieldMap + + implicit none + + +@testCase + type, extends(TestCase) :: test_fieldMap + private + type(fieldMap),allocatable :: map_cartesian + contains + procedure :: setUp + procedure :: tearDown + end type test_fieldMap + + !! + !! Test parameters + !! + character(*), parameter :: FIELD_DEF = "& + & type cartesianField; origin (0 0 0); & + & pitch (3 2 1); materials (all); default 1; & + & shape (2 2 2); all (1 1 1 1 1 1 1 1);" + +contains + + !! + !! Sets up test_fieldMap object we can use in a number of tests + !! + subroutine setUp(this) + class(test_fieldMap), intent(inout) :: this + type(dictionary) :: dict, mapDict1, dictTemp + character(nameLen) :: name + + ! Store surfaces, cells and universes dictionaries + call charToDict(dictTemp, FIELD_DEF) + + ! Initialise dictionaries + call mapDict1 % init(2) + + ! Build material map definition + call mapDict1 % store('field', dictTemp) + allocate(this % map_cartesian, source = fieldMap(mapDict1)) + + end subroutine setUp + + !! + !! Kills test_fieldMap object we can use in a number of tests + !! + subroutine tearDown(this) + class(test_fieldMap), intent(inout) :: this + + call this % map_cartesian % kill() + + end subroutine tearDown + +!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> +!! PROPER TESTS BEGIN HERE +!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> + + !! + !! Mapping test without undefined bin + !! +@Test + subroutine testMapping(this) + class(test_fieldMap), intent(inout) :: this + type(particleState) :: state + integer(shortInt) :: i + integer(shortInt),dimension(4) :: bins + integer(shortInt),dimension(4),parameter :: EXPECTED_BINS = [7, 1, 6, 0] + real(defReal), dimension(12), parameter :: r = [-2.0, 1.0, 0.5, -1.0, -1.0, -0.5, 1.4, -0.1, 0.1, 10.0, 10.0, 10.0] + + ! Note ordering of cartesian field + do i = 1, size(EXPECTED_BINS) + state % r = r((3*(i-1) + 1):(3*i)) + bins(i) = this % map_cartesian % map(state) + end do + + @assertEqual(EXPECTED_BINS,bins) + + end subroutine testMapping + + + !! + !! Test number of bins inquiry + !! +@Test + subroutine testNumberOfBinsInquiry(this) + class(test_fieldMap), intent(inout) :: this + + @assertEqual(8, this % map_cartesian % bins(1)) + @assertEqual(0, this % map_cartesian % bins(2), 'higher dimension') + @assertEqual(0, this % map_cartesian % bins(-2),'invalid dimension') + + end subroutine testNumberOfBinsInquiry + + !! + !! Test correctness of print subroutine + !! Does not checks that values are correct, but that calls sequance is without errors + !! +@Test + subroutine testPrint(this) + class(test_fieldMap), intent(inout) :: this + type(outputFile) :: out + + call out % init('dummyPrinter', fatalErrors = .false.) + + call this % map_cartesian % print(out) + @assertTrue(out % isValid()) + call out % reset() + + end subroutine testPrint + +end module fieldMap_test diff --git a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 index cfd92607a..5d1dfad06 100644 --- a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 +++ b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 @@ -4,17 +4,23 @@ module fieldMap_class use genericProcedures, only : fatalError, numToChar use dictionary_class, only : dictionary use particle_class, only : particleState + use coord_class, only : coordList use outputFile_class, only : outputFile use tallyMap1D_inter, only : tallyMap1D, kill_super => kill - ! Geometry - use geometryStd_class, only : geometryStd, geometryStd_CptrCast - use geometry_inter, only : geometry - use geometryReg_mod, only : geomPtr, geomNum - use FIELDS + ! Field + use pieceConstantField_inter, only : pieceConstantField + use pieceConstantFieldFactory_func, only : new_pieceConstantField implicit none private + + !! + !! Constructor + !! + interface fieldMap + module procedure fieldMap_fromDict + end interface !! !! Map that wraps fields to locate a particle. Performs the field mapping, @@ -36,9 +42,9 @@ module fieldMap_class !! type, public,extends(tallyMap1D) :: fieldMap private - integer(shortInt) :: default = 0 - integer(shortInt) :: Nbins = 0 - class(pieceConstantField) :: field + integer(shortInt) :: default = 0 + integer(shortInt) :: Nbins = 0 + class(pieceConstantField), allocatable :: field contains ! Superclass interface implementaction @@ -49,9 +55,6 @@ module fieldMap_class procedure :: print procedure :: kill - ! Class specific procedures - procedure :: build - end type fieldMap contains @@ -67,7 +70,7 @@ subroutine init(self, dict) class(dictionary),pointer :: tempDict tempDict => dict % getDictPtr('field') - call self % field % init(tempDict) + call new_pieceConstantField(self % field, tempDict) self % Nbins = self % field % getSize() end subroutine init @@ -155,6 +158,25 @@ elemental subroutine kill(self) self % Nbins = 0 end subroutine kill + + !! + !! Build new field Map from dictionary + !! + !! Args: + !! dict[in] -> input dictionary for the map + !! + !! Result: + !! Initialised fieldMap instance + !! + !! Errors: + !! See init procedure. + !! + function fieldMap_fromDict(dict) result(new) + class(dictionary), intent(in) :: dict + type(fieldMap) :: new + + call new % init(dict) + end function fieldMap_fromDict end module fieldMap_class diff --git a/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 b/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 index c64ae1209..a044b26d7 100644 --- a/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 +++ b/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 @@ -35,6 +35,7 @@ module tallyMap1DFactory_func use collNumMap_class, only : collNumMap use radialMap_class, only : radialMap use directionMap_class, only : directionMap + use fieldMap_class, only : fieldMap implicit none private @@ -55,6 +56,7 @@ module tallyMap1DFactory_func 'collNumMap ',& 'radialMap ',& 'directionMap',& + 'fieldMap ',& 'testMap '] contains @@ -109,6 +111,9 @@ subroutine new_tallyMap1D(new, dict) case('radialMap') allocate(radialMap :: new) + case('fieldMap') + allocate(fieldMap :: new) + case('directionMap') allocate(directionMap :: new) From 58fa9875ed2f576909ab327f23ca47180780a08b Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 29 Aug 2025 16:45:54 +0100 Subject: [PATCH 17/27] Updated docs --- docs/User Manual.rst | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/docs/User Manual.rst b/docs/User Manual.rst index 7eb82785c..c573f9812 100644 --- a/docs/User Manual.rst +++ b/docs/User Manual.rst @@ -706,7 +706,8 @@ PieceConstantFields These are fields which are piecewise constant and are endowed with a distance calculation to compute the distance until the value of the field changes. These can be used for imposing -density and temperature distributions across the system in a convenient manner. +density and temperature distributions across the system in a convenient manner. Can be initialised +either with an explicit definition or with a path to the field definition. Currently there is only one available PieceConstantField: @@ -744,6 +745,8 @@ Example: :: 610 611 612); default 302; } + density { file ./myDensityField; } + Visualiser ---------- @@ -1375,6 +1378,14 @@ Examples: :: map1 { type spaceMap; axis x; grid lin; min -50.0; max 50.0; N 100; } map2 { type spaceMap; axis z; grid unstruct; bins (0.0 0.2 0.3 0.5 0.7 0.8 1.0); } +* fieldMap (1D map), map over superimposed fields. Limited currently to pieceConstantFields. + + - field: field definition, corresponding to those in pieceConstantFields. + +Examples: :: + + map1 { type fieldMap; field {file ./myField.txt } } + * weightMap (1D map), divides weight into number of discrete bins - grid: ``log`` for logarithmically spaced bins or ``lin`` for linearly spaced bins From 298b1fbf62d59ba24d3f958121539ba8342c9a4b Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 29 Aug 2025 17:07:54 +0100 Subject: [PATCH 18/27] Fix tests and docs --- IntegrationTestFiles/Geometry/densityField | 1 - IntegrationTestFiles/Geometry/test_field | 3 ++- docs/User Manual.rst | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/IntegrationTestFiles/Geometry/densityField b/IntegrationTestFiles/Geometry/densityField index e4aa1ff0a..a4074c31b 100644 --- a/IntegrationTestFiles/Geometry/densityField +++ b/IntegrationTestFiles/Geometry/densityField @@ -1,4 +1,3 @@ -type cartesianField; materials (water); origin (0 0 0); shape (1 1 20); diff --git a/IntegrationTestFiles/Geometry/test_field b/IntegrationTestFiles/Geometry/test_field index 7985149ff..9c3a06a16 100644 --- a/IntegrationTestFiles/Geometry/test_field +++ b/IntegrationTestFiles/Geometry/test_field @@ -14,7 +14,8 @@ temperature { } density { -file ./densityField; +type cartesianField; +path ./IntegrationTestFiles/Geometry/densityField; } surfaces { diff --git a/docs/User Manual.rst b/docs/User Manual.rst index c573f9812..dbd6b3173 100644 --- a/docs/User Manual.rst +++ b/docs/User Manual.rst @@ -745,7 +745,7 @@ Example: :: 610 611 612); default 302; } - density { file ./myDensityField; } + density { type cartesianField; file ./myDensityField; } Visualiser ---------- From fa7683a8c45ba72398a54d37e2d61a35cd91e328 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sun, 7 Dec 2025 20:15:07 +0000 Subject: [PATCH 19/27] Field interface accepts particles or coords --- .../neutronCEimp_class.f90 | 6 ++-- .../neutronMGimp_class.f90 | 2 +- .../Tests/uniformScalarField_test.f90 | 7 +++- .../Fields/ScalarFields/scalarField_inter.f90 | 35 +++++++++++++++---- .../ScalarFields/uniformScalarField_class.f90 | 20 +++++++++-- .../Tests/uniFissSitesField_test.f90 | 6 ++-- .../Tests/uniformVectorField_test.f90 | 7 +++- .../Tests/weightWindowsField_iTest.f90 | 4 +-- .../VectorFields/uniFissSitesField_class.f90 | 26 ++++++++++++-- .../VectorFields/uniformVectorField_class.f90 | 20 +++++++++-- .../Fields/VectorFields/vectorField_inter.f90 | 31 +++++++++++++--- .../VectorFields/weightWindowsField_class.f90 | 26 ++++++++++++-- 12 files changed, 157 insertions(+), 33 deletions(-) diff --git a/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 b/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 index ea42f32ad..1bd5accc3 100644 --- a/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 +++ b/CollisionOperator/CollisionProcessors/neutronCEimp_class.f90 @@ -305,7 +305,7 @@ subroutine implicit(self, p, tally, collDat, thisCycle, nextCycle) ! Sample number of fission sites generated ! Support -ve weight particles if (self % uniFissSites) then - val = self % ufsField % at(p) + val = self % ufsField % atP(p) n = int(abs( (wgt * sig_nufiss) / (sig_tot * k_eff))*val(1)/val(2) + rand1, shortInt) wgt = val(2)/val(1) else @@ -422,7 +422,7 @@ subroutine fission(self, p, tally, collDat, thisCycle, nextCycle) ! Support -ve weight particles ! Note change of denominator (sig_fiss) wrt implicit generation if (self % uniFissSites) then - val = self % ufsField % at(p) + val = self % ufsField % atP(p) n = int(abs( (wgt * sig_nufiss) / (sig_fiss * k_eff))*val(1)/val(2) + rand1, shortInt) wgt = val(2)/val(1) else @@ -572,7 +572,7 @@ subroutine cutoffs(self, p, tally, collDat, thisCycle, nextCycle) ! Weight Windows treatment elseif (self % weightWindows) then - val = self % weightWindowsMap % at(p) + val = self % weightWindowsMap % atP(p) minWgt = val(1) maxWgt = val(2) avWgt = val(3) diff --git a/CollisionOperator/CollisionProcessors/neutronMGimp_class.f90 b/CollisionOperator/CollisionProcessors/neutronMGimp_class.f90 index bc2155c22..d22258455 100644 --- a/CollisionOperator/CollisionProcessors/neutronMGimp_class.f90 +++ b/CollisionOperator/CollisionProcessors/neutronMGimp_class.f90 @@ -315,7 +315,7 @@ subroutine cutoffs(self, p, tally, collDat, thisCycle, nextCycle) ! Weight Windows treatment elseif (self % weightWindows) then - val = self % weightWindowsMap % at(p) + val = self % weightWindowsMap % atP(p) minWgt = val(1) maxWgt = val(2) avWgt = val(3) diff --git a/Geometry/Fields/ScalarFields/Tests/uniformScalarField_test.f90 b/Geometry/Fields/ScalarFields/Tests/uniformScalarField_test.f90 index b4de8840a..01b220c2a 100644 --- a/Geometry/Fields/ScalarFields/Tests/uniformScalarField_test.f90 +++ b/Geometry/Fields/ScalarFields/Tests/uniformScalarField_test.f90 @@ -2,6 +2,7 @@ module uniformScalarField_test use numPrecision use dictionary_class, only : dictionary + use coord_class, only : coordList use particle_class, only : particle use field_inter, only : field use scalarField_inter, only : scalarField, scalarField_CptrCast @@ -23,6 +24,7 @@ subroutine test_uniformScalarField() type(uniformScalarField), pointer :: ptr2 type(dictionary) :: dict type(particle) :: p + type(coordList) :: coords real(defReal), parameter :: TOL = 1.0E-7_defReal ! Test invalid pointers @@ -50,7 +52,10 @@ subroutine test_uniformScalarField() call fieldT % init(dict) ! Check value - @assertEqual(9.6_defReal, fieldT % at(p), TOL) + @assertEqual(9.6_defReal, fieldT % atP(p), TOL) + + call coords % assignPosition([ZERO, ZERO, ZERO]) + @assertEqual(9.6_defReal, fieldT % at(coords), TOL) ! Kill call fieldT % kill() diff --git a/Geometry/Fields/ScalarFields/scalarField_inter.f90 b/Geometry/Fields/ScalarFields/scalarField_inter.f90 index f1772eac0..66b10e185 100644 --- a/Geometry/Fields/ScalarFields/scalarField_inter.f90 +++ b/Geometry/Fields/ScalarFields/scalarField_inter.f90 @@ -2,6 +2,7 @@ module scalarField_inter use numPrecision use field_inter, only : field + use coord_class, only : coordList use particle_class, only : particle implicit none @@ -18,13 +19,17 @@ module scalarField_inter !! Access to field is via coordList to allow more fancy fields to be defined !! (e.g. assign value to each uniqueID etc.) !! + !! Also allows access by particle until WW and UFS are sorted + !! !! Interface: !! field interface - !! at -> Return scalar value given position coordinates + !! at -> Return scalar value given position coordinates + !! atP -> Return scalar value given particle !! type, public, abstract, extends(field) :: scalarField contains - procedure(at), deferred :: at + procedure(at), deferred :: at + procedure(atP), deferred :: atP end type scalarField abstract interface @@ -38,12 +43,28 @@ module scalarField_inter !! Result: !! Value of the scalar field. Real number. !! - function at(self, p) result(val) - import :: scalarField, particle, defReal - class(scalarField), intent(in) :: self - class(particle), intent(inout) :: p - real(defReal) :: val + function at(self, coords) result(val) + import :: scalarField, coordList, defReal + class(scalarField), intent(in) :: self + class(coordList), intent(in) :: coords + real(defReal) :: val end function at + + !! + !! Get value of the scalar field at the particle's phase space point + !! + !! Args: + !! particle [in] -> Coordinates + other phase space info + !! + !! Result: + !! Value of the scalar field. Real number. + !! + function atP(self, p) result(val) + import :: scalarField, particle, defReal + class(scalarField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal) :: val + end function atP end interface diff --git a/Geometry/Fields/ScalarFields/uniformScalarField_class.f90 b/Geometry/Fields/ScalarFields/uniformScalarField_class.f90 index 06ea0a253..5d22cf27b 100644 --- a/Geometry/Fields/ScalarFields/uniformScalarField_class.f90 +++ b/Geometry/Fields/ScalarFields/uniformScalarField_class.f90 @@ -2,6 +2,7 @@ module uniformScalarField_class use numPrecision use dictionary_class, only : dictionary + use coord_class, only : coordList use particle_class, only : particle use field_inter, only : field use scalarField_inter, only : scalarField @@ -35,6 +36,7 @@ module uniformScalarField_class procedure :: init procedure :: kill procedure :: at + procedure :: atP end type uniformScalarField contains @@ -68,14 +70,28 @@ end subroutine kill !! !! See scalarField_inter for details !! - function at(self, p) result(val) + function at(self, coords) result(val) class(uniformScalarField), intent(in) :: self - class(particle), intent(inout) :: p + class(coordList), intent(in) :: coords real(defReal) :: val val = self % val end function at + + !! + !! Get value of the scalar field at particle phase space location + !! + !! See scalarField_inter for details + !! + function atP(self, p) result(val) + class(uniformScalarField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal) :: val + + val = self % val + + end function atP !! !! Cast field pointer to uniformScalarField pointer diff --git a/Geometry/Fields/VectorFields/Tests/uniFissSitesField_test.f90 b/Geometry/Fields/VectorFields/Tests/uniFissSitesField_test.f90 index 392fc9bc9..1fb2c3463 100644 --- a/Geometry/Fields/VectorFields/Tests/uniFissSitesField_test.f90 +++ b/Geometry/Fields/VectorFields/Tests/uniFissSitesField_test.f90 @@ -81,14 +81,14 @@ subroutine testGetValue(this) ! Test case in the map p % coords % lvl(1) % r = [0.5, 7.0, 50.0] - bins = this % ufsField % at(p) + bins = this % ufsField % atP(p) EXPECTED_BINS = [0.25, 0.25, 0.0] @assertEqual(EXPECTED_BINS, bins, tolerance=1.0e-6) ! Test case outside the map p % coords % lvl(1) % r = [0.5, 7.0, 100.0] - bins = this % ufsField % at(p) + bins = this % ufsField % atP(p) EXPECTED_BINS = [1.0, 1.0, 1.0] @assertEqual(EXPECTED_BINS,bins) @@ -107,7 +107,7 @@ subroutine testGetValue(this) ! Test case in the updated map p % coords % lvl(1) % r = [0.5, 7.0, 18.1] - bins = this % ufsField % at(p) + bins = this % ufsField % atP(p) EXPECTED_BINS = [0.25, 0.06666666667, 0.0] @assertEqual(EXPECTED_BINS, bins, tolerance=1.0e-6) diff --git a/Geometry/Fields/VectorFields/Tests/uniformVectorField_test.f90 b/Geometry/Fields/VectorFields/Tests/uniformVectorField_test.f90 index ee0eb181c..357280190 100644 --- a/Geometry/Fields/VectorFields/Tests/uniformVectorField_test.f90 +++ b/Geometry/Fields/VectorFields/Tests/uniformVectorField_test.f90 @@ -2,6 +2,7 @@ module uniformVectorField_test use numPrecision use dictionary_class, only : dictionary + use coord_class, only : coordList use particle_class, only : particle use field_inter, only : field use vectorField_inter, only : vectorField, vectorField_CptrCast @@ -23,6 +24,7 @@ subroutine test_uniformVectorField() type(uniformVectorField), pointer :: ptr2 type(dictionary) :: dict type(particle) :: p + type(coordList) :: coords real(defReal), parameter :: TOL = 1.0E-7_defReal ! Test invalid pointers @@ -50,7 +52,10 @@ subroutine test_uniformVectorField() call fieldT % init(dict) ! Check value - @assertEqual([9.6_defReal, -8.0_defReal, 9.7_defReal], fieldT % at(p), TOL) + @assertEqual([9.6_defReal, -8.0_defReal, 9.7_defReal], fieldT % atP(p), TOL) + + call coords % assignPosition([ZERO, ZERO, ZERO]) + @assertEqual([9.6_defReal, -8.0_defReal, 9.7_defReal], fieldT % at(coords), TOL) ! Kill call fieldT % kill() diff --git a/Geometry/Fields/VectorFields/Tests/weightWindowsField_iTest.f90 b/Geometry/Fields/VectorFields/Tests/weightWindowsField_iTest.f90 index 1fd2d320c..1a89e9e59 100644 --- a/Geometry/Fields/VectorFields/Tests/weightWindowsField_iTest.f90 +++ b/Geometry/Fields/VectorFields/Tests/weightWindowsField_iTest.f90 @@ -67,7 +67,7 @@ subroutine testGetValue(this) p % coords % lvl(1) % r = [0.5, 7.0, 0.0] p % E = 10.0 - bins = this % wwField % at(p) + bins = this % wwField % atP(p) EXPECTED_BINS = [0.4, 1.5, 0.8] @assertEqual(EXPECTED_BINS, bins, tolerance=1e-6) @@ -76,7 +76,7 @@ subroutine testGetValue(this) p % coords % lvl(1) % r = [-0.5, 7.0, 0.0] p % E = 10.0 - bins = this % wwField % at(p) + bins = this % wwField % atP(p) EXPECTED_BINS = ZERO @assertEqual(EXPECTED_BINS, bins, tolerance=1e-6) diff --git a/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 b/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 index 0bb8425e3..e57fdb865 100644 --- a/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 +++ b/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 @@ -4,6 +4,7 @@ module uniFissSitesField_class use genericProcedures, only : fatalError, numToChar use universalVariables, only : OUTSIDE_MAT, VOID_MAT, P_NEUTRON_CE use dictionary_class, only : dictionary + use coord_class, only : coordList use particle_class, only : particle, particleState use field_inter, only : field use vectorField_inter, only : vectorField @@ -77,6 +78,7 @@ module uniFissSitesField_class procedure :: kill procedure :: estimateVol procedure :: at + procedure :: atP procedure :: storeFS procedure :: updateMap end type uniFissSitesField @@ -230,15 +232,33 @@ subroutine estimateVol(self, geom, rand, type) end if end subroutine estimateVol + + !! + !! Get value of the vector field given coordinates + !! Not defined for UFS field + !! + !! See vectorField_inter for details + !! + function at(self, coords) result(val) + class(uniFissSitesField), intent(in) :: self + class(coordList), intent(in) :: coords + real(defReal), dimension(3) :: val + type(particleState) :: state + integer(shortInt) :: binIdx + character(100), parameter :: Here = 'at (uniFissSitesField_class.f90)' + + call fatalError(Here,'Not defined when providing coords - must provide particle.') + + end function at !! !! Get value of the vector field given the phase-space location of a particle !! !! See vectorField_inter for details !! - function at(self, p) result(val) + function atP(self, p) result(val) class(uniFissSitesField), intent(in) :: self - class(particle), intent(inout) :: p + class(particle), intent(in) :: p real(defReal), dimension(3) :: val type(particleState) :: state integer(shortInt) :: binIdx @@ -259,7 +279,7 @@ function at(self, p) result(val) val(2) = self % sourceFraction(binIdx) val(3) = ZERO - end function at + end function atP !! !! Store the fission sites generated in a vector diff --git a/Geometry/Fields/VectorFields/uniformVectorField_class.f90 b/Geometry/Fields/VectorFields/uniformVectorField_class.f90 index 607eb8900..b844b831d 100644 --- a/Geometry/Fields/VectorFields/uniformVectorField_class.f90 +++ b/Geometry/Fields/VectorFields/uniformVectorField_class.f90 @@ -3,6 +3,7 @@ module uniformVectorField_class use numPrecision use genericProcedures, only : fatalError, numToChar use dictionary_class, only : dictionary + use coord_class, only : coordList use particle_class, only : particle use field_inter, only : field use vectorField_inter, only : vectorField @@ -36,6 +37,7 @@ module uniformVectorField_class procedure :: init procedure :: kill procedure :: at + procedure :: atP end type uniformVectorField contains @@ -77,14 +79,28 @@ end subroutine kill !! !! See vectorField_inter for details !! - function at(self, p) result(val) + function at(self, coords) result(val) class(uniformVectorField), intent(in) :: self - class(particle), intent(inout) :: p + class(coordList), intent(in) :: coords real(defReal), dimension(3) :: val val = self % val end function at + + !! + !! Get value of the scalar field by particle + !! + !! See vectorField_inter for details + !! + function atP(self, p) result(val) + class(uniformVectorField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal), dimension(3) :: val + + val = self % val + + end function atP !! !! Cast field pointer to uniformVectorField pointer diff --git a/Geometry/Fields/VectorFields/vectorField_inter.f90 b/Geometry/Fields/VectorFields/vectorField_inter.f90 index a3b35ac20..63e490ae7 100644 --- a/Geometry/Fields/VectorFields/vectorField_inter.f90 +++ b/Geometry/Fields/VectorFields/vectorField_inter.f90 @@ -2,6 +2,7 @@ module vectorField_inter use numPrecision use field_inter, only : field + use coord_class, only : coordList use particle_class, only : particle implicit none @@ -18,13 +19,17 @@ module vectorField_inter !! Access to field is via coordList to allow more fancy fields to be defined !! (e.g. assign vector to each uniqueID etc.) !! + !! Also allows access by particle until WW and UFS are sorted + !! !! Interface: !! field interface - !! at -> Return vector value given position coordinates + !! at -> Return vector value given position coordinates + !! atP -> Return vector value given particle !! type, public, abstract, extends(field) :: vectorField contains - procedure(at), deferred :: at + procedure(at), deferred :: at + procedure(atP), deferred :: atP end type vectorField abstract interface @@ -38,13 +43,29 @@ module vectorField_inter !! Result: !! Size 3 vector of real values. !! - function at(self, p) result(val) - import :: vectorField, particle, defReal + function at(self, coords) result(val) + import :: vectorField, coordList, defReal class(vectorField), intent(in) :: self - class(particle), intent(inout) :: p + class(coordList), intent(in) :: coords real(defReal), dimension(3) :: val end function at + !! + !! Get value of the vector field by particle + !! + !! Args: + !! particle [in] -> Coordinates + other phase space info + !! + !! Result: + !! Size 3 vector of real values. + !! + function atP(self, p) result(val) + import :: vectorField, particle, defReal + class(vectorField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal), dimension(3) :: val + end function atP + end interface contains diff --git a/Geometry/Fields/VectorFields/weightWindowsField_class.f90 b/Geometry/Fields/VectorFields/weightWindowsField_class.f90 index b055a896f..a9d9c71b0 100644 --- a/Geometry/Fields/VectorFields/weightWindowsField_class.f90 +++ b/Geometry/Fields/VectorFields/weightWindowsField_class.f90 @@ -4,6 +4,7 @@ module weightWindowsField_class use genericProcedures, only : fatalError, numToChar use dictionary_class, only : dictionary use dictParser_func, only : fileToDict + use coord_class, only : coordList use particle_class, only : particle, particleState use field_inter, only : field use vectorField_inter, only : vectorField @@ -61,6 +62,7 @@ module weightWindowsField_class procedure :: init procedure :: kill procedure :: at + procedure :: atP end type weightWindowsField contains @@ -120,15 +122,33 @@ elemental subroutine kill(self) self % constSurvival = ZERO end subroutine kill + + !! + !! Get value of the vector field by coordinate + !! Not defined for weight windows + !! + !! See vectorField_inter for details + !! + function at(self, coords) result(val) + class(weightWindowsField), intent(in) :: self + class(coordList), intent(in) :: coords + real(defReal), dimension(3) :: val + type(particleState) :: state + integer(shortInt) :: binIdx + character(100), parameter :: Here = 'at (weightWindowsField_class.f90)' + + call fatalError(Here,'Invalid to access by coords only.') + + end function at !! !! Get value of the vector field given the phase-space location of a particle !! !! See vectorField_inter for details !! - function at(self, p) result(val) + function atP(self, p) result(val) class(weightWindowsField), intent(in) :: self - class(particle), intent(inout) :: p + class(particle), intent(in) :: p real(defReal), dimension(3) :: val type(particleState) :: state integer(shortInt) :: binIdx @@ -149,7 +169,7 @@ function at(self, p) result(val) val(2) = self % upperW(binIdx) val(3) = val(1) * self % constSurvival - end function at + end function atP !! !! Cast field pointer to weightWindowsField pointer From 13c1ecb956cf4f59e1a6376732866904a1472328 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sun, 7 Dec 2025 21:16:13 +0000 Subject: [PATCH 20/27] Updating field interface --- Geometry/Fields/CMakeLists.txt | 1 - Geometry/Fields/ScalarFields/CMakeLists.txt | 1 + .../PieceConstantFields/CMakeLists.txt | 0 .../Tests/cartesianField_test.f90 | 0 .../cartesianField_class.f90 | 16 ++++++++++ .../pieceConstantField_inter.f90 | 30 +++++-------------- .../VectorFields/uniFissSitesField_class.f90 | 3 +- .../VectorFields/weightWindowsField_class.f90 | 3 +- 8 files changed, 27 insertions(+), 27 deletions(-) rename Geometry/Fields/{ => ScalarFields}/PieceConstantFields/CMakeLists.txt (100%) rename Geometry/Fields/{ => ScalarFields}/PieceConstantFields/Tests/cartesianField_test.f90 (100%) rename Geometry/Fields/{ => ScalarFields}/PieceConstantFields/cartesianField_class.f90 (96%) rename Geometry/Fields/{ => ScalarFields}/PieceConstantFields/pieceConstantField_inter.f90 (84%) diff --git a/Geometry/Fields/CMakeLists.txt b/Geometry/Fields/CMakeLists.txt index 16dc30d76..edb182848 100644 --- a/Geometry/Fields/CMakeLists.txt +++ b/Geometry/Fields/CMakeLists.txt @@ -1,6 +1,5 @@ add_subdirectory(ScalarFields) add_subdirectory(VectorFields) -add_subdirectory(PieceConstantFields) add_sources(./field_inter.f90) diff --git a/Geometry/Fields/ScalarFields/CMakeLists.txt b/Geometry/Fields/ScalarFields/CMakeLists.txt index 53f855cf7..4e0c0cb5f 100644 --- a/Geometry/Fields/ScalarFields/CMakeLists.txt +++ b/Geometry/Fields/ScalarFields/CMakeLists.txt @@ -1,3 +1,4 @@ +add_subdirectory(PieceConstantFields) add_sources( ./scalarField_inter.f90 ./uniformScalarField_class.f90) diff --git a/Geometry/Fields/PieceConstantFields/CMakeLists.txt b/Geometry/Fields/ScalarFields/PieceConstantFields/CMakeLists.txt similarity index 100% rename from Geometry/Fields/PieceConstantFields/CMakeLists.txt rename to Geometry/Fields/ScalarFields/PieceConstantFields/CMakeLists.txt diff --git a/Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 b/Geometry/Fields/ScalarFields/PieceConstantFields/Tests/cartesianField_test.f90 similarity index 100% rename from Geometry/Fields/PieceConstantFields/Tests/cartesianField_test.f90 rename to Geometry/Fields/ScalarFields/PieceConstantFields/Tests/cartesianField_test.f90 diff --git a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/ScalarFields/PieceConstantFields/cartesianField_class.f90 similarity index 96% rename from Geometry/Fields/PieceConstantFields/cartesianField_class.f90 rename to Geometry/Fields/ScalarFields/PieceConstantFields/cartesianField_class.f90 index 255fe4345..7cc32ab64 100644 --- a/Geometry/Fields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/ScalarFields/PieceConstantFields/cartesianField_class.f90 @@ -6,6 +6,7 @@ module cartesianField_class use field_inter, only : field use pieceConstantField_inter, only : pieceConstantField use coord_class, only : coordList + use particle_class, only : particle use dictionary_class, only : dictionary use box_class, only : box use materialMenu_mod, only : mm_matIdx => matIdx @@ -62,6 +63,7 @@ module cartesianField_class ! Superclass procedures procedure :: init procedure :: at + procedure :: atP procedure :: distance procedure :: kill @@ -223,6 +225,20 @@ function at(self, coords) result(val) val = self % val(localID) end function at + + !! + !! Get value of the field at the particle's location + !! + !! See pieceConstantField for details + !! + function atP(self, p) result(val) + class(cartesianField), intent(in) :: self + class(particle), intent(in) :: p + real(defReal) :: val + + val = self % at(p % coords) + + end function atP !! !! Get distance to the next element of the field at the co-ordinate point and direction diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 b/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantField_inter.f90 similarity index 84% rename from Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 rename to Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantField_inter.f90 index 09c1ba638..b6413b1a9 100644 --- a/Geometry/Fields/PieceConstantFields/pieceConstantField_inter.f90 +++ b/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantField_inter.f90 @@ -2,9 +2,11 @@ module pieceConstantField_inter use numPrecision use genericProcedures, only : fatalError, numToChar - use field_inter, only : field + use scalarField_inter, only : scalarField use coord_class, only : coordList use dictionary_class, only : dictionary + use field_inter, only : field + use scalarField_inter, only : scalarField implicit none private @@ -24,16 +26,16 @@ module pieceConstantField_inter !! !! Interface: !! field interface - !! at -> Return scalar value given particle + !! at -> Return scalar value given coordinates + !! atP -> Return scalar value given particle !! distance -> Return distance to next element of the field !! setValue -> Sets value of field at a given index !! getMaxValue -> Returns the maximum field value !! - type, public, abstract, extends(field) :: pieceConstantField - real(defReal), dimension(:), allocatable :: val - integer(shortInt) :: N = 0 + type, public, abstract, extends(scalarField) :: pieceConstantField + real(defReal), dimension(:), allocatable :: val + integer(shortInt) :: N = 0 contains - procedure(at), deferred :: at procedure(distance), deferred :: distance procedure :: setValue @@ -44,22 +46,6 @@ module pieceConstantField_inter abstract interface - !! - !! Get value of the field at the given coordinates - !! - !! Args: - !! coords [in] -> Coordinates of the position in the geometry - !! - !! Result: - !! Value of the scalar field. Real number. - !! - function at(self, coords) result(val) - import :: pieceConstantField, coordList, defReal - class(pieceConstantField), intent(in) :: self - class(coordList), intent(in) :: coords - real(defReal) :: val - end function at - !! !! Get distance to the next element of the field at the given coordinates !! diff --git a/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 b/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 index e57fdb865..401a8bdc5 100644 --- a/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 +++ b/Geometry/Fields/VectorFields/uniFissSitesField_class.f90 @@ -243,10 +243,9 @@ function at(self, coords) result(val) class(uniFissSitesField), intent(in) :: self class(coordList), intent(in) :: coords real(defReal), dimension(3) :: val - type(particleState) :: state - integer(shortInt) :: binIdx character(100), parameter :: Here = 'at (uniFissSitesField_class.f90)' + val = ZERO call fatalError(Here,'Not defined when providing coords - must provide particle.') end function at diff --git a/Geometry/Fields/VectorFields/weightWindowsField_class.f90 b/Geometry/Fields/VectorFields/weightWindowsField_class.f90 index a9d9c71b0..71d40a955 100644 --- a/Geometry/Fields/VectorFields/weightWindowsField_class.f90 +++ b/Geometry/Fields/VectorFields/weightWindowsField_class.f90 @@ -133,10 +133,9 @@ function at(self, coords) result(val) class(weightWindowsField), intent(in) :: self class(coordList), intent(in) :: coords real(defReal), dimension(3) :: val - type(particleState) :: state - integer(shortInt) :: binIdx character(100), parameter :: Here = 'at (weightWindowsField_class.f90)' + val = ZERO call fatalError(Here,'Invalid to access by coords only.') end function at From 028775a9a640ce5be0a1fde891cf94655dd40332 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sun, 7 Dec 2025 21:38:25 +0000 Subject: [PATCH 21/27] Moving the PCField factory --- .../PieceConstantFields/pieceConstantFieldFactory_func.f90 | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename Geometry/Fields/{ => ScalarFields}/PieceConstantFields/pieceConstantFieldFactory_func.f90 (100%) diff --git a/Geometry/Fields/PieceConstantFields/pieceConstantFieldFactory_func.f90 b/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantFieldFactory_func.f90 similarity index 100% rename from Geometry/Fields/PieceConstantFields/pieceConstantFieldFactory_func.f90 rename to Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantFieldFactory_func.f90 From a9952725f16acce60cf9ab139856f59736ba2400 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Mon, 15 Dec 2025 20:45:04 +0000 Subject: [PATCH 22/27] Removing merge artefacts --- TransportOperator/transportOperatorHT_class.f90 | 5 ----- 1 file changed, 5 deletions(-) diff --git a/TransportOperator/transportOperatorHT_class.f90 b/TransportOperator/transportOperatorHT_class.f90 index 3041da821..ad3afc80d 100644 --- a/TransportOperator/transportOperatorHT_class.f90 +++ b/TransportOperator/transportOperatorHT_class.f90 @@ -229,10 +229,6 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) ! Save state before movement call p % savePrePath() -<<<<<<< HEAD - ! Move to the next stop. NOTE: "move" resets dist to distance moved! - call self % geom % move(p % coords, dist, event) -======= ! Move to the next stop. if (self % cache) then call self % geom % move_withCache(p % coords, dist, event, cache) @@ -245,7 +241,6 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) ! Set fate if a collision occurred if (event == COLL_EV) p % fate = collFate ->>>>>>> develop ! Send tally report for a path moved call tally % reportPath(p, dist) From aa6c30957ad152b17b5283e55f971a7934b039fe Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Tue, 10 Feb 2026 18:26:10 +0000 Subject: [PATCH 23/27] Mid-changes --- .../aceDatabase/aceNeutronDatabase_class.f90 | 13 ++++++++++--- .../baseMgNeutron/baseMgNeutronDatabase_class.f90 | 11 +++++++++-- NuclearData/nuclearDatabase_inter.f90 | 15 +++++++++------ .../testNeutronData/testNeutronDatabase_class.f90 | 2 +- ParticleObjects/Source/fissionSource_class.f90 | 5 +++-- ParticleObjects/Source/materialSource_class.f90 | 2 +- ParticleObjects/particle_class.f90 | 4 ++-- SharedModules/universalVariables.f90 | 4 ++++ Tallies/TallyMaps/Maps1D/fieldMap_class.f90 | 2 +- docs/User Manual.rst | 2 +- 10 files changed, 41 insertions(+), 19 deletions(-) diff --git a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 index 854f8e285..8a8fed1cb 100644 --- a/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 +++ b/NuclearData/ceNeutronData/aceDatabase/aceNeutronDatabase_class.f90 @@ -1325,9 +1325,10 @@ end subroutine activate !! subroutine initMajorant(self, loud, maxTemp, scaleDensity) class(aceNeutronDatabase), intent(inout) :: self - logical(defBool), intent(in) :: loud + logical(defBool), intent(in), optional :: loud real(defReal), intent(in), optional :: maxTemp real(defReal), intent(in), optional :: scaleDensity + logical(defBool) :: isLoud real(defReal), dimension(:), allocatable :: tmpGrid integer(shortInt) :: i, j, k, matIdx, nNuc, nucIdx, isDone, & sizeGrid, eIdx, nucIdxLast, eIdxLast, & @@ -1339,6 +1340,12 @@ subroutine initMajorant(self, loud, maxTemp, scaleDensity) integer(shortInt), parameter :: IN_SET = 1, NOT_PRESENT = 0 real(defReal), parameter :: NUDGE = 1.0e-06_defReal + if (present(loud)) then + isLoud = loud + else + isLoud = .false. + end if + ! Check maxTemp is present and sensible if (present(maxTemp)) then if (maxTemp < ZERO) then @@ -1523,7 +1530,7 @@ subroutine initMajorant(self, loud, maxTemp, scaleDensity) ! Save final grid and remove duplicates self % eGridUnion = removeDuplicatesSorted(tmpGrid) - if (loud) then + if (isLoud) then print '(A)', 'CE unionised energy grid has size: '//numToChar(size(self % eGridUnion)) end if @@ -1605,7 +1612,7 @@ subroutine initMajorant(self, loud, maxTemp, scaleDensity) end do - if (loud) print '(A)', 'CE unionised majorant cross section calculation completed' + if (isLoud) print '(A)', 'CE unionised majorant cross section calculation completed' end subroutine initMajorant diff --git a/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 b/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 index f7ec5d70a..a710a9dec 100644 --- a/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 +++ b/NuclearData/mgNeutronData/baseMgNeutron/baseMgNeutronDatabase_class.f90 @@ -451,13 +451,20 @@ end subroutine activate !! subroutine initMajorant(self, loud, maxTemp, scaleDensity) class(baseMgNeutronDatabase), intent(inout) :: self - logical(defBool), intent(in) :: loud + logical(defBool), optional, intent(in) :: loud real(defReal), optional, intent(in) :: maxTemp real(defReal), optional, intent(in) :: scaleDensity + logical(defBool) :: isLoud integer(shortInt) :: g, i, idx real(defReal) :: xs, densityFactor integer(shortInt), parameter :: TOTAL_XS = 1 + if (present(loud)) then + isLoud = loud + else + isLoud = .false. + end if + ! Scale density if (present(scaleDensity)) then if (scaleDensity < ONE) then @@ -485,7 +492,7 @@ subroutine initMajorant(self, loud, maxTemp, scaleDensity) self % majorant(g) = xs * densityFactor end do - if (loud) print '(A)', 'MG unionised majorant cross section calculation completed' + if (isLoud) print '(A)', 'MG unionised majorant cross section calculation completed' end subroutine initMajorant diff --git a/NuclearData/nuclearDatabase_inter.f90 b/NuclearData/nuclearDatabase_inter.f90 index 48a6850ef..54acc80c0 100644 --- a/NuclearData/nuclearDatabase_inter.f90 +++ b/NuclearData/nuclearDatabase_inter.f90 @@ -96,6 +96,9 @@ end subroutine activate !! Can be called repeatedly to update the majorant subject !! to changes in the geometry. !! + !! Optionally can be 'loud', i.e., outputs information on initialising + !! the majorant. + !! !! Optionally can account for the temperature due to super-imposed !! temperature fields. This should receive the maximum temperature in !! the system. This is conservative and can be improved by creating a @@ -104,15 +107,15 @@ end subroutine activate !! Optionally can scale the density. scaleDensity should be !! the relative (to input) density of the highest density material. !! This is most naturally used with a super-imposed density field. - !! As for temperature, this is conservative and could be improved with - !! a material-wise density scaling factor. + !! As for temperature, this approach for density is conservative and + !! could be improved with a material-wise density scaling factor. !! subroutine initMajorant(self, loud, maxTemp, scaleDensity) import :: nuclearDatabase, defBool, defReal - class(nuclearDatabase), intent(inout) :: self - logical(defBool), intent(in) :: loud - real(defReal), optional, intent(in) :: maxTemp - real(defReal), optional, intent(in) :: scaleDensity + class(nuclearDatabase), intent(inout) :: self + logical(defBool), optional, intent(in) :: loud + real(defReal), optional, intent(in) :: maxTemp + real(defReal), optional, intent(in) :: scaleDensity end subroutine initMajorant !! diff --git a/NuclearData/testNeutronData/testNeutronDatabase_class.f90 b/NuclearData/testNeutronData/testNeutronDatabase_class.f90 index e67c50efc..32f17eb62 100644 --- a/NuclearData/testNeutronData/testNeutronDatabase_class.f90 +++ b/NuclearData/testNeutronData/testNeutronDatabase_class.f90 @@ -169,7 +169,7 @@ end subroutine activate !! subroutine initMajorant(self, loud, maxTemp, scaleDensity) class(testNeutronDatabase), intent(inout) :: self - logical(defBool), intent(in) :: loud + logical(defBool), intent(in), optional :: loud real(defReal), intent(in), optional :: maxTemp real(defReal), intent(in), optional :: scaleDensity diff --git a/ParticleObjects/Source/fissionSource_class.f90 b/ParticleObjects/Source/fissionSource_class.f90 index 33847188b..b9117af46 100644 --- a/ParticleObjects/Source/fissionSource_class.f90 +++ b/ParticleObjects/Source/fissionSource_class.f90 @@ -2,7 +2,8 @@ module fissionSource_class use numPrecision use endfConstants - use universalVariables, only : OUTSIDE_MAT, VOID_MAT, UNDEF_MAT, OVERLAP_MAT + use universalVariables, only : OUTSIDE_MAT, VOID_MAT, UNDEF_MAT, OVERLAP_MAT, & + NO_TEMPERATURE, NO_DENSITY use genericProcedures, only : rotateVector, numToChar use errors_mod, only : fatalError use dictionary_class, only : dictionary @@ -224,7 +225,7 @@ function sampleParticle(self, rand) result(p) end if ! Get Nuclide - nucIdx = matCE % sampleFission(self % E, -ONE, -ONE, rand) + nucIdx = matCE % sampleFission(self % E, NO_TEMPERATURE, NO_DENSITY, rand) ! Get reaction object fissCE => fissionCE_TptrCast(nucData % getReaction(N_FISSION, nucIdx)) diff --git a/ParticleObjects/Source/materialSource_class.f90 b/ParticleObjects/Source/materialSource_class.f90 index 88cb109a7..1a3d54a1e 100644 --- a/ParticleObjects/Source/materialSource_class.f90 +++ b/ParticleObjects/Source/materialSource_class.f90 @@ -168,7 +168,7 @@ function sampleParticle(self, rand) result(p) call self % geom % whatIsAt(matIdx, uniqueID, r) ! Reject if there is no material or if the particle is in void - if (matIdx == OUTSIDE_MAT .or. matIdx == VOID_MAT) cycle rejection + if (matIdx == OUTSIDE_MAT) cycle rejection mat => neutronMaterial_CptrCast(nucData % getMaterial(matIdx)) if (.not.associated(mat)) call fatalError(Here, "Nuclear data did not return neutron material.") diff --git a/ParticleObjects/particle_class.f90 b/ParticleObjects/particle_class.f90 index 4218c1a2a..3db87d0bd 100644 --- a/ParticleObjects/particle_class.f90 +++ b/ParticleObjects/particle_class.f90 @@ -101,8 +101,8 @@ module particle_class real(defReal) :: time ! Particle time point ! Information passed from geometry - real(defReal) :: T = -INF ! Local temperature - real(defReal) :: rho = -INF ! Local density scaling + real(defReal) :: T = NO_TEMPERATURE ! Local temperature + real(defReal) :: rho = NO_DENSITY ! Local density scaling ! Precursor particle data real(defReal) :: lambda = INF ! Precursor decay constant diff --git a/SharedModules/universalVariables.f90 b/SharedModules/universalVariables.f90 index 98b117ce2..8f5e2b022 100644 --- a/SharedModules/universalVariables.f90 +++ b/SharedModules/universalVariables.f90 @@ -93,4 +93,8 @@ module universalVariables character(nameLen), parameter :: nameUFS = 'uniFissSites' character(nameLen), parameter :: nameWW = 'WeightWindows' + ! Flags associated with fields + real(defReal), parameter :: NO_TEMPERATURE = -INF, & + NO_DENSITY = -INF + end module universalVariables diff --git a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 index 5d1dfad06..363870deb 100644 --- a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 +++ b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 @@ -36,7 +36,7 @@ module fieldMap_class !! Sample Dictionary Input: !! myMap { !! type fieldMap; - !! + !! field {pieceConstant field dictionary} !! !! } !! diff --git a/docs/User Manual.rst b/docs/User Manual.rst index 7f0a79714..dcfee5bf8 100644 --- a/docs/User Manual.rst +++ b/docs/User Manual.rst @@ -837,7 +837,7 @@ Currently there is only one available PieceConstantField: in different materials, or uniformly across all materials. - shape: (x y z) array of integers, stating the numbers of x, y and z - elements of the field. For a 2D field, one of the entries has to be 0 + elements of the field. For a 2D field, the z entry has to be 0. - pitch: (x y z) array with the x, y and z field pitches. In a 2D field, the value entered in the third dimension is not used. [cm] - origin (*optional*, default = (0.0 0.0 0.0)): (x y z) array with the From 0f8b6b7b28ea67c236464b1d759a38327fb59a23 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Fri, 20 Feb 2026 18:46:58 +0000 Subject: [PATCH 24/27] Nearly there --- .../PieceConstantFields/CMakeLists.txt | 1 - .../cartesianField_class.f90 | 7 +- .../pieceConstantFieldFactory_func.f90 | 58 ----- .../pieceConstantField_inter.f90 | 27 +-- Geometry/Tests/geometryStd_iTest.f90 | 118 ---------- Geometry/geometryReg_mod.f90 | 24 ++- Geometry/geometryStd_class.f90 | 203 ++++++------------ Geometry/geometry_inter.f90 | 70 ------ IntegrationTestFiles/Geometry/densityField | 8 - IntegrationTestFiles/Geometry/test_field | 62 ------ PhysicsPackages/eigenPhysicsPackage_class.f90 | 32 ++- .../fixedSourcePhysicsPackage_class.f90 | 31 ++- .../kineticPhysicsPackage_class.f90 | 36 +++- SharedModules/universalVariables.f90 | 6 +- Tallies/TallyMaps/Maps1D/fieldMap_class.f90 | 8 +- .../transportOperatorDT_class.f90 | 25 ++- .../transportOperatorHT_class.f90 | 9 +- .../transportOperatorST_class.f90 | 19 +- TransportOperator/transportOperator_inter.f90 | 56 ++++- 19 files changed, 261 insertions(+), 539 deletions(-) delete mode 100644 Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantFieldFactory_func.f90 delete mode 100644 IntegrationTestFiles/Geometry/densityField delete mode 100644 IntegrationTestFiles/Geometry/test_field diff --git a/Geometry/Fields/ScalarFields/PieceConstantFields/CMakeLists.txt b/Geometry/Fields/ScalarFields/PieceConstantFields/CMakeLists.txt index 64cde1d7d..dd90e7975 100644 --- a/Geometry/Fields/ScalarFields/PieceConstantFields/CMakeLists.txt +++ b/Geometry/Fields/ScalarFields/PieceConstantFields/CMakeLists.txt @@ -1,6 +1,5 @@ add_sources( ./pieceConstantField_inter.f90 - ./pieceConstantFieldFactory_func.f90 ./cartesianField_class.f90) add_unit_tests( ./Tests/cartesianField_test.f90) diff --git a/Geometry/Fields/ScalarFields/PieceConstantFields/cartesianField_class.f90 b/Geometry/Fields/ScalarFields/PieceConstantFields/cartesianField_class.f90 index 5c5b6db66..e1b109513 100644 --- a/Geometry/Fields/ScalarFields/PieceConstantFields/cartesianField_class.f90 +++ b/Geometry/Fields/ScalarFields/PieceConstantFields/cartesianField_class.f90 @@ -57,7 +57,6 @@ module cartesianField_class real(defReal), dimension(3) :: corner = ZERO real(defReal), dimension(3) :: a_bar = ZERO type(box) :: outline - integer(shortInt) :: outLocalID = 0 integer(shortInt) :: nMat = 0 integer(shortInt), dimension(:), allocatable :: matIdxs @@ -164,7 +163,6 @@ subroutine init_dict(self, dict) end if ! Size field value array - self % outLocalID = product(self % sizeN) self % N = product(self % sizeN * self % nMat) allocate(self % val(self % N + 1)) @@ -241,9 +239,7 @@ pure function map(self, coords) result(idx) if (any(self % matIdxs == coords % matIdx)) then idx0 = findloc(self % matIdxs, coords % matIdx, 1) idx = idx + (idx0 - 1) * product(self % sizeN) - else if (self % matIdxs(1) == ALL_MATS) then - idx = idx - else + else if (self % matIdxs(1) /= ALL_MATS) then idx = 0 end if @@ -351,7 +347,6 @@ elemental subroutine kill(self) self % nMat = 0 self % corner = ZERO self % a_bar = ZERO - self % outLocalID = 0 call self % outline % kill() end subroutine kill diff --git a/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantFieldFactory_func.f90 b/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantFieldFactory_func.f90 deleted file mode 100644 index 31b30f847..000000000 --- a/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantFieldFactory_func.f90 +++ /dev/null @@ -1,58 +0,0 @@ -!! -!! Module to build pieceConstantField -!! -module pieceConstantFieldFactory_func - - use numPrecision - use errors_mod, only : fatalError - use dictionary_class, only : dictionary - - use pieceConstantField_inter, only : pieceConstantField - use cartesianField_class, only : cartesianField - - implicit none - private - - ! List that contains all acceptable types of pieceConstantFields - ! It is printed if type was unrecognised - ! NOTE: - ! For now it is necessary to adjust trailing blanks so all enteries have the same length - character(nameLen),dimension(*),parameter :: AVAILABLE_fields = [ 'cartesianField'] - - public :: new_pieceConstantField - -contains - - !! - !! Allocate new allocatable pieceConstantField to a specific type - !! If new is allocated it deallocates it - !! - subroutine new_pieceConstantField(new, dict) - class(pieceConstantField),allocatable, intent(inout):: new - class(dictionary), intent(in) :: dict - character(nameLen) :: type - character(100),parameter :: Here = 'new_pieceConstantField (pieceConstantFieldFactory_func.f90)' - - if(allocated(new)) deallocate(new) - - ! Obtain string that specifies type to be built - call dict % get(type,'type') - - ! Allocate approperiate subclass of pieceConstantField - select case(type) - case('cartesianField') - allocate( cartesianField :: new) - - case default - print *, AVAILABLE_fields - call fatalError(Here, 'Unrecognised type pieceConstantField: ' // trim(type)) - - end select - - ! Initialise new pieceConstantField - call new % init(dict) - - end subroutine new_pieceConstantField - - -end module pieceConstantFieldFactory_func diff --git a/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantField_inter.f90 b/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantField_inter.f90 index 0aabbbaa9..8d21708e5 100644 --- a/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantField_inter.f90 +++ b/Geometry/Fields/ScalarFields/PieceConstantFields/pieceConstantField_inter.f90 @@ -43,12 +43,11 @@ module pieceConstantField_inter real(defReal), dimension(:), allocatable :: val integer(shortInt) :: N = 0 contains - procedure(init_dict), deferred :: init_dict - procedure(distance), deferred :: distance - procedure(map), deferred :: map + procedure(init_dict), deferred, private :: init_dict + procedure(distance), deferred :: distance + procedure(map), deferred :: map procedure :: init - procedure :: init_file procedure :: map_particle procedure :: setValue procedure :: getMaxValue @@ -118,32 +117,18 @@ subroutine init(self, dict) class(pieceConstantField), intent(inout) :: self class(dictionary), intent(in) :: dict character(pathLen) :: path + class(dictionary), pointer :: tempDict if (dict % isPresent('path')) then call dict % get(path, 'path') - call self % init_file(path) + call fileToDict(tempDict, path) + call self % init_dict(tempDict) else call self % init_dict(dict) end if end subroutine init - !! - !! Initialise field from a file - !! - !! Args: - !! file [in] -> Path to a file containing the field definition - !! - subroutine init_file(self, path) - class(pieceConstantField), intent(inout) :: self - character(pathLen), intent(in) :: path - type(dictionary) :: dict - - call fileToDict(dict, path) - call self % init(dict) - - end subroutine init_file - !! !! Cast field pointer to pieceConstantField pointer !! diff --git a/Geometry/Tests/geometryStd_iTest.f90 b/Geometry/Tests/geometryStd_iTest.f90 index 051ab87a9..976e821ac 100644 --- a/Geometry/Tests/geometryStd_iTest.f90 +++ b/Geometry/Tests/geometryStd_iTest.f90 @@ -295,122 +295,4 @@ subroutine test_tilted_cylinder() end subroutine test_tilted_cylinder - !! - !! Geometry integration test -> Fuel pin with imposed temperature and density fields - !! -@Test - subroutine test_field_geom() - type(geometryStd) :: geom - character(*), parameter :: path = './IntegrationTestFiles/Geometry/test_field' - type(charMap) :: mats - integer(shortInt) :: i, idx, event - type(dictionary) :: dict - character(nameLen) :: name - real(defReal), dimension(3) :: r, u, r_ref, u_ref - type(dictionary),pointer :: tempDict - type(coordList) :: coords - real(defReal) :: T, rho, maxDist - real(defReal), parameter :: TOL = 1.0E-7_defReal - character(nameLen), dimension(:), allocatable :: keys - - ! Load dictionary - call fileToDict(dict, path) - - ! Load materials - tempDict => dict % getDictPtr('nuclearData') - tempDict => tempDict % getDictPtr('materials') - call tempDict % keys(keys, 'dict') - do i = 1, size(keys) - call mats % add(keys(i), i) - end do - - ! Need to create material menu for the fields - call mm_init(tempDict) - - ! Build geometry - call geom % init(dict, mats, silent=.true.) - - ! Check field values at different points - r = [0.0_defReal, 0.0_defReal, 0.1_defReal] - u = [ZERO, ZERO, ONE] - call coords % init(r, u) - call geom % placeCoord(coords) - - ! Should be in the middle of the fuel - ! Density scaling should be the default value - ! Temperature should be that from the centre - T = geom % getTemperature(coords) - rho = geom % getDensity(coords) - - name = 'mox43' - idx = mats % get(name) - - @assertEqual(idx, coords % matIdx) - @assertEqual(510.0_defReal, T) - @assertEqual(-7.0_defReal, rho) - - ! Place elsewhere in the coolant - ! Temperature should be the default value - r = [0.62_defReal, 0.0_defReal, 190.0_defReal] - call coords % init(r, u) - call geom % placeCoord(coords) - T = geom % getTemperature(coords) - rho = geom % getDensity(coords) - - name = 'water' - idx = mats % get(name) - - @assertEqual(idx, coords % matIdx) - @assertEqual(-10.0_defReal, T) - @assertEqual(0.1_defReal, rho) - - ! Place in the clad - ! Both values should become their default - r = [0.0_defReal, 0.42_defReal, -50.0_defReal] - call coords % init(r, u) - call geom % placeCoord(coords) - T = geom % getTemperature(coords) - rho = geom % getDensity(coords) - - name = 'clad' - idx = mats % get(name) - - @assertEqual(idx, coords % matIdx) - @assertEqual(-10.0_defReal, T) - @assertEqual(-7.0_defReal, rho) - - ! Check distances at different points - - ! Pointing straight up, the distance should be to the next field element - r = [0.0_defReal, 0.0_defReal, 0.1_defReal] - u = [ZERO, ZERO, ONE] - call coords % init(r, u) - call geom % placeCoord(coords) - - r_ref = [0.0_defReal, 0.0_defReal, 20.0_defReal] - maxDist = 1000.0_defReal - call geom % move(coords, maxDist, event) - - @assertEqual(19.9_defReal, maxDist, TOL) - @assertEqual(FIELD_EV, event) - @assertEqual(r_ref, coords % lvl(1) % r, TOL) - - ! At the boundary, the event should be BOUNDARY_EV, even if the field - ! overlaps the boundary - r = [0.0_defReal, 0.0_defReal, -195.2_defReal] - u = [ZERO, ZERO, -ONE] - call coords % init(r, u) - call geom % placeCoord(coords) - - r_ref = [0.0_defReal, 0.0_defReal, -200.0_defReal] - maxDist = 1000.0_defReal - call geom % move(coords, maxDist, event) - - @assertEqual(4.8_defReal, maxDist, TOL) - @assertEqual(BOUNDARY_EV, event) - @assertEqual(r_ref, coords % lvl(1) % r, TOL) - - end subroutine test_field_geom - - end module geometryStd_iTest diff --git a/Geometry/geometryReg_mod.f90 b/Geometry/geometryReg_mod.f90 index 153bd4443..183e27d87 100644 --- a/Geometry/geometryReg_mod.f90 +++ b/Geometry/geometryReg_mod.f90 @@ -20,9 +20,10 @@ !! geomIdx -> Get index of the geometry !! geomPtr -> Get pointer to a geometry with an index !! addField -> Add new field +!! hasField -> Does the field with a given name exist? !! fieldIdx -> Get index of a field !! fieldPtr -> Get pointer to a field specified by index -!! display -> Display info abou defined fields and geometries +!! display -> Display info about defined fields and geometries !! kill -> Return to uninitialised state !! module geometryReg_mod @@ -66,6 +67,7 @@ module geometryReg_mod public :: addField public :: fieldIdx public :: fieldPtr + public :: hasField public :: kill integer(shortInt), parameter :: START_SIZE = 5 @@ -230,6 +232,26 @@ subroutine addField(kentta, name) call move_alloc(kentta, fields(idx) % kentta) end subroutine addField + + !! + !! Returns whether a field is present + !! + !! Args: + !! name [in] -> Name of the field + !! + !! Result: + !! Logical stating whether the field exists + !! + pure function hasField(name) result(exists) + character(nameLen), intent(in) :: name + logical(defBool) :: exists + integer(shortInt), parameter :: NOT_PRESENT = -8 + integer(shortInt) :: idx + + idx = fieldNameMap % getOrDefault(name, NOT_PRESENT) + exists = (idx /= NOT_PRESENT) + + end function hasField !! !! Get index of a field given its name diff --git a/Geometry/geometryStd_class.f90 b/Geometry/geometryStd_class.f90 index a57c1a7a4..d2009e236 100644 --- a/Geometry/geometryStd_class.f90 +++ b/Geometry/geometryStd_class.f90 @@ -11,8 +11,12 @@ module geometryStd_class use universe_inter, only : universe use surface_inter, only : surface - use pieceConstantField_inter, only : pieceConstantField - use pieceConstantFieldFactory_func, only : new_pieceConstantField + use field_inter, only : field + use pieceConstantField_inter, only : pieceConstantField, pieceConstantField_CptrCast + + use geometryReg_mod, only : gr_hasField => hasField, & + gr_fieldIdx => fieldIdx, & + gr_fieldPtr => fieldPtr ! Nuclear Data use materialMenu_mod, only : nMat @@ -26,6 +30,11 @@ module geometryStd_class !! public :: geometryStd_CptrCast + !! + !! Private distance to the nearest pieceConstant field crossing + !! + private :: getFieldDist + !! !! Standard Geometry Model !! @@ -43,23 +52,17 @@ module geometryStd_class !! geometry { !! type geometryStd; !! - !! #temperature # - !! #density # !! } !! !! Public Members: !! geom -> Representation of geometry by csg_class. Contains all surfaces, cells and universe !! as well as geometry graph and info about root uni and boundary surface. - !! temperatureField -> Field of temperatures overlaid on the geometry - !! densityField -> Field of densities overlaid on the geometry !! !! Interface: !! Geometry Interface !! type, public, extends(geometry) :: geometryStd type(csg) :: geom - class(pieceConstantField), allocatable :: temperatureField - class(pieceConstantField), allocatable :: densityField contains ! Superclass procedures @@ -73,10 +76,6 @@ module geometryStd_class procedure :: moveGlobal procedure :: teleport procedure :: activeMats - procedure :: getTemperature - procedure :: getDensity - procedure :: getMaxDensityFactor - procedure :: getMaxTemperature ! Private procedures procedure, private :: diveToMat @@ -96,24 +95,10 @@ subroutine init(self, dict, mats, silent) class(dictionary), intent(in) :: dict type(charMap), intent(in) :: mats logical(defBool), optional, intent(in) :: silent - class(dictionary), pointer :: tempDict ! Build the representation call self % geom % init(dict, mats, silent) - ! If present, build temperature and density fields - if (dict % isPresent('temperature')) then - tempDict => dict % getDictPtr('temperature') - !call new_pieceConstantField(self % temperatureField, tempDict) - call new_field(tempField, tempDict) - end if - - if (dict % isPresent('density')) then - tempDict => dict % getDictPtr('density') - !call new_pieceConstantField(self % densityField, tempDict) - call new_field(self % densityField, tempDict) - end if - end subroutine init !! @@ -123,14 +108,6 @@ elemental subroutine kill(self) class(geometryStd), intent(inout) :: self call self % geom % kill() - if (allocated(self % temperatureField)) then - call self % temperatureField % kill() - deallocate(self % temperatureField) - end if - if (allocated(self % densityField)) then - call self % densityField % kill() - deallocate(self % densityField) - end if end subroutine kill @@ -235,14 +212,14 @@ end function bounds !! Uses explicit BC !! subroutine move_noCache(self, coords, maxDist, event) - class(geometryStd), intent(in) :: self - type(coordList), intent(inout) :: coords - real(defReal), intent(inout) :: maxDist - integer(shortInt), intent(out) :: event - integer(shortInt) :: surfIdx, level, level0 - real(defReal) :: dist, fieldDist - class(surface), pointer :: surf - class(universe), pointer :: uni + class(geometryStd), intent(in) :: self + type(coordList), intent(inout) :: coords + real(defReal), intent(inout) :: maxDist + integer(shortInt), intent(out) :: event + integer(shortInt) :: surfIdx, level, level0 + real(defReal) :: dist, fieldDist + class(surface), pointer :: surf + class(universe), pointer :: uni character(100), parameter :: Here = 'move_noCache (geometryStd_class.f90)' if (.not.coords % isPlaced()) then @@ -255,14 +232,7 @@ subroutine move_noCache(self, coords, maxDist, event) call self % closestDist(dist, surfIdx, level, coords) ! Check fields - fieldDist = INF - if (allocated(self % temperatureField)) then - fieldDist = min(fieldDist, self % temperatureField % distance(coords)) - end if - - if (allocated(self % densityField)) then - fieldDist = min(fieldDist, self % densityField % distance(coords)) - end if + fieldDist = getFieldDist(coords) if (maxDist < dist .and. maxDist < fieldDist) then ! Moves within cell call coords % moveLocal(maxDist, coords % nesting) @@ -270,7 +240,8 @@ subroutine move_noCache(self, coords, maxDist, event) maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway ! This check is really awful - can we do something better? - else if (fieldDist < dist .and. abs(fieldDist - dist) > 10*NUDGE) then ! Stays within the same cell, but crosses field boundary + !else if (fieldDist < dist .and. abs(fieldDist - dist) > 10*NUDGE) then ! Stays within the same cell, but crosses field boundary + else if (maxDist < dist .and. maxDist >= fieldDist) then ! Stays within the same cell, but crosses field boundary call coords % moveLocal(fieldDist, level0) event = FIELD_EV maxDist = fieldDist @@ -314,15 +285,15 @@ end subroutine move_noCache !! Uses explicit BC !! subroutine move_withCache(self, coords, maxDist, event, cache) - class(geometryStd), intent(in) :: self - type(coordList), intent(inout) :: coords - real(defReal), intent(inout) :: maxDist - integer(shortInt), intent(out) :: event - type(distCache), intent(inout) :: cache - integer(shortInt) :: surfIdx, level, level0 - real(defReal) :: dist, fieldDist - class(surface), pointer :: surf - class(universe), pointer :: uni + class(geometryStd), intent(in) :: self + type(coordList), intent(inout) :: coords + real(defReal), intent(inout) :: maxDist + integer(shortInt), intent(out) :: event + type(distCache), intent(inout) :: cache + integer(shortInt) :: surfIdx, level, level0 + real(defReal) :: dist, fieldDist + class(surface), pointer :: surf + class(universe), pointer :: uni character(100), parameter :: Here = 'move_withCache (geometryStd_class.f90)' if (.not.coords % isPlaced()) then @@ -335,14 +306,7 @@ subroutine move_withCache(self, coords, maxDist, event, cache) call self % closestDist_cache(dist, surfIdx, level, coords, cache) ! Check fields - fieldDist = INF - if (allocated(self % temperatureField)) then - fieldDist = min(fieldDist, self % temperatureField % distance(coords)) - end if - - if (allocated(self % densityField)) then - fieldDist = min(fieldDist, self % densityField % distance(coords)) - end if + fieldDist = getFieldDist(coords) if (maxDist < dist .and. maxDist < fieldDist) then ! Moves within cell call coords % moveLocal(maxDist, coords % nesting) @@ -351,7 +315,8 @@ subroutine move_withCache(self, coords, maxDist, event, cache) cache % lvl = 0 ! This check is really awful - can we do something better? - else if (fieldDist < dist .and. abs(fieldDist - dist) > 10 * NUDGE) then ! Stays within the same cell, but crosses field boundary + !else if (fieldDist < dist .and. abs(fieldDist - dist) > 10 * NUDGE) then ! Stays within the same cell, but crosses field boundary + else if (maxDist < dist .and. maxDist >= fieldDist) then ! Stays within the same cell, but crosses field boundary call coords % moveLocal(fieldDist, level0) event = FIELD_EV maxDist = fieldDist @@ -658,78 +623,6 @@ subroutine closestDist_cache(self, dist, surfIdx, lvl, coords, cache) end do end subroutine closestDist_cache - !! - !! Returns the local temperature, provided the temperatureField - !! has been allocated - !! - !! See geometry_inter for details - !! - function getTemperature(self, coords) result(T) - class(geometryStd), intent(in) :: self - type(coordList), intent(in) :: coords - real(defReal) :: T - - if (allocated(self % temperatureField)) then - T = self % temperatureField % at(coords) - else - T = -INF - end if - - end function getTemperature - - !! - !! Returns the local density, provided the densityField - !! has been allocated - !! - !! See geometry_inter for details - !! - function getDensity(self, coords) result(rho) - class(geometryStd), intent(in) :: self - type(coordList), intent(in) :: coords - real(defReal) :: rho - - if (allocated(self % densityField)) then - rho = self % densityField % at(coords) - else - rho = -INF - end if - - end function getDensity - - !! - !! Returns the maximum density scaling factor across the geometry - !! - !! See geometry_inter for details - !! - function getMaxDensityFactor(self) result(rho) - class(geometryStd), intent(in) :: self - real(defReal) :: rho - - if (allocated(self % densityField)) then - rho = max(ONE, self % densityField % getMaxValue()) - else - rho = ONE - end if - - end function getMaxDensityFactor - - !! - !! Returns the maximum temperature across the geometry - !! - !! See geometry_inter for details - !! - function getMaxTemperature(self) result(temp) - class(geometryStd), intent(in) :: self - real(defReal) :: temp - - if (allocated(self % temperatureField)) then - temp = self % temperatureField % getMaxValue() - else - temp = -ONE - end if - - end function getMaxTemperature - !! !! Cast geometry pointer to geometryStd class pointer !! @@ -753,5 +646,33 @@ pure function geometryStd_CptrCast(source) result(ptr) end select end function geometryStd_CptrCast + + !! + !! Helper function. + !! Get the distance to the nearest pieceConstantField boundary + !! + !! Returns INF if neither density nor temperature fields exist + !! + function getFieldDist(coords) result(dist) + type(coordList), intent(in) :: coords + real(defReal) :: dist + class(field), pointer :: genericField + class(pieceConstantField), pointer :: pcField + + dist = INF + if (gr_hasField(nameTemperature)) then + genericField => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + pcField => pieceConstantField_CptrCast(genericField) + dist = min(dist, pcField % distance(coords)) + end if + + if (gr_hasField(nameDensity)) then + genericField => gr_fieldPtr(gr_fieldIdx(nameDensity)) + pcField => pieceConstantField_CptrCast(genericField) + dist = min(dist, pcField % distance(coords)) + end if + + end function getFieldDist + end module geometryStd_class diff --git a/Geometry/geometry_inter.f90 b/Geometry/geometry_inter.f90 index 911127b1d..973007549 100644 --- a/Geometry/geometry_inter.f90 +++ b/Geometry/geometry_inter.f90 @@ -43,10 +43,6 @@ module geometry_inter procedure(moveGlobal), deferred :: moveGlobal procedure(teleport), deferred :: teleport procedure(activeMats), deferred :: activeMats - procedure(getTemperature), deferred :: getTemperature - procedure(getDensity), deferred :: getDensity - procedure(getMaxDensityFactor), deferred :: getMaxDensityFactor - procedure(getMaxTemperature), deferred :: getMaxTemperature ! Common procedures procedure :: slicePlot @@ -266,72 +262,6 @@ function activeMats(self) result(matList) integer(shortInt), dimension(:), allocatable :: matList end function activeMats - !! - !! Returns the temperature at a position in space. - !! - !! Args: - !! coords - !! - !! Result: - !! Temperature at a given location. If this information has not been provided - !! to the geometry then a default result should be returned. - !! - function getTemperature(self, coords) result(T) - import :: geometry, coordList, defReal - class(geometry), intent(in) :: self - type(coordList), intent(in) :: coords - real(defReal) :: T - end function getTemperature - - !! - !! Returns the density at a position in space. - !! - !! Args: - !! coords - !! - !! Result: - !! Density at a given location. If this information has not been provided - !! to the geometry then a default result should be returned. - !! - function getDensity(self, coords) result(rho) - import :: geometry, coordList, defReal - class(geometry), intent(in) :: self - type(coordList), intent(in) :: coords - real(defReal) :: rho - end function getDensity - - !! - !! Returns the maximum density scaling factor across the system. - !! Used for updating the majorant, for example. - !! - !! Args: - !! - !! Result: - !! Maximum density scaling factor due to imposed field. If there is no density - !! scaling then the result is ONE - !! - function getMaxDensityFactor(self) result(rho) - import :: geometry, defReal - class(geometry), intent(in) :: self - real(defReal) :: rho - end function getMaxDensityFactor - - !! - !! Returns the maximum temperature in kelvin across the system. - !! Used for updating the majorant, for example. - !! - !! Args: - !! - !! Result: - !! Maximum temperature due to imposed field. If there is no temperature - !! field then the result is -ONE - !! - function getMaxTemperature(self) result(temp) - import :: geometry, defReal - class(geometry), intent(in) :: self - real(defReal) :: temp - end function getMaxTemperature - end interface contains diff --git a/IntegrationTestFiles/Geometry/densityField b/IntegrationTestFiles/Geometry/densityField deleted file mode 100644 index a4074c31b..000000000 --- a/IntegrationTestFiles/Geometry/densityField +++ /dev/null @@ -1,8 +0,0 @@ -materials (water); -origin (0 0 0); -shape (1 1 20); -pitch (1.27 1.27 20); -default -7; -water ( - 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2 -); diff --git a/IntegrationTestFiles/Geometry/test_field b/IntegrationTestFiles/Geometry/test_field deleted file mode 100644 index 9c3a06a16..000000000 --- a/IntegrationTestFiles/Geometry/test_field +++ /dev/null @@ -1,62 +0,0 @@ -boundary ( 2 2 2 2 0 0); -graph {type shrunk;} - -temperature { - type cartesianField; - materials (mox43); - origin (0 0 0); - shape (1 1 20); - pitch (1.26 1.26 20); - default -10; - mox43 ( - 330 350 370 390 410 430 450 470 490 510 530 550 570 590 610 630 650 670 690 710 - ); -} - -density { -type cartesianField; -path ./IntegrationTestFiles/Geometry/densityField; -} - -surfaces { - squareBound { id 1; type box; origin (0.0 0.0 0.0); halfwidth (0.63 0.63 200.0);} -} - -cells { -} - - -universes { - root { id 1; type rootUniverse; border 1; fill u<31>; } - pin31 { id 31; type pinUniverse; radii (0.4095 0.5400 0.0 ); fills (mox43 clad water);} - -} - - - - - -nuclearData { - materials { - - water { - temp 75675; - composition { - } - } - - clad { - temp 12345; - composition { - } - } - - mox43 { - temp 305; - tms 1; - composition { - } - } - -} -} diff --git a/PhysicsPackages/eigenPhysicsPackage_class.f90 b/PhysicsPackages/eigenPhysicsPackage_class.f90 index 76a72d93e..d21c01652 100644 --- a/PhysicsPackages/eigenPhysicsPackage_class.f90 +++ b/PhysicsPackages/eigenPhysicsPackage_class.f90 @@ -36,6 +36,7 @@ module eigenPhysicsPackage_class ! Fields use field_inter, only : field + use pieceConstantField_inter, only : pieceConstantField, pieceConstantField_CptrCast use uniFissSitesField_class, only : uniFissSitesField, uniFissSitesField_TptrCast use fieldFactory_func, only : new_field @@ -426,6 +427,7 @@ subroutine init(self, dict) type(outputFile) :: test_out type(visualiser) :: viz class(field), pointer :: field + class(pieceConstantField), pointer :: pcField real(defReal) :: maxDensityScale, maxTemperature character(100), parameter :: Here ='init (eigenPhysicsPackage_class.f90)' @@ -514,11 +516,6 @@ subroutine init(self, dict) call ndReg_activate(self % particleType, nucData, self % geom % activeMats()) self % nucData => ndReg_get(self % particleType) - ! Update majorant in case of density and temperature fields - maxDensityScale = self % geom % getMaxDensityFactor() - maxTemperature = self % geom % getMaxTemperature() - call self % nucData % initMajorant(.false., maxTemp = maxTemperature, scaleDensity = maxDensityScale) - ! Call visualisation if (dict % isPresent('viz') .and. isMPIMaster()) then call statusMsg("Initialising visualiser") @@ -528,6 +525,31 @@ subroutine init(self, dict) call viz % makeViz() call viz % kill() endif + + ! If present, build temperature field + if (dict % isPresent('temperature')) then + tempDict => dict % getDictPtr('temperature') + call new_field(tempDict, nameTemperature) + field => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + pcField => pieceConstantField_CptrCast(field) + maxTemperature = pcField % getMaxValue() + else + maxTemperature = NO_TEMPERATURE + end if + + ! If present, build density field + if (dict % isPresent('density')) then + tempDict => dict % getDictPtr('density') + call new_field(tempDict, nameDensity) + field => gr_fieldPtr(gr_fieldIdx(nameDensity)) + pcField => pieceConstantField_CptrCast(field) + maxDensityScale = pcField % getMaxValue() + else + maxDensityScale = NO_DENSITY + end if + + ! Update majorant in case of density and temperature fields + call self % nucData % initMajorant(.false., maxTemp = maxTemperature, scaleDensity = maxDensityScale) ! Read uniform fission site option as a geometry field if (dict % isPresent('uniformFissionSites')) then diff --git a/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 b/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 index 59c1ccae2..4ac578486 100644 --- a/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 +++ b/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 @@ -30,11 +30,14 @@ module fixedSourcePhysicsPackage_class ! Geometry use geometry_inter, only : geometry - use geometryReg_mod, only : gr_geomPtr => geomPtr, gr_geomIdx => geomIdx + use geometryReg_mod, only : gr_geomPtr => geomPtr, gr_geomIdx => geomIdx, & + gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr use geometryFactory_func, only : new_geometry ! Fields use fieldFactory_func, only : new_field + use field_inter, only : field + use pieceConstantField_inter, only : pieceConstantField, pieceConstantField_CptrCast ! Nuclear Data use materialMenu_mod, only : mm_nMat => nMat @@ -331,6 +334,8 @@ subroutine init(self, dict) character(nameLen) :: nucData, energy, geomName type(outputFile) :: test_out type(visualiser) :: viz + class(field), pointer :: field + class(pieceConstantField), pointer :: pcField real(defReal) :: maxTemperature, maxDensityScale character(100), parameter :: Here ='init (fixedSourcePhysicsPackage_class.f90)' @@ -410,9 +415,29 @@ subroutine init(self, dict) call ndReg_activate(self % particleType, nucData, self % geom % activeMats()) self % nucData => ndReg_get(self % particleType) + ! If present, build temperature field + if (dict % isPresent('temperature')) then + tempDict => dict % getDictPtr('temperature') + call new_field(tempDict, nameTemperature) + field => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + pcField => pieceConstantField_CptrCast(field) + maxTemperature = pcField % getMaxValue() + else + maxTemperature = NO_TEMPERATURE + end if + + ! If present, build density field + if (dict % isPresent('density')) then + tempDict => dict % getDictPtr('density') + call new_field(tempDict, nameDensity) + field => gr_fieldPtr(gr_fieldIdx(nameDensity)) + pcField => pieceConstantField_CptrCast(field) + maxDensityScale = pcField % getMaxValue() + else + maxDensityScale = NO_DENSITY + end if + ! Update majorant in case of density and temperature fields - maxDensityScale = self % geom % getMaxDensityFactor() - maxTemperature = self % geom % getMaxTemperature() call self % nucData % initMajorant(.false., maxTemp = maxTemperature, scaleDensity = maxDensityScale) ! Call visualisation diff --git a/PhysicsPackages/kineticPhysicsPackage_class.f90 b/PhysicsPackages/kineticPhysicsPackage_class.f90 index d21eec4ce..ac4a3f790 100644 --- a/PhysicsPackages/kineticPhysicsPackage_class.f90 +++ b/PhysicsPackages/kineticPhysicsPackage_class.f90 @@ -29,8 +29,14 @@ module kineticPhysicsPackage_class ! Geometry use geometry_inter, only : geometry - use geometryReg_mod, only : gr_geomPtr => geomPtr, gr_geomIdx => geomIdx + use geometryReg_mod, only : gr_geomPtr => geomPtr, gr_geomIdx => geomIdx, & + gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr use geometryFactory_func, only : new_geometry + + ! Fields + use field_inter, only : field + use pieceConstantField_inter, only : pieceConstantField, pieceConstantField_CptrCast + use fieldFactory_func, only : new_field ! Nuclear Data use materialMenu_mod, only : mm_nMat => nMat @@ -502,6 +508,9 @@ subroutine init(self, dict) character(nameLen) :: nucData, energy, geomName type(outputFile) :: test_out type(visualiser) :: viz + class(field), pointer :: field + class(pieceConstantField), pointer :: pcField + real(defReal) :: maxTemperature, maxDensityScale character(100), parameter :: Here ='init (kineticPhysicsPackage_class.f90)' call cpu_time(self % CPU_time_start) @@ -622,6 +631,31 @@ subroutine init(self, dict) ! Activate Nuclear Data *** All materials are active call ndReg_activate(self % particleType, nucData, self % geom % activeMats()) self % nucData => ndReg_get(self % particleType) + + ! If present, build temperature field + if (dict % isPresent('temperature')) then + tempDict => dict % getDictPtr('temperature') + call new_field(tempDict, nameTemperature) + field => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + pcField => pieceConstantField_CptrCast(field) + maxTemperature = pcField % getMaxValue() + else + maxTemperature = NO_TEMPERATURE + end if + + ! If present, build density field + if (dict % isPresent('density')) then + tempDict => dict % getDictPtr('density') + call new_field(tempDict, nameDensity) + field => gr_fieldPtr(gr_fieldIdx(nameDensity)) + pcField => pieceConstantField_CptrCast(field) + maxDensityScale = pcField % getMaxValue() + else + maxDensityScale = NO_DENSITY + end if + + ! Update majorant in case of density and temperature fields + call self % nucData % initMajorant(.false., maxTemp = maxTemperature, scaleDensity = maxDensityScale) ! Call visualisation if (dict % isPresent('viz') .and. isMPIMaster()) then diff --git a/SharedModules/universalVariables.f90 b/SharedModules/universalVariables.f90 index e099ee8e1..7986d4fc3 100644 --- a/SharedModules/universalVariables.f90 +++ b/SharedModules/universalVariables.f90 @@ -90,8 +90,10 @@ module universalVariables kBoltzmannMeV = kBoltzmann / joulesPerMeV ! Global name variables used to define specific geometry or field types - character(nameLen), parameter :: nameUFS = 'uniFissSites' - character(nameLen), parameter :: nameWW = 'WeightWindows' + character(nameLen), parameter :: nameUFS = 'uniFissSites' + character(nameLen), parameter :: nameWW = 'WeightWindows' + character(nameLen), parameter :: nameTemperature = 'temperature' + character(nameLen), parameter :: nameDensity = 'density' ! Flags associated with fields real(defReal), parameter :: NO_TEMPERATURE = -INF, & diff --git a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 index 363870deb..1793579a8 100644 --- a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 +++ b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 @@ -10,7 +10,6 @@ module fieldMap_class ! Field use pieceConstantField_inter, only : pieceConstantField - use pieceConstantFieldFactory_func, only : new_pieceConstantField implicit none private @@ -69,9 +68,10 @@ subroutine init(self, dict) class(dictionary), intent(in) :: dict class(dictionary),pointer :: tempDict - tempDict => dict % getDictPtr('field') - call new_pieceConstantField(self % field, tempDict) - self % Nbins = self % field % getSize() + ! UNDO ME + !tempDict => dict % getDictPtr('field') + !call new_pieceConstantField(self % field, tempDict) + !self % Nbins = self % field % getSize() end subroutine init diff --git a/TransportOperator/transportOperatorDT_class.f90 b/TransportOperator/transportOperatorDT_class.f90 index 01f86fad0..8aefa39d7 100644 --- a/TransportOperator/transportOperatorDT_class.f90 +++ b/TransportOperator/transportOperatorDT_class.f90 @@ -5,25 +5,25 @@ module transportOperatorDT_class use numPrecision use universalVariables - use errors_mod, only : fatalError - use genericProcedures, only : numToChar - use particle_class, only : particle - use particleDungeon_class, only : particleDungeon - use dictionary_class, only : dictionary + use errors_mod, only : fatalError + use genericProcedures, only : numToChar + use particle_class, only : particle + use particleDungeon_class, only : particleDungeon + use dictionary_class, only : dictionary ! Superclass - use transportOperator_inter, only : transportOperator, init_super => init + use transportOperator_inter, only : transportOperator, init_super => init ! Geometry interfaces - use geometry_inter, only : geometry + use geometry_inter, only : geometry ! Tally interface use tallyCodes - use tallyAdmin_class, only : tallyAdmin + use tallyAdmin_class, only : tallyAdmin ! Nuclear data interfaces - use nuclearDataReg_mod, only : ndReg_get => get - use nuclearDatabase_inter, only : nuclearDatabase + use nuclearDataReg_mod, only : ndReg_get => get + use nuclearDatabase_inter, only : nuclearDatabase implicit none private @@ -109,9 +109,8 @@ subroutine deltaTracking(self, p, tally, thisCycle, nextCycle) exit DTLoop end if - ! Get local conditions - p % T = self % geom % getTemperature(p % coords) - p % rho = self % geom % getDensity(p % coords) + ! Get local conditions of temperature and density + call self % localConditions(p) ! Obtain the local cross-section sigmaT = self % xsData % getTrackMatXS(p, p % matIdx()) diff --git a/TransportOperator/transportOperatorHT_class.f90 b/TransportOperator/transportOperatorHT_class.f90 index ad3afc80d..c1461b4a0 100644 --- a/TransportOperator/transportOperatorHT_class.f90 +++ b/TransportOperator/transportOperatorHT_class.f90 @@ -63,8 +63,7 @@ subroutine tracking_selection(self, p, tally, thisCycle, nextCycle) sigmaT = ZERO else ! Get local conditions - p % T = self % geom % getTemperature(p % coords) - p % rho = self % geom % getDensity(p % coords) + call self % localConditions(p) sigmaT = self % xsData % getTrackMatXS(p, p % matIdx()) end if @@ -150,8 +149,7 @@ subroutine deltaTracking(self, p, tally, thisCycle, nextCycle) end if ! Get local conditions - p % T = self % geom % getTemperature(p % coords) - p % rho = self % geom % getDensity(p % coords) + call self % localConditions(p) ! Obtain the local cross-section sigmaT = self % xsData % getTrackMatXS(p, p % matIdx()) @@ -189,8 +187,7 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) STLoop: do ! Get local conditions - p % T = self % geom % getTemperature(p % coords) - p % rho = self % geom % getDensity(p % coords) + call self % localConditions(p) sigmaTrack = self % xsData % getTrackingXS(p, p % matIdx(), MATERIAL_XS) diff --git a/TransportOperator/transportOperatorST_class.f90 b/TransportOperator/transportOperatorST_class.f90 index 1815a58aa..f73d27563 100644 --- a/TransportOperator/transportOperatorST_class.f90 +++ b/TransportOperator/transportOperatorST_class.f90 @@ -5,23 +5,23 @@ module transportOperatorST_class use numPrecision use universalVariables - use errors_mod, only : fatalError - use particle_class, only : particle - use particleDungeon_class, only : particleDungeon - use dictionary_class, only : dictionary + use errors_mod, only : fatalError + use particle_class, only : particle + use particleDungeon_class, only : particleDungeon + use dictionary_class, only : dictionary ! Superclass - use transportOperator_inter, only : transportOperator, init_super => init + use transportOperator_inter, only : transportOperator, init_super => init ! Geometry interfaces - use geometry_inter, only : geometry, distCache + use geometry_inter, only : geometry, distCache ! Tally interface use tallyCodes - use tallyAdmin_class, only : tallyAdmin + use tallyAdmin_class, only : tallyAdmin ! Nuclear data interfaces - use nuclearDatabase_inter, only : nuclearDatabase + use nuclearDatabase_inter, only : nuclearDatabase implicit none private @@ -62,8 +62,7 @@ subroutine surfaceTracking(self, p, tally, thisCycle, nextCycle) STLoop: do ! Get local conditions - p % T = self % geom % getTemperature(p % coords) - p % rho = self % geom % getDensity(p % coords) + call self % localConditions(p) sigmaTrack = self % xsData % getTrackingXS(p, p % matIdx(), MATERIAL_XS) diff --git a/TransportOperator/transportOperator_inter.f90 b/TransportOperator/transportOperator_inter.f90 index 6e035b24a..36fc24388 100644 --- a/TransportOperator/transportOperator_inter.f90 +++ b/TransportOperator/transportOperator_inter.f90 @@ -2,23 +2,29 @@ module transportOperator_inter use numPrecision use universalVariables - use errors_mod, only : fatalError + use errors_mod, only : fatalError - use particle_class, only : particle - use particleDungeon_class, only : particleDungeon - use dictionary_class, only : dictionary + use particle_class, only : particle + use particleDungeon_class, only : particleDungeon + use dictionary_class, only : dictionary ! Geometry interfaces - use geometryReg_mod, only : gr_geomPtr => geomPtr - use geometry_inter, only : geometry + use geometryReg_mod, only : gr_geomPtr => geomPtr, & + gr_hasField => hasField, & + gr_fieldIdx => fieldIdx, & + gr_fieldPtr => fieldPtr + use geometry_inter, only : geometry + + use field_inter, only : field + use pieceConstantField_inter, only : pieceConstantField, pieceConstantField_CptrCast ! Tally interface - use tallyAdmin_class, only : tallyAdmin + use tallyAdmin_class, only : tallyAdmin ! Nuclear data interfaces - use nuclearDataReg_mod, only : ndReg_get => get - use nuclearDatabase_inter, only : nuclearDatabase + use nuclearDataReg_mod, only : ndReg_get => get + use nuclearDatabase_inter, only : nuclearDatabase @@ -42,6 +48,9 @@ module transportOperator_inter !! Customisable procedures or transport actions !! transit(p, tally, thisCycle, nextCycle) -> implements movement from collision to collision !! + !! Procedures generic to transport operators: + !! localConditions(p) -> obtains local conditions of temperature and density for use in transport + !! type, abstract, public :: transportOperator !! Nuclear Data block pointer -> public so it can be used by subclasses (protected member) class(nuclearDatabase), pointer :: xsData => null() @@ -57,6 +66,9 @@ module transportOperator_inter procedure :: init procedure :: kill + ! Query for local conditions of temperature and density. + procedure, non_overridable :: localConditions + ! Customisable deferred procedures procedure(transit), deferred :: transit @@ -118,6 +130,32 @@ subroutine transport(self, p, tally, thisCycle, nextCycle) end subroutine transport + !! + !! Queries local conditions of temperature and density from + !! the geometry registry. Updates the particle to carry this info. + !! + subroutine localConditions(self, p) + class(transportOperator), intent(in) :: self + class(particle), intent(inout) :: p + class(field), pointer :: genericField + class(pieceConstantField), pointer :: pcField + + ! Temperature check + if (gr_hasField(nameTemperature)) then + genericField => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + pcField => pieceConstantField_CptrCast(genericField) + p % T = pcField % at(p % coords) + end if + + ! Density check + if (gr_hasField(nameDensity)) then + genericField => gr_fieldPtr(gr_fieldIdx(nameDensity)) + pcField => pieceConstantField_CptrCast(genericField) + p % rho = pcField % at(p % coords) + end if + + end subroutine localConditions + !! !! Initialise transport operator from dictionary and geometry !! From 5191016979830d75c1dbb5e87a9582af6dd28797 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sat, 21 Feb 2026 14:30:30 +0000 Subject: [PATCH 25/27] Simplifying field handling for T and rho Also removed fieldMaps. Unnecessary for the moment. --- Geometry/fieldFactory_func.f90 | 5 +- Geometry/geometryReg_mod.f90 | 92 +++++++-- Geometry/geometryStd_class.f90 | 7 +- PhysicsPackages/eigenPhysicsPackage_class.f90 | 7 +- .../fixedSourcePhysicsPackage_class.f90 | 7 +- .../kineticPhysicsPackage_class.f90 | 7 +- Tallies/TallyMaps/CMakeLists.txt | 2 - .../TallyMaps/Maps1D/Tests/fieldMap_test.f90 | 120 ------------ Tallies/TallyMaps/Maps1D/fieldMap_class.f90 | 182 ------------------ .../Maps1D/tallyMap1DFactory_func.f90 | 5 - TransportOperator/transportOperator_inter.f90 | 7 +- 11 files changed, 97 insertions(+), 344 deletions(-) delete mode 100644 Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 delete mode 100644 Tallies/TallyMaps/Maps1D/fieldMap_class.f90 diff --git a/Geometry/fieldFactory_func.f90 b/Geometry/fieldFactory_func.f90 index f024f2db2..3e292e1c2 100644 --- a/Geometry/fieldFactory_func.f90 +++ b/Geometry/fieldFactory_func.f90 @@ -43,7 +43,7 @@ module fieldFactory_func !! name [in] -> Name of the field for the geometry registry !! !! Errors: - !! fatalError is type of field is unknown + !! fatalError if type of field is unknown !! subroutine new_field(dict, name) class(dictionary), intent(in) :: dict @@ -86,6 +86,5 @@ subroutine new_field(dict, name) call gr_addField(kentta, name) end subroutine new_field - - + end module fieldFactory_func diff --git a/Geometry/geometryReg_mod.f90 b/Geometry/geometryReg_mod.f90 index 183e27d87..a4ceb805b 100644 --- a/Geometry/geometryReg_mod.f90 +++ b/Geometry/geometryReg_mod.f90 @@ -16,28 +16,30 @@ !! fieldNameMap -> Map of field names to idx !! !! Interface: -!! addGeom -> Add new geometry -!! geomIdx -> Get index of the geometry -!! geomPtr -> Get pointer to a geometry with an index -!! addField -> Add new field -!! hasField -> Does the field with a given name exist? -!! fieldIdx -> Get index of a field -!! fieldPtr -> Get pointer to a field specified by index -!! display -> Display info about defined fields and geometries -!! kill -> Return to uninitialised state +!! addGeom -> Add new geometry +!! geomIdx -> Get index of the geometry +!! geomPtr -> Get pointer to a geometry with an index +!! addField -> Add new field +!! hasField -> Does the field with a given name exist? +!! fieldIdx -> Get index of a field +!! fieldPtr -> Get pointer to a field specified by index +!! fieldPtrName -> Get pointer to a field specified by name, for select names +!! display -> Display info about defined fields and geometries +!! kill -> Return to uninitialised state !! module geometryReg_mod use numPrecision - use genericProcedures, only : fatalError, numToChar - use dictionary_class, only : dictionary - use charMap_class, only : charMap + use genericProcedures, only : fatalError, numToChar + use universalVariables, only : nameTemperature, nameDensity + use dictionary_class, only : dictionary + use charMap_class, only : charMap ! Geometry - use geometry_inter, only : geometry + use geometry_inter, only : geometry ! Fields - use field_inter, only : field + use field_inter, only : field implicit none private @@ -67,6 +69,7 @@ module geometryReg_mod public :: addField public :: fieldIdx public :: fieldPtr + public :: fieldPtrName public :: hasField public :: kill @@ -81,6 +84,10 @@ module geometryReg_mod type(fieldBox), dimension(:), allocatable, target :: fields integer(shortInt) :: fieldTop = 0 type(charMap) :: fieldNameMap + + ! Save indices for speed. Avoids repeated calls to the character map + integer(shortInt) :: temperatureIdx = -8 + integer(shortInt) :: densityIdx = -8 contains @@ -228,6 +235,13 @@ subroutine addField(kentta, name) call fieldNameMap % add(name, idx) fields(idx) % name = name + ! Save density or temperature indices for speed + if (name == nameTemperature) then + temperatureIdx = idx + elseif (name == nameDensity) then + densityIdx = idx + end if + ! Point field call move_alloc(kentta, fields(idx) % kentta) @@ -248,7 +262,15 @@ pure function hasField(name) result(exists) integer(shortInt), parameter :: NOT_PRESENT = -8 integer(shortInt) :: idx - idx = fieldNameMap % getOrDefault(name, NOT_PRESENT) + select case(name) + case(nameTemperature) + idx = temperatureIdx + case(nameDensity) + idx = densityIdx + case default + idx = fieldNameMap % getOrDefault(name, NOT_PRESENT) + end select + exists = (idx /= NOT_PRESENT) end function hasField @@ -277,6 +299,46 @@ function fieldIdx(name) result(idx) end if end function fieldIdx + + !! + !! Get pointer to a field given its name + !! Optimised for frequently accessed fields to avoid + !! the relatively slow character map + !! + !! Args: + !! name [in] -> Name of the field + !! + !! Result: + !! Pointer to the field with the name + !! + !! Errors: + !! fatalError if name was not defined or + !! an unrecognised name was given + !! + function fieldPtrName(name) result(ptr) + character(nameLen), intent(in) :: name + class(field), pointer :: ptr + integer(shortInt) :: idx + integer(shortInt), parameter :: NOT_PRESENT = -8 + character(*), parameter :: Here = 'fieldPtrName (geometryReg_mod.f90)' + + select case(name) + case(nameTemperature) + idx = temperatureIdx + case(nameDensity) + idx = densityIdx + case default + idx = NOT_PRESENT + end select + + if (idx < 1 .or. idx > fieldTop) then + call fatalError(Here,'Index: '//numToChar(idx)//' does not correspond to valid field. & + &Must be 1-'//numToChar(fieldTop)) + end if + + ptr => fields(idx) % kentta + + end function fieldPtrName !! !! Get pointer to a field by index diff --git a/Geometry/geometryStd_class.f90 b/Geometry/geometryStd_class.f90 index d2009e236..dc3f0ec0d 100644 --- a/Geometry/geometryStd_class.f90 +++ b/Geometry/geometryStd_class.f90 @@ -15,8 +15,7 @@ module geometryStd_class use pieceConstantField_inter, only : pieceConstantField, pieceConstantField_CptrCast use geometryReg_mod, only : gr_hasField => hasField, & - gr_fieldIdx => fieldIdx, & - gr_fieldPtr => fieldPtr + gr_fieldPtrName => fieldPtrName ! Nuclear Data use materialMenu_mod, only : nMat @@ -661,13 +660,13 @@ function getFieldDist(coords) result(dist) dist = INF if (gr_hasField(nameTemperature)) then - genericField => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + genericField => gr_fieldPtrName(nameTemperature) pcField => pieceConstantField_CptrCast(genericField) dist = min(dist, pcField % distance(coords)) end if if (gr_hasField(nameDensity)) then - genericField => gr_fieldPtr(gr_fieldIdx(nameDensity)) + genericField => gr_fieldPtrName(nameDensity) pcField => pieceConstantField_CptrCast(genericField) dist = min(dist, pcField % distance(coords)) end if diff --git a/PhysicsPackages/eigenPhysicsPackage_class.f90 b/PhysicsPackages/eigenPhysicsPackage_class.f90 index d21c01652..76829770e 100644 --- a/PhysicsPackages/eigenPhysicsPackage_class.f90 +++ b/PhysicsPackages/eigenPhysicsPackage_class.f90 @@ -31,7 +31,8 @@ module eigenPhysicsPackage_class ! Geometry use geometry_inter, only : geometry use geometryReg_mod, only : gr_geomPtr => geomPtr, gr_geomIdx => geomIdx, & - gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr + gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr, & + gr_fieldPtrName => fieldPtrName use geometryFactory_func, only : new_geometry ! Fields @@ -530,7 +531,7 @@ subroutine init(self, dict) if (dict % isPresent('temperature')) then tempDict => dict % getDictPtr('temperature') call new_field(tempDict, nameTemperature) - field => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + field => gr_fieldPtrName(nameTemperature) pcField => pieceConstantField_CptrCast(field) maxTemperature = pcField % getMaxValue() else @@ -541,7 +542,7 @@ subroutine init(self, dict) if (dict % isPresent('density')) then tempDict => dict % getDictPtr('density') call new_field(tempDict, nameDensity) - field => gr_fieldPtr(gr_fieldIdx(nameDensity)) + field => gr_fieldPtrName(nameDensity) pcField => pieceConstantField_CptrCast(field) maxDensityScale = pcField % getMaxValue() else diff --git a/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 b/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 index 4ac578486..1489b0f08 100644 --- a/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 +++ b/PhysicsPackages/fixedSourcePhysicsPackage_class.f90 @@ -31,7 +31,8 @@ module fixedSourcePhysicsPackage_class ! Geometry use geometry_inter, only : geometry use geometryReg_mod, only : gr_geomPtr => geomPtr, gr_geomIdx => geomIdx, & - gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr + gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr, & + gr_fieldPtrName => fieldPtrName use geometryFactory_func, only : new_geometry ! Fields @@ -419,7 +420,7 @@ subroutine init(self, dict) if (dict % isPresent('temperature')) then tempDict => dict % getDictPtr('temperature') call new_field(tempDict, nameTemperature) - field => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + field => gr_fieldPtrName(nameTemperature) pcField => pieceConstantField_CptrCast(field) maxTemperature = pcField % getMaxValue() else @@ -430,7 +431,7 @@ subroutine init(self, dict) if (dict % isPresent('density')) then tempDict => dict % getDictPtr('density') call new_field(tempDict, nameDensity) - field => gr_fieldPtr(gr_fieldIdx(nameDensity)) + field => gr_fieldPtrName(nameDensity) pcField => pieceConstantField_CptrCast(field) maxDensityScale = pcField % getMaxValue() else diff --git a/PhysicsPackages/kineticPhysicsPackage_class.f90 b/PhysicsPackages/kineticPhysicsPackage_class.f90 index ac4a3f790..1fba2e202 100644 --- a/PhysicsPackages/kineticPhysicsPackage_class.f90 +++ b/PhysicsPackages/kineticPhysicsPackage_class.f90 @@ -30,7 +30,8 @@ module kineticPhysicsPackage_class ! Geometry use geometry_inter, only : geometry use geometryReg_mod, only : gr_geomPtr => geomPtr, gr_geomIdx => geomIdx, & - gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr + gr_fieldIdx => fieldIdx, gr_fieldPtr => fieldPtr, & + gr_fieldPtrName => fieldPtrName use geometryFactory_func, only : new_geometry ! Fields @@ -636,7 +637,7 @@ subroutine init(self, dict) if (dict % isPresent('temperature')) then tempDict => dict % getDictPtr('temperature') call new_field(tempDict, nameTemperature) - field => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + field => gr_fieldPtrName(nameTemperature) pcField => pieceConstantField_CptrCast(field) maxTemperature = pcField % getMaxValue() else @@ -647,7 +648,7 @@ subroutine init(self, dict) if (dict % isPresent('density')) then tempDict => dict % getDictPtr('density') call new_field(tempDict, nameDensity) - field => gr_fieldPtr(gr_fieldIdx(nameDensity)) + field => gr_fieldPtrName(nameDensity) pcField => pieceConstantField_CptrCast(field) maxDensityScale = pcField % getMaxValue() else diff --git a/Tallies/TallyMaps/CMakeLists.txt b/Tallies/TallyMaps/CMakeLists.txt index 013d1075e..6e0638ef5 100644 --- a/Tallies/TallyMaps/CMakeLists.txt +++ b/Tallies/TallyMaps/CMakeLists.txt @@ -13,7 +13,6 @@ add_sources(./tallyMap_inter.f90 ./Maps1D/weightMap_class.f90 ./Maps1D/cellMap_class.f90 ./Maps1D/radialMap_class.f90 - ./Maps1D/fieldMap_class.f90 ./Maps1D/timeMap_class.f90 ./Maps1D/collNumMap_class.f90 ./Maps1D/directionMap_class.f90 @@ -29,7 +28,6 @@ add_unit_tests(./Tests/multiMap_test.f90 ./Maps1D/Tests/homogMatMap_test.f90 ./Maps1D/Tests/radialMap_test.f90 ./Maps1D/Tests/cellMap_test.f90 - ./Maps1D/Tests/fieldMap_test.f90 ./Maps1D/Tests/timeMap_test.f90 ./Maps1D/Tests/collNumMap_test.f90 ./Maps1D/Tests/directionMap_test.f90) diff --git a/Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 b/Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 deleted file mode 100644 index 81b99321f..000000000 --- a/Tallies/TallyMaps/Maps1D/Tests/fieldMap_test.f90 +++ /dev/null @@ -1,120 +0,0 @@ -module fieldMap_test - use numPrecision - use funit - use particle_class, only : particleState - use dictionary_class, only : dictionary - use dictParser_func, only : charToDict - use charMap_class, only : charMap - use outputFile_class, only : outputFile - use fieldMap_class, only : fieldMap - - implicit none - - -@testCase - type, extends(TestCase) :: test_fieldMap - private - type(fieldMap),allocatable :: map_cartesian - contains - procedure :: setUp - procedure :: tearDown - end type test_fieldMap - - !! - !! Test parameters - !! - character(*), parameter :: FIELD_DEF = "& - & type cartesianField; origin (0 0 0); & - & pitch (3 2 1); materials (all); default 1; & - & shape (2 2 2); all (1 1 1 1 1 1 1 1);" - -contains - - !! - !! Sets up test_fieldMap object we can use in a number of tests - !! - subroutine setUp(this) - class(test_fieldMap), intent(inout) :: this - type(dictionary) :: dict, mapDict1, dictTemp - character(nameLen) :: name - - ! Store surfaces, cells and universes dictionaries - call charToDict(dictTemp, FIELD_DEF) - - ! Initialise dictionaries - call mapDict1 % init(2) - - ! Build material map definition - call mapDict1 % store('field', dictTemp) - allocate(this % map_cartesian, source = fieldMap(mapDict1)) - - end subroutine setUp - - !! - !! Kills test_fieldMap object we can use in a number of tests - !! - subroutine tearDown(this) - class(test_fieldMap), intent(inout) :: this - - call this % map_cartesian % kill() - - end subroutine tearDown - -!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> -!! PROPER TESTS BEGIN HERE -!!<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><> - - !! - !! Mapping test without undefined bin - !! -@Test - subroutine testMapping(this) - class(test_fieldMap), intent(inout) :: this - type(particleState) :: state - integer(shortInt) :: i - integer(shortInt),dimension(4) :: bins - integer(shortInt),dimension(4),parameter :: EXPECTED_BINS = [7, 1, 6, 0] - real(defReal), dimension(12), parameter :: r = [-2.0, 1.0, 0.5, -1.0, -1.0, -0.5, 1.4, -0.1, 0.1, 10.0, 10.0, 10.0] - - ! Note ordering of cartesian field - do i = 1, size(EXPECTED_BINS) - state % r = r((3*(i-1) + 1):(3*i)) - bins(i) = this % map_cartesian % map(state) - end do - - @assertEqual(EXPECTED_BINS,bins) - - end subroutine testMapping - - - !! - !! Test number of bins inquiry - !! -@Test - subroutine testNumberOfBinsInquiry(this) - class(test_fieldMap), intent(inout) :: this - - @assertEqual(8, this % map_cartesian % bins(1)) - @assertEqual(0, this % map_cartesian % bins(2), 'higher dimension') - @assertEqual(0, this % map_cartesian % bins(-2),'invalid dimension') - - end subroutine testNumberOfBinsInquiry - - !! - !! Test correctness of print subroutine - !! Does not checks that values are correct, but that calls sequance is without errors - !! -@Test - subroutine testPrint(this) - class(test_fieldMap), intent(inout) :: this - type(outputFile) :: out - - call out % init('dummyPrinter', fatalErrors = .false.) - - call this % map_cartesian % print(out) - @assertTrue(out % isValid()) - call out % reset() - - end subroutine testPrint - -end module fieldMap_test diff --git a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 b/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 deleted file mode 100644 index 1793579a8..000000000 --- a/Tallies/TallyMaps/Maps1D/fieldMap_class.f90 +++ /dev/null @@ -1,182 +0,0 @@ -module fieldMap_class - - use numPrecision - use genericProcedures, only : fatalError, numToChar - use dictionary_class, only : dictionary - use particle_class, only : particleState - use coord_class, only : coordList - use outputFile_class, only : outputFile - use tallyMap1D_inter, only : tallyMap1D, kill_super => kill - - ! Field - use pieceConstantField_inter, only : pieceConstantField - - implicit none - private - - !! - !! Constructor - !! - interface fieldMap - module procedure fieldMap_fromDict - end interface - - !! - !! Map that wraps fields to locate a particle. Performs the field mapping, - !! returning the index that a particle occupies. - !! - !! Private Members: - !! default -> binIdx for cells not in binMap - !! Nbins -> Number of bins in the map - !! - !! Interface: - !! tallyMap Interface - !! - !! Sample Dictionary Input: - !! myMap { - !! type fieldMap; - !! field {pieceConstant field dictionary} - !! - !! } - !! - type, public,extends(tallyMap1D) :: fieldMap - private - integer(shortInt) :: default = 0 - integer(shortInt) :: Nbins = 0 - class(pieceConstantField), allocatable :: field - - contains - ! Superclass interface implementaction - procedure :: init - procedure :: bins - procedure :: map - procedure :: getAxisName - procedure :: print - procedure :: kill - - end type fieldMap - -contains - - !! - !! Initialise cell map from dictionary - !! - !! See tallyMap for specification - !! - subroutine init(self, dict) - class(fieldMap), intent(inout) :: self - class(dictionary), intent(in) :: dict - class(dictionary),pointer :: tempDict - - ! UNDO ME - !tempDict => dict % getDictPtr('field') - !call new_pieceConstantField(self % field, tempDict) - !self % Nbins = self % field % getSize() - - end subroutine init - - !! - !! Return total number of bins in the map/elements in the field - !! - !! See tallyMap for specification - !! - elemental function bins(self, D) result(N) - class(fieldMap), intent(in) :: self - integer(shortInt), intent(in) :: D - integer(shortInt) :: N - - if (D == 1 .or. D == 0) then - N = self % Nbins - else - N = 0 - end if - - end function bins - - !! - !! Map particle to a single bin. Return 0 for particle out of division - !! - !! See tallyMap for specification - !! - elemental function map(self,state) result(idx) - class(fieldMap), intent(in) :: self - class(particleState), intent(in) :: state - type(coordList) :: coords - integer(shortInt) :: idx - - call coords % assignPosition(state % r) - idx = self % field % map(coords) - - end function map - - !! - !! Return string that describes variable used to divide event space - !! - !! See tallyMap for specification - !! - function getAxisName(self) result(name) - class(fieldMap), intent(in) :: self - character(nameLen) :: name - - name = 'Field' - - end function getAxisName - - !! - !! Add information about division axis to the output file - !! - !! See tallyMap for specification - !! - subroutine print(self,out) - class(fieldMap), intent(in) :: self - class(outputFile), intent(inout) :: out - character(nameLen) :: name - integer(shortInt) :: i - - ! Name the array - name = trim(self % getAxisName()) // 'Bins' - - call out % startArray(name, [1, self % Nbins]) - - ! Print field indexes - do i = 1, self % Nbins - call out % addValue(numToChar(i)) - end do - - call out % endArray() - - end subroutine print - - !! - !! Return to uninitialised state - !! - elemental subroutine kill(self) - class(fieldMap), intent(inout) :: self - - call kill_super(self) - call self % field % kill() - self % Nbins = 0 - - end subroutine kill - - !! - !! Build new field Map from dictionary - !! - !! Args: - !! dict[in] -> input dictionary for the map - !! - !! Result: - !! Initialised fieldMap instance - !! - !! Errors: - !! See init procedure. - !! - function fieldMap_fromDict(dict) result(new) - class(dictionary), intent(in) :: dict - type(fieldMap) :: new - - call new % init(dict) - - end function fieldMap_fromDict - -end module fieldMap_class diff --git a/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 b/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 index 67938f4ea..476d97dfb 100644 --- a/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 +++ b/Tallies/TallyMaps/Maps1D/tallyMap1DFactory_func.f90 @@ -35,7 +35,6 @@ module tallyMap1DFactory_func use collNumMap_class, only : collNumMap use radialMap_class, only : radialMap use directionMap_class, only : directionMap - use fieldMap_class, only : fieldMap use timeMap_class, only : timeMap implicit none @@ -58,7 +57,6 @@ module tallyMap1DFactory_func 'radialMap ',& 'timeMap ',& 'directionMap',& - 'fieldMap ',& 'testMap '] contains @@ -116,9 +114,6 @@ subroutine new_tallyMap1D(new, dict) case('radialMap') allocate(radialMap :: new) - case('fieldMap') - allocate(fieldMap :: new) - case('directionMap') allocate(directionMap :: new) diff --git a/TransportOperator/transportOperator_inter.f90 b/TransportOperator/transportOperator_inter.f90 index 36fc24388..3659a48f6 100644 --- a/TransportOperator/transportOperator_inter.f90 +++ b/TransportOperator/transportOperator_inter.f90 @@ -12,8 +12,7 @@ module transportOperator_inter ! Geometry interfaces use geometryReg_mod, only : gr_geomPtr => geomPtr, & gr_hasField => hasField, & - gr_fieldIdx => fieldIdx, & - gr_fieldPtr => fieldPtr + gr_fieldPtrName => fieldPtrName use geometry_inter, only : geometry use field_inter, only : field @@ -142,14 +141,14 @@ subroutine localConditions(self, p) ! Temperature check if (gr_hasField(nameTemperature)) then - genericField => gr_fieldPtr(gr_fieldIdx(nameTemperature)) + genericField => gr_fieldPtrName(nameTemperature) pcField => pieceConstantField_CptrCast(genericField) p % T = pcField % at(p % coords) end if ! Density check if (gr_hasField(nameDensity)) then - genericField => gr_fieldPtr(gr_fieldIdx(nameDensity)) + genericField => gr_fieldPtrName(nameDensity) pcField => pieceConstantField_CptrCast(genericField) p % rho = pcField % at(p % coords) end if From b797cc1c369500b34b117c2a42d066ae752f5d67 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sat, 21 Feb 2026 14:42:15 +0000 Subject: [PATCH 26/27] Removing old comments --- Geometry/geometryStd_class.f90 | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Geometry/geometryStd_class.f90 b/Geometry/geometryStd_class.f90 index dc3f0ec0d..d3a0e03f4 100644 --- a/Geometry/geometryStd_class.f90 +++ b/Geometry/geometryStd_class.f90 @@ -238,8 +238,6 @@ subroutine move_noCache(self, coords, maxDist, event) event = COLL_EV maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway - ! This check is really awful - can we do something better? - !else if (fieldDist < dist .and. abs(fieldDist - dist) > 10*NUDGE) then ! Stays within the same cell, but crosses field boundary else if (maxDist < dist .and. maxDist >= fieldDist) then ! Stays within the same cell, but crosses field boundary call coords % moveLocal(fieldDist, level0) event = FIELD_EV @@ -313,8 +311,6 @@ subroutine move_withCache(self, coords, maxDist, event, cache) maxDist = maxDist ! Left for explicitness. Compiler will not stand it anyway cache % lvl = 0 - ! This check is really awful - can we do something better? - !else if (fieldDist < dist .and. abs(fieldDist - dist) > 10 * NUDGE) then ! Stays within the same cell, but crosses field boundary else if (maxDist < dist .and. maxDist >= fieldDist) then ! Stays within the same cell, but crosses field boundary call coords % moveLocal(fieldDist, level0) event = FIELD_EV From 22efdd536d43c1a870fe569cfbb789f60d36b959 Mon Sep 17 00:00:00 2001 From: ChasingNeutrons Date: Sun, 1 Mar 2026 23:03:57 +0000 Subject: [PATCH 27/27] Fixing old comments --- NuclearData/ceNeutronData/ceNeutronCache_mod.f90 | 2 -- 1 file changed, 2 deletions(-) diff --git a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 index 93a6aa859..60c5402c8 100644 --- a/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 +++ b/NuclearData/ceNeutronData/ceNeutronCache_mod.f90 @@ -103,8 +103,6 @@ module ceNeutronCache_mod !! Public Members: !! E -> energy of the cross section !! xs -> value of the cross section - !! T -> temperature of the cross section - !! rho -> density scaling of the cross section !! type, public :: cacheSingleXS real(defReal) :: E = ZERO