
The probability mass function is given by the following table. I am having trouble trying to solve this mathematically.

The probability mass function is given by the following table. I am having trouble trying to solve this mathematically.
Copyright © 2021 JogjaFile Inc.
Comment: In order to give you a general idea how such a simulation can be done, I am showing R code for a million 3-dice experiments, along with some remarks. The R function
sample(1:6, 3, rep=T)randomly 'throws' 3 fair dice,Notes: Of course simulated values are only estimates. But there are ways to assess accuracy.
It is easy to find the exact mean and variance for one die by analytic means, and thus to find exact values for $E(X)$ and $V(X).$ By the Law of Large Numbers, sample means of a million values should be good approximations of respective population values.
Similarly for $P(2 <X< 13).$ [What is the normal approximation of this probability?
By the Central Limit Theorem you can get 95% margins of simulation error for the mean and the probability above.
The histogram is a bit tricky because you want one bin for each possible value 3 through 18 (controlled here by the
brparameter).With a million iterations, you can manipulate results of
tableto get (very likely) numerators of $6^3$ in the PMF.For example, it is easy to see that $P(X = 3) = 1/216.$
Addendum: Your die is unfair, The R
samplefunction can handle that. Parts of the simulation are modified for your unfair die as follows: