19th Ave New York, NY 95822, USA

# 统计代写|Sample spaces and Pebble World stat 代写

## 统计代考

The mathematical framework for probability is built around sets. Imagine that an experiment is performed, resulting in one out of a set of possible outcomes. Before the experiment is performed, it is unknown which outcome will be the result; after, the result “crystallizes” into the actual outcome.

Definition 1.2.1 (Sample space and event). The sample space $S$ of an experiment is the set of all possible outcomes of the experiment. An event $A$ is a subset of the sample space $S$, and we say that $A$ occurred if the actual outcome is in $A$.

The sample space of an experiment can be finite, countably infinite, or uncountably infinite (see Section A.1.5 of the math appendix for an explanation of countable and uncountable sets). When the sample space is finite, we can visualize it as Pebble World, as shown in Figure 1.1. Each pebble represents an outcome, and an event is a set of pebbles.

Performing the experiment amounts to randomly selecting one pebble. If all the pebbles are of the same mass, all the pebbles are equally likely to be chosen. This special case is the topic of the next two sections. In Section $1.6$, we give a general definition of probability that allows the pebbles to differ in mass.

Set theory is very useful in probability, since it provides a rich language for express-ing and working with events; Section A.1 of the math appendix provides a review of set theory. Set operations, especially unions, intersections, and complements, make it easy to build new events in terms of already-defined events. These concepts also let us express an event in more than one way; often, one expression for an event is much easier to work with than another expression for the same event.

For example, let $S$ be the sample space of an experiment and let $A, B \subseteq S$ be events. Then the union $A \cup B$ is the event that occurs if and only if at least one of $A, B$ occurs, the intersection $A \cap B$ is the event that occurs if and only if both $A$ and $B$ occur, and the complement $A^{c}$ is the event that occurs if and only if $A$ does not occur. We also have $D e$ Morgan’s laws:
$$(A \cup B)^{c}=A^{c} \cap B^{c} \text { and }(A \cap B)^{c}=A^{c} \cup B^{c},$$
since saying that it is not the case that at least one of $A$ and $B$ occur is the same as saying that $A$ does not occur and $B$ does not occur, and saying that it is not the case that both occur is the same as saying that at least one does not occur. Analogous results hold for unions and intersections of more than two events.

In the example shown in Figure 1.1, $A$ is a set of 5 pebbles, $B$ is a set of 4 pebbles, $A \cup B$ consists of the 8 pebbles in $A$ or $B$ (including the pebble that is in both), $A \cap B$ consists of the pebble that is in both $A$ and $B$, and $A^{c}$ consists of the 4 pebbles that are not in $A$.

The notion of sample space is very general and abstract, so it is important to have some concrete examples in mind.

Example 1.2.2 (Coin flips). A coin is flipped 10 times. Writing Heads as $H$ and Tails as $T$, a possible outcome (pebble) is HHHTHHTTHT, and the sample space is the set of all possible strings of length 10 of $H$ ‘s and $T$ ‘s. We can (and will) encode $H$ as 1 and $T$ as 0 , so that an outcome is a sequence $\left(s_{1}, \ldots, s_{10}\right)$ with $s_{j} \in{0,1}$, and the sample space is the set of all such sequences. Now let’s look at some events:

1. Let $A_{1}$ be the event that the first flip is Heads. As a set,
$$A_{1}=\left{\left(1, s_{2}, \ldots, s_{10}\right): s_{j} \in{0,1} \text { for } 2 \leq j \leq 10\right}$$
This is a subset of the sample space, so it is indeed an event; saying that $A_{1}$ occurs is the same thing as saying that the first flip is Heads. Similarly, let $A_{j}$ be the event that the $j$ th flip is Heads for $j=2,3, \ldots, 10$.
2. Let $B$ be the event that at least one flip was Heads. As a set,
$$B=\bigcup_{j=1}^{10} A_{j} .$$
3. Let $C$ be the event that all the flips were Heads. As a set,4. Let $D$ be the event that there were at least two consecutive Heads. As a set,
$$D=\bigcup_{j=1}^{9}\left(A_{j} \cap A_{j+1}\right)$$
Example 1.2.3 (Pick a card, any card). Pick a card from a standard deck of 52 cards. The sample space $S$ is the set of all 52 cards (so there are 52 pebbles, one for each card). Consider the following four events:
• A: card is an ace.
• B: card has a black suit.
• $D$ : card is a diamond.
• $H$ : card is a heart.
As a set, $H$ consists of 13 cards:
{Ace of Hearts, Two of Hearts, …, King of Hearts $}$.
We can create various other events in terms of the events $A, B, D$, and $H$. Unions, intersections, and complements are especially useful for this. For example:
• $A \cap H$ is the event that the card is the Ace of Hearts.
• $A \cap B$ is the event {Ace of Spades, Ace of Clubs $} .$
• $A \cup D \cup H$ is the event that the card is red or an ace.
• $(A \cup B)^{c}=A^{c} \cap B^{c}$ is the event that the card is a red non-ace.
Also, note that $(D \cup H)^{c}=D^{c} \cap H^{c}=B$, so $B$ can be expressed in terms of $D$ and $H$. On the other hand, the event that the card is a spade can’t be written in terms of $A, B, D, H$ since none of them are fine-grained enough to be able to distinguish between spades and clubs.

There are many other events that could be defined using this sample space. In fact, the counting methods introduced later in this chapter show that there are $2^{52} \approx 4.5 \times 10^{15}$ events in this problem, even though there are only 52 pebbles.
What if the card drawn were a joker? That would indicate that we had the wrong sample space; we are assuming that the outcome of the experiment is guaranteed to be an element of $S$.

As the preceding examples demonstrate, events can be described in English or in set notation. Sometimes the English description is easier to interpret while the set notation is easier to manipulate. Let $S$ be a sample space and $s_{\text {actual }}$ be the actual outcome of the experiment (the pebble that ends up getting chosen when the experiment is performed). A mini-dictionary for converting between English and sets is given on the next page. 统计代写|A sample space as Pebble World, with two events $A$ and $B$ spotlighted.

## 统计代考

$$(A \cup B)^{c}=A^{c} \cap B^{c} \text { 和}(A \cap B)^{c}=A^{c} \cup B^{c },$$

1. 让 $A_{1}$ 成为第一次翻转是正面的事件。作为一套，
$$A_{1}=\left{\left(1, s_{2}, \ldots, s_{10}\right): s_{j} \in{0,1} \text { for } 2 \列克 j \列克 10\右}$$
这是样本空间的一个子集，所以它确实是一个事件；说 $A_{1}$ 发生与说第一个翻转是正面是一样的。类似地，假设 $A_{j}$ 是第 $j$ 次翻转是正面 $j=2,3, \ldots, 10$ 的事件。
2. 假设 $B$ 是至少一次翻转是正面的事件。作为一套，
$$B=\bigcup_{j=1}^{10} A_{j} 。$$
3. 假设 $C$ 是所有翻转都是正面的事件。作为一组，4。假设 $D$ 是至少有两个连续正面的事件。作为一套，
$$D=\bigcup_{j=1}^{9}\left(A_{j} \cap A_{j+1}\right)$$
例 1.2.3（选一张牌，任意一张牌）。从一副标准的 52 张牌中挑选一张牌。样本空间 $S$ 是所有 52 张卡片的集合（因此有 52 个鹅卵石，每张卡片一个）。考虑以下四个事件：
• 答：卡是王牌。
• B：卡有黑色西装。
• $D$：卡是钻石。
• $H$：卡片是一颗心。
作为一组，$H$ 由 13 张牌组成：
{红心王牌，红心二，…，红心王$}$。
我们可以根据事件 $A、B、D$ 和 $H$ 创建各种其他事件。并集、交集和补集对此特别有用。例如：
• $A \cap H$ 是卡片是红桃 A 的事件。
• $A \cap B$ 是事件 {黑桃 A，梅花 A $} .$
• $A \cup D \cup H$ 是牌是红色或 A 的事件。
• $(A \cup B)^{c}=A^{c} \cap B^{c}$ 是卡片是红色非 A 的事件。
另外，请注意 t