ICape Thermo MaterialGet TPFraction Method
Retrieves temperature, pressure and composition for a Phase.
Definition
Namespace: CapeOpen
Assembly: CapeOpen (in CapeOpen.dll) Version: 1.0.0.0 (1.0.0.0)
Assembly: CapeOpen (in CapeOpen.dll) Version: 1.0.0.0 (1.0.0.0)
C#
[DispIdAttribute(8)]
void GetTPFraction(
string phaseLabel,
out double temperature,
out double pressure,
out Object composition
)VB
<DispIdAttribute(8)>
Sub GetTPFraction (
phaseLabel As String,
<OutAttribute> ByRef temperature As Double,
<OutAttribute> ByRef pressure As Double,
<OutAttribute> ByRef composition As Object
)Parameters
- phaseLabel String
- Phase label of the Phase for which the property is required. The Phase label must be one of the identifiers returned by the GetPresentPhases method of this interface.
- temperature Double
- Temperature (in K)
- pressure Double
- Pressure (in Pa)
- composition Object
- Composition (mole fractions)
Return Value
No return.Remarks
This method is provided to make it easier for developers to make efficient use of the CAPEOPEN interfaces. It returns the most frequently requested information from a Material Object in a single call.
There is no choice of basis in this method. The composition is always returned as mole fractions.
To get the equivalent information for the overall mixture the GetOverallTPFraction method of the ICapeThermoMaterial interface should be used.
Exceptions
| ECapeNoImpl | The operation GetTPFraction is “not” implemented even if this method can be called for reasons of compatibility with the CAPE-OPEN standards. That is to say that the operation exists but it is not supported by the current implementation. |
| ECapeThrmPropertyNotAvailable | One of the properties is not available from the Material Object. This exception is raised when a property value has not been set following a call to the CreateMaterial or the value has been erased by a call to the ClearAllProps methods. |
| ECapeInvalidArgument | To be used when an invalid argument value was passed: for example UNDEFINED for property, or an unrecognised identifier for phaseLabel. |
| ECapeFailedInitialisation | The pre-requisites are not valid. The necessary initialisation has not been performed, or has failed. This exception is returned if the Phase specified does not exist. |
| ECapeUnknown | The error to be raised when other error(s), specified for this operation, are not suitable. |