Commit 763191ed authored by Gurecky, William's avatar Gurecky, William
Browse files

move card to write nodal vera h5 results to CTF card group 1 and check if is_nodal

parent 6ac43004
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

+6 −4
Original line number Diff line number Diff line
@@ -115,6 +115,11 @@ 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")
   group1Data.append("*Card 1.5\n")
   if model.editOptions['hdf5'] == True and model.is_nodal:
      group1Data.append("     nodal_model     1\n")
   else:
      group1Data.append("     nodal_model     0\n")

   # The Card Group 2 data to be written to the deck
   group2Data=[]
@@ -673,9 +678,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")