Skip to main content
Subfolder of a Simulation, regrouping Output/Result for a step. #include "Run.hpp" Inheritance diagram for ansys::Project::Run:

Public Types

Public Member Functions

Public Member Functions inherited from ansys::Project::SimBase
Public Member Functions inherited from ansys::Project::RunOutputAttr

Static Public Member Functions

Protected Member Functions

Protected Member Functions inherited from ansys::Project::SimBase

Additional Inherited Members

Static Public Attributes inherited from ansys::Project::RunOutputAttr
Protected Attributes inherited from ansys::Project::SimBase

Detailed Description

Subfolder of a Simulation, regrouping Output/Result for a step. Subclass of Iterator, can be constructed from an Iterator, the Run is ok() only if the provided iterator is of the appropriate subclass.
In a Simulation, one or multiple Run are created, to store the simulation Results, organized in Output subfolders. The Run might have Metatada assigned from the settings for this computation ( reference conditions, etc. ) The expected amount of Output in a run, and the variables expected to be defined for each Output depends of the RunOutputType.
  • Simple : Single Output
  • Transient : One or more Output. variable : Time
  • Steady : One or more Output. variable : SolverIteration
  • Sequence : One or more Output. variable : Index
  • Parametric : One or more Output, for a sweep of values across a list of variables.
A variable (addVariable(), addVar*()) enabled in a Run, is expected to be changed across all Output subfolders. Its related to the input settings, or the context of a result (for example, the solver iteration or time step) Additional variables can be added, in addition to the mandatory variables from the RunOutputType Output variables (addOutputVariable()) are values computed from that result, they might be from monitors or probe points.
Variable values assigned to the Run will be inherited by all underlying Output and Result children.

Member Enumeration Documentation

OutputMatchOperator

OutputSequenceOrder

RunOutputType

Constructor & Destructor Documentation

Run() [1/2]

Constructor from Iterator.
The input Iterator must be of subclass Run If the subclass is not Run, the Run object is invalid ( !ok() )

~Run()

inline virtual

Run() [2/2]

protected

Member Function Documentation

addOutputVariable()

Register an output variable for this run. All Output subfolders should define a specific value for this variable.

addVarCaseId()

Add the CaseId variable - Id is incremented when the case settings are changed.

addVarConnectivityId()

Add the ConnectivityId variable - Id should be incremented when the cells of a mesh are changed (number changed, connectivity changed, …)

addVarCoordinatesId()

Add the CoordinatesId variable - Id should be incremented when the node locations of a mesh have changed.

addVarCrankAngle()

Add the built-in variable.

addVarDomainTransformationId()

Add the DomainTransformationId variable - Id should be incremented when the mesh transformation metadata has changed.

addVariable()

Register an input variable for this run. This registration is not required for automatic variables (Transient=Time, etc.) All Output subfolders should define a specific value for this variable.

addVarIndex()

Add the Index variable (not required if mandatory for the run type)

addVarInputSettingsId()

Add the InputSettings variable - Id is incremented when the input case settings are changed. If provided, this should be incremented when any of the dependent input settings are changed, such as PhysicsId or DomainTransformationId

addVarLocationId()

Add the LocationId variable - Id should be incremented when the node locations of a mesh have changed.

addVarMeshId()

Add the MeshId variable - Id should be incremented when the mesh has changed.

addVarOutputSettingsId()

Add the OutputSettings variable - Id is incremented when the case output settings are changed.

addVarPhysicsId()

Add the PhysicsId variable - Id should be incremented when the physics settings have changed.

addVarSolverIteration()

Add the SolverIteration variable (not required if mandatory for the run type)

addVarTime()

Add the Time variable (not required if mandatory for the run type)

addVarTopologyId()

Add the TopologyId variable - Id should be incremented when the topology (list of boundaries, domains) has changed.

computeIds()

Compute missing ids (CaseId, MeshId, InputSettingsId) from their dependencies.

getAllVariables()

Returns the list of all variables ( input and output )

getCase()

virtual Returns the case file associated with this run (if any, see setCase()) Reimplemented from ansys::Project::SimBase.

getCurrentOutput()

Return the current output link for this run, typically the latest output is the current.

getData()

Returns the default latest data file (from the current output, main data type)

getIterator()

inline virtual Implements ansys::Project::RunOutputAttr. Reimplemented in ansys::Project::RunGroup.

getOutputIterators()

Return the list of Output in the current Run, as a vector of Iterator.

getOutputs()

Return the list of Output in the current Run.

getOutputSequence()

Get the Output sequence, ordered by the specified parameter. Retrieve the output list, as ordered by a specific recipe and based on the value of a variable. The default getOutput() will return the outputs as ordered by their creation order. In a simple transient or steady run, this will be sufficient to get the ordered datasets. Transient postprocessing typically assumes a monotonic (increasing, unique values) sequence. Parametric runs might have their dataset generated in any order, and a sorted list of outputs might be desirable. Parameters RunOutputAttr contains the list of standard variable names See: RunOutputAttr::sVarTime, RunOutputAttr::sVarSolverIteration, etc. Parameters Returns : Error in case of unknown variable or invalid parameters

getOutputsMatching()

Get the list of outputs matching the specified condition. Returns the subset of outputs matching the specified condition, the outputs will not have any specified order. See also getOutputSequence() Parameters

getOutputVariables()

Returns the list of output variables.

getResult()

Returns the current data file of specified type.

getResultIterators()

Return the list of results in the current Run and Output subfolders, as vector of Iterator. Parameters

getResults()

Return the list of results in the current Run and Output subfolders. Parameters

getResultTypes()

Returns the list of available output types listed in the run Outputs.

getRunOutputType()

Return the RunOutputType as the enum.

getRunOutputTypeAsString()

Return the RunOutputType as a string.

getRunStatus()

Returns the RunStatus state for this Output. See setRunStatus()

getTransientOutputs()

For transient runs - return the list of output results and their time values. The output runs are processed to return a monotonic (increasing, unique values) sequence (see getOutputSequence()). For each output of that sequence, if a result of the specified type exist, its returned alongside with the time value. Parameters

getValue()

virtual Search the metadata (local and inherited) for the specified key and return the value as string. Parameters Implements ansys::Project::RunOutputAttr.

getValueDouble()

virtual Search the metadata (local and inherited) for the specified key and return the value as double. Parameters Implements ansys::Project::RunOutputAttr.

getValueInt()

virtual Search the metadata (local and inherited) for the specified key and return the value as integer. Parameters Implements ansys::Project::RunOutputAttr.

getValueIter()

Search the metadata (local and inherited) for the specified metadata link and return the value as an iterator. Parameters

getValues()

Return the list of values -one per output- for a list of variables.

getValueType()

virtual Search the metadata (local and inherited) for the specified key and return the its data type. Parameters Implements ansys::Project::RunOutputAttr.

getVariables()

Return the list of input variables for this Run.

hasValue()

virtual Search the metadata (local and inherited) for the specified key. Parameters Implements ansys::Project::RunOutputAttr.

isValid()

virtual Returns error with message if invalid. Implements ansys::Project::SimBase. Reimplemented in ansys::Project::RunGroup.

newOutput()

Create a Output folder in the current Run folder. The Output folder is by default a virtual (project-only) folder and no folder is created in the filesystem. By default, all Result owned by a Run/Output are stored in the same disk folder, but the Project structure regroup each group of Result in an Output block. Parameters

removeOutputs()

Remove the specified list of Output from the children of this run. Parameters

removeOutputVariable()

Remove an output variable.

removeVariable()

Remove a variable from the list of inputs. Mandatory variables cannot be removed

runStatusToString()

static

setCurrentOutput()

Set the current output link for this run, typically the latest output is the current.

setOutputVariables()

Set/replace the list of output variables.

setRunOutputType()

Set the run output type, will add automatically the mandatory variables (if any)

setRunStatus()

Set the RunStatus state for this Run. (Optional API) The run status permits to indicate if a Run is running, completed, waiting for execution, etc. This status can also be defined at the Output level

setValue() [1/3]

virtual Sets the local metadata to the specified key/value. Implements ansys::Project::RunOutputAttr.

setValue() [2/3]

inline

setValue() [3/3]

inline

setValueDouble()

virtual Sets the local metadata to the specified key/value. Implements ansys::Project::RunOutputAttr.

setValueInt()

virtual Sets the local metadata to the specified key/value. Implements ansys::Project::RunOutputAttr.

setVariables()

Set/replace the list of variables for this run. The operation will fail if the list of variables does not contain the mandatory variable for the RunOutputType All Output subfolders should define a specific value for each variable.

stringToRunStatus()

static