Solution (source code)

= Solution

Use the bilinear pairing $T_g(f)=\int_{\mathbb R^n}fg$, so the map $g\mapsto T_g$ is complex linear. With the sesquilinear convention $\int f\overline g$ the representing map would instead be conjugate linear. For <conjugate exponents> $p,q$, <Hölder's inequality> gives $|T_g(f)|\leq\|g\|_q\|f\|_p$. If $g\ne0$, take $v=|g|^{q-2}\overline g$, defined as zero where $g=0$. Then
$$
\int vg=\|g\|_q^q,\qquad \|v\|_p=\|g\|_q^{q/p},\qquad q-q/p=1.
$$
Consequently \b[$\|T_g\|=\|g\|_q$]. This also proves <injectivity> of the representation.

For <surjectivity>, let $\ell$ be a nonzero element of the <continuous dual space> of $L^p$ and choose $f_0$ with $\ell(f_0)=1$. Its kernel $K$ is a <closed linear subspace>. Use the allowed best-approximation fact to choose $h\in K$ and put $z=f_0-h$. Thus $\ell(z)=1$ and
$$
\Phi(k):=\int |z|^{p-2}\overline z\,k=0\quad(k\in K),\qquad \Phi(z)=\|z\|_p^p>0.
$$
For each $f$, the vector $f-\ell(f)z$ belongs to $K$. Therefore $\Phi(f)=\ell(f)\|z\|_p^p$, giving
$$
\boxed{\ell(f)=\int fg,\qquad g=\frac{|z|^{p-2}\overline z}{\|z\|_p^p}\in L^q,\qquad \|\ell\|=\|g\|_q.}
$$
Membership follows from $(p-1)q=p$; the zero functional is represented by zero. This proves the isometric isomorphism $(L^p(\mathbb R^n))^*\cong L^q(\mathbb R^n)$ without using a representation theorem as a substitute for the proof. It is the <closed-hyperplane proof of Lp duality>.