Minimizing $\int_0^1|f'(t)|^2dt$ subject to $f(0)=0$ and $f(1)=1$. Say you want to minimize 
$$
\int_0^1 \!|f'(t)|^2 \,dt,
$$
subject to $f(0)=0$ and $f(1)=1$, amongst infinitely differentiable functions. Is this even possible? My guess is the minimizing function $f(x)=x$.
My line of thinking...
A function $f$ minimizes $\int_0^1|f'(t)|^2\,dt$ iff it minimizes $\int_0^1 (1+|f'(t)|^2)\, dt$, iff it minimizes $\int_0^1\sqrt{1+|f'(t)|^2}\,dt$. Since this last expression is the arc length formula, the question is equivalent to finding the shortest continuous function from $(0,0)$ to $(1,1)$, which is just $f(x)=x$, and this is the unique function which minimizes the integral.
Is this line of reasoning sound? Maybe I overlooked some subtlety. 
 A: Equivalently, you're looking for a smooth function $g$ such that $\int_0^1 g(t)\,dt=1$ and such that $\int_0^1 g(t)^2\,dt$ is minimal in this class of functions (then $f$ is the primitive function of $g$ s.t. $f(0)=0$). Writing $g(t)=1+h(t)$, where now $\int_0^1 h(t)\,dt=0$, we want to minimize $\int_0^1(1+h(t))^2dt=\int_0^1(1+2h(t)+h(t)^2)dt=1+\int h(t)^2\,dt$, and there is clearly the unique minimum for $h=0$. So we have $g(t)=1$ and $f(t)=t$.
A: Alternatively, you can apply integral Cauchy-Schwarz
which is $\int_0^1 h^2(x)dx\cdot\int_0^1 g^2(x)dx\ge \left(\int_0^1 h(x)g(x)dx\right)^2$ for $h(x)=f'(x)$ and $g(x)=1$ to get
$$\int_0^1 f'^2(x)dx\cdot\int_0^1 1 dx\ge \left(\int_0^1 f'(x)dx\right)^2=(f(1)-f(0))^2=1.$$
Equality holds when $f'(x)=const$ almost everywhere which together with boundary conditions implies that $f(x)=x.$
A: You can try the calculus of variation. See Euler–Lagrange equation.
A: Following Mhenni et al.'s suggestion: The Euler-Lagrange equations say that for a functional $F(x, y, y')$ to be minimized, the equation 
$\frac{\partial F}{\partial y} - \frac{d}{dx}(\frac{\partial F}{\partial y'}) = 0$
must be satisfied.  For $F = |y'|^2$, for positive y we have:
$\frac{d}{dx}(2y') = 0 \implies y' = C_1 \implies y = C_1x + C_2$. 
The conditions $y(0) = 0$ and $y(1) = 1$  give the solution $y = x$.
