Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6103657
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T13:45:13+00:00 2026-05-23T13:45:13+00:00

I just read this interesting question about a random number generator that never generates

  • 0

I just read this interesting question about a random number generator that never generates the same value three consecutive times. This clearly makes the random number generator different from a standard uniform random number generator, but I’m not sure how to quantitatively describe how this generator differs from a generator that didn’t have this property.

Suppose that you handed me two random number generators, R and S, where R is a true random number generator and S is a true random number generator that has been modified to never produce the same value three consecutive times. If you didn’t tell me which one was R or S, the only way I can think of to detect this would be to run the generators until one of them produced the same value three consecutive times.

My question is – is there a better algorithm for telling the two generators apart? Does the restriction of not producing the same number three times somehow affect the observable behavior of the generator in a way other than preventing three of the same value from coming up in a row?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T13:45:14+00:00Added an answer on May 23, 2026 at 1:45 pm

    As a consequence of Rice’s Theorem, there is no way to tell which is which.

    Proof: Let L be the output of the normal RNG. Let L’ be L, but with all sequences of length >= 3 removed. Some TMs recognize L’, but some do not. Therefore, by Rice’s theorem, determining if a TM accepts L’ is not decidable.

    As others have noted, you may be able to make an assertion like “It has run for N steps without repeating three times”, but you can never make the leap to “it will never repeat a digit three times.” More appropriately, there exists at least one machine for which you can’t determine whether or not it meets this criterion.

    Caveat: if you had a truly random generator (e.g. nuclear decay), it is possible that Rice’s theorem would not apply. My intuition is that the theorem still holds for these machines, but I’ve never heard it discussed.

    EDIT: a secondary proof. Suppose P(X) determines with high probability whether or not X accepts L'. We can construct an (infinite number of) programs F like:

    F(x): if x(F), then don't accept L'
          else, accept L'
    

    P cannot determine the behavior of F(P). Moreover, say P correctly predicts the behavior of G. We can construct:

    F'(x): if x(F'), then don't accept L'
           else, run G(x)
    

    So for every good case, there must exist at least one bad case.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I just read this post about why new-line warnings exist, but to be honest
Just finished read this post by Greg Young, where he is talking about Microsoft
I just started to read about this new technology... Does someone have some knowledge
Just read this interesting article by Omar on his blog Linq to SQL solve
I've just read here ( http://ruby.runpaint.org/programs#lexical ) that comments are tokens. I've never thought
On this post , I read about the usage of XMPP. Is this sort
Firstly, I realise that this is a very similar question to this one: Which
I just read http://aspalliance.com/2062_The_Darkness_Behind_DateTimeNow and started to wonder if this is really something to
I just read up on a performance of LINQ, and there is a HUGE
I just read the Wikipedia article on mock objects , but I'm still not

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.