HyperStudy

Process Environment Variables

Process Environment Variables

Previous topic Next topic No expanding text in this topic  

Process Environment Variables

Previous topic Next topic JavaScript is required for expanding text JavaScript is required for the print function  

When running HyperStudy on Windows and the Solver on UNIX, the following two process environment variables can prove useful:

STUDY_PC_PATH:

Holds the full path of the current run directory on Windows. HyperStudy is running on Windows, the study directory is a local directory on Windows, but the solver is running on a remote UNIX machine.

STUDY_UNIX_PATH:

Holds the full path of the current run directory, excluding the drive letter of the mapped drive.  HyperStudy is running on Windows, the study directory is on a UNIX mapped drive, and the solver is running on UNIX.

Note:These process environment variables are only available on Windows.

The following process environment variables are available on all platforms:

HST_ALTAIR_HOME:

Holds the path to the HyperWorks installation folder.

HST_APPROACH_MODEL_PATH:

Holds the path to the model folder in the current run folder.

HST_APPROACH_PATH:

Hold the path to the approach folder.

HST_APPROACH_VARNAME:

Holds the approach variable name.

HST_STUDY_VARNAME:

Holds the study variable name.

STUDY_DIR_PATH:

Holds the study directory.

STUDY_NOM_PATH:

Holds the path to the nom_run folder.

STUDY_NUM_MODELS:

Holds the number (integer) of models in the study.

STUDY_RUN_PATH / HST_APPROACH_RUN_PATH:

Holds the path to the current run folder. This variable is available during the process of writing the input deck, executing the solver, and extracting the output responses from the output file. The default value is set to the nominal run folder.

STUDY_RUN_NUMBER:

Holds the number (integer) of the current run. This variable is available to extract results from a table of existing results, for example. To use this environment variable in an expression, use the Templex statement convert(getenv("STUDY_RUN_NUMBER")), which will return an integer (see getenv). In the study Setup, STUDY_RUN_NUMBER is set to the first run and has a value of one.

Note:   The vector indexing of HyperStudy starts with zero. To retrieve a vector component from a table, v_1[convert(getenv("STUDY_RUN_NUMBER"))-1] has to be used.

 

To view examples of environment variables, right-click in the Message Log and select Verbose > Level 3 from the context sensitive menu. Once you have changed the verbose level to three, evaluate any approach. The values of the environment variables for the current study approach will be displayed in the message log.

message_log_process_environment_variables