Normal Distribution
A character in a game deals a standard attack 75% of the time and a critical attack the rest of the time (call these events \(S\) and \(S^c\)). Given that it is a standard attack, the attack power is \(X\,|\,S \sim \text{Normal}(\mu=40,\sigma=3)\). When the character deals a critical attack, a random fluctuation is added to this according to a \(\text{Normal}(\mu=5,\sigma=1)\) distribution.
Exercises
- What is the distribution of \(X\,|\,S^c\)?
- Calculate \(\Pr(X<43\,|\,S)\) and \(\Pr(X<43\,|\,S^c)\).
- Calculate \(\Pr(X<43)\). ,, (hint: law of total probability)
- If the character deals less than 43 damage points, what is the probability that the attack was a critical attack?
Solution
Let’s go step-by-step through this probabilistic game scenario:
1. Distribution of \(X\,|\,S^c\)
If the character performs a critical attack \((S^c)\), the base attack \(X \sim N(40, 3^2)\) gets an added random fluctuation \(F \sim N(5, 1^2)\).
Since the sum of two independent normal variables is also normal:
\[ X\,|\,S^c = X + F \sim N(40 + 5,\ 3^2 + 1^2) = N(45,\ 10) \]
Answer: \(X\,|\,S^c \sim \text{Normal}(45,\ 10)\)
2. Calculate \(\Pr(X < 43\,|\,S)\) and \(\Pr(X < 43\,|\,S^c)\)
Standard Attack: \(X\,|\,S \sim N(40, 3^2)\)
\[ Z = \frac{43 - 40}{3} = 1 \quad \Rightarrow P(Z < 1) ≈ 0.8413 \]
Critical Attack: \(X\,|\,S^c \sim N(45, \sqrt{10}) ≈ N(45, 3.162)\)
\[ Z = \frac{43 - 45}{\sqrt{10}} = \frac{-2}{3.162} ≈ -0.632 \quad \Rightarrow P(Z < -0.632) ≈ 0.263 \]
Answers: - \(\Pr(X < 43\,|\,S) ≈ 0.8413\) - \(\Pr(X < 43\,|\,S^c) ≈ 0.263\)
3. Calculate \(\Pr(X < 43)\) using the law of total probability
\[ \Pr(X < 43) = \Pr(X < 43\,|\,S) \cdot P(S) + \Pr(X < 43\,|\,S^c) \cdot P(S^c) \] \[ = 0.8413 \cdot 0.75 + 0.263 \cdot 0.25 = 0.630975 + 0.06575 = 0.6967 \]
Answer: \(\Pr(X < 43) ≈ 0.6967\)
4. Probability the attack was critical given \(X < 43\)
This is a conditional probability using Bayes’ Theorem:
\[ \Pr(S^c\,|\,X < 43) = \frac{\Pr(X < 43\,|\,S^c) \cdot \Pr(S^c)}{\Pr(X < 43)} = \frac{0.263 \cdot 0.25}{0.6967} ≈ \frac{0.06575}{0.6967} ≈ 0.0944 \]
Answer: Approximately 9.44% chance the attack was critical, given it did less than 43 damage.