Solution to What and Define The Hamming Metric with example in mathematical foundations of computer science - Sikademy
Author Image

Archangel Macsika

What and Define The Hamming Metric with example in mathematical foundations of computer science

The Answer to the Question
is below this banner.

Can't find a solution anywhere?

NEED A FAST ANSWER TO ANY QUESTION OR ASSIGNMENT?

Get the Answers Now!

You will get a detailed answer to your question or assignment in the shortest time possible.

Here's the Solution to this Question

For the vectors a=(a_1,a_2,\ldots,a_n)\in\{0,1\}^n and b=(b_1,b_2,\ldots,b_n)\in\{0,1\}^n the Hamming Metric \rho_H is defined as

\rho_H(a,b)=\sum\limits_{i=1}^n|a_i-b_i|.


For example, for a=(1,0,1,1)\in\{0,1\}^4 and b=(0,0,1,0)\in\{0,1\}^4 the Hamming Metric \rho_H(a,b) is equal to


\rho_H(a,b)=|1-0|+|0-0|+|1-1|+|1-0|=1+0+0+1=2.


Related Answers

Was this answer helpful?

Join our Community to stay in the know

Get updates for similar and other helpful Answers

Question ID: mtid-5-stid-8-sqid-450-qpid-337