News for hackers. Stuff that matters.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by crazygringo on Wednesday December 02, 2020 @05:43PM (#25282755)
Does anyone have any idea how many daily "official" lotteries are drawn worldwide?

I'd guess something on the order of 1,000 maybe? (One per country, plus a bunch more for individual states within countries?)

I know they vary in numbers of positions and values, but I am kind of curious roughly how often you can expect a sequence of consecutive numbers (increasing or decreasing) to be chosen anywhere worldwide.

As an initial guess, if it's 5 balls drawn from 50, a thousand times a day, then it's something like a ~13% chance to happen somewhere yearly.

So since this is international news, and not the kind of thing that gets reported every year... it doesn't seem implausibly unlikely, no? (It's not like it's a once-in-a-millenia or once-in-earth's-lifetime kind of thing.)

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by mrb on Thursday December 03, 2020 @12:58AM (#25285891)
They draw 6 balls out of 50. There are C(50,6) = 15,890,700 possible draws (C(n,k) = binomial coefficient)

45 of the draws are made of 6 consecutive numbers (1-2-3-4-5-6, then 2-3-4-5-6-7, etc, until 45-46-47-48-49-50)

A single draw has a 45 out of 15,890,700 chances of being 6 consecutive numbers

A single draw has a probability of 1-(45/15,890,700) of NOT being 6 consecutive numbers

Assuming 1000 draws (lotteries) per day, in a year we expect probability (1-(45/15,890,700))^(1000*365) = 36% that none of the lotteries draw 6 consecutive numbers

So there is a 64% probability that at least one lottery will draw 6 consecutive numbers in a year. If there are 1000 draws per week (instead of per day) the probability is still 17% that this will happen in a year.

So this South African draw is kinda expected.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by BlackFingolfin on Thursday December 03, 2020 @03:46AM (#25286926)
According to a comment elsewhere in this HN discussion, it seems there are rather something like <200 draws a week. That gets us to just a 3% chance of this happening in a given year. That's still quite a bit more than one might intuit, but not quite as drastic.

Of course, as others here already pointed out that there are far more "suspicious" patterns (e.g. other arithmetic progressions like 5-10-15-20-25-30, primes, ...). And of course they often play by different rules, etc.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by T-hawk on Thursday December 03, 2020 @02:29PM (#25293408)
3% chance in a given year. And for how many years when it didn't happen have we been running this many lotteries? Probably right around 33.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by dheera on Thursday December 03, 2020 @01:02AM (#25285914)
Not to mention the reverse consecutive numbers, the same numbers, the +=2 numbers, the -=2 numbers, the prime numbers, and all the other sequences that people would find "suspicious" because "omgfwow that could never happen"
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by computerphage on Thursday December 03, 2020 @01:11AM (#25285970)
These six numbers could've been drawn in any order.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by Freak_NL on Thursday December 03, 2020 @02:44AM (#25286571)
5-10-15-20-25-30, 1-2-3-11-22-33; yeah there are a bunch more that people would find suspicious.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by 6gvONxR4sf7o on Thursday December 03, 2020 @04:49PM (#25295620)
Wikipedia says that powerball is out of 69 balls, not out of 50, and in the U.S. there are only about 100 draws per week. I cant imagine the worldwide numbers are more than an order of magnitude higher (I guessed it at 200/week in a sibling comment). That’s 7.5x more potential draws, and 5x-35x fewer draws per week, which would change the numbers quite a bit, making the weekly chance way way lower than your estimate.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by mrb on Saturday December 05, 2020 @02:53AM (#25312715)
I did check this South African powerball. They have 50 balls.

If they are 200 draws per week, the probability is 26% over 10 years.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by bouke on Thursday December 03, 2020 @04:40AM (#25287272)
You compete (as understood from the article) in Powerball by 50 choose 5, 20 choose 1. So 1 in (50!/(5!⨉45!)⨉20 = 42.375.200. There are 15 ascending "suspicious" winning sequences, as the choice of Powerball is always last and thus must be 6-20. Therefore the chance of winning Powerball with a "suspicious" sequence is 15 in 42.375.200. If there are 1000 Powerballs drawings per day for a year, that gives a chance of approximately 12% of happening at least once a year.

https://www.wolframalpha.com/input/?i=binomial+calculator&as...

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Thursday December 03, 2020 @01:41AM (#25286183)
Without going into detail about why your math is flawed, which it is -- a basic viability check would be to consider: if there was a 64% probability of some event happening each year, don't you think in your lifetime you'd have seen quite a few instances of that thing happening?
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by endtime on Thursday December 03, 2020 @01:56AM (#25286282)
If you read a daily digest of global lottery results, yes!

This might not be in the news because it's so rare. It might just be a slow news day.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Thursday December 03, 2020 @02:57AM (#25286651)
...or "crazygringo's" 1000 per day guess could be way, way off, and anybody, like "mrb," accepting it blindly as a basis for their own calculations is guilty (of failing to think critically) by association
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by dna_polymerase on Thursday December 03, 2020 @02:20AM (#25286439)
There is no 64%. It's hypothetical if there were 1000 draws per day. If you want to proof their math wrong please do more than calling it flawed.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Thursday December 03, 2020 @02:34AM (#25286513)
He states a conclusion -- "So this South African draw is kinda expected" -- referring to THIS DRAW, not a hypothetical example.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by drewmol on Thursday December 03, 2020 @03:23AM (#25286796)
>probability of some event happening each year, don't you think in your lifetime you'd have seen..

No. This is not particularly newsworthy. But for most HN users and this event the answer is: no, but I did see it on HN and it will probably get re posted cyclicaly ;)

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by Spare_account on Thursday December 03, 2020 @02:53AM (#25286621)
If you have the time,would you mind expanding on this with the detail that you mentioned?
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by konjin on Thursday December 03, 2020 @02:07AM (#25286349)
Why is the maths wrong?
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by arolihas on Thursday December 03, 2020 @08:07AM (#25288432)
Maybe he is referring to the fact that not all of the lotteries have the same structure? Idk it still seems like a good estimate to me
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Thursday December 03, 2020 @12:09PM (#25291269)
64% likelihood seems like a good estimate to you? Just take a second and consider whether you'd take the following bet: Your $1000 against my $5000 that anywhere in the world in 2021, a state-run lottery (with at least 5 balls out of at least 50, and a sixth out of at least 20) will have a perfectly sequential result.

You're being offered 5 to 1 odds on a probability that you just estimated to be significantly better than a coin flip. Are you in? Or does your gut tell you that 6 perfectly sequential numbers is crazy unlikely?

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by arolihas on Friday December 04, 2020 @11:23AM (#25304096)
It’s crazy unlikely for any particular lottery but there are a ton of draws and a ton of lotteries, and it only needs to happen once in a year. I probably would take that bet if it were feasible but then again I like to gamble.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Friday December 04, 2020 @02:41PM (#25306743)
Terrific, the same comment I replied to konjin applies to you as well. I'll absolutely make this bet if there's a trustable platform.

Just curious, if a random HN commenter said, there's about a 64% chance that at least one human being will grow to 12 feet tall in 2021, would you take that wager also? I mean, there are a ton of people on the planet, and it only needs to happen once.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by arolihas on Saturday December 05, 2020 @08:18PM (#25320047)
The difference is it’s biophysically infeasible for any human to mature and live as a 12 foot tall adult, considering there is a very small number of 7 feet tall people in 2020. Whereas there is no such constraint for any given sequence of numbers if the lottery allows for them to be drawn. I would rather wager on whether you will continue being an annoying pedant. I prefer my odds there.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by konjin on Thursday December 03, 2020 @09:11PM (#25298134)
Sure, how do you want to do that bet?
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Friday December 04, 2020 @02:28PM (#25306574)
I'm 100% serious about making this wager, I've sought out the wisdom of HN for help with a "smart contract" to guarantee trust.

https://news.ycombinator.com/item?id=25306489

At the same time, I'm not a thief -- to be entirely certain that you want to make this bet, have you read the entire thread, where alternate probabilities (far less than 64%) are proposed? You're aware that the original assumption of 1000 lottery draws per day was a guess from thin air with no research nor basis in fact? You're aware that mrb's calculations overstated the number of possible conforming sequences and undercounted the total number of potential outcomes? If you acknowledge that you're aware of all of this and still want to proceed, let's do it, no joke, I'm 100% in.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Thursday December 03, 2020 @02:45AM (#25286576)
It starts with the literal first sentence of the comment -- "They draw 6 balls out of 50." No, they don't.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by krit_dms on Thursday December 03, 2020 @02:50AM (#25286604)
thats... not math.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Thursday December 03, 2020 @02:58AM (#25286655)
calculating C(50, 6) is, as is everything that follows.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by BMSmnqXAE4yfe1 on Wednesday December 02, 2020 @08:03PM (#25283981)
There are 6 numbers, so it's not a 5 out of 50 lottery. 5 out of 50 means every 42000th tickets wins, which is a very high number, and can only be used in a lottery with small prizes. Of course, there are many lotteries for small prizes, for example there are millions of rounds of roulette plays occurring daily, and of course it's pretty often to have 2,3,4,5 and 6 occurring in sequence on some roulette table somewhere during a day. The phrase "1000 a year" relates to large national lotteries, where probabilities are much much smaller, it's about 1/250mln for US megamillions lottery, for example. So for 1000 of 1/10mln lotteries this will happen once every 273 years. I would say the probability of a foul play is high enough to warrant an investigation.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by Widdershin on Wednesday December 02, 2020 @08:10PM (#25284025)
If someone was going to rig the outcome, why would they make it such a conspicuous number?
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by ezzaf on Thursday December 03, 2020 @12:35AM (#25285763)
You're going to share the jackpot with dozens of other winners, so it wouldn't be immediately obvious which of the winners rigged it. While if you pick a random number sequence and are the only winner, you'll be the prime suspect if anyone realises the draw was rigged.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by BurningFrog on Wednesday December 02, 2020 @08:49PM (#25284291)
As a prank and/or to expose how unsafe the system is.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by Widdershin on Wednesday December 02, 2020 @10:36PM (#25285053)
Good point, I hadn't considered that. Seems pretty plausible.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by lb1lf on Thursday December 03, 2020 @07:36AM (#25288245)
-I'd say that is plausible if next week's draw turns out to be 1-2-3-4-5-6, for instance.

(That is - as is pointed out upthread, such 'weird' draws will occur naturally on occasion. It would, however, be quite suspicious if it happened twice in a row.)

I am sure one of the things the lottery looks into is how many coupons with 'weird' numbers chosen like this week's winning numbers have been picked in the past - of course, if you get a result which makes you suspect shenanigans AND the number of coupons with such a strange sequence of numbers is way up from normal, then perhaps that suspicion is well founded.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by BMSmnqXAE4yfe1 on Wednesday December 02, 2020 @08:11PM (#25284030)
true ... might be an innocent mistake too.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by jamesrcole on Wednesday December 02, 2020 @08:16PM (#25284064)
mistake? As far as I can see, it could only be either intentional or the result of randomness.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by jtbayly on Wednesday December 02, 2020 @08:35PM (#25284204)
It could also be an attempt to rig gone bad
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by jamesrcole on Wednesday December 02, 2020 @09:02PM (#25284388)
Sure. I’d call that the result of an intentional action, but maybe that’s just personal preference.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by chki on Wednesday December 02, 2020 @08:39PM (#25284232)
There might be some error in the randomization process that caused consecutive balls to be drawn.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by jamesrcole on Wednesday December 02, 2020 @09:04PM (#25284404)
That’s a fair point. In that case it would be the result of a both a mistake and randomization.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by BMSmnqXAE4yfe1 on Friday December 04, 2020 @10:12PM (#25311348)
software bugs are neither intentional not random
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by tyingq on Wednesday December 02, 2020 @08:59PM (#25284366)
"Does anyone have any idea how many daily "official" lotteries are drawn worldwide?"

https://www.gamblingsites.org/blog/how-many-different-lotter...

Looks like a reasonable analysis. Their total is 180.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by Freak_NL on Thursday December 03, 2020 @02:48AM (#25286597)
Are those lotteries with daily drawings though? They seem to list lotteries, but not specifically those with daily drawings.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by BlackFingolfin on Thursday December 03, 2020 @03:40AM (#25286884)
At least those I know in Europe and US are weekly...
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by a1369209993 on Wednesday December 02, 2020 @09:56PM (#25284755)
Assuming for simplicity that it's 6d50; you'd get 6 numbers ascending or decending:

  You have: 50^6 / (50*2) / (1000/day)
  You want: yr
    * 427.79832
about once every 4 centuries.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by naniwaduni on Wednesday December 02, 2020 @10:09PM (#25284863)
It turns out 50^6 is much, much bigger than C(50,5)*20 (as the article implies), by about 400x.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by ouid on Wednesday December 02, 2020 @06:15PM (#25283089)
there are 6 balls drawn in the example, which would drop that number down to .26%, which would be once every 400 years. I didn't check the rest of your math though.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by onlyrealcuzzo on Wednesday December 02, 2020 @06:19PM (#25283126)
Cool, as a rough approximation, it is close to (1/50)^6, right? But couldn't the first ball be any ball? That doesn't really matter. So wouldn't it just be 1/50^5 for 6 balls?

And wouldn't the odds really be: p = (1/49 * 1/48 * 1/47 * 1/46 * 1/45) for the balls to be drawn in order in one lottery?

The odds for them not to be drawn in order are then: 1 - p.

If there are 1000 lotteries per day, the odds it doesn't happen in a year are: ynp = (1-p)^(365 * 1000).

The yearly probability would be: 1-ynp.

If the balls can be drawn in any order, but they have to end as 6 ascending balls - then I think the probability is much higher, right?

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by jonahx on Wednesday December 02, 2020 @10:22PM (#25284958)
> Cool, as a rough approximation, it is close to (1/50)^6, right?

No. 50^6 is about 938x bigger than (50 choose 6), which is the correct chance of picking 6 of 50 numbers.

> And wouldn't the odds really be: p = (1/49 * 1/48 * 1/47 * 1/46 * 1/45) for the balls to be drawn in order in one lottery?

This is not correct either. There are 45 sequential possibilities of winning numbers: 1-2-3-4-5-6, 2-3-4-5-6-7, ... 45-46-47-48-49-50. So "45 / (50 choose 6)", about 647 times more likely than that calculation for p.

Of course, if you start adding in other striking patterns like 2-4-6-8-10-12, the chance of a "fishy" draw becomes more and more likely.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by naniwaduni on Wednesday December 02, 2020 @10:20PM (#25284942)
> Cool, as a rough approximation, it is close to (1/50)^6, right? But couldn't the first ball be any ball? That doesn't really matter. So wouldn't it just be 1/50^5 for 6 balls?

It's very, very far, between non-replacement (~1.36x), order (5!=120x), the fact that final ball is out of 20 instead of out of 50 (2.5x), and the number of possible sequences which would be notable (at least 16x, but actually probably a fair bit more because recognizable patterns are pretty broad).

The upshot of which is that estimating at 50^6 is off by multiple orders of magnitude...

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by sturmeh on Wednesday December 02, 2020 @10:46PM (#25285122)
If it's 5 specific numbers drawn from a pool of 50 in any order, we're talking 2118760 combinations of numbers that can be drawn, i.e. a 0.0000472% chance.

For 5 drawn in a specific order from a pool of 50, we're talking about 254251200 ways 5 numbers can be drawn, with a 0.0000004% chance.

In this case it was actually 6 numbers, which is about 10x less likely to match a combination (orderless) and 50x less likely to match a permutation (with order).

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by im3w1l on Wednesday December 02, 2020 @10:57PM (#25285194)
The chance for six ascending balls in a single drawing.

First definition. Let's count a sequence as ascending if the sorted set of drawn balls is ascending. E.g. 18,15,14,19,16 with a powerball of 17 would be counted as ascending.

I found that it was easiest to start with the odd one out and work from there. The powerball can be chosen in 20 ways. If the powerball is 1, then the sequence must start at 1 (1 combination). If it is 2, then the sequence can start with either 1 or 2 (2 combinations), 3 means 3 combinations, 4 means 4 combinations. For 5 and above, there are 5 combinations (the upper part of the range has no similar issue, since the normal balls go all the way to 50). We get a total of 85 combinations.

Now every combination of the 5 normal balls can be permuted in 5! ways, so we have 85 * 5! = 10200 ascending draws.

The total number of possible draws are 50 * 49 * 48 * 47 * 46 * 20 = 5085024000.

So the probability of an ascending draw is 10200 / 5085024000 ~= 2 in a million.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by hatsunearu on Wednesday December 02, 2020 @11:50PM (#25285517)
Random but there was an incident where the lottery number was identical to last weeks', just out of sheer luck.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by kbenson on Wednesday December 02, 2020 @06:14PM (#25283069)
Does someone mind posting the math on this? I'm getting something like 775% chance it would happen yearly, but that seems too likely, and I think I screwed mine up somewhere, and wouldn't mind seeing where I made some wrong assumption in how to compute the probabilities.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by OJFord on Wednesday December 02, 2020 @07:28PM (#25283731)
> I'm getting something like 775% chance it would happen yearly, but that seems too likely,

In probability, when you roam outside of the 0-1 (or 0-100%) range, you can guarantee with 775% certainty that something went wrong somewhere. ;)

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by robbintt on Wednesday December 02, 2020 @07:52PM (#25283894)
That’s not necessarily accurate if you are already operating in probability per year in this case. It just means 7.75 occurrences per time.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by OJFord on Wednesday December 02, 2020 @08:06PM (#25283996)
You can have an expected value E[X] = 7.75

You cannot have a probability P[X ≥ 1] >1.

There is no 'probability per year' (if it were meaningful year would have to be <1 for a >1 result anyway) - that time frame is built into 'X', it's 'inside' the probability.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by drdeca on Wednesday December 02, 2020 @08:37PM (#25284215)
If they are independent, then there should be a log-probability of it not happening per year though, right? Like, if the chance for each year is the same and they are independent, then the log of the probability that it doesn’t happen in a given year, If you multiply that that by the number of years, that will give the log of the probability that it doesn’t happen in any of the years. This seems like it could serve many of the purposes that people are intuitively looking for when they think of “probability per year”. And if the different years aren’t independent, uh, maybe some terms could be added to adjust for that?
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by free_rms on Wednesday December 02, 2020 @08:20PM (#25284095)
But OP didn't use either of those terms, they used "775% chance per year", which you can interpret colloquially as a speaker of English.

It's been clear throughout this thread what was meant.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by a1369209993 on Wednesday December 02, 2020 @10:04PM (#25284844)
> "chance per year", which you can interpret

Probably something like reciprocal half-life; 775% / yr is about 1 / 1.5 month ie, happens about once every month and a half.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by alentist on Wednesday December 02, 2020 @08:11PM (#25284032)
That would be the expected value E(X), not the probability P(X > 0). The two are not conflatable.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by rubidium on Wednesday December 02, 2020 @07:55PM (#25283912)
Nope. Bad maths. Average of 7.75 per year !== >100% of it happening at least once in one year.

There’s still some chance it doesn’t happen in one year.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by mrosett on Wednesday December 02, 2020 @06:21PM (#25283149)
Probability it happens is 1 in 50c5 (the number of ways to choose 5 balls out of 50.) So probability it doesn't happen is 1-1/50c5. Probability it never happens in a year is that number raised to (3651000). That gives 85%, so there's a 1-.85 = 15% chance that it does happen each year:

https://www.wolframalpha.com/input/?i=%281-1%2F%2850choose5%...

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by brandmeyer on Wednesday December 02, 2020 @07:17PM (#25283650)
This analysis is spot-on under the assumption of 1000 lotteries per day, although your asterisks are getting trashed by the markdown.

To the other folks ending up with some wild results, there is a basic checksum on probability: If you compute the probability of an event happening at greater than 100% you've borked something up.

Bug: They drew 5 balls from one pool of 50 with an independent draw from another smaller pool of 20, so you need ~~50 ncr 6~~ (50 ncr 5) * 20, not 50 ncr 5.

Nit: I would rephrase your answer that there is a 0.85% chance that it happens one or more times in any given year. There remains a (vanishingly small) chance that it happened on every single random draw during the year.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by onlyrealcuzzo on Wednesday December 02, 2020 @07:44PM (#25283845)
Wait. Why is it 50c5? If you want to know how many ways you can roll triples with 3 dice, it isn't 6c3, right?

There's 6 possible triple dice combinations and there are 6^3 possible dice combinations, so it's 6/(6^3).

If you wanted to know the odds of rolling 3 dice in order, you could roll: 1, 2, 3 OR 2, 3, 4 OR 3, 4, 5 OR 4, 5, 6 - which is 4/(6^3) - which is not 6c3.

Why is it different with the lottery? Or did I get the dice wrong?

Or are you calculating that the balls can be drawn in any order?

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by brandmeyer on Wednesday December 02, 2020 @07:59PM (#25283944)
Balls drawn in any order, without replacement.

The probability of guessing all 6 balls in a single lottery is 1 in (50 ncr 6). So, the probability of losing is 1 - 1/(50 ncr 6). The probability of losing every time is (1 - 1/(50 ncr 6)^(n_games), where n_games = 365 * 1000. Therefore, the probability of winning at least one game is (1 - (1 - 1/(50 ncr 6)^(n_games)).

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by onlyrealcuzzo on Wednesday December 02, 2020 @08:31PM (#25284172)
Got it. 50c6 is the total combinations. But there's more than 1 combination of 6 ascending balls, right? Why is it 1 in (50c6) instead of 45 in (50c6)?
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by brandmeyer on Wednesday December 02, 2020 @09:55PM (#25284748)
Oh, sure. There's a number of different suspect or convenient sequences out there. All of the evenly-spaced sequences could be considered suspicious if you go broadly enough. A detail I tried to add back in up-thread: The sixth ball is from a separate pool of 20 balls. So 50c5 * 20 is the total number of possible draws, and there are 14 directly in-order sequences.

But the main point was the methodology. (1 - (1 - chance_of_sequence)^(n_draws)).

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by onlyrealcuzzo on Wednesday December 02, 2020 @10:14PM (#25284905)
Thanks! Why are there only 14 in-order sequences??

Couldn't there be 1 2 3 4 5 6 AND 2 3 4 5 6 7 AND 3 4 5... Doesn't this give you 45?

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by NineStarPoint on Thursday December 03, 2020 @12:12AM (#25285634)
As the person above said, one of the balls is restricted to only 1-20. This ball is drawn last.

You get 14 possible draws if the order the balls are drawn in matters (14-20 being the highest, with 20 drawn last), and 20 permutations if it does not (since any straight above 20-25 is not possible). The math is much different for drawing if the order matters though. There also would probably be some funky stuff going on for the higher straights where order doesn’t matter, since for a 20-25 straight the 20 ball must be the special ball. For a 19-24 straight either 19 or 20 must be, etc. Really you’re looking at calculating “Chance that the first five balls can create a straight with a number between 1-20, and then a 1/20 chance that straight actually happens.”

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by crazygringo on Wednesday December 02, 2020 @06:28PM (#25283232)
Sure, sorry. I'd used:

  2*(1/49)*(1/48)*(1/47)*(1/46)*365*1000*(45/50) = 12.9%
The initial "2" term is for consecutive numbers going both directions, and the final (45/50) term is to account for the fact that if you start with 4 or less and decreasing, or 46 or greater and increasing, you'll run out of numbers.

Edit: but if the numbers don't have to be drawn in order (e.g. 8-5-9-6-7 is OK), then the odds are much higher still:

  2*(4/49)*(3/48)*(2/47)*(1/46)*365*1000 = 344.5%
(With the initial "2" term accounting for 4 consecutive numbers on either side of the initial pick -- though I'm not sure I've got that entirely right?) Then it would happen three to four times a year. Even with a 6th ball drawn separately out of 20, that's still a 17% chance happening somewhere in the world in a year, given 1,000 daily draws.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by JoshTriplett on Wednesday December 02, 2020 @06:55PM (#25283476)
> Edit: but if the numbers don't have to be drawn in order (e.g. 8-5-9-6-7 is OK), then the odds are much higher still:

Most lotteries are order-insensitive, and typically present the results in ascending numeric order. The actual draw often happens in some order (e.g. numbered balls being drawn from a hopper), and it'd be even more unusual if the numbers were actually drawn in consecutive order, but drawing 5-2-3-1-4 would typically be presented as 1-2-3-4-5 and would still be remarked upon as unusual.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by Asraelite on Wednesday December 02, 2020 @07:37PM (#25283792)
To calculate the probability of some event with probability P coming true at least once out of N total tries, you do 1 - ((1 - P) ^ N), not P * N as you've done.

Doing this, your final figures should be 12.1% and 96.8%.

For the expected number of times it would happen though, you are right, it would be three or four times per year on average for the second case.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by kbenson on Wednesday December 02, 2020 @06:42PM (#25283363)
Oh. I assumed consecutive numbers, but not necessarily consecutive on each pull. That is, 1,2,3,4,5 is no different than 2,3,4,5,1 in my calculations, which makes the possible ways got get consecutive numbers at the end quite a bit higher. Still not positive I got it right, but at least I know it shouldn't match your results, as they are for slightly different things. :)

Edit: What I did was take all the possible combinations of 5 balls (5!) by the number of different sets that could be drawn (50-5, based on lowest number), over the total possible draws (50!). I think perhaps what that does it not account for overlap between sets (1-5 and 2-6), inflating the number somewhat, which is why it's a bit more than twice the probability than you got for any possible sequence of 5.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by ALittleLight on Wednesday December 02, 2020 @07:32PM (#25283761)
Unless I'm doing something wrong here - just typing some javascript into the console gives me...

  function rn() {
      return parseInt(Math.random() * 100);
  }


  function drawing(){
      let result = [rn(), rn(), rn(), rn(), rn()]; 
      return result.sort();
  };


  function sequential(arr){
      for(let i = 0; i < arr.length-1; i++){
          if(arr[i] + 1 != arr[i+1]){
              return false
          } 
      } 
      return true
  }

  let counter = 0; 

  for (let i = 0; i < 10000000; i ++){
      if (sequential(drawing())){
          counter ++;
      } 
  }; 

  console.log(counter);

  16
Mathematically, it seems like you'd need to draw one of five numbers from the range, then one of four numbers, then one of three... so the likelihood would be 5/100 * 4/100 * 3/100 * 2/100 * 1/100 = 0.000000012. Although those odds don't seem to line up with the javascript I posted.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by bweitzman on Wednesday December 02, 2020 @06:42PM (#25283357)
FYI 0.129 = 1 / 7.75. I think you and person you're responding to are doing the same calculations, but inverted.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by brlewis on Wednesday December 02, 2020 @08:30PM (#25284167)
Lumping all world lotteries together introduces a lot of handwaving, so let's start with what we know and work forward.

According to the article, this event happened for South Africa Powerball, where 5 numbers are chosen out of 45, and 1 number chosen out of 20: https://en.wikipedia.org/wiki/South_African_National_Lottery...

That same Wikipedia page does some of the math for us: The chance of one combination being chosen is 1/42,375,200. So if we count all possible sequential combinations, N, we'll know that the chance of a single winning combination being sequential is N/42,375,200.

Say the powerball comes out as any number 6 <= M <= 20. There are 6 ways the numbers 1-45 could be picked such that M is part of the sequence. That's 90 ways total. If the powerball is 5, there are only 5 ways, same continuing down to a powerball of 1 where there's only 1 combination of numbers 1-45 where it could be part of the sequence. 90 + 5 + 4 + 3 + 2 + 1 brings us to 105 as our N.

So this single event had a probability of 105/42,375,200, or 1/403,573. This means that for similar lotteries one would expect to see a sequence after about 200,000 picks.

EDIT: If you only count events where the powerball is the high number, as happened this time, N goes down to 15, making the odds 1/2,825,013, so one would expect such a sequence after about 1.4 million picks.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by smallnamespace on Wednesday December 02, 2020 @06:23PM (#25283173)
That seems right, 1 * 1/49 * 1/47 * 1/46 * 1/45 * 5! * 1000 * 365 gets about 8 occurrences per year.
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by thaumasiotes on Wednesday December 02, 2020 @06:40PM (#25283339)
There are two very different questions:

1. How often does this happen? This is a question about expected value, and the answer could be anything zero or above.

2. What are the chances that this will happen within a year? This is a question about probability, and the answer must lie between zero and one. There is no such thing as "a 775% chance it would happen yearly".

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by smallnamespace on Wednesday December 02, 2020 @10:01PM (#25284811)
Those two questions are closely related here by a very simple transformation: if the expected number of occurrences is N over many independent tries, then probability of 0 occurrences is approximately 1-e^(-N), or 99.96% if N=7.75.

Note that for N close to 0, 1-N is also a good approximation to 1-e^(-N).

For large N, it's generally more convenient to talk about the expectation rather than the probability of 0 hits—I'm sure many readers implicitly converted 775% to the expectation in their heads.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by thaumasiotes on Thursday December 03, 2020 @12:48AM (#25285836)
> I'm sure many readers implicitly converted 775% to the expectation in their heads.

Most people cannot do this correctly; the most obvious interpretation of a "775% chance" is that it represents a 25% chance of seven occurrences and a 75% chance of eight occurrences, with no other possibilities.

The problem gets even worse when you have expectations less than one. If the expected number of occurrences is 80%, what are the odds of getting any occurrences at all? They're less than 80% as long as it's possible to have more than one occurrence.

Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by listenallyall on Friday December 04, 2020 @03:57PM (#25307838)
you skipped 1/48
Re:South Africa's lottery probed as 5, 6, 7, 8, 9 and 10 drawn by RobRivera on Wednesday December 02, 2020 @08:00PM (#25283953)
Probability is a 0-1 range