Skip to main content

System Coupling C++ library 2024 R1

sysc::Region Class Reference

Last update: 17.07.2025

Provide a class for a System Coupling region. More...

#include <Region.hpp>

Public Member Functions

 Region (const RegionName &name)
 Create region to be used in a coupled analysis.
 
 Region (const RegionName &name, enum Topology topology)
 Create region to be used in a coupled analysis.
 
 Region (const RegionName &name, enum Topology topology, const DisplayName &displayName)
 Create region to be used in a coupled analysis.
 
 Region (const RegionName &name, enum Topology topology, enum RegionDiscretizationType regionDiscretizationType)
 Create region to be used in a coupled analysis.
 
 Region (const RegionName &name, enum Topology topology, const DisplayName &displayName, enum RegionDiscretizationType regionDiscretizationType)
 Create region to be used in a coupled analysis.
 
void addInputVariable (const Variable &variable)
 Provide a method to add an input variable to the region.
 
void addOutputVariable (const Variable &variable)
 Provide a method to add an output variable to the region.
 
const RegionNamegetName () const noexcept
 Get the region's name.
 
Topology getTopology () const noexcept
 Get the region's topology.
 
const DisplayNamegetDisplayName () const noexcept
 Get the region's display name.
 
RegionDiscretizationType getRegionDiscretizationType () const noexcept
 Get the region's mesh type.
 
const VariablegetInputVariable (const VariableName &name) const
 Get the region's input variable by name.
 
const VariablegetOutputVariable (const VariableName &name) const
 Get the region's output variable by name.
 
std::size_t getNumOutputVariables () const noexcept
 Provide a method to get number of output variables for this region.
 
std::size_t getNumInputVariables () const noexcept
 Provide a method to get number of input variables for this region.
 
const VariablegetOutputVariable (std::size_t index) const
 Get the region's output variable by index.
 
const VariablegetInputVariable (std::size_t index) const
 Get the region's input variable by index.
 

Detailed Description

Provide a class for a System Coupling region.

Participant can declare which regions can be used in the coupled analysis. Each region can declare its input variables and output variables. Input variables represent physical quantities whose values the participant expects System Coupling to provide. Output variables represent physical quantities whose values System Coupling expects the participant to provide.

Definition at line 30 of file Region.hpp.

Constructor & Destructor Documentation

◆ Region() [1/5]

sysc::Region::Region ( const RegionName name)

Create region to be used in a coupled analysis.

Parameters
name- Unique name for this region.

Display name will default to the same as name.

Topology will default to surface.

Region mesh type will default to mesh.

◆ Region() [2/5]

sysc::Region::Region ( const RegionName name,
enum Topology  topology 
)

Create region to be used in a coupled analysis.

Parameters
name- Unique name for this region.
topology- region topology.

Display name will default to the same as name.

Region mesh type will default to mesh.

◆ Region() [3/5]

sysc::Region::Region ( const RegionName name,
enum Topology  topology,
const DisplayName displayName 
)

Create region to be used in a coupled analysis.

Parameters
name- Unique name for this region.
topology- region topology.
displayName- region display name.

Mesh type will default to mesh.

◆ Region() [4/5]

sysc::Region::Region ( const RegionName name,
enum Topology  topology,
enum RegionDiscretizationType  regionDiscretizationType 
)

Create region to be used in a coupled analysis.

Parameters
name- Unique name for this region.
topology- region topology.
regionDiscretizationType- region discretization type.

Display name will default to the same as name.

◆ Region() [5/5]

sysc::Region::Region ( const RegionName name,
enum Topology  topology,
const DisplayName displayName,
enum RegionDiscretizationType  regionDiscretizationType 
)

Create region to be used in a coupled analysis.

Parameters
name- Unique name for this region.
topology- region topology.
displayName- region display name.
regionDiscretizationType- region mesh type.

Member Function Documentation

◆ addInputVariable()

void sysc::Region::addInputVariable ( const Variable variable)

Provide a method to add an input variable to the region.

If this variable has already been added to the region as an input variable, then this call will have no effect.

If a different variable with the same name has already been added to the region as an input variable, then a runtime error will be thrown.

If a variable with the same name has already been added to the region as an output variable, then a runtime error will be thrown.

If the variable name contains invalid characters, a runtime error will be thrown.

If the region discretization type is point cloud, then the location of the variable added to this region is insignificant.

Parameters
variableVariable whose values are provided by System Coupling and consumed by the participant.

◆ addOutputVariable()

void sysc::Region::addOutputVariable ( const Variable variable)

Provide a method to add an output variable to the region.

If this variable has already been added to the region as an output variable, then this call will have no effect.

If a different variable with the same name has already been added to the region as an output variable, then a runtime error will be thrown.

If a variable with the same name has already been added to the region as an input variable, then a runtime error will be thrown.

If the variable name contains invalid characters, a runtime error will be thrown.

If the region discretization type is point cloud, then the location of the variable added to this region is insignificant.

Parameters
variableVariable whose values are provided by the participant and consumed by System Coupling.

◆ getDisplayName()

const DisplayName & sysc::Region::getDisplayName ( ) const
noexcept

Get the region's display name.

Returns
Return value is the display name of this region.

◆ getInputVariable()

const Variable & sysc::Region::getInputVariable ( const VariableName name) const

Get the region's input variable by name.

Parameters
nameName of the desired input variable.
Returns
Return is the Variable object that was requested.

◆ getName()

const RegionName & sysc::Region::getName ( ) const
noexcept

Get the region's name.

Returns
Return value is the region's unique name (string).

◆ getOutputVariable()

const Variable & sysc::Region::getOutputVariable ( const VariableName name) const

Get the region's output variable by name.

Parameters
nameName of the desired output variable.
Returns
Return is the Variable object that was requested.

◆ getRegionDiscretizationType()

RegionDiscretizationType sysc::Region::getRegionDiscretizationType ( ) const
noexcept

Get the region's mesh type.

Returns
Return value is the mesh type of this region.

◆ getTopology()

Topology sysc::Region::getTopology ( ) const
noexcept

Get the region's topology.

Returns
Return value is the topology of this region.

Connect with Ansys