This project calculates the probability distribution of dice rolls and visualizes the results. It parses a dice notation (e.g., 4d12+12
), computes the probability density function (PDF) using convolution, and plots the resulting distribution along with the mean outcome.
- Parse dice notations to extract the number of dice, number of faces, and modifiers.
- Calculate the probability distribution using convolution of discrete probability densities.
- Plot the distribution with a marked mean value for better understanding.
This project was inspired by a video by 3Blue1Brown on the convolution of discrete probability densities. You can watch the video here: 3Blue1Brown - Convolution.