code: public static double orientationMetric(Quat4d q1, Quat4d q2) {
  		return Math.acos(Math.abs(dotProduct(q1, q2)));
  	}
docs: The orientation metric is obtained by comparing two unit quaternion
  orientations.
  <p>
  The two quaternions are compared using the formula: d(q1,q2) =
  arccos(|q1*q2|). The range of the metric is [0, Pi/2], where 0 means the
  same orientation and Pi/2 means the opposite orientation.
  <p>
  The formula is taken from: Huynh, D. Q. (2009). Metrics for 3D rotations:
  comparison and analysis. Journal of Mathematical Imaging and Vision,
  35(2), 155–164. http://doi.org/10.1007/s10851-009-0161-2
  
  @param q1
  quaternion as Quat4d object
  @param q2
  quaternion as Quat4d object
  @return the quaternion orientation metric