@Override
  public void terminate(PointCollector collector) throws Exception {
    List<Double> correlationArrayList =
        CrossCorrelation.calculateCrossCorrelation(valueArrayList, valueArrayList);
    for (int i = 0; i < correlationArrayList.size(); i++) {
      collector.putDouble(i, correlationArrayList.get(i));
    }
  }
This function calculates auto-correlation factor of a single input series.
library-udf/src/main/java/org/apache/iotdb/library/dprofile/UDTFACF.java