Class MetricFactory


  • public class MetricFactory
    extends java.lang.Object
    Metric constructor functions.

    The constructor functions are parameterized by a type of vector. Valid
    vector types include:

    - Q
    - Vector2D<double>
    - Vector3D<double>
    - std::vector<double>
    - Eigen::VectorXd
    • Constructor Detail

      • MetricFactory

        public MetricFactory​(long cPtr,
                             boolean cMemoryOwn)
    • Method Detail

      • delete

        public void delete()
      • makeEuclideanQ

        public static MetricQPtr makeEuclideanQ()
        Euclidean configuration metric.

        See class EuclideanMetric for details.
      • makeWeightedEuclideanQ

        public static MetricQPtr makeWeightedEuclideanQ​(Q weights)
        Weighted Euclidean configuration metric.

        See class WeightedEuclideanMetric for details.

        Parameters:
        weights - [in] Weights for the metric.
        Returns:
        Weighted Euclidean metric.
      • makeInfinityQ

        public static MetricQPtr makeInfinityQ()
        Infinity configuration metric.

        See class InfinityMetric for details.
      • makeWeightedInfinityQ

        public static MetricQPtr makeWeightedInfinityQ​(Q weights)
        Weighted infinity configuration metric.

        See class WeightedInfinity for details.

        Parameters:
        weights - [in] Weights for the metric.
        Returns:
        Weighted infinity metric.
      • makeManhattanQ

        public static MetricQPtr makeManhattanQ()
        Manhattan configuration metric.

        See class ManhattanMetric for details.
      • makeWeightedManhattanQ

        public static MetricQPtr makeWeightedManhattanQ​(Q weights)
        WeightedManhattan configuration metric.

        See class WeightedManhattanMetric for details.
      • makeTransform3DMetric

        public static MetricTransform3DPtr makeTransform3DMetric​(double linWeight,
                                                                 double angWeight)
        Metric computing distance between two transformations

        The metric is defined as a weighted sum of the positional distance and the
        angle of the rw::math::EAA of the rotation.

        Parameters:
        linWeight - [in] Positional weight.
        angWeight - [in] Angular weight.
      • makeRotation3DMetric

        public static MetricRotation3DPtr makeRotation3DMetric()
        Metric computing distance between two rotations.

        The metric is defined as the angle of the rw::math::EAA
        of the rotation.