Marco, if you are mathematician, do you must know, what is the function %, no?
An example.... and is simple, in code is more long and formula more hard.
If X= 100 then Super Goal
if X>=90 GOAL
If X>=80 Penalty
If X>=70 Corner
If X>=60 Fault
If X>=50 Lose ball
Is an example simple to understand, code never is it

.
Think that Mathematicas are exactly is be wrong. One thing is a formula simple with a constant an other variables.
If was exactly then all will be predictable, you know before. There are a little space to different possibilities.
All is more complex, but after 100 matchs a team level 100 always must win, but can 1 time win level 1, very hard, but never impossible, only that %>0, only 1 or 0.01, etc
Regards