# Sum of random variables tilted by Bernoullies

Let $$(X_i)_{i\in\mathbb{N}}$$ be a sequence of real valued i.i.d. random variables for which the following convergence in probability holds

$$\frac{1}{n}\sum_{i=1}^nX_i\stackrel{n\to\infty}{\longrightarrow}c,$$

where $$c\in\mathbb{R}.$$

Now consider a sequence $$(B_i)_{i\in\mathbb{N}}$$ of i.i.d. Bernoulli random variables in $$\{0,1\}$$ of parameter $$p.$$ I'm expecting that the following convergence in probability holds:

$$\frac{1}{n}\sum_{i=1}^nX_iB_i\stackrel{n\to\infty}{\longrightarrow}cp.$$

Any idea how to prove it?

• Do you mean for the sums to be scaled by $n^{-1}$? Otherwise, if $X_i$ are i.i.d. with mean $\mu$ and variance $\sigma^2$, then the first sum has mean $n\mu$ and variance $n \sigma^2$, which cannot converge in any sense unless $X_i = 0$ a.s. – Tom Chen Mar 11 at 16:11
• Yes sorry I forgot the rescaling factor – bojica Mar 11 at 16:18

• If $$X_1$$ is integrable, then it follows from the strong law of large numbers that $$c = \mathbb{E}(X_1)$$. Since the iid random variables $$X_i B_i$$ are clearly also integrable, another application of the strong law of large numbers yields $$\frac{1}{n} \sum_{i=1}^n X_i B_i \to \mathbb{E}(X_1 B_1) = \mathbb{E}(X_1) \mathbb{E}(B_1) = cp \quad \text{a.s.}$$
• If $$\frac{1}{n} \sum_{i=1}^n X_i$$ converges almost surely to $$c$$, then it follows from the converse of the strong law of large numbers that $$\mathbb{E}(|X_1|)< \infty$$ (see e.g. this question). Hence, we can reason as in the first remark to obtain the desired convergence.

Now let's consider the general case. There is the following characterization of the weak law of large numbers which can be, for instance, found in the book by Kallenberg (Theorem 4.4.16).

Theorem: Let $$(\xi_i)_{i \geq 1}$$ be a sequence of iid random variables and let $$c \in \mathbb{R}$$. Then $$n^{-1} \sum_{i=1}^n \xi_i \to c$$ in probability if, and only if, $$r \mathbb{P}(|\xi_1| > r) \xrightarrow[]{r \to \infty} 0 \quad \text{and} \quad \mathbb{E}(\xi_1 1_{\{|\xi_1| \leq r\}}) \xrightarrow[]{r \to \infty} c.$$

Let $$(X_i)_i$$ be a sequence of iid random variables such that

$$\frac{1}{n} \sum_{i=1}^n X_i \to c \quad \text{in probability}$$ for some $$c \in \mathbb{R}$$, and let $$(B_i)_{i \geq 1}$$ be an independent sequence of iid Bernoulli random variables. Applying the theorem we get $$\mathbb{P}(|X_1|>r) \xrightarrow[]{r \to \infty} 0 \quad \text{and} \quad \mathbb{E}(|X_1| 1_{|X_1| \leq r}) \xrightarrow[]{r \to \infty} c.$$ Since $$B_1$$ takes only the values $$0$$ and $$1$$ we find that $$\xi_1 := X_1 B_1$$ satisfies

$$\mathbb{P}(|\xi_1| > r) \leq \mathbb{P}(|X_1|>r) \xrightarrow[]{r \to \infty} 0.$$

On the other hand, we have

\begin{align*}\mathbb{E}(\xi_1 1_{\{|\xi_1| \leq r\}}) &= \mathbb{E}(X_1 1_{\{|X_1| \leq r\}} 1_{\{B_1=1\}}) \\ &= \mathbb{E}(X_1 1_{\{|X_1| \leq r\}}) \mathbb{P}(B_1=1)\\ &\xrightarrow[]{r \to \infty} cp. \end{align*}

Applying the above theorem for $$\xi_i := X_i B_i$$, we conclude that

$$\frac{1}{n} \sum_{i=1}^n X_i B_i \xrightarrow[]{n \to \infty} cp \quad \text{in probability}.$$

Suppose $$X_i$$ have mean $$\mu$$ and variance $$\sigma^2$$. By i.i.d. of $$X_i$$, we must have $$\overline{X}$$ have mean $$\mu$$ and variance $$\sigma^2/n$$. But $$\overline{X}$$ converges to $$c$$ itself, so $$\mu = c$$. Then by the (weak) law of large numbers, \begin{align*} \frac{1}{n}\sum_{i=1}^{n}X_i B_i \overset{\mathcal{P}}{\rightarrow} \mathbb{E}[X_1 B_1] = \mathbb{E}[X_1] \mathbb{E}[B_1] = cp \end{align*}

• What if $X_i$ doesn't have finite mean/variance? As far as I can see, the OP doesn't make any such integrability assumptions – saz Mar 11 at 16:28
• If $X_i$ doesn't have finite mean nor variance, then neither does $\overline{X}$. However, we are given that $\overline{X}$ converges to a real number, so it must be the case we can assume finite mean and variance? – Tom Chen Mar 11 at 16:30
• No, that's not true. If $n^{-1} \sum_{i=1}^n X_i$ converges almost surely, then $X_i$ has finite mean (that's not obvious, but it's true anyway). However, if $n^{-1} \sum_{i=1}^n X_i$ converges only in probability, we cannot conclude that $X_i$ has finite mean, see e.g. this question (in particular the comment by @Did). – saz Mar 11 at 16:34
• What can we say if we remove the i.i.d condtion of the sequence $(X_i)_{i\in\mathbb{N}}$? – bojica Mar 11 at 16:56
• @TomChen You misunderstand Did's comment. Define a distribution $\mu$ by $$\mu:= \sum_{k \in \mathbb{Z} \backslash \{0\}} \frac{c}{k^2 \log(|k|)} \delta_k$$ where $\delta_k$ denotes the Dirac measure at $k$ and $c$ is a normalizing constant such that $\mu(\mathbb{R})=1$. What Did is saying that if $(X_i)$ is an iid sequence with $X_i \sim \mu$, then $(X_i)_i$ satisfies the WLLN but not the SLLN. – saz Mar 11 at 22:07