title: dot product of two quaternion rotations
body: <p>I understand that the dot (or inner) product of two quaternions is the angle between the rotations (including the axis-rotation).  This makes the dot product equal to the angle between two points on the quaternion hypersphere.<br>
  I can not, however, find how to actually compute the dot product.</p>
  
  <p>Any help would be appreciated!</p>
  
  <p>current code:</p>
  
  <pre><code>public static float dot(Quaternion left, Quaternion right){
      float angle;
  
      //compute
  
      return angle;
  }
  </code></pre>
  
  <p>Defined are Quaternion.w, Quaternion.x, Quaternion.y, and Quaternion.z.</p>
  
  <p>Note: It can be assumed that the quaternions are normalised.</p>