Tutorial B7: Complete the Rule and Run It

Display a Contour Plot

Finally, we can complete the rule by adding a command to create a contour plot after the solution is complete.

  1. Copy the following text:
    strCmdForDisplayContour = "<Contour ID=""1""/>"
       ' New Material
    	  i = AddinObj.Run(strCmdForNewMaterial)
    
    	  ' New Idealization
    	  i = AddinObj.Run(strCmdForNewIdealization)
    
    	  ' Mesh Model
    	  i = AddinObj.Run(strCmdForMeshModel)
    
    	  ' Generate Mesh
    	  i = AddinObj.Run(strCmdForMesh)
    
    	  ' Create Load
    	  i = AddinObj.Run(strCmdForLoad)
    
    	  ' Create Constraint
    	  i = AddinObj.Run(strCmdForConstraint)
    
    	  ' Run Analysis
    	  i = AddinObj.Run(strCmdForSolve)
    	
    	  iLogicVb.UpdateWhenDone = True
    End Sub
  2. Paste the text below the existing commands in the Edit Rule dialog.

Run the Rule

Now we are ready to save the rule and run it.

  1. Click Save and then click Close to exit the Edit Rule dialog.
  2. Switch to the Autodesk Nastran Model tree browser, and under Model tree, delete Solid 1 Idealization and the Generic material.
  3. Switch back to the iLogic browser, right-click in the white space of the browser and choose Run All Rules.
  4. If you receive a warning about multiple idealizations, click OK.
  5. When the solution is complete, click OK to view the contour plot.