Skip to content

Reduce entropy loss when num of dice and length of wordlist do not fit #41

Open

Description

@ulif

When we have dice with n sides and use a wordlist of m words, then we would like to get an optimum entropy of log(m) per word. If, however, m is not a power of n, then, I think, we lose entropy when mapping dice throws to the words in the wordlist.

Consider n=3 and m=2:

1  →  A
2  →  B
3  →  ?

What to do when the user rolls a "3"?

Two possibilities come to mind:

a)
1 → A
2 → B
3 → A

b)
1 → A
2 → B
3 → deny, roll again, until one of (1, 2) is rolled

The second one (b) is, what we implement currenty. But is this mathematically the best?

Activity

  1. self-assigned this
    on Sep 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions