$n$th Mathematics Blog

A place where I write about math-related topics

Product of an Infinite Series

| Comments

Recently, I came across a problem that was asking for a way to calculate the infinite product of $1\cdot 2\cdot 3\cdot 4\cdot\ldots$. At first glance I thought there wasn’t an answer to this since the sequence diverges. However, there is a way to calculate this product and in this post I will show just that. However, it is arguable whether this is really calculating the product.

First note that

$$\prod_{n=1}^{\infty}n=\exp\left[\log\left(\prod_{n=1}^{\infty}n\right)\right]=\exp\left(\sum_{n=1}^{\infty}\log{n}\right)$$ Now, notice that $$\zeta’(s)=\frac{d}{ds}\sum_{n=1}^{\infty}n^{-s}=\sum_{n=1}^{\infty}\frac{d}{ds}n^{-s}=\sum_{n=1}^{\infty}-n^{-s}\log{n}=-\sum_{n=1}^{\infty}n^{-s}\log{n}$$ At $s=0$, $$\zeta’(0)=-\sum_{n=1}^{\infty}\log{n}$$ $$\therefore \exp\left(\sum_{n=1}^{\infty}\log{n}\right)=\exp(-\zeta’(0))$$

Now what is $\sum_{n=1}^{\infty}\log{n}$?

Note that by Wallis’s formula, we have that: $$\frac{\pi}{2}=\prod_{n=1}^{\infty}\frac{(2n)^2}{(2n-1)(2n+1)}=\frac{2\cdot 2}{1\cdot 3}\cdot\frac{4\cdot 4}{3\cdot 5}\cdot\ldots$$ Now, consider this function: $$F(s)=\left(1-2^{1-s}\right)\zeta(s)=\frac 12 + \frac 12\sum_{n=1}^{\infty}(-1)^{n-1}\left(\frac{1}{n^s}-\frac{1}{(n+1)^s}\right)$$ $$\therefore F’(s)=2^{1-s}(\log{2})\zeta(s)+\left(1-2^{1-s}\right)\zeta’(s)=\frac 12\sum_{n=1}^{\infty}(-1)^n\left[\frac{\log{n}}{n^s}-\frac{\log(n+1)}{(n+1)^s}\right]$$ Note that $\zeta(0)=-\frac{1}{2}$, then at $s=0$: $$F’(0)=2(\log{2})\left(-\frac{1}{2}\right)+(1-2)\zeta’(0)=\frac 12\sum_{n=1}^{\infty}(-1)^n[\log{n}-\log(n+1)]$$ $$=\frac{1}{2}\log\left(\frac{2\cdot 2}{1\cdot 3}\cdot\frac{4\cdot 4}{3\cdot 5}\cdot\ldots\right)=\frac{1}{2}\log{\frac{\pi}{2}}$$ $$\therefore \zeta’(0)=-\frac{1}{2}\log{2\pi}$$

$$\therefore \prod_{n=1}^{\infty}n=\exp\left(\sum_{n=1}^{\infty}\log{n}\right)=\exp(-\zeta’(0))=\sqrt{2\pi}$$

General Solution for the Integral of $f^{-1}(x)$ in Terms of $f(x)$

| Comments

Note that $$\int f^{-1}(x)\,dx=\int 1\cdot f^{-1}(x)\,dx = x\cdot f^{-1}(x)-\int x\cdot (f^{-1})’(x)\,dx$$ $$=x\cdot f^{-1}(x)-\int \frac{x}{f’(f^{-1}(x))}\,dx$$

Now, we calculate $\int \frac{x}{f’f^{-1}(x)}\,dx$:

Let $F=\int f(x)\,dx$, and make the substitutions of $u=f^{-1}(x)\implies x=f(u)\implies dx=f’(u)\,du$. Therefore, we have transformed our integral to:

$$\int \frac{f(u)}{f’(u)}f’(u)\,du=F(u)=F(f^{-1}(x))$$

$$\therefore \int f^{-1}(x)\,dx = x\cdot f^{-1}(x)-F(f^{-1}(x))$$

Some Notes on Small and Large Prime Gaps

| Comments

Euclid proved that there are infinitely many primes. Denote $P_n$ as the $n$th prime number. $$P_1=2, P_2=3, P_3=5, \ldots$$ A prime gap is essentially $P_{n+1}-P_n$. The prime gap is odd only for $P_2-P_1=1$. After that it is always even, because after $P_1=2$, all primes are odd. The prime gaps give a sequence of even numbers. From this sequence, we can ask two questions. One question is ‘how small can $P_{n+1}-P_n$ be for large $n$?’ and the second is ‘how big can $P_{n+1}-P_n$ be for large $n$?’.

Small Prime Gaps:
Twin Prime Conjecture states that there are infinitely many pairs of primes with distance of $2$, i.e. $P_{n+1}-P_n=2$ infinitely often. On average, the prime gap increases logarithmically. However, we expect that the prime gap should return back to $2$ at some point. It had been proved that $P_{n+1}-P_n\le 70,000,000$ infinitely often. The Polymath project hosted by Terence Tao, resulted in improving this bound to $P_{n+1}-P_n\le 246$ infinitely often.

Large Prime Gaps:
Prime gap can by infinitely large. To prove this, look at the following consecutive string of numbers: $$n!+2,n!+3,n!+4,\ldots,n!+n$$ This is a string of composite numbers with length $n-1$. This implies that the primes to the left and right must have a gap of at least $n-1$ with any arbitrary $n$.
Prime Number Theorem tells us roughly how many primes there are up to a given level. Number of primes $\le x=\frac{x}{\log{x}}$. By the pigeonhole principle, among the primes $\le x$, there is a prime gap $P_{n+1}-P_n\ge\log{x}$ infinitely often, i.e. $P_{n+1}-P_n\ge\log{P_n}$ infinitely often. The best unconditional bound we know is: $$P_{n+1}-P_n\ll P_n^{0.55}$$ If we assume the Riemann Hypothesis, we can create the bound: $$P_{n+1}-P_n\ll P_n^{0.55}\log{P_n}$$ Cramer modeled the primes $\le x$ by a random subset of numbers $\le x$ of cardinality ~ $\frac{x}{\log{x}}$. We say that primes behave pseudorandomly, i.e. like a random set. Cramer conjectured that $P_{n+1}-P_{n}\ge c\log^2{P_n}$ infinitely often for a sufficiently small $c$. If $P_{n+1}-P_{n}\ge C\log^2{P_n}$, then finitely often for large $C$. However, not much progress has been made in this direction.
It had been shown by Westzynthius: $$P_{n+1}-P_n\gg\log{P_n}\frac{\log\log\log{P_n}}{\log\log\log\log{P_n}}$$ This was improved by Erdos: $$P_{n+1}-P_n\gg\log{P_n}\frac{\log\log{P_n}}{(\log\log\log{P_n})^2}$$ This was improved by Rankin: $$P_{n+1}-P_n\gg c\log{P_n}\frac{\log\log{P_n}(\log\log\log\log{n})}{(\log\log\log{P_n})^2}$$ In his first paper, Rankin let $c=\frac{1}{3}$. After that, people improved $c$, but could not come up with another bound.
The latest bound that we know of is: $$P_{n+1}-P_n\gg \log{P_n}\frac{\log\log{P_n}(\log\log\log\log{n})}{\log\log\log{P_n}}$$

Riemann Zeta Function: What Is $ζ(2n)$?

| Comments

Throughout this post, I will let $s:=2n$.

Recall from Calculus the Taylor Series for $\sin{x}$: $$\sin{x}=x-\frac{x^3}{3!}+\frac{x^5}{5!}-\ldots$$ Now divide both sides by $x$ to find the Taylor Series for $\frac{\sin{x}}{x}$: $$\frac{\sin{x}}{x}=1-\frac{x^2}{3!}+\frac{x^4}{5!}-\ldots$$

Throughout this post, I will let $s:=2n$.

Recall from Calculus the Taylor Series for $\sin{x}$: $$\sin{x}=x-\frac{x^3}{3!}+\frac{x^5}{5!}-\ldots$$ Now divide both sides by $x$ to find the Taylor Series for $\frac{\sin{x}}{x}$: $$\frac{\sin{x}}{x}=1-\frac{x^2}{3!}+\frac{x^4}{5!}-\ldots$$ Now, we need to find the zeroes of the sine function. Using trigonometry knowledge, recall that the zeroes occur when $x=k\pi\,\forall k\in\mathbb Z$. Therefore, we have the following factorization for $\frac{\sin{x}}{x}$: $$\frac{\sin{x}}{x}=\left(1-\frac{x}{\pi}\right)\cdot\left(1+\frac{x}{\pi}\right)\cdot\left(1-\frac{x}{2\pi}\right)\cdot\left(1+\frac{x}{2\pi}\right)\cdot\ldots=\left(1-\frac{x^2}{\pi^2}\right)\cdot\left(1-\frac{x^2}{2^2\pi^2}\right)\cdot\ldots$$ In a recent post I had proved this. This function, $\frac{\sin{x}}{x}$, is commonly referred to as Euler’s infinite product, and has a general formula: $$\frac{\sin{x}}{x} = \prod_{k=1}^{\infty} \left( 1 - \frac{x^2}{(k\pi)^{2}}\right) =\left(1-\frac{x^2}{\pi^2}\right)\cdot\left(1-\frac{x^2}{2^2\pi^2}\right)\cdot\ldots$$ Now, let us substitute $x=\pi s$: $$\implies \frac{\sin{\pi s}}{\pi s}=\left(1-s^2\right)\cdot\left(1-\frac{s^2}{2^2}\right)\cdot\ldots=\prod_{k=1}^{\infty}\left(1-\frac{s^2}{k^2}\right)$$ A simple trick we can use here, is to take the $\log$ of the product to make it a sum: $$\implies \log{\left(\frac{\sin{\pi s}}{\pi s}\right)}=\log{\left(\prod_{k=1}^{\infty}\left(1-\frac{s^2}{k^2}\right)\right)}=\sum_{k=1}^{\infty}\log{\left(1-\frac{s^2}{k^2}\right)}$$ $$\implies \log{\left(\sin{\pi s}\right)}=\log{\pi s}+\sum_{k=1}^{\infty}\log{\left(1-\frac{s^2}{k^2}\right)}$$ If we differentiate each side with respect to $s$, we will get: $$\pi\cdot\frac{\cos{\pi s}}{\sin{\pi s}}=\frac{1}{s}+\sum_{k=1}^{\infty}\frac{1}{\left({1-\frac{s^2}{k^2}}\right)}\cdot\left(-\frac{2s}{k^2}\right)$$ Now, multiply each side by $s$: $$\pi s\cdot\frac{\cos{\pi s}}{\sin{\pi s}}=1+\sum_{k=1}^{\infty}\frac{1}{\left({1-\frac{s^2}{k^2}}\right)}\cdot\left(-\frac{2s^2}{k^2}\right)$$ What do you notice on the LHS. You should notice that $\frac{\cos{\pi s}}{\sin{\pi s}}=\cot{\pi s}$. This implies: $$\pi s\cdot\frac{\cos{\pi s}}{\sin{\pi s}}=\pi s\cot{\pi s}$$ $$\implies \pi s\cot{\pi s}=1-2\displaystyle\sum_{k=1}^{\infty} \left[\left(1+\frac{s^2}{k^2}+\frac{s^4}{k^4}+\ldots\right)\left(\frac{s^2}{k^2}\right)\right]=1-2\sum_{k=1}^{\infty}\sum_{n=1}^{\infty} \left(\frac{s^2}{k^2}\right)^n$$ $$=1-2\displaystyle\sum_{n=1}^{\infty}\left(\frac{s^{2n}}{1^{2n}}+\frac{s^{2n}}{2^{2n}}+\ldots\right)=1-2\sum_{n=1}^{\infty} \zeta (2n)\cdot s^{2n}$$ Can we find some other way to represent $\pi s\cot{\pi s}$? A little knowledge of complex analysis is required beyond this point. Notice that we could do the following: $$\pi s\cot{\pi s}=\pi s \cdot \frac{\cos{\pi s}}{\sin{\pi s}}=\pi s\cdot \frac{e^{i\pi s}+e^{-i\pi s}}{2}\cdot\frac{2i}{e^{i\pi s}-e^{-i\pi s}}=\pi s i\cdot \frac{e^{i\pi s}+e^{-i\pi s}}{e^{i\pi s}-e^{-i\pi s}}$$ When we multiply both the numerator and the denominator by $e^{i\pi s}$: $$\pi s\cot{\pi s}=\pi s i \cdot \frac{e^{2i\pi s}+1}{e^{2i\pi s}-1}=i\pi s \cdot\frac{2i\pi s}{e^{2i\pi s}-1}$$ Now, we have to find the infinite series for $\frac{z}{e^z-1}$. Let us assume the following is an infinite series of $\frac{z}{e^z-1}$: $$\frac{z}{e^z-1}=\sum_{n=0}^{\infty}\frac{\beta_n z^n}{n!}$$ If we multiply each side by $e^z-1$, then by using the Taylor Series expansion for $\frac{e^z}{z}$: $$1=\sum_{n=0}^{\infty}\frac{\beta_n z^n}{n!}\sum_{n=0}^{\infty}\frac{z^n}{(n+1)!}$$ The Cauchy Product Formula states that: $$\left(\sum_{n=0}^{\infty}a_n\right)\left(\sum_{n=0}^{\infty}b_n\right)=\sum_{j=0}^{\infty}c_j, c_j=\sum_{k=0}^j{a_kb_{j-k}}$$ Therefore, $$1=\sum_{n=0}^{\infty}\frac{\beta_n z^n}{n!}\sum_{n=0}^{\infty}\frac{z^n}{(n+1)!}\implies 1=\sum_{j=0}^{\infty}\sum_{k=0}^j\frac{\beta_kz^j}{k!(j-k+1)!}$$ $$\implies 1=\displaystyle\sum_{j=0}^{\infty}\frac{1}{(j+1)!}\sum_{k=0}^{j} {\left(\begin{array}{c}j+1 \\k\end{array}\right)}\beta_kz^k$$ Since when $j=0$, $\beta=1$. This implies that the output is $1$. Therefore, the sum of all the other terms will be $0$. However this contradicts that fact that we set $z\ne 0$. Therefore, $$\displaystyle\sum_{k=0}^{j} {\left(\begin{array}{c}j+1 \\k\end{array}\right)}\beta_k=0$$ Since we know that $\beta_0=1$, we can find a realtion between all $\beta_k$, i.e. find all the terms of the sequence. This brings up another concept. These numbers are referred to as Bernoulli numbers. These numbers are of high importance in analysis and number theory. So now that we have found the infinite series of $\frac{z}{e^z-1}$, we can do the following: $$\pi s \cot{\pi s}=i\pi s +\frac{2i\pi s}{e^{2i\pi s}-1}=\pi i s + \sum_{n=0}^{\beta_n}\frac{\beta_n(2\pi i s)^n}{n!}$$ Since the cotangent function is an even function, this implies that the powers in the series expansion will all be even, i.e. $\beta_{2k+1}=0\,\forall k>0$. This gives us the following: $$\pi s \cot{\pi s}=\pi i s+\frac{\beta_0}{0!}+\frac{\beta_1(2\pi i s)}{1!}+\sum_{n=2}^{\infty}{\frac{\beta_n(2\pi i s)^n}{n!}}$$ Since we have $\beta_1=-0.5$: $$\pi s\cot{\pi s}=1+\sum_{n=1}^{\infty}\frac{\beta_{2n}(2\pi i s)^{2n}}{2n!}=1-2\sum_{n=1}^{\infty}-\frac{\beta_{2n}(2\pi i s)^{2n}}{2(2n!)}=1-2\sum_{n=1}^{\infty}\zeta(2n)s^{2n}$$ Therefore, $$-\frac{\beta_{2n}(2\pi i s)^{2n}}{2(2n!)}=\zeta(2n)s^{2n}\implies \zeta(2n)=(-1)^{n+1}\frac{\beta_{2n}2^{2n-1}\pi^{2n}}{2n!}$$

Riemann Zeta Function: What Is $ζ(2)$

| Comments

First, start off with the integral: $$\displaystyle I=\int _{ 0 }^{ \pi /2 }{ \ln(\cos(x))\, dx } $$

Now, we know that $\cos(x)=\frac{e^{ix}+e^{-ix}}{2}$

$$\Rightarrow I=\displaystyle \int _{ 0 }^{ \pi /2 }{ \ln\left(\frac { { e }^{ ix }+{ e }^{ -ix } }{ 2 } \right)\,dx } = \displaystyle \int _{ 0 }^{ \pi /2 }{ \ln\left(1+{ e }^{ 2ix }\right)\,dx } - \int _{ 0 }^{ \pi /2 }{ (\ln(2)+ix)\,dx } $$

Now, consider the taylor series expansion of $\ln(1+x)$:

$$\displaystyle I = \int _{ 0 }^{ \pi /2 }{ \sum _{ r=1 }^{ \infty }{ \frac { { (-1) }^{ r-1 } { e }^{ 2irx }}{ r } } \,dx } -\left(\frac{\pi \ln(2)}{2}+\frac{\pi^{2}i}{8}\right)\displaystyle $$ $$= \sum _{ r=1 }^{ \infty }{ \frac { { (-1) }^{ r-1 } }{ r } \int _{ 0 }^{ \pi /2 }{ { e }^{ 2irx }\,dx } } -\left(\frac{\pi \ln(2)}{2}+\frac{\pi^{2}i}{8}\right)\displaystyle $$ $$= \sum _{ r=1 }^{ \infty }{ \frac { { (-1) }^{ r-1 } \left({ e }^{ \pi ir }-1\right)}{ 2i{ r }^{ 2 } } } - \left(\frac{\pi \ln(2)}{2}+\frac{\pi^{2}i}{8}\right) $$

Now, ${e}^{\pi ir} = {(-1)}^{r}$, so:

$$\displaystyle I = \left(\sum _{ r=1 }^{ \infty }{ \frac { 1-{ (-1) }^{ r } }{ 2{ r }^{ 2 } } } \right)i - \left(\frac{\pi \ln(2)}{2}+\frac{\pi^{2}i}{8}\right)$$

Now we calculate the summation:

$$S=\left(1+\frac { 1 }{ { 3 }^{ 2 } } +\frac { 1 }{ { 5 }^{ 2 } } +\ldots\right)=\left(1+\frac { 1 }{ { 2 }^{ 2 } } +\frac { 1 }{ { 3 }^{ 2 } } +\frac { 1 }{ { 4 }^{ 2 } } +\ldots\right)-\left(\frac { 1 }{ { 2 }^{ 2 } } +\frac { 1 }{ { 4 }^{ 2 } } +\ldots\right)$$ $$=\left(1+\frac { 1 }{ { 2 }^{ 2 } } +\frac { 1 }{ { 3 }^{ 2 } } +\frac { 1 }{ { 4 }^{ 2 } } +\ldots\right)-\frac { 1 }{ 4 } \left(\frac { 1 }{ { 1 }^{ 2 } } +\frac { 1 }{ { 2 }^{ 2 } } +\ldots\right)=\left(\frac { 3 }{ 4 } \right)\left(1+\frac { 1 }{ { 2 }^{ 2 } } +\frac { 1 }{ { 3 }^{ 2 } } +\frac { 1 }{ { 4 }^{ 2 } } +\ldots\right)$$ $$=\left(\frac { 3 }{ 4 } \right)\zeta (2)$$

After we substitute $S$ into our integral we get:

$$I=\frac { -\pi \ln(2) }{ 2 } +\left(\frac { 3\zeta (2) }{ 4 } -\frac {\pi^{ 2 }}{ 8 } \right)i$$

Since the integral is real, the imaginary part of our integral is $0$:

$$\frac { 3\zeta (2) }{ 4 } =\frac { { \pi }^{ 2 } }{ 8 }\Rightarrow\zeta(2) = \frac{\pi^{2}}{6}$$

Product of Odd Factorials: Do They Exist?

| Comments

Case 1 ($n=1$): $$x_1!=1!\cdot3!=6=3!$$ Case 2 ($n=2$): $$x_2!=1!\cdot3!\cdot 5!=(1)\cdot(1\cdot 2\cdot 3)\cdot (1\cdot 2\cdot 3\cdot 4\cdot 5)=1\cdot 2\cdot 3\cdot 4\cdot 5\cdot 6=6!$$ Case 3 ($n=3$): $$x_3!=1!\cdot3!\cdot 5!\cdot 7!=(1)\cdot(1\cdot 2\cdot 3)\cdot (1\cdot 2\cdot 3\cdot 4\cdot 5) \cdot (1\cdot 2\cdot 3\cdot 4\cdot 5\cdot 6\cdot 7)$$ $$=1\cdot 2\cdot 3\cdot 4\cdot 5\cdot 6\cdot 7\cdot 8\cdot 9 \cdot 10=10!$$ Case 4 ($n=4$): $$x_4!=1!\cdot3!\cdot 5!\cdot 7!\cdot 9!$$ It is sufficient to say that: $$x_4!>11!\implies 11\mid x_4!$$ However: $$11 \mid 1!\cdot3!\cdot 5!\cdot 7!\cdot 9!$$ Case 5 ($n=5$): $$x_5!=1!\cdot3!\cdot 5!\cdot 7!\cdot 9!\cdot 11!$$ It is sufficient to say that: $$x_5!>13!\implies 13\mid x_5!$$ However: $$13 \mid 1!\cdot 3!\cdot 5!\cdot 7!\cdot 9!\cdot 11!$$ Case $n$ ($n \ge 6$): $$1!\cdot3!\cdot 5! \cdots (2n+1)!=x_{\ge 6}!$$ It is sufficient to say that: $$x_{\ge 6}!>(4n+2)!$$

Bertrand’s Postulate (should be a theorem) states that $\forall n>1, n< p< 2n$ for some prime, $p$. Generalizing this to our argument, we have the following: $$2n+1< p < 4n+2$$ $$\implies (2n+1)!< p!<(4n+2)!$$ $$\implies (2n+1)!< p!<(4n+2)!< x_{\ge 6}!$$ $$\implies p \mid x!$$ However, since $p!>(2n+1)!$, there exists no $p$ such that $p \mid x!$. Therefore, $p \mid x!$.

Proposition does not hold past $n=1,2,3$. So, no they do not exist.

Finding the Median Fibonacci Number

| Comments

Here I show how to find $F_{n+2}$, when given $F_{n}$ and $F_{n+4}$ in the Fibonacci sequence.

We can deduce that:

$$F_{n+4} = F_{n+3} + F_{n+2} = (F_{n+2} + F_{n+1}) + F_{n+2} = 2\cdot F_{n+2} + F_{n+1}$$


$$F_{n+2} = F_{n+1} + F_{n} \implies F_{n+1} = F_{n+2} - F_{n}$$

Therefore, $$F_{n+4} = 2\cdot F_{n+2} + (F_{n+2} - F_{n}) = 3\cdot F_{n+2} - F_{n}$$

$$\implies F_{n+2} = \frac{F_{n+4} + F_{n}}{3}$$