# Exercise using the derivation of the Euler-Lagrange equation

Here is a exercice using the derivation of the Euler-Lagrange equation:

Here is the exercice:

For a given function $$f(x,u,u')$$ and constants $$K_1, K_2$$ minimize the functional using the Euler-Lagrange equation $$F(u) = \int_{a}^{b}f(x,u(x),u'(x))dx - K_1 \cdot u(b) - \frac{1}{2}K_2u^2(b)$$

\begin{align*} F(u + \varepsilon\phi) = &\int_{a}^{b}f(x,u(x) + \varepsilon\phi(x),u'(x) + \varepsilon\phi'(x))\:dx - \\ &- K_1 \cdot(u(b) + \varepsilon\phi(b)) - \frac{1}{2}K_2 \cdot (u(b) + \varepsilon\phi(b))^2 \tag{1}\\ 0 = \frac{d}{d\varepsilon}F(u + \varepsilon\phi)\Big|_{\varepsilon = 0} = &\int_{a}^{b}f_{u}(x,u(x),u'(x))\phi(x) + f_{u'}(x,u(x),u'(x))\phi'(x)\:dx \\ &- K_1 \cdot\phi(b) - K_2 u(b) \cdot \phi(b) \tag{2}\\ = &\int_{a}^{b}f_{u}(x,u(x),u'(x))\phi(x) - \frac{d}{dx}(f_{u'}(x,u(x),u'(x)))\phi(x)\:dx \\ &-f_{u'}(a,u(a),u'(a))\phi(a) + f_{u'}(b,u(b),u'(b))\phi(b) - K_1\cdot \phi(b) - K_2u(b)\cdot \phi(b)\tag{3} \\ \end{align*}

Here are my questions regarding this proof:

1. The expression $$0 = \frac{d}{d\varepsilon}F(u + \varepsilon\phi)\Big|_{\varepsilon = 0}$$ can be read as "the derivativ of $$F(u + \varepsilon\phi)$$ with respect to $$\varepsilon$$ at the point $$\varepsilon = 0$$ correct?

2. How $$- K_1 \cdot(u(b) + \varepsilon\phi(b))$$ in (1) becomes $$- K_1 \cdot\phi(b))$$ in (2). Why doesn't it become $$- K_1 \cdot u(b))$$

3. What is beeing done between (2) and (3)? Is it integration by parts?

2. Only the term linear in $$\varepsilon$$ contributes.
• thank you for your answers @Qmechanic which helped a lot. Regarding the question 2. what i still don't understand is why $-K_1 \cdot (u(b) \varepsilon \phi(b))$ becomes $-K_1 \cdot \phi(b)$ and not $-K_1 \cdot u(b)$ as $\varepsilon$ is $0$? – ecjb Dec 12 '18 at 22:37
• Differentiation of a term $-K_1 \cdot u(b) \varepsilon \phi(b)$ would lead to $-K_1 \cdot u(b) \phi(b)$. However, the term in your question (v4) is different. – Qmechanic Dec 13 '18 at 0:07