In this tutorial, we’ll use the iLogic Automation rules to build, run, and post-process a linear static simulation. We’ll simulate a gravity load acting on a carbon steel frame.
Now we can begin to create a rule containing the iLogic commands that define the model. We can create multiple rules, each with unique steps, or we can create a single rule containing all the steps required to build our model. In this case, we’ll create a single rule.
You will see that the Main rule has already been created. This rule must exist in parallel to all other rules you create. For the purposes of this tutorial, just be aware that this rule must always be present. The main rule is used for
By default, in the Main rule, the iLogic External Rules directory and iLogic Addin DLLs directory are set to the C drive as follows:
ExternalRuleDirectory(0) = "C:\Program Files\Autodesk\Inventor Nastran 2023\In-CAD\System\iLogic"
oIlogic.FileOptions.AddinDirectory = "C:\Program Files\Autodesk\Inventor Nastran 2023\In-CAD\System"
If Inventor Nastran 2023 is installed on a different drive, both of the directories need to be set accordingly. For example, if installed in a folder D:\ADSK_NS2023, the paths for both directories need to be updated in the Main rule. Edit the Main rule and change the paths as follows:
ExternalRuleDirectory(0) = "D:\ADSK_NS2023\Inventor Nastran 2023\In-CAD\System\iLogic"
oIlogic.FileOptions.AddinDirectory = " D:\ADSK_NS2023\Inventor Nastran 2023\In-CAD\System"
The iLogic rules are created in Visual Basic language. The first set of commands we’ll add will define the external iLogic rules and Inventor Nastran add-ins.
AddReference "NINIlogic" Sub Main() iLogicVb.RunExternalRule("IlogicExtRule_EnterInCADEnv") Dim AddinObj As New NINIlogic.InCadAddin Dim strCmdForNewMaterial, strCmdFornewIdealization As String