Commit 4d4a238f authored by Gurecky, William's avatar Gurecky, William Committed by Salko Jr, Robert
Browse files

Update due to change in CTF input deck format

Move where model is specified as being nodal.
parent 16ef5be7
Loading
Loading
Loading
Loading
+16 −0
Original line number Diff line number Diff line
@@ -79,6 +79,9 @@ class Model:
      # Stopping criteria for steady state
      me.runSteadyState = True

      # Is the model nodal
      me._is_nodal = False

      # Time group information
      me.dtMin = []; me.dtMax = []; me.editInterval = []; me.tEnd = []

@@ -139,6 +142,19 @@ class Model:
      # Single-phase turbulent mixing coefficient
      me.beta = 0.037

   @property
   def is_nodal(self):
      """ Access private is_nodal attr """
      return self._is_nodal

   @is_nodal.setter
   def is_nodal(self, is_nodal_in):
      """Set if the model is nodal

      Args:
         is_nodal_in (bool): Nodal model flag
      """
      self._is_nodal = bool(is_nodal_in)

   def setTitle(me, title):
      """Set the title of the model.
+1 −0
Original line number Diff line number Diff line
@@ -806,6 +806,7 @@ class SquareLatticeLWR_Nodal(CoreBuilder.Core):

      me.modelGuideTubes = modelGuideTubes
      model.addSection(sectionID, me.sec)
      model.is_nodal = True
      me.chMapObj = chMapObj
      me.nodalGeom = nodalGeom

+4 −4
Original line number Diff line number Diff line
@@ -115,6 +115,9 @@ def writeDeck(model, filename):
   group1Data.append("*Card 1.4\n")
   group1Data.append("**GTP(1)   VFRAC(3)  GTP(2) VFRAC(4)  GTP(3) VFRAC(5)  GTP(4) VFRAC(6)\n")
   group1Data.append("     air     0.0001\n")
   if model.editOptions['hdf5'] == True and model.is_nodal:
      group1Data.append("*Card 1.5\n")
      group1Data.append("     {nodal_model}     .true.\n")

   # The Card Group 2 data to be written to the deck
   group2Data=[]
@@ -673,9 +676,6 @@ def writeDeck(model, filename):
      group17Data.append("*NGR group number\n")
      group17Data.append("   17\n")
      group17Data.append("*Card 17.1 - HDF5_NAME VTK_NAME\n")
      if model.editOptions['hdf5'] == True:
         group17Data.append(" nodal  vtk_name\n")
      else:
      group17Data.append(" hdf5_name  vtk_name\n")
      group17Data.append("*Card 17.2 - Rod Map Dimensions\n")
      group17Data.append("**TOTRODSROW TOTRODSCOL\n")
+3 −1
Original line number Diff line number Diff line
@@ -25,6 +25,8 @@
*Card 1.4
**GTP(1)   VFRAC(3)  GTP(2) VFRAC(4)  GTP(3) VFRAC(5)  GTP(4) VFRAC(6)
     air     0.0001
*Card 1.5
     {nodal_model}     .true.
***********************************************************************************************
*GROUP 2 - Channel Description
***********************************************************************************************
@@ -101402,7 +101404,7 @@ end 14
*NGR group number
   17
*Card 17.1 - HDF5_NAME VTK_NAME
 nodal  vtk_name
 hdf5_name  vtk_name
*Card 17.2 - Rod Map Dimensions
**TOTRODSROW TOTRODSCOL
          30          30