Welcome Guest
Log In | Register )
You last visited January 18, 2017, 3:03 pm
All times shown are
Eastern Time (GMT-5:00)

can someone here post me an example of a fake RNG lottery drawing?

Topic closed. 37 replies. Last post 9 years ago by time*treat.

Page 2 of 3
3.84
PrintE-mailLink
lottobrain's avatar - box
Smyrna, DE
United States
Member #10074
January 1, 2005
125 Posts
Offline
Posted: July 25, 2007, 9:53 pm - IP Logged

Actually, this is quite a good question.  You will be sickened by this, but you need to see it.

Here is yesterday's Minnesota drawing:

http://www.mnlottery.com/drawshow/tue256wm.html

(It takes a minute to get started, just be patient.)

Welcome to the world of computerized drawings, where a cartoon gives you the winning numbers.

Todd, Delaware has a similar sick animated drawing with floating balls in the machines.  I have visited the drawings on several occasions. My last trip there about 3 months ago, I suggested to them that the "actual drawing" was the auditor selecting the numbers by pushing the button on the RNG computer and that was what should be made into a video for anyone to log onto their site and view.  Also that there should be some kind of oraganized method in doing the RNG drawing, and not a variety of button punching techniques by several different auditors. The lottery official said that my thoughts would be considered, but that in order for them to video tape the persons doing the drawings , they would have to have them sign releases to do so....blah, blah. DE long ago quit showing the animated drawing on TV, saying that no one watched.

    Guru101's avatar - rw6jhh
    Indiana
    United States
    Member #48725
    January 7, 2007
    1958 Posts
    Offline
    Posted: July 25, 2007, 10:21 pm - IP Logged

    This is a very basic Pick 5/36 C++ program:

    // BOF

    #include <iostream>
    #include <iomanip>
    #include <fstream>
    #include <ctime>

    using namespace std;

    int Num1 = 0;
    int Num2 = 0;
    int Num3 = 0;
    int Num4 = 0;
    int Num5 = 0;

    void PickNumbers();
    void SortNumbers();

    int main()
    {
     ofstream outFile("QuickPicks.txt", ios::app);
     if(outFile.fail())
     {
      cerr << "outFile error" << endl;
      exit(1);
     }
     int count = 0;
     srand(time(0));
     for(;;)
     {
      cout << "How many Quick Picks would you like to print(0 to exit)? ";
      cin >> count;
      cout << endl;
      if(count != 0)
      {
       for(int i = 1; i <= count; i++)
       {
        PickNumbers();

        cout << setw(2) << Num1 << " "
          << setw(2) << Num2 << " "
          << setw(2) << Num3 << " "
          << setw(2) << Num4 << " "
          << setw(2) << Num5 << endl;

        outFile << setw(2) << Num1 << " "
            << setw(2) << Num2 << " "
            << setw(2) << Num3 << " "
            << setw(2) << Num4 << " "
            << setw(2) << Num5 << endl;
       }
      }
      else
      {
       break;
      }
      cout << endl;
     }
     outFile.close();
     return 0;
    }

    void PickNumbers()
    {
     do
     {
      Num1 = rand() % (36 - 1 + 1) + 1;
      Num2 = rand() % (36 - 1 + 1) + 1;
      Num3 = rand() % (36 - 1 + 1) + 1;
      Num4 = rand() % (36 - 1 + 1) + 1;
      Num5 = rand() % (36 - 1 + 1) + 1;
     }while(Num1 == Num2 || Num1 == Num3 || Num1 == Num4 || Num1 == Num5 ||
        Num2 == Num3 || Num2 == Num4 || Num2 == Num5 ||
        Num3 == Num4 || Num3 == Num5 ||
        Num4 == Num5);

     SortNumbers();
    }

    void SortNumbers()
    {
     do
     {
      if(Num1 > Num2) swap(Num1, Num2);
      if(Num2 > Num3) swap(Num2, Num3);
      if(Num3 > Num4) swap(Num3, Num4);
      if(Num4 > Num5) swap(Num4, Num5);
     }while(Num1 > Num2 || Num2 > Num3 || Num3 > Num4 || Num4 > Num5);
    }

    // EOF

     

    At the beginning of the program, the random number generator is initialized by the srand() function using the argument(the seed) passed to the function. In this case, time(0) is the seed. Now what exactly is time(0)? time(0) returns the number of seconds accumulated since 00:00 January 1, 1970. Why that particular date and time? I have no idea. Now lets pretend that the lottery's software automatically chooses the official winning numbers at EXACTLY 9:00pm(with no pretests) and just for example purposes, they also use time(0) as the only seed just like the code above! Theoretically, would it be possible to determine the numbers that will come out the winners? Yes. Now lets look at what realistically(or at least we hope) happens during an RNG drawing:

    1. The program more than likely isn't programmed to choose the winning numbers at EXACTLY(which includes seconds) the official draw time. The program more than likely requires the draw person to click a "Choose numbers" button of some sort. Not only that, but the we have no idea when the RNG is reintialized with a new seed. It could be just when the program starts up, which we have no idea will happen. We don't know if these people are starting the program 5, 10, or 15 or whatever minutes before the drawing takes place. It could also be intialized after an entire set has been chosen, or after a single number has been chosen.

    2. We also don't know what other things the lottery uses as a way to initialize its RNG. Which I'll discuss now.

    There are indeed ways to make an RNG "more" random. How? By using factors that are constantly changing. For example, the number of bytes of physical memory that are in use by the computer are constantly changing. You could write a function that returns the number of bytes that are in use by the computer at the time the function is called. So instead of initializing the RNG simply as:

    srand(time(0));

    Suppose I wrote a function that returns the current amount of bytes in use by the system, I could intialize it with one of these:

    srand(time(0) * GetPhysicalMemoryUsageInBytes());

    srand(time(0) / GetPhysicalMemoryUsageInBytes());

    srand(time(0) % GetPhysicalMemoryUsageInBytes());

    You could also make it "more" random by using a pseudo-random number as a factor for reseeding the RNG. For example:

    srand(time(0) * rand());

    Take it another step further, and you could combine both the examples and use something like:

    srand(time(0) * rand() * GetPhysicalMemoryUsageInBytes());

    So a way I could make the number choosing process of the program above more random, I could replace the PickNumbers() function with something like this:

    void PickNumbers()
    {
     do
     {
      srand(time(0) * rand() * GetPhysicalMemoryUsageInBytes());
      Num1 = rand() % (36 - 1 + 1) + 1;
      Num2 = rand() % (36 - 1 + 1) + 1;
      Num3 = rand() % (36 - 1 + 1) + 1;
      Num4 = rand() % (36 - 1 + 1) + 1;
      Num5 = rand() % (36 - 1 + 1) + 1;
     }while(Num1 == Num2 || Num1 == Num3 || Num1 == Num4 || Num1 == Num5 ||
        Num2 == Num3 || Num2 == Num4 || Num2 == Num5 ||
        Num3 == Num4 || Num3 == Num5 ||
        Num4 == Num5);

     SortNumbers();
    }

    Now, the RNG would be reseeded after each SET of numbers, using 3 factors that are constantly changing. Pretty random right? Could I be more obsessive and make it even more random? Sure, instead of reseeding the RNG after each SET is picked, I could reseed it after each NUMBER is picked. So I could change the function to:

    void PickNumbers()
    {
     do
     {
      srand(time(0) * rand() * GetPhysicalMemoryUsageInBytes());
      Num1 = rand() % (36 - 1 + 1) + 1;
      srand(time(0) * rand() * GetPhysicalMemoryUsageInBytes());
      Num2 = rand() % (36 - 1 + 1) + 1;
      srand(time(0) * rand() * GetPhysicalMemoryUsageInBytes());
      Num3 = rand() % (36 - 1 + 1) + 1;
      srand(time(0) * rand() * GetPhysicalMemoryUsageInBytes());
      Num4 = rand() % (36 - 1 + 1) + 1;
      srand(time(0) * rand() * GetPhysicalMemoryUsageInBytes());
      Num5 = rand() % (36 - 1 + 1) + 1;
     }while(Num1 == Num2 || Num1 == Num3 || Num1 == Num4 || Num1 == Num5 ||
        Num2 == Num3 || Num2 == Num4 || Num2 == Num5 ||
        Num3 == Num4 || Num3 == Num5 ||
        Num4 == Num5);

     SortNumbers();
    }

    That function alone is EXTREMELY random at choosing numbers. Plus, I could even add more things that constantly change as factors. Like the number of total handles, the amount of I/O reads or I/O writes. So many things that are constantly changing on the computer.

     

    This is why I have no problem playing an RNG lottery as far as randomness itself is concerned, ASSUMING all the code within the lottery program is legitimate. HOWEVER, I also don't know if all the code is legitimate, and THAT is why I'm against RNG lotteries. The operation of choosing the numbers are viewable by the player. There are no underlying operations taking place.

    Gonna win.Big Smile

      LOTTOMIKE's avatar - cash money.jpg
      Tennessee
      United States
      Member #7853
      October 15, 2004
      11338 Posts
      Offline
      Posted: July 25, 2007, 10:22 pm - IP Logged

      just watched that minnesota drawing,thanks for the link.i can't believe the public would be gullible enough to fall for that.

        Avatar
        Columbia City, Indiana
        United States
        Member #2978
        December 9, 2003
        381 Posts
        Offline
        Posted: July 26, 2007, 12:24 am - IP Logged

        Could you elaborate on this? How can they threaten you for someone else's activity?

           Sure, treat; I'd be happy to elaborate.

           I think it was in 2004 when LosingJeff and I went to Indianapolis to give our evidence file to the FBI. The meeting got off to a bad start when they refused to let us see an agent, and told us to go home and contact our attorney general. We told them we weren't leaving until we spoke with an agent. They threatened us with arrest if we didn't leave immediately. Then, they had us escorted to the lobby, where we were warned not to come back. I'm the type of person who believes the people who work for him should treat him with common courtesy and respect. If you're this type of person, don't ever call the FBI, because they are the laziest, rudest, most abusive group of people I've ever been exposed to. Naturally, I filed a complaint with the FBI Director in Quantico, and I am eagerly awaiting his response. 

          The entire incident is documented here on the forum somewhere, but I can't recall where it's posted (I was pretty upset about it, so there are several posts about this in different threads).

          If there's one thing we've learned from our investigation, it's that law enforcement and government officials can do anything they please, and we'll have precious little to say about it, if we know what's good for us.

        Come, Pinky; we must prepare for tomorrow night...

        Jim

          KyMystikal's avatar - 1457224010054
          Florence, Alabama
          United States
          Member #8658
          November 13, 2004
          1993 Posts
          Online
          Posted: July 26, 2007, 5:19 am - IP Logged

          Actually, this is quite a good question.  You will be sickened by this, but you need to see it.

          Here is yesterday's Minnesota drawing:

          http://www.mnlottery.com/drawshow/tue256wm.html

          (It takes a minute to get started, just be patient.)

          Welcome to the world of computerized drawings, where a cartoon gives you the winning numbers.

          If they're gonna go through the trouble of trying to make it look like balls being drawn, why not use the real thing???

          I love doubles and remember, it's just a game!!!!!!

            Todd's avatar - Cylon 2.gif
            Chief Bottle Washer
            New Jersey
            United States
            Member #1
            May 31, 2000
            23349 Posts
            Offline
            Posted: July 26, 2007, 7:14 am - IP Logged

            I've changed your program a little.  Let's see if you catch the change. 

            // BOF

            #include <iostream>
            #include <iomanip>
            #include <fstream>
            #include <ctime>

            using namespace std;

            int Num1 = 0;
            int Num2 = 0;
            int Num3 = 0;
            int Num4 = 0;
            int Num5 = 0;

            void PickNumbers();
            void SortNumbers();

            int main()
            {
             ofstream outFile("QuickPicks.txt", ios::app);
             if(outFile.fail())
             {
              cerr << "outFile error" << endl;
              exit(1);
             }
             int count = 0;
             srand(time(0));
             for(;;)
             {
              cout << "How many Quick Picks would you like to print(0 to exit)? ";
              cin >> count;
              cout << endl;
              if(count != 0)
              {
               for(int i = 1; i <= count; i++)
               {
                PickNumbers();

                cout << setw(2) << Num1 << " "
                  << setw(2) << Num2 << " "
                  << setw(2) << Num3 << " "
                  << setw(2) << Num4 << " "
                  << setw(2) << Num5 << endl;

                outFile << setw(2) << Num1 << " "
                    << setw(2) << Num2 << " "
                    << setw(2) << Num3 << " "
                    << setw(2) << Num4 << " "
                    << setw(2) << Num5 << endl;
               }
              }
              else
              {
               break;
              }
              cout << endl;
             }
             outFile.close();
             return 0;
            }

            void PickNumbers()
            {
             do
             {
              Num1 = 5; // rand() % (36 - 1 + 1) + 1;
              Num2 = 15; // rand() % (36 - 1 + 1) + 1;
              Num3 = 20; // rand() % (36 - 1 + 1) + 1;
              Num4 = 22; // rand() % (36 - 1 + 1) + 1;
              Num5 = 33; // rand() % (36 - 1 + 1) + 1;
             }while(Num1 == Num2 || Num1 == Num3 || Num1 == Num4 || Num1 == Num5 ||
                Num2 == Num3 || Num2 == Num4 || Num2 == Num5 ||
                Num3 == Num4 || Num3 == Num5 ||
                Num4 == Num5);

             SortNumbers();
            }

            void SortNumbers()
            {
             do
             {
              if(Num1 > Num2) swap(Num1, Num2);
              if(Num2 > Num3) swap(Num2, Num3);
              if(Num3 > Num4) swap(Num3, Num4);
              if(Num4 > Num5) swap(Num4, Num5);
             }while(Num1 > Num2 || Num2 > Num3 || Num3 > Num4 || Num4 > Num5);
            }

            // EOF

             

            Now, I'm sure you went through and easily saw how my ticket of 5-15-20-22-33 is going to win.  But did all the people watching the cartoon with the fake drawing know that?  How could they possibly?  And if I write my code in a more sophisticated manner, to avoid any checksum traps, and to self-delete after the drawing, how would anyone know I did it?

            It's not about "how random is the RNG".  That has NO BEARING on how BAD computerized drawings are. 

            Leave RNGs to the Quick Pick machines, and do drawings using real, physical drawing equipment that any human can witness.

             

            Check the State Lottery Report Card
            What grade did your lottery earn?

             

            Sign the Petition for True Lottery Drawings
            Help eliminate computerized drawings!

              time*treat's avatar - radar

              United States
              Member #13130
              March 30, 2005
              2171 Posts
              Offline
              Posted: July 26, 2007, 7:37 am - IP Logged

              I think people would understand this issue better if it were phrased in things more familiar, like:

              • voting machines with no paper trail (message: trust us. We'll count the votes for you)
              • those stupid commercials where the person paying *gasp* cash is made to feel bad because the "cashier" doesn't know how to have time to make proper change (message: trust this impatient idiot with your debit card)
              • numerous people who have had their credit ruined because someone bought/stole their identifiers, and "the computer says" they made all those purchases in 6 different states - that they have never lived in or traveled to.

               People need to understand that just because it's (queue angel Blue AngelBlue AngelBlue Angel chorus) "on the computer", that just makes tampering harder to prove ... although with better graphics.

              In neo-conned Amerika, bank robs you.
              Alcohol, Tobacco, and Firearms should be the name of a convenience store, not a govnoment agency.

                Amazing Grace's avatar - lion
                rainbow lake
                Canada
                Member #25177
                November 2, 2005
                10764 Posts
                Offline
                Posted: July 26, 2007, 8:43 am - IP Logged

                So far, it would seem the answer is no. Maybe that's because, at least in theory, RNG's are just as good as the ball machines.

                The only mishap I can remember was a few years ago (somewhere near Wisconsin or Minnesota, I think), when faulty hardware resulted in the same number being repeated for 3 days. I'm sure there have been a few other issues, but for the most part people are simply afraid of problems that exist in their own minds rather than reality.

                Sun, Dec 18, 2005KansasPick 35-0-9
                Sat, Dec 17, 2005KansasPick 35-0-9
                Fri, Dec 16, 2005KansasPick 35-0-9

                Secret to $uccess=Law of Attraction

                  Guru101's avatar - rw6jhh
                  Indiana
                  United States
                  Member #48725
                  January 7, 2007
                  1958 Posts
                  Offline
                  Posted: July 26, 2007, 3:57 pm - IP Logged

                  I've changed your program a little.  Let's see if you catch the change. 

                  // BOF

                  #include <iostream>
                  #include <iomanip>
                  #include <fstream>
                  #include <ctime>

                  using namespace std;

                  int Num1 = 0;
                  int Num2 = 0;
                  int Num3 = 0;
                  int Num4 = 0;
                  int Num5 = 0;

                  void PickNumbers();
                  void SortNumbers();

                  int main()
                  {
                   ofstream outFile("QuickPicks.txt", ios::app);
                   if(outFile.fail())
                   {
                    cerr << "outFile error" << endl;
                    exit(1);
                   }
                   int count = 0;
                   srand(time(0));
                   for(;;)
                   {
                    cout << "How many Quick Picks would you like to print(0 to exit)? ";
                    cin >> count;
                    cout << endl;
                    if(count != 0)
                    {
                     for(int i = 1; i <= count; i++)
                     {
                      PickNumbers();

                      cout << setw(2) << Num1 << " "
                        << setw(2) << Num2 << " "
                        << setw(2) << Num3 << " "
                        << setw(2) << Num4 << " "
                        << setw(2) << Num5 << endl;

                      outFile << setw(2) << Num1 << " "
                          << setw(2) << Num2 << " "
                          << setw(2) << Num3 << " "
                          << setw(2) << Num4 << " "
                          << setw(2) << Num5 << endl;
                     }
                    }
                    else
                    {
                     break;
                    }
                    cout << endl;
                   }
                   outFile.close();
                   return 0;
                  }

                  void PickNumbers()
                  {
                   do
                   {
                    Num1 = 5; // rand() % (36 - 1 + 1) + 1;
                    Num2 = 15; // rand() % (36 - 1 + 1) + 1;
                    Num3 = 20; // rand() % (36 - 1 + 1) + 1;
                    Num4 = 22; // rand() % (36 - 1 + 1) + 1;
                    Num5 = 33; // rand() % (36 - 1 + 1) + 1;
                   }while(Num1 == Num2 || Num1 == Num3 || Num1 == Num4 || Num1 == Num5 ||
                      Num2 == Num3 || Num2 == Num4 || Num2 == Num5 ||
                      Num3 == Num4 || Num3 == Num5 ||
                      Num4 == Num5);

                   SortNumbers();
                  }

                  void SortNumbers()
                  {
                   do
                   {
                    if(Num1 > Num2) swap(Num1, Num2);
                    if(Num2 > Num3) swap(Num2, Num3);
                    if(Num3 > Num4) swap(Num3, Num4);
                    if(Num4 > Num5) swap(Num4, Num5);
                   }while(Num1 > Num2 || Num2 > Num3 || Num3 > Num4 || Num4 > Num5);
                  }

                  // EOF

                   

                  Now, I'm sure you went through and easily saw how my ticket of 5-15-20-22-33 is going to win.  But did all the people watching the cartoon with the fake drawing know that?  How could they possibly?  And if I write my code in a more sophisticated manner, to avoid any checksum traps, and to self-delete after the drawing, how would anyone know I did it?

                  It's not about "how random is the RNG".  That has NO BEARING on how BAD computerized drawings are. 

                  Leave RNGs to the Quick Pick machines, and do drawings using real, physical drawing equipment that any human can witness.

                  I completely agree with you. The people playing these games don't know what's going on inside the lottery. The public should be able to see the true process in which the numbers are chosen.

                  Gonna win.Big Smile

                    Avatar
                    NY
                    United States
                    Member #23835
                    October 16, 2005
                    3502 Posts
                    Offline
                    Posted: July 26, 2007, 4:28 pm - IP Logged

                    I completely agree with you. The people playing these games don't know what's going on inside the lottery. The public should be able to see the true process in which the numbers are chosen.

                    You're 100% right that the "true process" should be open to inspection. When you confidently watch the balls mixing in the machine how do you know that they're really the same size and weight, and that nobody has tampered with something in an effort to skew the likely outcome? When somebody comes forard to claim a $50 million MM or PB jackpot how do oyu know the ticket wasn't printed after the drawing? Is it possible to write a program that superficially resembles an RNG but can return a result that is known with 100% certainty? Of course.  You can write a program to do whatever you want it to do, and the world is full of programmers who, intentionally or not, write programs that are convoluted and hard to follow. There are also plenty of programmers who can write good code. Can you write a program that will spit out numbers of your choosing with no chance of independent programmer finding out and blowing the whistle? Only in the land of conspiracy and incompetence. I don't doubt that there's a fair amount of incompetence out there,  but there's not nearly as much conspiracy as many of you are counting on.

                      Avatar
                      Coastal Georgia
                      United States
                      Member #2653
                      October 30, 2003
                      1866 Posts
                      Offline
                      Posted: July 26, 2007, 4:37 pm - IP Logged

                      Reminds me of the programmer that worked for the Nevada gaming commission. He wrote a program that would increase credits on a slot machine after a certain coin - in sequence was used.

                      Ironically, his job with the commission was to examine the RNG chips in slot machines to determine   "randomness" and repair them when they were out of whack...

                      He did this to cheat the system and in fact he got away with it ( for a while ) using an accomplice. Greed got the best of him and the casinos caught on.

                      Yes, Programs can be manipulated for desired results.

                       

                                                     

                                    

                       

                       

                        Guru101's avatar - rw6jhh
                        Indiana
                        United States
                        Member #48725
                        January 7, 2007
                        1958 Posts
                        Offline
                        Posted: July 26, 2007, 5:48 pm - IP Logged

                        You're 100% right that the "true process" should be open to inspection. When you confidently watch the balls mixing in the machine how do you know that they're really the same size and weight, and that nobody has tampered with something in an effort to skew the likely outcome? When somebody comes forard to claim a $50 million MM or PB jackpot how do oyu know the ticket wasn't printed after the drawing? Is it possible to write a program that superficially resembles an RNG but can return a result that is known with 100% certainty? Of course.  You can write a program to do whatever you want it to do, and the world is full of programmers who, intentionally or not, write programs that are convoluted and hard to follow. There are also plenty of programmers who can write good code. Can you write a program that will spit out numbers of your choosing with no chance of independent programmer finding out and blowing the whistle? Only in the land of conspiracy and incompetence. I don't doubt that there's a fair amount of incompetence out there,  but there's not nearly as much conspiracy as many of you are counting on.

                        It is possible to affect a program's process of randomly choosing numbers. You don't need to even modify the process itself. If someone is able to get a copy of the lottery program to learn how it works, they could write an external program running in the background to monitor running all processes, and when the lottery program comes up, their program could patch certain parts of the lottery program's memory to somehow affect the process in which numbers are chosen. That's just one example. However, I want you to keep in mind that if someone is going to take the risk of somehow modifying how the lottery program chooses its numbers, they're going to have to make a trade between how much certainty their numbers will come up and the risk of their method being detected. Todd's modification to the program I posted would be a good example. He has 100% certainty that his numbers are going to come up, however if this was a real lottery program that was drawing the official winning numbers, there would also be a 100% risk of that method being caught because as you can see, the function now picks those numbers no matter what. So instead of having 100% certainy and 100% risk, lets see if we can change the PickNumbers function so that although our certainty won't be as high, but neither will our risk:

                        void PickNumbers()
                        {
                           do
                           {
                               Num1 = rand() % (36 - 1 + 1) + 1;
                               Num2 = rand() % (36 - 1 + 1) + 1;
                               Num3 = rand() % (36 - 1 + 1) + 1;
                               Num4 = rand() % (36 - 1 + 1) + 1;
                               Num5 = rand() % (36 - 1 + 1) + 1;
                           }while(Num1 == Num2 || Num1 == Num3 || Num1 == Num4 || Num1 == Num5 ||
                                      Num2 == Num3 || Num2 == Num4 || Num2 == Num5 ||
                                      Num3 == Num4 || Num3 == Num5 ||
                                      Num4 == Num5 ||
                                      !(Num1 % 4 == 0 || Num2 % 4 == 0 || Num3 % 10 == 0 ||
                                        Num4 % 4 == 0 || Num5 % 4 == 0));

                           SortNumbers();
                        }

                        What would that do? That would make it so that at least 1 of the numbers chosen was divisible by 4(4, 8, 12, 16, 20, 24, 28, 32, or 36). Our certainty of which numbers will be chosen has gone down, but so has our risk of the method being detected(at least for a certain amount of time). Now, I want you to keep in mind that this is just an example. A real world situation would be very covert. A person needs to ask themself how much of a risk are they willing to take to do something this extreme.

                        Gonna win.Big Smile

                          Todd's avatar - Cylon 2.gif
                          Chief Bottle Washer
                          New Jersey
                          United States
                          Member #1
                          May 31, 2000
                          23349 Posts
                          Offline
                          Posted: July 27, 2007, 8:17 am - IP Logged

                          It is possible to affect a program's process of randomly choosing numbers. You don't need to even modify the process itself. If someone is able to get a copy of the lottery program to learn how it works, they could write an external program running in the background to monitor running all processes, and when the lottery program comes up, their program could patch certain parts of the lottery program's memory to somehow affect the process in which numbers are chosen. That's just one example. However, I want you to keep in mind that if someone is going to take the risk of somehow modifying how the lottery program chooses its numbers, they're going to have to make a trade between how much certainty their numbers will come up and the risk of their method being detected. Todd's modification to the program I posted would be a good example. He has 100% certainty that his numbers are going to come up, however if this was a real lottery program that was drawing the official winning numbers, there would also be a 100% risk of that method being caught because as you can see, the function now picks those numbers no matter what. So instead of having 100% certainy and 100% risk, lets see if we can change the PickNumbers function so that although our certainty won't be as high, but neither will our risk:

                          void PickNumbers()
                          {
                             do
                             {
                                 Num1 = rand() % (36 - 1 + 1) + 1;
                                 Num2 = rand() % (36 - 1 + 1) + 1;
                                 Num3 = rand() % (36 - 1 + 1) + 1;
                                 Num4 = rand() % (36 - 1 + 1) + 1;
                                 Num5 = rand() % (36 - 1 + 1) + 1;
                             }while(Num1 == Num2 || Num1 == Num3 || Num1 == Num4 || Num1 == Num5 ||
                                        Num2 == Num3 || Num2 == Num4 || Num2 == Num5 ||
                                        Num3 == Num4 || Num3 == Num5 ||
                                        Num4 == Num5 ||
                                        !(Num1 % 4 == 0 || Num2 % 4 == 0 || Num3 % 10 == 0 ||
                                          Num4 % 4 == 0 || Num5 % 4 == 0));

                             SortNumbers();
                          }

                          What would that do? That would make it so that at least 1 of the numbers chosen was divisible by 4(4, 8, 12, 16, 20, 24, 28, 32, or 36). Our certainty of which numbers will be chosen has gone down, but so has our risk of the method being detected(at least for a certain amount of time). Now, I want you to keep in mind that this is just an example. A real world situation would be very covert. A person needs to ask themself how much of a risk are they willing to take to do something this extreme.

                          I don't think you should use my code as an example of how somebody would rig the drawing.  It is merely a demonstration of how a blatant code change inside the computer is invisible to those who press the button to generate the fake results.  The silly cartoon can make the balls bounce around on the screen, but it has nothing to do with the actual randomness of the program.

                          Obviously, someone going through the trouble of rigging a drawing is going to be writing some clever code that would survive pretests and checksum tests, and then erase itself after the drawing (restoring the original program).  They would not be smart enough to rig the drawing, yet dumb enough to use the type of code I wrote as an example above.

                           

                          Check the State Lottery Report Card
                          What grade did your lottery earn?

                           

                          Sign the Petition for True Lottery Drawings
                          Help eliminate computerized drawings!

                            Guru101's avatar - rw6jhh
                            Indiana
                            United States
                            Member #48725
                            January 7, 2007
                            1958 Posts
                            Offline
                            Posted: July 27, 2007, 2:32 pm - IP Logged

                            I don't think you should use my code as an example of how somebody would rig the drawing.  It is merely a demonstration of how a blatant code change inside the computer is invisible to those who press the button to generate the fake results.  The silly cartoon can make the balls bounce around on the screen, but it has nothing to do with the actual randomness of the program.

                            Obviously, someone going through the trouble of rigging a drawing is going to be writing some clever code that would survive pretests and checksum tests, and then erase itself after the drawing (restoring the original program).  They would not be smart enough to rig the drawing, yet dumb enough to use the type of code I wrote as an example above.

                            I just wanted to point it out because some people seem to be making consiracy theories out of even the simplest method of trying to rig the lottery. Some people are thinking it's so easy to rig the lottery that just any lottery employee is allowed to walk into the room where the drawing computers are kept, access those computers themself, and leave the room without being detected at all. Although I'm not going to rule it out absolutely 100% because I don't work for the lottery and I don't know how the employees commute, the room where those computers are kept while they're not being used for the drawing, and whatnot while they're in the building, but to me, it would take a lot more than something non-covert to convince me that the lottery is rigged. I don't think the payouts would be a good argument because we don't know what the sales were. If someone thinks the lottery is rigged, they're going to have to prove it themself. The lottery isn't going to just come out of the blue and say "Folks, we rigged the game". If it's such a mission for people to prove that the lottery is rigged, why don't they arrange some sort of protest, or apply for a job at the lottery and when the right time comes, reveal what has been going on. I'm not saying it's not happening. There are indeed corrupt people in this world, but it takes a lot more than getting a losing ticket and shouting out "The lottery is rigged!" to convince people there's cheating going on. I'm not going to automatically think the lottery is rigged if all a person can do is yell "Cheat!" when they lose. That type of stuff doesn't float with me.

                            Gonna win.Big Smile

                              time*treat's avatar - radar

                              United States
                              Member #13130
                              March 30, 2005
                              2171 Posts
                              Offline
                              Posted: July 27, 2007, 7:15 pm - IP Logged

                              You're 100% right that the "true process" should be open to inspection. When you confidently watch the balls mixing in the machine how do you know that they're really the same size and weight, and that nobody has tampered with something in an effort to skew the likely outcome? When somebody comes forard to claim a $50 million MM or PB jackpot how do oyu know the ticket wasn't printed after the drawing? Is it possible to write a program that superficially resembles an RNG but can return a result that is known with 100% certainty? Of course.  You can write a program to do whatever you want it to do, and the world is full of programmers who, intentionally or not, write programs that are convoluted and hard to follow. There are also plenty of programmers who can write good code. Can you write a program that will spit out numbers of your choosing with no chance of independent programmer finding out and blowing the whistle? Only in the land of conspiracy and incompetence. I don't doubt that there's a fair amount of incompetence out there,  but there's not nearly as much conspiracy as many of you are counting on.

                              KY Floyd asked "When somebody comes forard to claim a $50 million MM or PB jackpot how do oyu know the ticket wasn't printed after the drawing?"

                              When a ticket is bought (I'll use PB as example), several numbers are printed on it (not just your 'bets'), plus a bar code. These numbers represent the store location, time purchased and original bet numbers & amount, etc. Also on the back of the ticket is another number (large red number string) that is the section of the roll of paper from which the ticket was printed. When the winning number is inputed back into the system, if there is a winner, all of that info is available to lottery HQ. They know where and when the winning ticket was sold, sometimes before the winner does. 

                              You would be hard pressed to fake it all beyond fooling your friends. 

                              In neo-conned Amerika, bank robs you.
                              Alcohol, Tobacco, and Firearms should be the name of a convenience store, not a govnoment agency.