# Functional Derivative, Calculus of Variations

$$R[\alpha(x,y)] = \left[ (y-\alpha(x,y)x)^2 + c\left(\frac{\partial \alpha(x,y)x}{\partial y}\right)_+\right]$$

$$c > 0$$

I would like to find the function $$\alpha(x,y)$$ which minimizes $$R$$. As additional information I know that $$R$$ is always greater than or equal to 0. I think this is a subject of calculus of variations, which I have no clue about.

I found the Functional Derivative article on Wikipedia.

https://en.wikipedia.org/wiki/Functional_derivative

Am I on the right track? Which rule should be applied here?

For example $$\alpha(x,y) = \frac{y}{x}$$ is a possible candidate function, but it only minimizes the first term (the square) but not both terms (square and the partial derivative) simultaneously. In this scenario $$R = 0 + c = c$$ assuming $$x \ne 0$$. If I try functions with predefined structure like $$\alpha(x,y) = m\frac{y}{x}$$ and solve for $$m$$ then it is easy, but I would like to find the best minimizing function not one with a particular structure (analytically, if not numerically for a particular $$x$$ and $$y$$).

Above is a simplified version of the following, which I plan to solve once I understand the simple one. I am also OK to start without the positive part requirement for the derivative term, in order not to introduce discontinuity. I just would like to have some kickstart for the derivations.

$$R[\alpha(x,y)] = \left[ (y-f(\alpha(x,y),x))^2 + c\left(\large\frac{\partial f(\alpha(x,y),x)}{\partial y}\right)_+\right]$$

• Is $R$ a function of not only $\alpha$ but also of $x$ and $y$? Do you want to find $\alpha$ that minimizes $R$ for given $x$ and $y$? – md2perpe Oct 24 '18 at 20:36
• Normally in calc of variation you would be looking to find $\alpha$ which minimises R integrated over x and y, subject to appropriate boundary conditions. In what you have you could set R=some large negative constant and treat it as a differential equation in $\alpha$ – user121049 Oct 25 '18 at 8:45
• I am not sure what you mean by a minimum of R. It could take on different values at every x & y. You could possibly arrange that R is very small at some point but at the cost of being large somewhere else. Do you mean average of R over the domain of x & y? Also what do x & y range over and is R fixed on the boundary? – user121049 Oct 25 '18 at 10:29
• Let me point it out. Say e.g. $x_0=y_0=1$. So you want to minimize $R$ at $(1,1)$ and do not care for values of $R$ at other $(x,y)$, right? This is what you say above. This is a simple interpolation where $R$ at that point can be made $0$. For example, pick $$\alpha(x,y)=\frac{y_0}{x_0}+(y-y_0)^2.$$ – A.Γ. Oct 26 '18 at 6:40
• Why not? $y_0$ is simply a constant, e.g. if $x_0=y_0=1$ then $\alpha(x,y)=1+(y-1)^2$. Could you provide more information on the problem? – A.Γ. Oct 26 '18 at 7:16

Too long for a comment so I write as an answer. I am just taking another guess at what you want. Let's guess that for the right choice of $$\alpha$$, $$R(x,y)=r$$ i.e. a constant everywhere. Also note in your simple example you can scale $$x$$ away so write $$z=x \alpha$$.
The equation becomes $$c \frac{dz}{dy} + (y-z)^2=r$$. Being lazy I've asked Wolfram Alpha to solve this for me. https://www.wolframalpha.com/input/?i=Solve+(y-+a(y))%5E2+%2B+c++da(y)%2Fdy+%3D+r
Let me call $$b=\sqrt{\frac{r-c}{c^2}}$$
Then $$\alpha(x,y)=\frac{z}{x}=\frac{c b +y}{x} -\frac{b c}{x(b k \exp{(2 b y)} - 1)}$$
Now the integration constant $$k$$ can depend on $$x$$, i.e. $$k(x)$$ and should be fixed by any boundary conditions you may have.
For $$b$$ to be real then $$r\geq c$$. When $$r=c$$ then $$b=0$$ and hence $$\alpha=\frac{y}{x}$$ as you already have. So the minimum value of $$r$$ and hence $$R$$ is given by the solution you already have.