Specify Solver Input Arguments

A solver input argument is any argument to be passed to the solver.

The default argument is ${file}, which means that the qualified solver input file name is passed to the solver script.

In the Define Models step, Solver Input Arguments column of the model you are defining, enter solver input arguments.
Tip: Access a list of HyperStudy specific variables and solver specific options from the Solver Input Arguments field by clicking .

Depending on the mode type selected, a default list of arguments is provided for specific Altair solvers. You can optionally attach your own help for any registered solver.

Example: Solver Input Arguments

Examples solver input arguments for various solvers and Linux.

In these examples, ${file} refers to the solver file that is passed to the solver script.
Radioss
${file} -both
OptiStruct
${file} -scr C:\temp
Compose/OML
-f ${file}
Excel
My_Vb_script1
LS-DYNA
i=${file} MEMORY=5000000
Nastran
Batch=no
Flux
-env_FLUX_NCORES=1 -env_MEMSIZN3=...
MADYMO
-fg <filename>.xml
Abaqus
job=<filename>.inp memory=200Mb interactive
You may need to edit the Abaqus environment file (ex: <ABAQUS INSTALL>\v6.11\6.11-1\site\abaqus v6.env) file to include ask_delete=OFF or comment the line ask delete=on if any.
This is needed as Abaqus prompts the user if they want to overwrite the old files when rerunning the analysis. In order to eliminate the need for user interaction we need to command Abaqus not to ask this question and overwrite.
Solver Scripts Running on Linux
-nobg

Example: Specify Multiple Solver Input Arguments

Solver input arguments are passed to the solver script as separate arguments. The script then treats them as %1 (first argument) , %2 (second argument), and so on.

In Figure 1, file1.txt is the model file updated by HyperStudy, and file2.txt and file3.txt are additional files needed for the solver (that is include files).


Figure 1.

Having these three files listed in the Solver Input Arguments field allows file1.txt to be updated and ensures that all three files are copied into the appropriate folder together. The solver input arguments ensures that ${file} ( = file1.txt), file2.txt and file3.txt are submitted to the solver script.

Figure 2 shows a sample solver script (.bat file) for this example.
echo %1
echo %2
echo %3 
Figure 2.
Which results in:
"C:\TEST\nom_run\m_1\file1.txt"
file2.txt
file3.txt 
It is possible to improve the solver script using:
%1
Full file name passed by HyperStudy to the solver script
%~n1
File name without extension and path
%~x1
File extension
You could also improve the solver script using a HyperStudy environment variables such as %STUDY_DIR_PATH% (to get the current path) or %STUDY_RUN_NUMBER% (to get the current run number).

Example: Excel Connection Solver Input Arguments

This example illustrates a Spreadsheet model type with solver input arguments for an Excel connection.

In Figure 3 the macro my_VB_script_1 will be executed for each solver run.


Figure 3.

Use Environment Variables as Solver Input Arguments

In the case of the Excel connection, solver input arguments also recognize a number of environment variables that can be used to pass information to the VB macro used in the spreadsheet.
$file, $filespec
Example: c:\studyfolder\approaches\doe_1\run__00001\plate.fem
$filebasename
Example: plate.fem
$studydir
Example: c:\studyfolder

Pass Current Run Folder Name to the Macro

You can pass the name of the current run folder to the macro, for example my_VB_Script1 $filespec.


Figure 4.