[proofplan]
We compute each identity by direct algebraic manipulation of the Bernstein operator $B_n(g; x) = \sum_{k=0}^n g(k/n) \binom{n}{k} x^k (1-x)^{n-k}$. For $g = 1$, this is the [Binomial Theorem](/theorems/750). For $g = t$, we reduce the sum by extracting a factor of $k/n$ and re-indexing. For $g = t^2$, we split $k^2 = k(k-1) + k$, re-index twice, and recombine using the first two identities. The variance identity then follows by expanding $(k/n - x)^2$ and substituting the three moment computations.
[/proofplan]
[step:Compute $B_n(1; x)$ via the Binomial Theorem]
Define the Bernstein basis polynomials
\begin{align*}
b_{n,k}: [0,1] &\to [0,1] \\
x &\mapsto \binom{n}{k} x^k (1-x)^{n-k}
\end{align*}
for $k = 0, 1, \ldots, n$. By the [Binomial Theorem](/theorems/750) applied with $a = x$ and $b = (1-x)$,
\begin{align*}
B_n(1; x) = \sum_{k=0}^{n} b_{n,k}(x) = \sum_{k=0}^{n} \binom{n}{k} x^k (1-x)^{n-k} = (x + (1-x))^n = 1.
\end{align*}
[guided]
The Bernstein operator applied to the constant function $g = 1$ gives
\begin{align*}
B_n(1; x) = \sum_{k=0}^{n} 1 \cdot \binom{n}{k} x^k (1-x)^{n-k} = \sum_{k=0}^{n} \binom{n}{k} x^k (1-x)^{n-k}.
\end{align*}
This is precisely the binomial expansion of $(x + (1-x))^n$. By the [Binomial Theorem](/theorems/750), which states that $(a+b)^n = \sum_{k=0}^n \binom{n}{k} a^k b^{n-k}$ for all $a, b \in \mathbb{R}$ and $n \in \mathbb{N}$, we set $a = x$ and $b = 1 - x$ to obtain
\begin{align*}
B_n(1; x) = (x + (1-x))^n = 1^n = 1.
\end{align*}
This identity says that the Bernstein basis polynomials $\{b_{n,0}, b_{n,1}, \ldots, b_{n,n}\}$ form a partition of unity on $[0,1]$. Every subsequent identity builds on this fact.
[/guided]
[/step]
[step:Compute $B_n(t; x)$ by extracting a factor and re-indexing]
We evaluate $B_n(t; x) = \sum_{k=0}^n \frac{k}{n} \binom{n}{k} x^k (1-x)^{n-k}$. The $k = 0$ term vanishes. For $k \geq 1$, we use the binomial coefficient absorption identity $\frac{k}{n} \binom{n}{k} = \binom{n-1}{k-1}$, which follows from
\begin{align*}
\frac{k}{n} \cdot \frac{n!}{k!(n-k)!} = \frac{(n-1)!}{(k-1)!(n-k)!} = \binom{n-1}{k-1}.
\end{align*}
Substituting and setting $j = k - 1$ (so $j$ runs from $0$ to $n-1$),
\begin{align*}
B_n(t; x) &= \sum_{k=1}^{n} \binom{n-1}{k-1} x^k (1-x)^{n-k} \\
&= x \sum_{j=0}^{n-1} \binom{n-1}{j} x^j (1-x)^{(n-1)-j} \\
&= x \cdot (x + (1-x))^{n-1} = x,
\end{align*}
where the final equality uses the [Binomial Theorem](/theorems/750) with exponent $n-1$.
[guided]
We need to evaluate
\begin{align*}
B_n(t; x) = \sum_{k=0}^{n} \frac{k}{n} \binom{n}{k} x^k (1-x)^{n-k}.
\end{align*}
The $k = 0$ term contributes $\frac{0}{n} \cdot \binom{n}{0} (1-x)^n = 0$, so the sum effectively starts at $k = 1$. The strategy is to simplify the coefficient $\frac{k}{n}\binom{n}{k}$ using an algebraic identity. Writing out the factorials explicitly:
\begin{align*}
\frac{k}{n} \binom{n}{k} = \frac{k}{n} \cdot \frac{n!}{k!(n-k)!} = \frac{n!}{n \cdot (k-1)! \cdot (n-k)!} = \frac{(n-1)!}{(k-1)!(n-k)!} = \binom{n-1}{k-1}.
\end{align*}
This is the absorption identity for binomial coefficients. With this substitution,
\begin{align*}
B_n(t; x) = \sum_{k=1}^{n} \binom{n-1}{k-1} x^k (1-x)^{n-k}.
\end{align*}
We re-index by setting $j = k - 1$. When $k = 1$, $j = 0$; when $k = n$, $j = n - 1$. Also $x^k = x^{j+1} = x \cdot x^j$ and $(1-x)^{n-k} = (1-x)^{(n-1)-j}$. The sum becomes
\begin{align*}
B_n(t; x) = x \sum_{j=0}^{n-1} \binom{n-1}{j} x^j (1-x)^{(n-1)-j}.
\end{align*}
By the [Binomial Theorem](/theorems/750) applied with $a = x$, $b = 1-x$, and exponent $n-1$, the inner sum equals $(x + (1-x))^{n-1} = 1$. Therefore $B_n(t; x) = x$.
This identity has a probabilistic interpretation: if $X_1, \ldots, X_n$ are independent Bernoulli random variables with parameter $x$, then $k/n$ is the sample mean and the Bernstein operator computes $\mathbb{E}[k/n] = x$, the population mean.
[/guided]
[/step]
[step:Compute $B_n(t^2; x)$ by splitting $k^2 = k(k-1) + k$]
We evaluate $B_n(t^2; x) = \sum_{k=0}^n \frac{k^2}{n^2} \binom{n}{k} x^k (1-x)^{n-k}$. We decompose
\begin{align*}
\frac{k^2}{n^2} = \frac{k(k-1)}{n^2} + \frac{k}{n^2}
\end{align*}
and handle each piece separately.
**First piece.** For $k \geq 2$, we use the double absorption identity
\begin{align*}
\frac{k(k-1)}{n^2} \binom{n}{k} = \frac{k(k-1)}{n^2} \cdot \frac{n!}{k!(n-k)!} = \frac{(n-1)}{n} \cdot \frac{(n-2)!}{(k-2)!(n-k)!} = \frac{n-1}{n} \binom{n-2}{k-2}.
\end{align*}
Setting $j = k - 2$,
\begin{align*}
\sum_{k=2}^{n} \frac{k(k-1)}{n^2} \binom{n}{k} x^k (1-x)^{n-k} &= \frac{n-1}{n} x^2 \sum_{j=0}^{n-2} \binom{n-2}{j} x^j (1-x)^{(n-2)-j} = \frac{n-1}{n} x^2,
\end{align*}
where the inner sum equals $1$ by the [Binomial Theorem](/theorems/750).
**Second piece.** We have $\sum_{k=0}^n \frac{k}{n^2} \binom{n}{k} x^k (1-x)^{n-k} = \frac{1}{n} B_n(t; x) = \frac{x}{n}$, using the identity from the previous step.
Combining:
\begin{align*}
B_n(t^2; x) = \frac{n-1}{n} x^2 + \frac{x}{n} = x^2 - \frac{x^2}{n} + \frac{x}{n} = x^2 + \frac{x(1-x)}{n}.
\end{align*}
[guided]
We need to evaluate
\begin{align*}
B_n(t^2; x) = \sum_{k=0}^{n} \frac{k^2}{n^2} \binom{n}{k} x^k (1-x)^{n-k}.
\end{align*}
The key idea is to decompose $k^2$ using the falling factorial: $k^2 = k(k-1) + k$. This decomposition is useful because each falling factorial power absorbs the corresponding number of factors from the binomial coefficient, reducing it to a lower-order binomial.
Dividing by $n^2$:
\begin{align*}
\frac{k^2}{n^2} = \frac{k(k-1)}{n^2} + \frac{k}{n^2}.
\end{align*}
**First piece: the $k(k-1)/n^2$ term.** The terms with $k = 0$ and $k = 1$ vanish (since $k(k-1) = 0$). For $k \geq 2$, we compute
\begin{align*}
\frac{k(k-1)}{n^2} \binom{n}{k} &= \frac{k(k-1)}{n^2} \cdot \frac{n!}{k!(n-k)!} = \frac{1}{n^2} \cdot \frac{n!}{(k-2)!(n-k)!}.
\end{align*}
We extract two factors from $n! = n(n-1)(n-2)!$:
\begin{align*}
\frac{1}{n^2} \cdot \frac{n(n-1)(n-2)!}{(k-2)!(n-k)!} = \frac{n-1}{n} \cdot \frac{(n-2)!}{(k-2)!((n-2)-(k-2))!} = \frac{n-1}{n} \binom{n-2}{k-2}.
\end{align*}
Setting $j = k-2$ (so $j$ runs from $0$ to $n-2$, $x^k = x^{j+2} = x^2 \cdot x^j$, and $(1-x)^{n-k} = (1-x)^{(n-2)-j}$):
\begin{align*}
\sum_{k=2}^{n} \frac{k(k-1)}{n^2} \binom{n}{k} x^k (1-x)^{n-k} = \frac{n-1}{n} x^2 \sum_{j=0}^{n-2} \binom{n-2}{j} x^j (1-x)^{(n-2)-j}.
\end{align*}
By the [Binomial Theorem](/theorems/750), the inner sum is $(x+(1-x))^{n-2} = 1$. So the first piece contributes $\frac{n-1}{n} x^2$.
**Second piece: the $k/n^2$ term.** This is $\frac{1}{n}$ times the sum $\sum_{k=0}^n \frac{k}{n} \binom{n}{k} x^k(1-x)^{n-k} = B_n(t;x) = x$ (from the previous step). So the second piece contributes $\frac{x}{n}$.
Combining:
\begin{align*}
B_n(t^2; x) = \frac{n-1}{n} x^2 + \frac{x}{n} = x^2 - \frac{x^2}{n} + \frac{x}{n} = x^2 + \frac{x - x^2}{n} = x^2 + \frac{x(1-x)}{n}.
\end{align*}
[/guided]
[/step]
[step:Derive the variance identity and the bound $1/(4n)$]
Expanding $(k/n - x)^2 = k^2/n^2 - 2x(k/n) + x^2$ and applying the Bernstein operator (which is linear in the function argument),
\begin{align*}
\sum_{k=0}^{n} \left(\frac{k}{n} - x\right)^2 b_{n,k}(x) &= B_n(t^2; x) - 2x \, B_n(t; x) + x^2 \, B_n(1; x) \\
&= \left(x^2 + \frac{x(1-x)}{n}\right) - 2x \cdot x + x^2 \cdot 1 \\
&= \frac{x(1-x)}{n}.
\end{align*}
For the upper bound, define the quadratic $q: [0,1] \to \mathbb{R}$, $q(x) = x(1-x)$. Then $q'(x) = 1 - 2x$, which vanishes at $x = 1/2$. Since $q(0) = q(1) = 0$ and $q(1/2) = 1/4$, the maximum of $q$ on $[0,1]$ is $1/4$. Therefore
\begin{align*}
\frac{x(1-x)}{n} \leq \frac{1}{4n}.
\end{align*}
[/step]