carykh / PrisonersDilemmaTournament

Watch This Place's awesome video about iterated Prisoner's Dilemma for context! https://www.youtube.com/watch?v=BOvAbjfJ0x0
MIT License
205 stars 160 forks source link

How many guarantee turns will it have? #7

Closed astropingo closed 3 years ago

astropingo commented 3 years ago

On /code/prisonersDilemma.py, line 44 the comment says it will guarantee 50 turns:

The games are a minimum of 50 turns long. The np.log here guarantees that every turn after the 50th has an equal (low) chance of being the final turn.

But on readme.md it says it is guaranteed to be at least 200 turns:

This means each game is guaranteed to be at least 200 turns long.

Which one is correct? I assume the 200, but both information are inconsistent.

Savethemarsh commented 3 years ago

It's 200, the length of the game is defined as 200-40*log(x), x being a random value from 0 to 1

peterHoburg commented 3 years ago

Between 200 and 1765

nobody5050 commented 3 years ago

Between 200 and 1765

For more on this, see #11

WalterCM commented 3 years ago

It's 200, the length of the game is defined as 200-40*log(x), x being a random value from 0 to 1

Isn't log of zero, undefined?

Savethemarsh commented 3 years ago

It's 200, the length of the game is defined as 200-40*log(x), x being a random value from 0 to 1

Isn't log of zero, undefined?

Yes; see #3

carykh commented 3 years ago

Between 200 and 1765! It's set up so that you know 200 rounds will happen for sure, but after that, there's an exponential dropoff (equal probability of ending each round) so you can't guess when it's going to end reliably.

Also, sorry for the contradiction from the comment! Forget the number "50", it's supposed to say "200". It should be fixed now!