RobWorkProject
24.12.4-
|
The PathAnalyzer provides a set a basic tools for analyzing a path. More...
#include <PathAnalyzer.hpp>
Classes | |
struct | CartesianAnalysis |
Result struct for Cartesian analysis. More... | |
struct | ClearanceAnalysis |
Result struct for CleracenAnalysis. More... | |
struct | JointSpaceAnalysis |
Result struct for joint space analysis. More... | |
struct | TimeAnalysis |
Result struct for Time analysis. More... | |
Public Types | |
typedef rw::core::Ptr< PathAnalyzer > | Ptr |
smart pointer type to this class | |
typedef rw::core::Ptr< const PathAnalyzer > | CPtr |
smart pointer type to this const class | |
Public Member Functions | |
PathAnalyzer (const rw::core::Ptr< const rw::models::Device > &device, const rw::kinematics::State &state) | |
Construct PathAnalyzer for a specific device. More... | |
virtual | ~PathAnalyzer () |
Destructor. | |
JointSpaceAnalysis | analyzeJointSpace (const rw::trajectory::QPath &path, rw::math::QMetric::Ptr metric=NULL) const |
Performs joint space analysis of path. More... | |
CartesianAnalysis | analyzeCartesian (const rw::trajectory::QPath &path, const rw::core::Ptr< rw::kinematics::Frame > frame) |
Performs analysis in Cartesian space. More... | |
TimeAnalysis | analyzeTime (const rw::trajectory::QPath &path) const |
Peforms analysis of the time. More... | |
ClearanceAnalysis | analyzeClearance (const rw::trajectory::QPath &path, const rw::core::Ptr< const rw::proximity::DistanceCalculator > &distanceCalculator) |
Performs an analysis of the clearance. More... | |
Static Public Member Functions | |
template<class It > | |
static double | pathLength (It begin, It end, const rw::math::Metric< typename It::value_type > &metric) |
The length of the path from begin up to and excluding end. This method will in a new version be moved to a collection of tools for path statistic. More... | |
The PathAnalyzer provides a set a basic tools for analyzing a path.
Features in the PathAnalyzer include analysis of joint space, Cartesian space, estimation of execution time and measures for clearance. See more details in the result structs PathAnalyzer::JointSpaceAnalysis, PathAnalyzer::CartesianAnalysis, PathAnalyzer::TimeAnalysis and PathAnalyzer::ClearanceAnalysis.
PathAnalyzer | ( | const rw::core::Ptr< const rw::models::Device > & | device, |
const rw::kinematics::State & | state | ||
) |
Construct PathAnalyzer for a specific device.
device | [in] Device to be associated with the path |
state | [in] State of the workcell |
CartesianAnalysis analyzeCartesian | ( | const rw::trajectory::QPath & | path, |
const rw::core::Ptr< rw::kinematics::Frame > | frame | ||
) |
Performs analysis in Cartesian space.
The method calculates the Cartesian distance travelled by the speficied frame. It provides the total distance travelled, the coordinate wise distances, and upper and lower bounds on the location of the frame during the path.
path | [in] Path to analyze |
frame | [in] Frame for which to analyze the path. |
ClearanceAnalysis analyzeClearance | ( | const rw::trajectory::QPath & | path, |
const rw::core::Ptr< const rw::proximity::DistanceCalculator > & | distanceCalculator | ||
) |
Performs an analysis of the clearance.
Calculates the average and minimum clearance along a path. Only the nodes of the path are sampled. The path should therefore be divided with the desired resolution before invoking this method.
path | [in] Path to analyze |
distanceCalculator | [in] DistanceCalculator to be used in the analysis |
JointSpaceAnalysis analyzeJointSpace | ( | const rw::trajectory::QPath & | path, |
rw::math::QMetric::Ptr | metric = NULL |
||
) | const |
Performs joint space analysis of path.
path | [in] Path to analyze |
metric | [in] Metric to use for calculating the distance in joint space. |
TimeAnalysis analyzeTime | ( | const rw::trajectory::QPath & | path | ) | const |
Peforms analysis of the time.
Calculates the time needed to execute the path when considering the dynamics.
path | [in] Path to analyze. |
|
inlinestatic |
The length of the path from begin up to and excluding end. This method will in a new version be moved to a collection of tools for path statistic.
If the range [begin, end) is of length 0 or 1 then a length of 0 is returned.
Note that the element pointed to by end is not included in the path and need not exist.
The distance between adjacent element is measured by metric.