docs: public static float[] doubleArrayToFloatArray(double[] a) {
      float[] result = new float[a.length];
      for (int i = 0; i < a.length; i++) {
        result[i] = (float) a[i];
      }
      return result;
    }