docs: public void addRotation(int axis1, int axis2, double angle) {
      // TODO: throw an exception instead of using assert
      assert (axis1 >= 0);
      assert (axis1 < dim);
      assert (axis1 >= 0);
      assert (axis2 < dim);
      assert (axis1 != axis2);
  
      // reset inverse transformation - needs recomputation.
      inv = null;
  
      double[][] ht = new double[dim + 1][dim + 1];
      // identity matrix
      for(int i = 0; i < dim + 1; i++) {
        ht[i][i] = 1.0;
      }
      // insert rotation values
      final DoubleWrapper tmp = new DoubleWrapper(); // To return cosine
      double s = FastMath.sinAndCos(angle, tmp), c = tmp.value;
      ht[axis1][axis1] = +c;
      ht[axis1][axis2] = -s;
      ht[axis2][axis1] = +s;
      ht[axis2][axis2] = +c;
      // Multiply from left
      trans = times(ht, trans);
    }