0
$\begingroup$

This should not be hard at all, in fact no one seems so be having my issue so it should be me missing out on a point of information or just experience.

My mission is to with Mathematica find the x,y,z's of the maximum points of the following function

$$\left[\frac{-\left(1-x^2\right) \left(y^2-4\right)-x^2-y^2+5}{\left(x^2+y^2+1\right)^2}\right]$$

Currently I am trying with Maximize

$Maximize[\left[\frac{-\left(1-x^2\right) \left(y^2-4\right)-x^2-y^2+5}{\left(x^2+y^2+1\right)^2}\right], {x,y,z}]$

image of the surface

I can't make heads or tails of this answer though, so I am doing something wrong.., finding the points for reference I did with wolfram.

Wolfram Alpha gives me the points

$$\left\{\pm\frac{1}{\sqrt{3}},0,\frac{9}{8}\right\}$$

How do I use for example maximize[] or some other simple function in Mathematica to find those values? I have set the partial derivatives to 0 and solved for the points, that works but seems to me to be overly complicated.

The documentation has me confused, it does this and gets three values, I try to do the same and I get something strange

Manual:

manual

My answer, which is to my eyes wrong:

my answer

Even if I try to use //NN I get strange answers:

strange answers

I kind of do get the x coordinate if I do this but why this is the case I don't know.

$Maximize[\left[\frac{-\left(1-x^2\right) \left(y^2-4\right)-x^2-y^2+5}{\left(x^2+y^2+1\right)^2}\right], {y,z}]$

I have also tried to use FindMaximum and FindMaxValue.

This baffles me, any ideas, it should be simple right? Why don't I get the points? is it because there are two extreme points perhaps?

$\endgroup$
2
  • $\begingroup$ People here generally like users to post code as Mathematica code instead of images or TeX, so they can copy-paste it. It makes it convenient for them and more likely you will get someone to help you. You may find this this meta Q&A helpful $\endgroup$
    – Michael E2
    Jun 13, 2016 at 11:36
  • $\begingroup$ Ok, cool, thanks Michael $\endgroup$
    – Celebrin
    Jun 13, 2016 at 14:03

1 Answer 1

1
$\begingroup$

I think it's only a question of accolades

Maximize[(-(1 - x^2) (y^2 - 4) - x^2 - y^2 + 5)/(x^2 + y^2 + 1)^2, {x,y}]

return

{9, {x -> 0, y -> 0}}

$\endgroup$
5
  • $\begingroup$ Hum, accolades?, "an award or an expression of praise" merriam webster. I do know the points already through wolfram, but I cant transfer that to mathematica since I dont have wolfPRO $\left\{+-\frac{1}{\sqrt{3}},0,\frac{9}{8}\right\}$ should be the solutions, what am I not getting from your answer? $\endgroup$
    – Celebrin
    Jun 13, 2016 at 10:29
  • 2
    $\begingroup$ @Celebrin Why not get the points through Mathematica instead of W|A? $\endgroup$
    – Michael E2
    Jun 13, 2016 at 11:39
  • $\begingroup$ Well that is what I hoped to do, and the question asked, . I have since calculated the points through partial derivatives.. but there should be an easier way. you got any idea Michael? $\endgroup$
    – Celebrin
    Jun 13, 2016 at 12:02
  • $\begingroup$ @Celebrin. I think cyrille means "brackets". You need to remove the internal square brackets and specify only the independent variables, x and y. $\endgroup$
    – m_goldberg
    Jun 13, 2016 at 13:02
  • $\begingroup$ In fact I think there is nothing wrong with Mathematica. Plot the function with PlotRange->{-1, 9.5}. You will find an absolute maximum. But there are also a number of local maxima and minima even some imaginary according to the solution by solving the system of derivatives. $\endgroup$ Jun 13, 2016 at 13:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.