Question 1164818: A lot of 75 washers contains 5 in which the variability in thickness around the circumference
of the washer is unacceptable. A sample of 10 washers is selected at random, without
replacement.
(a) What is the probability that none of the unacceptable washers is in the sample?
(b) What is the probability that at least one unacceptable washer is in the sample?
(c) What is the probability that exactly one unacceptable washer is in the sample?
(d) What is the mean number of unacceptable washers in the sample?
Also give R code
Found 2 solutions by CPhill, ikleyn: Answer by CPhill(2189) (Show Source):
You can put this solution on YOUR website! Since the sample is selected **without replacement** from a finite population, this problem follows a **Hypergeometric Distribution**.
### Given Parameters:
* **Total population size ():** 75 washers
* **Number of successes in population ():** 5 unacceptable washers
* **Number of failures in population ():** 70 acceptable washers
* **Sample size ():** 10 washers
The probability mass function for the hypergeometric distribution is:
---
### (a) Probability that none of the unacceptable washers is in the sample
We are looking for . This means we choose 0 from the 5 unacceptable and 10 from the 70 acceptable washers.
Calculating this:
---
### (b) Probability that at least one unacceptable washer is in the sample
This is the complement of "none are unacceptable":
---
### (c) Probability that exactly one unacceptable washer is in the sample
We are looking for . This means we choose 1 from the 5 unacceptable and 9 from the 70 acceptable washers.
Calculating this:
---
### (d) Mean number of unacceptable washers in the sample
For a hypergeometric distribution, the mean is calculated as:
---
### R Code
You can use the built-in `dhyper` (for exact probability) and `phyper` (for cumulative probability) functions in R.
```r
# Parameters
N <- 75 # Total population
K <- 5 # Unacceptable in population
n <- 10 # Sample size
m <- K # Number of 'success' items (unacceptable)
nn <- N - K # Number of 'failure' items (acceptable)
# (a) Probability X = 0
prob_a <- dhyper(0, m, nn, n)
print(paste("Probability none are unacceptable:", round(prob_a, 4)))
# (b) Probability X >= 1
prob_b <- 1 - dhyper(0, m, nn, n)
# Alternatively: phyper(0, m, nn, n, lower.tail = FALSE)
print(paste("Probability at least one is unacceptable:", round(prob_b, 4)))
# (c) Probability X = 1
prob_c <- dhyper(1, m, nn, n)
print(paste("Probability exactly one is unacceptable:", round(prob_c, 4)))
# (d) Mean
mean_val <- n * (m / N)
print(paste("Mean number of unacceptable washers:", round(mean_val, 4)))
```
Would you like me to calculate the **standard deviation** of unacceptable washers for this sample as well?
Answer by ikleyn(53618) (Show Source):
|
|
|