Professional Documents
Culture Documents
Test 1
Test 1
1. Calculate the Euclidean distance between vectors (0,0), (1,0), (0,2) pairs (pairs means
D1 = Distance from (0,0) to(1,0); D2 = Distance from (0,0) to (0,2) ; D3 = Distance from
(1,0) to (0,2) )
D= 1.0000 2.0000 2.2361
2. Calculate the Manhattan distance between vectors (0,0), (1,0), (0,2) pairs
D= 1 2 3
3. Calculate the Chebyshev distance between vectors (0,0), (1,0), (0,2) pairs
D= 1 2 2
4. Calculate the Minkowski distance between vectors (0,0), (1,0), (0,2) pairs
D= 1.0000 2.0000 2.2361
6.Calculate the cosine of the angle between (1,0), (1,1.732), (- 1,0) pairs
D= 0.5000 -1.0000 -0.5000
7. Calculate the the Hamming distance between vectors (0,0), (1,0), (0,2) paris
D = 0.5000 0.5000 1.0000