def test_createHomogenizedRZTBlock(self):
        newBlock = blocks.ThRZBlock("testBlock", self.cs)
        a = self.r.core[0]
        converterSettings = {}
        geomConv = geometryConverters.HexToRZConverter(
            self.cs, converterSettings, expandReactor=self._expandReactor)
        volumeExpected = a.getVolume()
        (
            _atoms,
            _newBlockType,
            _newBlockTemp,
            newBlockVol,
        ) = geomConv.createHomogenizedRZTBlock(newBlock, 0, a.getHeight(), [a])

        # The volume of the radialZone and the radialThetaZone should be equal for RZ geometry
        self.assertAlmostEqual(volumeExpected, newBlockVol)
Exemple #2
0
 def __init__(
     self,
     sourceBlock,
     driverFuelBlock=None,
     numInternalRings=1,
     numExternalRings=None,
     quiet=False,
 ):
     BlockConverter.__init__(self, sourceBlock, quiet=quiet)
     self._driverFuelBlock = driverFuelBlock
     self._numExternalRings = numExternalRings
     self.convertedBlock = blocks.ThRZBlock(name=sourceBlock.name + "-cyl",
                                            height=sourceBlock.getHeight())
     self.convertedBlock.setLumpedFissionProducts(
         sourceBlock.getLumpedFissionProductCollection())
     self._numInternalRings = numInternalRings