Homework 1

CHE 116: Numerical Methods and Statistics

Version 1.0 (1/17/2020)


1. Probability

The probability of an event or element in a sample space is written as $P(A)$, where $A$ is the event or element in the sample space. Answer the following problems symbolically and simplified.

  1. [2 points] Our sample space contains three elements: $Q = \{1, 2, 3\}$. What is the probability of observing $P(1 \,\textrm{OR} \,2\, \textrm{OR}\, 3)$?

  2. [2 points] What is the key differnce between $B_1$ and $B_2$ in these two expressions: $P( A \,\textrm{OR} \,B_1)$ and $P(A \,\textrm{AND}\, B_2)$ aside from the fact that OR is in the first expression and AND in the second.

  3. [2 points] Consider the sample space of days in 2020 and assume each day has equal probability. If event $E$ is elements $\{\textrm{September 3rd}, \textrm{October 24th}, \textrm{December 13th}\}$, then what is the probability of the event $E$, $P(E)$?

  4. [2 points] What is the probability of not event $E$ from the previous question?

  5. [2 points] What is the probability of observing September 3rd and then September 4th?

  6. [4 points] State the number of observations/samples for the probabilities specified in questions 1.3-1.5.

Die Probability

You are rolling a die with 6 sides. Event $A$ is that you roll a 4. Event $B$ is that you roll a $6$. Event $C$ is rolling a number greater than 2. Answer these problems using python code. Each problem is worth 1 point.

  1. [1 point] What is the probability of event $A$?
  2. [1 point] If you roll a 4, what is then the probability of rolling event $A$ or $C$ on your next roll?
  3. [2 points] What is the probability of rolling event $A$ and event $C$ in the course of two rolls?
  4. [2 points] If you roll event $A$, on your next roll what is the probability of event $A$?
  5. [2 points] What is the probability of rolling event $A$ followed by event $B$?
  6. [4 points] What is the probability of having event $A$ occur within 10 rolls?

3. Sample Spaces

Answers these problems symbolically

  1. [1 point] What could the sample space be for number of foxes on campus?
  2. [2 points] Each day I come to lecture with at most three whiteboard markers and each marker has ink or is out of ink. What is the sample space?
  3. [1 point] You are trying to guess a 10 digit phone numebr. What's the sample space size?
  4. [1 point] You have an 8 character password which can contain lowercase letters, uppercase letters, numbers, and 6 symbols (e.g., %, \$, !). What's the size of the sample space size?
  5. [1 point] You double the length of your password. What's the size of the sample size now?
  6. [4 points] Many websites require having each of these characters (lowercase, uppercase, number). What is more effective, a 12 character password with only lowercase or an 8 character password requiring each of the extra classes?

4. Data Collection

Choose two random things to observe over the course of the semester. Record your data youself and you should end up with at least 10 observations per month. Examples could be: screen time per day, time it takes to get to class, number of people you eat lunch with, colors in your outfit, number of birds in a particular tree, temperature at 9am.

[8 points] write out the sample space of your two data and give an example of them.