RAConstantOneWayCoupling#

class ansys.rocky.app.ra_cfd_coupling.RAConstantOneWayCoupling#

Bases: RABaseCFDCoupling

Rocky PrePost Scripting wrapper for One-Way Constant CFD coupling properties.

This wrapper can be accessed via the project’s RACFDCoupling:

cfd_coupling = study.GetCFDCoupling()
cfd_coupling.SetupOneWayConstant()
constant_one_way = cfd_coupling.GetCouplingProcess()

Overview#

GetDensity

Get the value of “Density”.

SetDensity

Set the value of “Density”.

GetSpecificHeat

Get the value of “Specific Heat”.

SetSpecificHeat

Set the value of “Specific Heat”.

GetStartTime

Get the value of “Start Time”.

SetStartTime

Set the value of “Start Time”.

GetTemperature

Get the value of “Temperature”.

SetTemperature

Set the value of “Temperature”.

GetThermalConductivity

Get the value of “Thermal Conductivity”.

SetThermalConductivity

Set the value of “Thermal Conductivity”.

GetTurbulentDissipationRate

Get the value of “Turbulent Dissipation Rate”.

SetTurbulentDissipationRate

Set the value of “Turbulent Dissipation Rate”.

GetTurbulentKineticEnergy

Get the value of “Turbulent Kinetic Energy”.

SetTurbulentKineticEnergy

Set the value of “Turbulent Kinetic Energy”.

GetUseTurbulentDispersion

Get the value of “Use Turbulent Dispersion”.

SetUseTurbulentDispersion

Set the value of “Use Turbulent Dispersion”.

EnableTurbulentDispersion

Set the value of “Turbulent Dispersion” to True.

DisableTurbulentDispersion

Set the value of “Turbulent Dispersion” to False.

IsTurbulentDispersionEnabled

Check if the “Turbulent Dispersion” is enabled.

GetVelocity

Get the value of “Velocity”.

SetVelocity

Set the values of “Velocity”.

GetViscosity

Get the value of “Viscosity”.

SetViscosity

Set the value of “Viscosity”.

Import detail#

from ansys.rocky.app.ra_cfd_coupling import RAConstantOneWayCoupling

Method detail#

classmethod RAConstantOneWayCoupling.GetWrappedClass()#
classmethod RAConstantOneWayCoupling.GetClassName()#
RAConstantOneWayCoupling.GetDensity(unit: str | None = None) float#

Get the value of “Density”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “kg/m3”.

RAConstantOneWayCoupling.SetDensity(value: str | float, unit: str | None = None) None#

Set the value of “Density”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “kg/m3”.

RAConstantOneWayCoupling.GetSpecificHeat(unit: str | None = None) float#

Get the value of “Specific Heat”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “J/kg.K”.

RAConstantOneWayCoupling.SetSpecificHeat(value: str | float, unit: str | None = None) None#

Set the value of “Specific Heat”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “J/kg.K”.

RAConstantOneWayCoupling.GetStartTime(unit: str | None = None) float#

Get the value of “Start Time”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “s”.

RAConstantOneWayCoupling.SetStartTime(value: str | float, unit: str | None = None) None#

Set the value of “Start Time”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “s”.

RAConstantOneWayCoupling.GetTemperature(unit: str | None = None) float#

Get the value of “Temperature”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “K”.

RAConstantOneWayCoupling.SetTemperature(value: str | float, unit: str | None = None) None#

Set the value of “Temperature”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “K”.

RAConstantOneWayCoupling.GetThermalConductivity(unit: str | None = None) float#

Get the value of “Thermal Conductivity”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “W/m.K”.

RAConstantOneWayCoupling.SetThermalConductivity(value: str | float, unit: str | None = None) None#

Set the value of “Thermal Conductivity”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “W/m.K”.

RAConstantOneWayCoupling.GetTurbulentDissipationRate(unit: str | None = None) float#

Get the value of “Turbulent Dissipation Rate”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “W/kg”.

RAConstantOneWayCoupling.SetTurbulentDissipationRate(value: str | float, unit: str | None = None) None#

Set the value of “Turbulent Dissipation Rate”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “W/kg”.

RAConstantOneWayCoupling.GetTurbulentKineticEnergy(unit: str | None = None) float#

Get the value of “Turbulent Kinetic Energy”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “J/kg”.

RAConstantOneWayCoupling.SetTurbulentKineticEnergy(value: str | float, unit: str | None = None) None#

Set the value of “Turbulent Kinetic Energy”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “J/kg”.

RAConstantOneWayCoupling.GetUseTurbulentDispersion() bool#

Get the value of “Use Turbulent Dispersion”.

RAConstantOneWayCoupling.SetUseTurbulentDispersion(value: bool) None#

Set the value of “Use Turbulent Dispersion”.

Parameters:

value – The value to set.

RAConstantOneWayCoupling.EnableTurbulentDispersion() None#

Set the value of “Turbulent Dispersion” to True.

RAConstantOneWayCoupling.DisableTurbulentDispersion() None#

Set the value of “Turbulent Dispersion” to False.

RAConstantOneWayCoupling.IsTurbulentDispersionEnabled() bool#

Check if the “Turbulent Dispersion” is enabled.

RAConstantOneWayCoupling.GetVelocity(unit: str | None = None) list[float]#

Get the value of “Velocity”.

Parameters:

unit – The unit for the returned values. If no unit is provided, the returned values will be in “m/s”.

RAConstantOneWayCoupling.SetVelocity(values: collections.abc.Sequence[str | float], unit: str | None = None) None#

Set the values of “Velocity”.

Parameters:
  • values – The values to set. The values can be heterogeneous, the element of values can be an expression with input variables or a float. Must have exactly 3 elements.

  • unit – The unit for values. If no unit is provided, values is assumed to be in “m/s”.

Raises:

RockyApiError – If values doesn’t have exactly 3 elements.

RAConstantOneWayCoupling.GetViscosity(unit: str | None = None) float#

Get the value of “Viscosity”.

Parameters:

unit – The unit for the returned value. If no unit is provided, the returned value will be in “Pa.s”.

RAConstantOneWayCoupling.SetViscosity(value: str | float, unit: str | None = None) None#

Set the value of “Viscosity”.

Parameters:
  • value – The value to set. This value can be an expression with input variables or float type.

  • unit – The unit for value. If no unit is provided, value is assumed to be in “Pa.s”.