sunil.page


Posts about Maths

A Feast for Probabilities

Tuesday, 22nd February 2022 ◆ Looking for French one in strange night (7)

In somewhat of a break from Uwe Rosenberg's usual worker placement games, A Feast for Odin introduced an element of luck in the form of die rolls. These die rolls come in two flavours:

  • Hunting/snaring/whaling - where you aim to roll low
  • Raiding/pillaging - where you aim to roll high

Under normal circumstances, you are allowed up to three rolls to get the result you want. After you stop rolling, you may spend resources and cards to further modify the result. I never really know how many resources and cards I need before I should risk using these spaces, so I thought I'd do a quick probability run-down. This also serves to determine how large the element of luck actually is...

Read more...

Round in circles

Thursday, 15th November 2018 ◆ Something unexpected in grand omelette (6)

Note: this is a follow-on post from follow your dart.

In making games, I often want to randomly place objects inside a circle. I have always done this one of two ways, but I feel unsatisfied with both.

Method 1: Randomly pick a point in the surrounding square, and reject points which are not in the circle.

Read more...

Follow your dart

Thursday, 1st November 2018 ◆ A bard trod clumsily on cork circle (9) ◆ Comments (3)

Imagine throwing a dart at a dartboard such that it will hit any point on the dartboard uniformly randomly. What is the expected distance between the dart and the centre of the dartboard?

Read more...

Rolling in the deep

Sunday, 21st October 2018 ◆ Sandwich spells troll's end (4)

I don't like traditional four-sided dice. When you toss them, they just thud to the table without really rolling. Reading the number is also awkward. All in all, bad.

I have collected a couple of variant d4s which I find much more satisfying. On each, the number is clearly visible after rolling, and the dice actually roll on the table once you release them. I knocked together a couple of models in Blender to show the shapes I have:

Read more...

The secret of Ms Dorobeth

Thursday, 18th October 2018 ◆ Abel's brother eats first honey links (5)

For the purpose of filling out an in-development site with placeholder data, I decided to make a random name generator based on Markov chains. The goal was for it to create pronounceable and plausible names, but not necessarily real names.

First, a bit about Markov chains. If you have a set of "states", a Markov chain simply describes the probability of moving from any state to any other state. For example, imagine we have a mood lamp which changes colour every second according to the following Markov chain:

Read more...