Problem interpretation - Distance Formula?

138 Views Asked by At

If you've got multiple arrays like this:

(24,36,28,28,16,27)

(38,38,45,57,35,50)

every array being 6 integers, each integer in range [0,60]

I would like to find the distance between those 2 arrays. The problem is related to computer science, however, I would like to interpret these arrays as "planes" so as to find the distance between the two.

What's the best way to find the distance between those 2 arrays? Can we interpret them as 6 points on a plane? Or maybe 3 coordinates?

1

There are 1 best solutions below

5
On BEST ANSWER

You can interpret them any way you want, each array as three points in a plane (but using which order), two points in space, one point in six-dimensional space. There are various distances available. If you define the points as $a=(a_1,a_2,a_3,a_4,a_5,a_6)$ and similarly for $b$ you can use $\sum |a_i-b_i|$ or $\sum (a_i-b_i)^2$, for example. Note I didn't use the dimension at all.