Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It seems like one could use the same technique to estimate the initial (lowest-observable) serial number...

From the article:

  If starting with an initial gap between 0 and the lowest
  sample (sample minimum), the average gap between samples is
  (m - k)/k; the -k being because the samples themselves are
  not counted in computing the gap between samples.
Perhaps someone with a better grasp on the math can confirm that this makes 'obfuscating size by starting with a higher serial number' an ineffective mechanism?


Yes. If you're only looking at the gaps between the numbers, adding a constant offset to the serial numbers would have no effect on the estimate.

On the other hand, if instead of ordering them sequentually I roll a die and add the number of spots to the previous serial number, I think I can trick you into thinking I have three times as many tanks as I actually do. In fact, I feel quite confident of it.


If I find sufficiently many of your tanks, the distribution of the differences in serial numbers would start showing that we aren't talking about a random sample from 1…n

For example, having seen 250 IDs in the 1…1000 range and 200 in the 1001…2000 range, the next ID in the 1…2000 range I see should fall in the 1…1000 range with probability 750/(750 + 800) ~= 0.48 in the 'normal' case, and around 36/(36 + 86) ~= 0.30 with your method of doling out IDs.

And I think it would be a factor of 3.5 (the expected number of eyes on a throw of a die). That's why I expect your method to dole out 286 out of every 1000 IDs.

But it would require me from checking for this, depend on finding such discrepancies in samples, and increase the variance on my estimates for a given sample size.


I don't have the math (or time (or ambition!)) to confirm or deny this, but I think that it's not really meant to stand up to serious scrutiny - just enough for someone to glance at an invoice or a URL or a receipt and being more impressed/less wary. (See fecak's reply to my comment.)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: