Skip to main content

DPF C++ client library 2023 R2

ansys::dpf::Result Class Reference

Last update: 10.07.2023

#include <dpf_result.h>

Public Member Functions

 Result (const char *res_name, Operator &stream_provider, Operator &timefreq_support_provider)
 
 Result (const char *res_name, Operator &stream_provider, Operator &timefreq_support_provider, Scoping meshScoping)
 
 Result (const char *res_name, Operator &stream_provider, Operator &timefreq_support_provider, Scoping meshScoping, Location requested_location, int cs_id)
 
 Result (const char *res_name, Operator &stream_provider, Operator &timefreq_support_provider, Operator &mesh_provider, const char *named_selection, Location requested_location, bool bInclusive, int cs_id)
 
FieldsContainer EvaluateAtGivenTime (double dTime, DpfError &error)
 
FieldsContainer EvaluateAtGivenTimeIndex (dp_int iSet, DpfError &error)
 
FieldsContainer EvaluateAtGivenStepIndexAndSubStep (dp_int iStep, dp_int iSubStep, DpfError &error)
 
FieldsContainer EvaluateAmplitudeAtGivenTime (double dTime, DpfError &error)
 
FieldsContainer EvaluateAmplitudeAtGivenTimeIndex (int iSet, DpfError &error)
 
FieldsContainer EvaluateAmplitudeAtGivenStepIndexAndSubStep (int iStep, int iSubStep, DpfError &error)
 
FieldsContainer EvaluateWithPhaseAtGivenTime (double dTime, double dPhase, DpfError &error)
 
FieldsContainer EvaluateWithPhaseAtGivenTimeIndex (int iSet, double dPhase, DpfError &error)
 
FieldsContainer EvaluateWithPhaseAtGivenStepIndexAndSubStep (int iStep, int iSubStep, double dPhase, DpfError &error)
 

Detailed Description

Encapsulation of results.

Examples
DataApis.cpp, and ModelTest.cpp.

Constructor & Destructor Documentation

◆ Result() [1/4]

ansys::dpf::Result::Result ( const char *  res_name,
Operator stream_provider,
Operator timefreq_support_provider 
)
inline

Create a new result from res_name using given stream and timefreq.

Parameters
[in]res_nameName of result on which to create result.
[in]stream_providerStream from which to create result.
[in]timefreq_support_providerTime/frequency from which to create result.

◆ Result() [2/4]

ansys::dpf::Result::Result ( const char *  res_name,
Operator stream_provider,
Operator timefreq_support_provider,
Scoping  meshScoping 
)
inline

Create a new result from res_name using given stream, timefreq, and scoping.

Parameters
[in]res_nameName of result on which to create result.
[in]stream_providerStream from which to create result.
[in]timefreq_support_providerTime/frequency from which to create result.
[in]meshScopingScoping from which to create result.

◆ Result() [3/4]

ansys::dpf::Result::Result ( const char *  res_name,
Operator stream_provider,
Operator timefreq_support_provider,
Scoping  meshScoping,
Location  requested_location,
int  cs_id 
)
inline

Create a new result from res_name using given stream, timefreq, scoping, and location.

Parameters
[in]res_nameName of result on which to create result.
[in]stream_providerStream from which to create result.
[in]timefreq_support_providerTime/frequency from which to create result.
[in]meshScopingScoping from which to create result.
[in]requested_locationLocation on which to create result.
[in]cs_idNot used.

◆ Result() [4/4]

ansys::dpf::Result::Result ( const char *  res_name,
Operator stream_provider,
Operator timefreq_support_provider,
Operator mesh_provider,
const char *  named_selection,
Location  requested_location,
bool  bInclusive,
int  cs_id 
)
inline

Create a new result from res_name using given stream, timefreq, mesh, named_selection, and location.

Parameters
[in]res_nameName of result on which to create result.
[in]stream_providerStream from which to create result.
[in]timefreq_support_providerTime/frequency from which to create result.
[in]mesh_providerMesh from which to create result.
[in]named_selectionNamed selection from which to create result.
[in]requested_locationLocation on which to create result.
[in]bInclusiveIf named_selection is a nodal region and location is elemental, this flag indicates to include full/partial contained elements in named_selection.
[in]cs_idNot used.

Member Function Documentation

◆ EvaluateAmplitudeAtGivenStepIndexAndSubStep()

FieldsContainer ansys::dpf::Result::EvaluateAmplitudeAtGivenStepIndexAndSubStep ( int  iStep,
int  iSubStep,
DpfError error 
)
inline

Get the amplitude of the real and imaginary part of results of given TimeFreqSupport. Results are evaluated at a given TimeFreqSupport. This is arranged in TimeFreqSupport::numberOfSteps groups of size TimeFreqSupport::numberOfSubStepsByStepIndex.

Returns
FieldsContainer for given step and substep index.
Parameters
[in]iStepGrouping index.
[in]iSubStepSubgrouping index.
[out]errorStatus of call.

◆ EvaluateAmplitudeAtGivenTime()

FieldsContainer ansys::dpf::Result::EvaluateAmplitudeAtGivenTime ( double  dTime,
DpfError error 
)
inline

Get the amplitude of the real and imaginary part of results at a given time.

Returns
FieldsContainer for given time.
Parameters
[in]dTimeTime for which to get fields.
[out]errorStatus of call.

◆ EvaluateAmplitudeAtGivenTimeIndex()

FieldsContainer ansys::dpf::Result::EvaluateAmplitudeAtGivenTimeIndex ( int  iSet,
DpfError error 
)
inline

Get the amplitude of the real and imaginary part of results of given TimeFreqSupport index.

Returns
FieldsContainer for given TimeFreqSupport index.
Parameters
[in]iSetIndex of TimeFreqSupport.
[out]errorStatus of call.

◆ EvaluateAtGivenStepIndexAndSubStep()

FieldsContainer ansys::dpf::Result::EvaluateAtGivenStepIndexAndSubStep ( dp_int  iStep,
dp_int  iSubStep,
DpfError error 
)
inline

Results are evaluated for at a given TimeFreqSupport. This is arranged in TimeFreqSupport::numberOfSteps groups of size TimeFreqSupport::numberOfSubStepsByStepIndex.

Returns
FieldsContainer for given step and substep index.
Parameters
[in]iStepGrouping index.
[in]iSubStepSubgrouping index.
[out]errorStatus of call.

◆ EvaluateAtGivenTime()

FieldsContainer ansys::dpf::Result::EvaluateAtGivenTime ( double  dTime,
DpfError error 
)
inline

Get the fields associated with results at a given time.

Returns
FieldsContainer for given time.
Parameters
[in]dTimeTime for which to get fields.
[out]errorStatus of call.
Examples
DataApis.cpp, and ModelTest.cpp.

◆ EvaluateAtGivenTimeIndex()

FieldsContainer ansys::dpf::Result::EvaluateAtGivenTimeIndex ( dp_int  iSet,
DpfError error 
)
inline

Get the fields associated with results at given TimeFreqSupport index.

Returns
FieldsContainer for given time/frequency index.
Parameters
[in]iSetIndex of TimeFreqSupport.
[out]errorStatus of call.

◆ EvaluateWithPhaseAtGivenStepIndexAndSubStep()

FieldsContainer ansys::dpf::Result::EvaluateWithPhaseAtGivenStepIndexAndSubStep ( int  iStep,
int  iSubStep,
double  dPhase,
DpfError error 
)
inline

Get the sweeping phase at given TimeFreqSupport and phase. Results are evaluated at a given TimeFreqSupport. This is arranged in TimeFreqSupport::numberOfSteps groups of size TimeFreqSupport::numberOfSubStepsByStepIndex.

Returns
FieldsContainer for given step and substep index and phase.
Parameters
[in]iStepGrouping index.
[in]iSubStepSubgrouping index.
[in]dPhasePhase angle measured in degrees.
[out]errorStatus of call.

◆ EvaluateWithPhaseAtGivenTime()

FieldsContainer ansys::dpf::Result::EvaluateWithPhaseAtGivenTime ( double  dTime,
double  dPhase,
DpfError error 
)
inline

Get the sweeping phase at a given time and phase.

Returns
FieldsContainer for given time and phase.
Parameters
[in]dTimeTime for which to get fields.
[in]dPhasePhase angle measured in degrees.
[out]errorStatus of call.

◆ EvaluateWithPhaseAtGivenTimeIndex()

FieldsContainer ansys::dpf::Result::EvaluateWithPhaseAtGivenTimeIndex ( int  iSet,
double  dPhase,
DpfError error 
)
inline

Get the sweeping phase at given TimeFreqSupport index and phase

Returns
FieldsContainer for given TimeFreqSupport index and phase.
Parameters
[in]iSetIndex of TimeFreqSupport.
[in]dPhasePhase angle measured in degrees.
[out]errorStatus of call.