# Thread: Unconstrained Optimization

1. ## Unconstrained Optimization

I'm getting $f_{xx}$ and $f_{yy}$ having opposite signs (-ve & +ve) for $f(x,y) = e^{5x^2-20x-9y^2-36y}$, I get point = (2, -2), and $f_x \left (i.e. \frac{\partial f}{ \partial x} \right ) = (10x - 20) \cdot e^{5x^2 -20x -9y^2 -36y}$

$f_{xx} = \frac{\partial (f_x)}{ \partial x}$

$= 10 \cdot e^{5x^2-20x-9y^2-36y} \{10 (x - 2)^2 + 1 \}$

at point 2, -2 , $f_{xx} = 10 \cdot e^{5 \cdot 4-40-36+72} \{10(2-2)^2 + 1 \}$

$= 10e^{16}$

$f_y (i.e. \frac{\partial f}{ \partial y})$

$= (-18y -36) \cdot e^{5x^2-20x-9y^2-36y}$

$f_{yy} = \frac{\partial (f_y)}{ \partial y}$

$f_{yy} = -18 \{[(y + 2) \cdot e^{5x^2-20x-9y^2-36y} \times (-18y -36)] + e^{5x^2-20x-9y^2-36y} \times 1 \}$

$f_{yy} = -18 \cdot e^{5x^2-20x-9y^2-36y} \{-18(y + 2)^2 + 1 \}$

$f_{yy} = -18 \cdot e^{5x^2-20x-9y^2-36y} (-18y^2 - 72y - 72 + 1 )$

$f_{yy} = -18 \cdot e^{5x^2-20x-9y^2-36y} (-18y^2 - 72y - 71 )$

at point 2,-2 $f_{yy} = -18 \cdot e^{5x^2-20x-9y^2-36y} (-18 \cdot 4 + 144 - 71 )$

$= -18e^{16}$

so $f_{xx} = 10 \cdot e^{16}$ and $f_{yy} = -18 \cdot e^{16}$ This gives a -ve sign for delta.

I was taught that $f_{xx}$ and $[f_{yy}$ should have the same sign but i'm not getting that here.

2. Originally Posted by ashura
I'm getting $f_{xx}$ and $f_{yy}$ having opposite signs (-ve & +ve) for $f(x,y) = e^{5x^2-20x-9y^2-36y}$, I get point = (2, -2), and $f_x \left (i.e. \frac{\partial f}{ \partial x} \right ) = (10x - 20) \cdot e^{5x^2 -20x -9y^2 -36y}$
You might make things easier for yourself with the observation that a local
maximum/minimum of $\exp(f(x,y))$ is also a local maximum/minimum of $f(x,y)$,
and a local maximum/minimum of $f(x,y)$ is also a local maximum/minimum
of $\exp(f(x,y))$

RonL

3. Originally Posted by ashura
I'm getting $f_{xx}$ and $f_{yy}$ having opposite signs (-ve & +ve) for $f(x,y) = e^{5x^2-20x-9y^2-36y}$, I get point = (2, -2), and $f_x \left (i.e. \frac{\partial f}{ \partial x} \right ) = (10x - 20) \cdot e^{5x^2 -20x -9y^2 -36y}$
It looks like (2,-2) is a saddle point to me. The attachment shows a plot of $g(x,y) = {5x^2-20x-9y^2-36y}$, from which you can see the saddle.

(In the plot red corresponds to the highest and blue the lowest values)

RonL

4. I also concluded that (2,-2) is a saddle point because delta(determinant = $f_{xx} \times f_{yy} = 10e^{16} \times (-18e^{16})$) is < 0. Can't find why $f_{xx}$ and $f_{yy}$ have different signs.

$g(x,y) = 5x^2 - 20x -9y^2 -36y$

$g_x = 10x -20$

$let g_x = 0$

$10x -20 = 0$

$x = \frac{20}{10} = 2$

$g_y = -18y - 36$

$let g_y = 0$

$-18y - 36 = 0$

$-18y = 36$

$y = -\frac{36}{18} = -2$

$f_{xx} = \frac {\partial f_x}{\partial x} = 10$

$f_{yy} = \frac {\partial f_y}{\partial y} = -18$

5. It seems that $f_{xx}$ and $f_{yy}$ don't have to be the same sign according to this site:

Where is the max, min or saddle point in f(x,y)=x<sup>2</sup>-y<sup>2</sup>?

So my solution could be correct.

6. Originally Posted by ashura
It seems that $f_{xx}$ and $f_{yy}$ don't have to be the same sign according to this site:

Where is the max, min or saddle point in f(x,y)=x<sup>2</sup>-y<sup>2</sup>?

So my solution could be correct.
If you look at the plot of the function you will see that a section through
the plot along the line y=-2, that the function has a minimum so the first
derivative wrt x, is zero at x=2, and the second derivative is positive.

If you look at the plot of the function you will see that a section through
the plot along the line x=2, that the function has a minimum so the first
derivative wrt y, is zero at y=-2, and the second derivative is negative.

That the first partials at a point are zero and the second have oposite signs
is guarantees that the point is a saddle point.

RonL

7. Thanks for the explanation, where can I get the grafting software?

8. Originally Posted by ashura
Thanks for the explanation, where can I get the grafting software?
You can get 2-D graphing software for free.
Free Software Downloads and Software Reviews - Download.com
(Spyware Free)

But I do not know if there are 3-D graphing software for free. They usually are expensive.

9. Originally Posted by ashura
Thanks for the explanation, where can I get the grafting software?
What I use is Euler, which is a data analysis language, which is probably too
complex for your needs.

RonL