14 hours ago
- Article proposes using a deck of 52 playing cards to store a 128-bit cryptographic key, with erasure by shuffling.
- Mapping between a number and a permutation is called ranking (permutation to number) and unranking (number to permutation).
- Algorithms for ranking/unranking have varying complexity: O(n²) for lexicographic order, O(n log n) for sophisticated methods, and O(n) for non-lexicographic order.
- SymPy's Permutation class provides `unrank_lex` and `rank` methods for lexicographic order, and `rank_nonlex` and `unrank_nonlex` for O(n) methods.
- Demonstration shows encoding a 225-bit random number into a permutation of 52 cards and visualizing the result using Unicode card symbols.