# Digital Dice: Computational Solutions to Practical Probability Problems

Princeton University Press, 2008 - Computers - 263 pages

Some probability problems are so difficult that they stump the smartest mathematicians. But even the hardest of these problems can often be solved with a computer and a Monte Carlo simulation, in which a random-number generator simulates a physical process, such as a million rolls of a pair of dice. This is what Digital Dice is all about: how to get numerical answers to difficult probability problems without having to solve complicated mathematical equations.

Popular-math writer Paul Nahin challenges readers to solve twenty-one difficult but fun problems, from determining the odds of coin-flipping games to figuring out the behavior of elevators. Problems build from relatively easy (deciding whether a dishwasher who breaks most of the dishes at a restaurant during a given week is clumsy or just the victim of randomness) to the very difficult (tackling branching processes of the kind that had to be solved by Manhattan Project mathematician Stanislaw Ulam). In his characteristic style, Nahin brings the problems to life with interesting and odd historical anecdotes. Readers learn, for example, not just how to determine the optimal stopping point in any selection process but that astronomer Johannes Kepler selected his second wife by interviewing eleven women.

The book shows readers how to write elementary computer codes using any common programming language, and provides solutions and line-by-line walk-throughs of a MATLAB code for each problem.

Digital Dice will appeal to anyone who enjoys popular math or computer science.

### What people are saying -Write a review

User Review - Flag as inappropriate

I was blown away years ago when I first learned of Monte Carlo simulations and how they can be applied to big, serious problems. Reading Paul Nahin's book, I realized the beauty of applying these techniques to everyday problems. Then I discovered Octave, the open source math programming language and alternative to Matlab. Then it became really fun.

### Contents

 I 1 II 35 III 37 IV 38 V 40 VI 42 VII 45 VIII 48
 XXX 124 XXXI 129 XXXII 140 XXXIII 144 XXXIV 148 XXXV 153 XXXVI 157 XXXVII 161

 IX 51 X 53 XI 59 XII 61 XIII 63 XIV 65 XV 69 XVI 74 XVII 77 XVIII 81 XIX 83 XX 85 XXI 87 XXII 91 XXIII 96 XXIV 101 XXV 103 XXVI 105 XXVII 109 XXVIII 114 XXIX 120
 XXXVIII 169 XXXIX 175 XL 184 XLI 187 XLII 191 XLIII 197 XLIV 204 XLV 213 XLVI 221 XLVII 223 XLVIII 229 XLIX 231 L 237 LI 244 LII 248 LIII 252 LIV 255 LV 257 LVI 259 LVII 261 Copyright