diff --git a/src/gausskernel/dbmind/db4ai/executor/distance_functions.cpp b/src/gausskernel/dbmind/db4ai/executor/distance_functions.cpp index af759c590..bac87b97b 100644 --- a/src/gausskernel/dbmind/db4ai/executor/distance_functions.cpp +++ b/src/gausskernel/dbmind/db4ai/executor/distance_functions.cpp @@ -37,6 +37,13 @@ IDENTIFICATION #endif +/*Euclidean distance: the distance between two points, +that is, the distance we usually calculate. +Manhattan distance: the sum of absolute +wheelbase of two points in the standard coordinate system. +Chebyshev distance: the maximum value of the +numerical difference of each coordinate.*/ + /* * L1 distance (Manhattan) * We sum using cascaded summation @@ -44,6 +51,10 @@ IDENTIFICATION * are not available or for the the case that the dimension is not a multiple * of the width of the registers */ + +/*Vectorization refers to using an array instead of a scalar +to manipulate each element in the array.*/ + static force_inline double l1_non_vectorized(double const * p, double const * q, uint32_t const dimension) { double term = 0.;