426
you are viewing a single comment's thread
view the rest of the comments
[-] marzhall@lemmy.world 4 points 1 day ago

If you explore compression using pi - i.e., giving an index and a length of pi as your compression method - what you'll end up finding is that the length of the data you want to compress is about the same as the length of the index in pi your data is at.

So if you wanted to "compress" five digits by just linking to its index in pi, you would most likely need a five-digit index into pi to find the spot where pi has that number. So, you save nothing on average.

There's a good blog post that goes into this, but I'm having trouble finding it. The rough explanation I can remember is: if you have every permutation of a given length n in a row with an even distribution, then a random string you choose is likely to be in the middle of that length. Using our numbers 0-9 as our base, that puts you at index 10^n/2. Given our example of 5 digits, that's 100000/2 - 50000, itself a 5 digit number, saving us no space.

In the mean time, you can use pifs to "store" your data using similar ideas.

[-] Clent@lemmy.dbzer0.com 1 points 1 day ago

Didn't say anything about compression.

Indexing and compression are not the same concept.

If there was an index for all 5 digit sequences and their locations, it wood reduce the search space for finding a 6 digit number.

This is about look up speed not saving space. Indexes always increase storage requirements. Always.

The question being asked here is does pi contain my phone number? Not does pi contain my phone number with an index location whose numeric value is shorter than my phone number?

[-] marzhall@lemmy.world 2 points 1 day ago* (last edited 1 day ago)

Does pi contain my phone number?

We can't yet answer this because we don't actually know whether or not Pi contains all permutations of all numbers. It's conjectured that it does, however.

Didn't say anything about compression.

You didn't, but "compression" using pi actually asks the same question you do, iiuc, of " How far do I have to search in order to find a thing of a given length?" And the answer is - if pi truly does contain all permutations of all numbers - probably 10^length /2 - for phone numbers, 10^10 /2, or half the length of all of the permutations of 10-digit phone numbers next to each other.

Which, coincidentally, and the reason I was aware of this, is why indexing into pi doesn't save you space on average if you're being a nerd and trying to use it for compression.

[-] Clent@lemmy.dbzer0.com 2 points 1 day ago

Someone has calculated the first 100 Trillion digits of pi, so if I understand the equation you're suggesting they means it is possible to know if pi contains all permutations of all phone numbers.

To keep the nerd going, I believe you're over counting because not all 10 digits numbers are a valid phone number but I doubt that matters but it does reduce total number of numbers to find.

And if we want to include international numbers the longest possible phone number is 15 digits which falls just outside the range of calculated digits 100 trillion (10e14)

[-] marzhall@lemmy.world 2 points 1 day ago

Someone has calculated the first 100 Trillion digits of pi, so if I understand the equation you're suggesting they means it is possible to know if pi contains all permutations of all phone numbers.

Yep, it definitely means we're above the average chance we could find a given 10-digit number in what's been looked at so far, if we're up to 14 digits! But here's the trouble: that calculation gives the "average" chance.

In the same way you could see the number "1" more than once in pi, you could see "11" more than once in pi, and so on for all sizes of patterns, as long as they're part of a larger not-yet-seen pattern (and as long as mathematicians' as-of-yet unproven guesses about pi are accurate). So if you're unlucky, even if pi does turn out to contain all numbers, we still may not have hit exactly your number yet, because larger patterns have been ahead of it that include things that aren't your number. But the odds are in your favor as far as I know.

this post was submitted on 10 Apr 2025
426 points (98.0% liked)

Science Memes

14150 readers
1896 users here now

Welcome to c/science_memes @ Mander.xyz!

A place for majestic STEMLORD peacocking, as well as memes about the realities of working in a lab.



Rules

  1. Don't throw mud. Behave like an intellectual and remember the human.
  2. Keep it rooted (on topic).
  3. No spam.
  4. Infographics welcome, get schooled.

This is a science community. We use the Dawkins definition of meme.



Research Committee

Other Mander Communities

Science and Research

Biology and Life Sciences

Physical Sciences

Humanities and Social Sciences

Practical and Applied Sciences

Memes

Miscellaneous

founded 2 years ago
MODERATORS