Mantid
Loading...
Searching...
No Matches
Functions
Mantid::Algorithms::PolarizationCorrectionsHelpers Namespace Reference

Functions

MANTID_ALGORITHMS_DLL API::MatrixWorkspace_sptr workspaceForSpinState (const API::WorkspaceGroup_sptr &group, const std::string &spinStateOrder, const std::string &targetSpinState)
 Returns the workspace in the group associated with the given targetSpinState according to the order defined by spinStateOrder.
 

Function Documentation

◆ workspaceForSpinState()

API::MatrixWorkspace_sptr Mantid::Algorithms::PolarizationCorrectionsHelpers::workspaceForSpinState ( const API::WorkspaceGroup_sptr group,
const std::string &  spinStateOrder,
const std::string &  targetSpinState 
)

Returns the workspace in the group associated with the given targetSpinState according to the order defined by spinStateOrder.

Parameters
groupWorkspace group containing spin states.
spinStateOrderThe order of the different spin states within the group.
targetSpinStateThe spin state workspace to extract from the group.
Returns
The MatrixWorkspace containing the target spin state. nullptr if not present.

Definition at line 30 of file PolarizationCorrectionsHelpers.cpp.

References group, Mantid::Kernel::SpinStateHelpers::indexOfWorkspaceForSpinState(), Mantid::Kernel::SpinStateHelpers::splitSpinStateString(), and workspaceForSpinState().

Referenced by Mantid::Algorithms::PolarizerEfficiency::calculatePolarizerEfficiency(), and workspaceForSpinState().