# How is the inter and the intra distance of a PUF calculated?

I was wondering, if I want to calculate the intra distance of a PUF, and I have already measured $n$ times a response to a challenge. Do I choose one reference value and compare the hamming distance of it to all other values $n-1$ comparisons? Or do I compare each response to each other $(n \times(n-1))/2$ comparisons?

The same question for the inter distance. Furthermore would be interesting how great should be $n$ in both cases to get meaningful values? Can this somhow be statistically "proven" by some kind of tests?

I believe Roel Maes gives a very good answer to your question in his PhD thesis, pages 20-23.

In essence, ideally, you need to calculate an array of the Hamming Distance between every pair of responses to the same challenge. Those pairs correspond to either the same chip or different chips depending on if you are looking at intra- or inter- distance.

Both metrics and various statistics based on them are, in principle, characterising the performance of the whole PUF construction. For example, the maximum intra-distance would give an idea of the worst case ('least reliable') response that could be expected. As a result, $$n$$ should be equal to the maximum number of challenge-response pairs (CRPs) offered by the PUF.

Of course, reading out all the CRPs negates the purpose of the PUF in some scenarios. In practice, one would get hold of a number of instances of the same chip and run some characterisation experiments to get the metrics. After establishing a certain confidence in those metrics a different set of chip instances would be deployed in production.

The whole thesis (with a lot more details and formulas) is freely available at https://lirias.kuleuven.be/handle/123456789/353455