Jump to content

Recommended Posts

Is it possible to, using PHP, take an array of 3 or 4 digit numbers, and find some sort of real pattern in the numbers? I've been working on trying to get something semi reliable in finding a pattern in random 3 or 4 digit numbers, but can't seem to really get anything that seems remotely like any pattern. Any help would be appreciated.

Link to comment
https://forums.phpfreaks.com/topic/80529-random-number-pattern/
Share on other sites

a pattern can really forced on to any set of integers so you can't say that exactly

you could look at common series of numbers and then see if it matches one of those, but lets say I have

{1,25,100,289}

 

the pattern there is

n^2 for a1

((n*n)+(An-1))^2 for a >1

 

 

See the problem?

Link to comment
https://forums.phpfreaks.com/topic/80529-random-number-pattern/#findComment-408313
Share on other sites

I've been working on trying to get something semi reliable in finding a pattern in random 3 or 4 digit numbers

 

Surely, by definition, random numbers have no pattern? Im not sure what you're asking us to help you do. Perhaps if you provide some examples we might be able to help a bit more.

Link to comment
https://forums.phpfreaks.com/topic/80529-random-number-pattern/#findComment-408343
Share on other sites

You could also say that all random numbers have a pattern, if you allow arbitrarily complex patterns.  For example, the pattern for 364,255,927,584 could be "364,255,927,584".  So what counts as a pattern needs to be defined.

 

For example, you may be looking for patterns where the numbers increase according to some simple rule (as in cooldude's example).

Link to comment
https://forums.phpfreaks.com/topic/80529-random-number-pattern/#findComment-408403
Share on other sites

By definition they wouldn't but computer generated random numbers sure do.

 

I've been working on trying to get something semi reliable in finding a pattern in random 3 or 4 digit numbers

 

Surely, by definition, random numbers have no pattern? Im not sure what you're asking us to help you do. Perhaps if you provide some examples we might be able to help a bit more.

Link to comment
https://forums.phpfreaks.com/topic/80529-random-number-pattern/#findComment-408491
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.