# Deducing Euler Equation

From Sydsaeter / Hammond (Further Mathematics for Economic Analysis, 2008, 2nd ed., p. 293):

$$\max \int\limits_{0}^T [N(\dot{x}(t)) + \dot{x}(t)f(x(t))] e^{-rt} dt$$ where N and f are $C^1$ functions, r and T positive constants, $x(0) = x_0$, and $x(T)=x_T$. Deduce the Euler Equation: $\frac{d}{dt} N'(\dot{x}) = r [N'(\dot{x} + f(x)]$

Now, first of all, I'm not really sure how to understand 'deduce' here. Does it mean that I should bring the equation into the general Euler-equation form

$$\frac{\delta F}{\delta x} = \frac{d}{dt} \frac{\delta F}{\delta \dot{x}}$$

?

If so, I end up with

$$\dot{x} e^{-rt} f'(x) = \frac{d}{dt} N'(\dot{x})$$

which doesn't look too promising.

Am I totally misunderstanding the task here, or is my derivative wrong? Thanks!

I think you did it wrong. The left side is correct. The right side is $\displaystyle\frac{d}{dt}[N'(\dot{x})+f(x)]e^{-rt}$ where $\displaystyle\frac{d}{dt}$ is being applied to the whole expression. This gives $\displaystyle e^{-rt}\frac{d}{dt}[N'(\dot{x})+f(x)]-re^{-rt}[N'(\dot{x})+f(x)]$, hence $\displaystyle \frac{d}{dt}[N'(\dot{x})+f(x)]-r[N'(\dot{x})+f(x)]=\dot{x}f'(x)$, and using chain rule on the left side, this is $\displaystyle \frac{d}{dt}N'(\dot{x})+\dot{x}f'(x)-r[N'(\dot{x})+f(x)]=\dot{x}f'(x)$, hence $\displaystyle \frac{d}{dt}N'(\dot{x})=r[N'(\dot{x})+f(x)]$
The estremals for the functional $F$ are the solution of the Euler--Lagrange equation which you have correctly written. It seems to me that you have erroneously computed $\dfrac{\delta F}{\delta\dot x}$. I have reported below my computations: $$\frac{\delta F}{\delta x}=\dot x f'(x)e^{-rt},$$
$$\frac{\delta F}{\delta\dot x}=(N'(\dot x)+f(x))e^{-rt},$$
$$\frac{d}{dt}\frac{\delta F}{\delta\dot x}=e^{-rt}\left(\frac{d}{dt} N'(\dot x)+f'(x)\dot x-rN'(\dot x)-rf(x)\right).$$
Therefore $$0=\frac{d}{dt}\frac{\delta F}{\delta\dot x}-\frac{\delta F}{\delta x}=e^{-rt}\left(\frac{d}{dt} N'(\dot x)-rN'(\dot x)-rf(x)\right).$$