1
$\begingroup$

A company is building 100 new apartments. Based on previous data from similar areas, the company knows that the propability is 25% that a household will not have a car, 50% that a household will have 1 car and 25% that a household will have 2 cars. How many parking spaces should the company build if the company wants to be 95% sure that all cars in every household can be parked? (number of parking spaces must be equal to or greater than the number of the total number of cars)

I truly do not know how to proceed. Really greatful for help.

I was thinking of using a binomial distribution, but since there are three different outcomes, I do not know what to do. I suppose I could divide the binomial distribution into "0 cars" vs "1 car or more" but I don't understand where to go from there.

I suppose I could enter all values into Excel and calculate every possible combination of cars that can exist but that feels like a bad method.

$\endgroup$
  • $\begingroup$ Could you please post your verbatim homework problem? There is some confusing phrasing in what you wrote about the “95% sure”, and it would help to see the original phrasing. $\endgroup$ – Dave Oct 19 at 11:32
  • $\begingroup$ Please add the [self-study] tag & read its wiki. $\endgroup$ – Stephan Kolassa Oct 19 at 11:46
  • $\begingroup$ @Dave I updated the wording of the problem. $\endgroup$ – Adam Jenssen Oct 19 at 11:56
  • $\begingroup$ @StephanKolassa added tag, read wiki, rephrased question! $\endgroup$ – Adam Jenssen Oct 19 at 12:01
  • $\begingroup$ In real life the knowledge "the company knows that .... " is more uncertain than the computation of the parkings needed. The answer below shows is a distribution with a mean of 100 and standard deviation of only about 7 (ie with the 95% confidence interval you are only gonna build in a 10% margin relative to the expected number of parking places needed). In addition, you'd need to build for the future requirements of parking places and not what is typical now. Also you need to look for the specific households that are gonna live in the appartments and not the average household. $\endgroup$ – Sextus Empiricus Oct 19 at 12:16
1
$\begingroup$

Here is one unnecessary way to approximate the answer to this question, using normal distributions.

The expected number of cars $X$ is $E[X]=0.25 \cdot 0+0.5 \cdot 1+0.25 \cdot 2=1$.

The standard deviation of $X$ is $SD[X]=\sqrt{(0-1)^2 \cdot 0.25+(1-1)^2 \cdot 0.5+(2-1)^2 \cdot 0.25}=\sqrt{0.5}=0.707$.

Using convolutions we can sum 100 such normal distributions to get the distribution of 100 households, which results in $Y=N(1 \cdot 100,\sqrt{0.5 \cdot 100})=N(100,\sqrt{50})$.

From here it is easy to estimate the 95 % right interval using the quantile function.

> qnorm(0.95,100,sqrt(50))
[1] 111.6309

And here is yet another way to approximate the answer using simulations (using R)

> sim=replicate(1e4,sum(sample(0:2,100,replace=T,prob=c(0.25,0.5,0.25))))
> quantile(sim,0.95)
95% 
112 
| cite | improve this answer | |
$\endgroup$
  • $\begingroup$ Why is it unnecessary? And also, since the number of cars (and spaces) are a discrete variable, isn't normal distributions off the table? $\endgroup$ – Adam Jenssen Oct 19 at 11:58
  • $\begingroup$ @AdamJenssen Yes, that's why I said this is an approximation. It's unnecessary in the sense that you do not need to do this, there are other more direct ways of getting to the solution. $\endgroup$ – user2974951 Oct 19 at 12:05
  • $\begingroup$ @AdamJenssen, the normal distribution can also be used to approximate the probability mass function of discrete distributions. It is in fact how it has been seen the first time in history (as an estimate for the binomial distribution that can have a very large number and becomes impractical to compute). In your case you can also compute it by applying a convolution 100 times. $\endgroup$ – Sextus Empiricus Oct 19 at 12:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.