[−][src]Function acap::taxi::taxicab_distance
pub fn taxicab_distance<T, U>(x: T, y: U) -> T::Value where
T: Coordinates,
U: Coordinates<Value = T::Value>,
Compute the taxicab distance between two points.
\begin{aligned}
\mathrm{taxicab\_distance}(x, y) &= \|x - y\|_1 \\
&= \sum_i |x_i - y_i|
\end{aligned}