[1] 0.0256
A random variable is a quantified observation from a process whose outcome is not known with uncertainty. \[\begin{align} X=x \end{align}\]
The capital letter “X” is the definition of the random variable.
The small caps letter “x” is the value it can take.
\[\begin{align} X=\{0,1,3\} \end{align}\]
\[\begin{align} X = \{0,1\} \end{align}\]
There are different interpretations of probability.
Words such as chance and likelihood can be used colloquially but it does not define anything. In fact in statistics, likelihood refers to something else.
Objective interpretation: Relative frequency of the value of a random variable in a large number of trials which obeys laws of probability.
Subjective interpretation: Quantification of uncertainty which obeys laws of probability.
Imagine a coin. You toss the coin and you will assign a probability to heads (X=1) and tails (X=0)
P(X=1)=0.5 & P(X=0) = 0.5
But why? It can not be just because there are 2 outcomes. Would you assign 0.5 as probability to sun rising tomorrow?
You either did a mental calculation of having a really large number of coin tosses and calculated the relative frequency (objective) or you used your mental image of the world and what you have experienced in your life about coin tosses (subjective).
Let 1 represent heads, 0 for tails.
Marginal: \(P(X=x)\) Probability associated with the value of a single random variable. What is the probability of the first coin toss being heads. P(X=1)
Joint: \(P(X_{1}=x_{1},X_{2}=x_{2})\) Probability of having two or more random variables happening together. What is the variable I will toss a coin two times and the first time it lands heads and the second time it lands tails. \(P(X_{1}=1,X_{2}=0)\)
Convexity: \(0<P(X=x)<1\)
Addition: \(P(X_{1}=x_{1} \cup X_{2}=x_{2} )=\)
Multiplication: \(P(X_{1}=x_{1} , X_{2}=x_{2} )=\) \[ \begin{split} & P(X_{1}=x_{1}\vert X_{2}=x_2) \times P(X_{2}=x_2) \\ & P(X_{2}=x_{2}\vert X_{1}=x_1) \times P(X_{1}=x_1) \end{split} \]
\(P(\Omega)=1\) where \(\Omega\) is sample space of X.
\[\begin{align} P(Y=y|X=x) = P(Y=y) \\ P(X=x|Y=y) = P(X=x) \end{align}\]
Think about the consecutive coin tosses again. \[ \begin{split} & P(X_{1}=1,X_{2}=1|p=0.5)= \\ & P(X_{1}|p=0.5) \times P(X_{2}=1|p=0.5) \end{split} \] where p is the common probability of the outcome of a coin toss being heads.
Probability distributions are functions that assign uncertainty to random variables’ values which obey the laws of probability. They can come in two types. Discrete or Continuous.
If you take any arbitrary set of two values from a random variable, and a middle point can always be found within the sample space of that random variable what you have is a continuous variable. Otherwise you do have a discrete one.
\[ \begin{split} & P(X=x) = p^{x}\times(1-p)^{1-x}\\ & P(X=1) = p^{1}\times(1-p)^{1-1}=p^{1}\times (1-p)^{0}=p\\ & P(X=0) = p^{0}\times(1-p)^{1-0}=p^{1}\times (1-p)^{1}=1-p \end{split} \]
Furthermore if X has a Bernoulli distribution. \[ E(X)=p\]
\[ Var(X)=p\times(1-p)\]
\[ P(Y=y) = \binom{n}{y} \times p^{y} \times (1-p)^{n-y} \] - where n is the total number of Bernoulli trials, p is probability of success and y is the total number of successes.
\[ E(Y)=n\times p , Var(Y)=n \times p \times (1-p) \]
\[ \binom{n}{y}=\frac{n!}{y!\times(n-y)!} \]
Assume you are inspecting 4 widgets. The probability of finding a defective widget is 0.2. If this probability did not change what is the probability that you will find 3 defective items.
Y is the sum of 4 bernoulli trials, each leading to either defective \((X_{i}=1)\) or nondefective \((X_{i}=0)\) where \(i\) is 1 \(\ldots\) 4.
\[ P(Y=3 \vert n=4, p =0.2)= \binom{4}{3} \times 0.2^{3} \times (1-0.2)^{4-3} \]
\[ \binom{4}{3} = \frac{4!}{3!\times (4-3)!}=\frac{4 \times 3 \times 2 \times 1}{3 \times 2 \times 1 \times 1}=4 \] - This simply implies that there are 4 different ways you can choose 3 successes (and one failure by default) out of 4 tries.
Row | Widget 1 | Widget 2 | Widget 3 | Widget 4 |
---|---|---|---|---|
1 | 1 | 1 | 1 | 0 |
2 | 1 | 1 | 0 | 1 |
3 | 1 | 0 | 1 | 1 |
4 | 0 | 1 | 1 | 1 |
Row | Widget 1 | Widget 2 | Widget 3 | Widget 4 |
---|---|---|---|---|
2 | 1 | 1 | 0 | 1 |
This is joint probability and can be represented with notation as \(p(X_{1}=1,X_{2}=1,X_{3}=0,X_{4}=1)\)
How do we calculate this joint probability?
\[ \begin{split} & p(X_{1}=1,X_{2}=1,X_{3}=0,X_{4}=1)\\ & p(X_{i}=1)=0.2 ~\&~ (1-p(X_{i}=1))=0.8\\ & p \times p \times (1-p) \times p = \\ & 0.2 \times 0.2 \times 0.8 \times 0.2 \\ & 0.2^{3} \times 0.8 = 0.0064 \end{split} \]
Row | \(X_{1}\) | \(X_{2}\) | \(X_{3}\) | \(X_{4}\) | P(Row) |
---|---|---|---|---|---|
1 | 1 | 1 | 1 | 0 | 0.0064 |
2 | 1 | 1 | 0 | 1 | 0.0064 |
3 | 1 | 0 | 1 | 1 | 0.0064 |
4 | 0 | 1 | 1 | 1 | 0.0064 |
\(\sum_{1}^{4}\) | \(4 \times 0.0064\) |
The quality control procedure inspects 8 items in lot 1, 10 items from lot 2. If there is at least 2 items that are defective in lot 1 or at least 3 items that are defective in lot 2. You stop the manufacturing process. What is the probability that you will stop the process. Probability of a random item to be defective in lot 1 is 0.3. Probability of a random item to be defective in lot 2 is 0.25.
Start by defining the random variables and identify prob.
Define the question with notation and the random variables you have defined.
Let Y represent the number of items in lot A that are defective. \(Y=\{0,\cdots,8\},p_{y}=0.3,n_{y}=8\)
Let Z represent the number of items in lot B that are defective. \(Z=\{0,\cdots,10\},p_{z}=0.25,n_{z}=10\)
The question redefined with notation and r.v.s \[ \begin{split} & P(Y \ge 2 \cup Z \ge 3) \\ & P(Y \ge 2)+P(Z \ge 3) - P(Y \ge 2, Z \ge 3)\\ \end{split} \]
Since the probability of all values of Y has to add up to 1. \[ \begin{split} & P(Y \le 1) + P(Y \ge 2)) =1 \\ & P(Y \ge 2)=1-P(Y \le 1) \end{split} \]
Find each component in the equation separately.
\[ \begin{split} & P(Z \le 2) + P(Z \ge 3)) =1 \\ & P(Z \ge 3)=1-P(Z \le 2) \end{split} \]
\[ P(Y \ge 2) \times P(Z \ge 3)= 0.7447 \times 0.4744=0.3533\] - Putting it all together
\[ \begin{split} & P(Y \ge 2) &+& & P(Z \ge 3) &-& & P(Y \ge 2 , Z \ge 3)&= \\ & 0.7447 &+& & 0.4744 &-& & 0.3533 &= 0.8658 \end{split} \]
What values do you think were involved to assume these cutoff values that lead to process stoppage?
Think short term. Think long term.
Think about what you are trying to optimize and why.