# 2022-05-23-Monday
Just watched https://www.youtube.com/watch?v=bOXCLR3Wric
Thanks for the problems, Grant!
## Problem 1
Take the derivative of both sides of
$
\frac{1}{1-x}=\sum_{n=0}^{\infty} x^{n}
$
How can you use this to compute the expected number of times you have to roll a fair six-sided die before seeing the number 1?
### Solution
Take derivative
$\left(\frac{1}{1-x}\right)^2=\sum_{n=1}^{\infty} n x^{n-1}$
Notice that if $x=\frac{5}{6}$ then the right side is proportional to a weighted average of rolls taken to see a one.
$
\begin{aligned}
\left(\frac{1}{1-\frac{5}{6}}\right)^2&=\sum_{n=1}^{\infty} n \left(\frac{5}{6}\right)^{n-1}\\
\frac16\left(\frac{1}{1-\frac{5}{6}}\right)^2&=\frac16\sum_{n=1}^{\infty} n \left(\frac{5}{6}\right)^{n-1}\\
\end{aligned}$
The $\frac16$ accounts for the $n^\text{th}$ roll, while all rolls before that should be non-ones, having probabilities $\frac56$ each time.
When simplified $\frac16\left(\frac{1}{1-\frac{5}{6}}\right)^2=\frac16(6)^2=\boxed6$
## Problem 2
Compute the sum
$
\sum_{k=0}^{n} 2^{k}\left(\begin{array}{l}n \\ k\end{array}\right)
$
(Hint, expand the expression $(1+x)^{n}$)
### Solution
Take the hint
$(1+x)^{n}=\sum_{k=0}^{n}x^k{n\choose k}$
allow $x=2$
$\boxed{3}=(1+2)^{n}=\sum_{k=0}^{n}2^k{n\choose k}$
## Problem 3
Let $f_{n}$ be the $n$th Fibonacci number, and consider the function
$
F(x)=\sum_{n=0}^{\infty} f_{n} \frac{x^{n}}{n !}
$
Explain why the differential equation $F^{\prime \prime}(x)=F^{\prime}(x)+F(x)$ is true.
For bonus points, solve this differential equation, and use it to find a closed-form expression for $f_{n}$
### Solution
## Problem 4
Suppose $f(x)=\sum_{n=0}^{\infty} a_{n} x^{n}$
What do the coefficients of $f(x) /(1-x)$ tell you?
### Solution
Let $g(x)=\frac{f(x)}{1-x}=\frac{\sum_{n=0}^{\infty} a_{n} x^{n}}{1-x}=\sum_{n=1}^{\infty} b_{n-1} x^{n-1}$
So that $b_nx^n(1-x)=b_nx^n-b_nx^{n-1}$
and $b_{n-1}x^{n-1}(1-x)=b_{n-1}x^{n-1}-b_{n-1}x^{n}$
Meaning $a_nx^n=b_nx^n-b_{n-1}x^{n}$