[HN Gopher] A two-person method to simulate die rolls
       ___________________________________________________________________
        
       A two-person method to simulate die rolls
        
       Author : Fraterkes
       Score  : 32 points
       Date   : 2025-12-05 19:32 UTC (2 days ago)
        
 (HTM) web link (blog.42yeah.is)
 (TXT) w3m dump (blog.42yeah.is)
        
       | AnotherGoodName wrote:
       | A + B mod n seems much easier than this.
        
         | BoiledCabbage wrote:
         | Yup
        
         | tomsmeding wrote:
         | The method proposed is just A - B mod n. The two are entirely
         | equivalent.
        
           | AnotherGoodName wrote:
           | A few extra steps to essentially manually do the mod part
           | tbh. Would take their 20 line program to a 1 liner.
        
       | IanCal wrote:
       | This starts by assuming humans are bad at coming up with unbiased
       | numbers but then requires them to do so. I don't get how this
       | could work with biased inputs.
        
         | jdpage wrote:
         | Bear in mind, the terminal goal doesn't actually require
         | unbiased numbers; the way most TTRPGs work is that you're
         | trying to roll over or under a target number to get a weighted,
         | unpredictable outcome. The idea is that while players (usually)
         | want any given action to succeed, they some of their actions to
         | fail in order to preserve narrative interest, while having
         | their character be better at some things than others.
         | 
         | As such, while randomness is _best_ , the given method is quite
         | sufficient for having fun, and both players can agree that it's
         | fair: they each have equal influence over the result.
        
       | xg15 wrote:
       | > _We can prove that in an ideal situation, the die roll will be
       | fair. Assuming both parties can come up with unbiased random
       | numbers ranging from [0;12)..._
       | 
       | Doesn't that assumption remove the entire problem though? I
       | thought the whole reason for the method was that people _can 't_
       | easily think of an unbiased random number.
       | 
       | Or put differently, if that's your starting point, what's
       | stopping you from simply doing (A mod 6) + 1?
        
         | AnotherGoodName wrote:
         | I think the game theory inherit here makes it ok for this
         | purpose. You get an advantage being random. You're likely still
         | not going to generate random numbers but at least there's good
         | motivation to be random and that part just becomes part of the
         | game imho (guess what number the opponent calls to maximize
         | your roll).
         | 
         | Of course as others note this is a convoluted mod n process.
        
         | torginus wrote:
         | Yeah, the only valuable idea here is the angle-one, which is
         | like a modulo, making the approach a primitive LCG, which is a
         | way of generating pseudorandom numbers from seeds.
         | 
         | I'd say the only unbiased and non crappy method here is to feed
         | the 2 participants' numbers into some sorth of hash function.
        
       | zeroonetwothree wrote:
       | It would be more interesting to look at how much this reduces
       | bias based on numbers humans actually tend to generate.
       | 
       | BTW a "classic" method of generating random numbers is to look at
       | the second hand of a watch mod n.
        
       | AlotOfReading wrote:
       | Another procedure based on a similar problem I worked on with a
       | friend: you both pick positive integers a and b, then add them
       | together to create c. Either sqrt(c) or sqrt(c+1) is irrational
       | and the fractional digits provide your random numbers. If you
       | need a new sequence, you take some digits from the current
       | expansion and sqrt() them again.
       | 
       | Might not be unbiased, but good luck proving it.
        
       | amelius wrote:
       | After a while both people will get tired or bored and start
       | generating the same number over and over again. At which point
       | the method breaks down.
        
       | fweimer wrote:
       | Usually, commitment schemes are used for this:
       | https://en.wikipedia.org/wiki/Commitment_scheme
       | 
       | (However, if the stakes are high enough, the party that learns
       | the outcome first can choose to exit the protocol if they are
       | unsatisfied with the result.)
        
       ___________________________________________________________________
       (page generated 2025-12-07 23:00 UTC)