Register External Optimizers

In order to use HyperStudy with other external optimizers, they must be registered.

Register external optimizers in HyperStudy or by editing the preferences file.

Register External Optimizers in HyperStudy

  1. From the menu bar, click Edit > Register Optimizer.
    The Register External Optimizer dialog opens.
  2. Add an external optimizer.
    1. Click Add External Optimizer.
    2. In the Add dialog, enter a label for the optimizer and click OK.
  3. In the Path column, enter the location of the external optimizer to be registered.
  4. Click Close to exit the external optimizer registration.

Register External Optimizers by Editing the Preferences File

Register external optimizers in the *BeginExternalOptimizerDefaults() section of the preferences_study.mvw file.

  1. In a text editor, open the preferences_study.mvw file.
    You can find the preferences_study.mvw file in the HyperWorks installation directory under <install directory>/hw/prefinc/.
  2. Search for the syntax *BeginExternalOptimizerDefaults().
  3. If you are working with a Windows operating system, append the first list of *RegisterExternalOptimizer statements. Otherwise, you will need to append the second list of *RegisterExternalOptimizer statements.
  4. Immediately following the existing *RegisterExternalOptimizer statements, register further external optimizers using the following syntax:
    *RegisterExternalOptimizer (opti_name,"opti_label","executable")
    where:
    opti_name
    Unique name for the optimizer.
    opti_label
    Name used within HyperStudy to reference the optimizer.
    Note: This name must be enclosed in double quotes.
    executable
    Full path of the external optimizer, including file name and extension.
  5. Save the preferences_study.mvw file.

Example: Register sqp.exe in the Preferences File

In this example, the sqp.exe executable is added to the default list of registered external optimizer for a Windows operating system. The added line is in bold.
*BeginExternalOptimizerDefaults()

       {machtype = sysid()}

       {if (machtype == "windows")}

              *RegisterExternalOptimizer(xopt, "Xopt", { getenv("HST_ALTAIR_HOME") + "/hw/bin/WIN64/xopt.exe" })
*RegisterExternalOptimizer(sqp, "SQP", {"C:/My_SQPOptimizer/sqp.exe" })

         {else}

              *RegisterExternalOptimizer(xopt, "Xopt", { getenv("HST_ALTAIR_HOME") + "/hw/bin/" + getenv("ALTAIR_PROD_ARCH") + "/xopt" })

         {endif}
          
   *EndExternalOptimizerDefaults()