1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Graph drawing—Finding the points on a curve that are nearest to the origin

  1. Dec 15, 2017 #41

    Ray Vickson

    User Avatar
    Science Advisor
    Homework Helper

    No, you have made a number of serious errors.
    If ##x = c X - sY## and ##y = sX+cY##, with ##c = \cos \theta, s = \sin \theta##, then ##5(x^2+y^2) = 5(X^2+Y^2)## and ##6 x y = cs(6X^2-6Y^2) +6XY(c^2-s^2)##.
    The "##XY##" term is eliminated if ##c = s = 1/\sqrt{2}##, giving ##6xy = 3X^2 - 3Y^2##. Thus, ##F = 5(x^2+y^2)-6xy## ##= 5X^2+5Y^2-3X^2+3Y^2## ## = 2X^2 + 8Y^2.## The curve is ##2X^2 + 8Y^2 = 4##.
     
  2. Dec 17, 2017 #42
    $$2x^2+8y^2=4~\rightarrow~y^2=\frac{1}{2}-\frac{1}{4}x^2$$
    $$s^2=x^2+y^2=x^2+\frac{1}{2}-\frac{1}{4}x^2=\frac{3}{4}x^2+\frac{1}{2}$$
    $$s^2_{min}(x=0)=\frac{1}{4}~\rightarrow~s_{min}=\frac{1}{2}$$

    $$5(x^2+y^2)-6xy=4~\rightarrow~xy=\frac{5}{6}(x^2+y^2)-\frac{2}{3}$$
    $$\gamma (x^2 + y^2)=\gamma s^2 \geq (x^2 y^2 )^{\frac{1}{2}} = xy=\frac{5}{6}(x^2+y^2)-\frac{2}{3}$$
    $$\gamma s^2 \leq \frac{12}{5-6\gamma}$$
    It doesn't lead to anything.
    I tried an other thing:
    $$xy=\sqrt{x^2y^2}=\sqrt{ \left[ \frac{5}{6}(x^2+y^2)-\frac{2}{3} \right ]}^2=\left[ \frac{25}{36}(x^2+y^2)^2-\frac{20}{18}(x^2+y^2)+\frac{4}{9} \right]^{1/2} \leq \gamma(x^2+y^2)$$
    No where
     
  3. Dec 17, 2017 #43

    StoneTemplePython

    User Avatar
    Science Advisor
    Gold Member

    ##GM \leq AM## seems to be one of my favorite inequalities these days, so what I was thinking of was actually was

    your goal: minimize ##x^2+y^2 = LHS##. This is an equality, so the Left Hand Side (LHS) is minimized if and only if the Right Hand Side (RHS) is.

    ##RHS = \frac{4+6xy}{5} = \frac{4}{5} + \frac{6}{5}xy = constant + \frac{6}{5}xy##

    an additive constant is not directly important in optimization problems (another way to think about why they get mapped to zero by the derivative operator), so the RHS is minimized if and only if ##\frac{6}{5}xy## is minimized which is minimized if and only if ##xy## is minimized.

    Draw the picture and split cases into two.

    Top right and bottom left quadrants of your graph
    ##RHS = constant + \frac{6}{5}\big \vert xy \big \vert##

    the scaling is positive, so ##\frac{6}{5}\big \vert xy \big \vert \geq 0##

    Top left and bottom right quadrants
    ##RHS = constant + \frac{3}{5}\Big(-1*\big \vert 2 xy \big \vert\Big)##

    it's immediately apparent we want top left and bottom right quadrants, as we can scale the magnitude of ##\big \vert 2 xy \big \vert## by a negative number, and hence shrink the RHS.

    Goal: maximize ##\big \vert 2 xy \big \vert##. Apply ##GM \leq AM##

    ##\big \vert 2 xy \big \vert = 2\big \vert x \big \vert \big \vert y \big \vert \leq \big \vert x\big \vert^2 + \big \vert y\big \vert^2 = x^2 + y^2##

    with equality if and only if

    ## \big \vert x \big \vert= \big \vert y \big \vert ##

    and since we are in top left and bottom right quadrants, this means

    ##x = -y##
    - - - -
    edit: to be extra clear, the above tells us that for minimization we're dealing in top left or bottom right quadrant, and we have

    ##x^2 + y^2 = constant + \frac{3}{5}\Big(-1*\big \vert 2 xy \big \vert\Big) \geq constant - \frac{3}{5} (x^2 + y^2)##

    add ## \frac{3}{5} (x^2 + y^2)## to each side
    thus we have

    ##\frac{8}{5}\big(x^2 + y^2\big) \geq constant##

    giving you the minimum value

    ##\big(x^2 + y^2\big) \geq \frac{5}{8}constant##

    and from above, we know reaching this minimum occurs if and only if ##x = -y##

    - - - -

    To be real clear, my approach is start by sketching the graph and looking at it. Then I look at the symbols involved -- in this case I see products on RHS and sums on LHS and I look for a way to go from products to sums. ##GM \leq AM## is one way to do this.
     
    Last edited: Dec 17, 2017
  4. Dec 17, 2017 #44

    Ray Vickson

    User Avatar
    Science Advisor
    Homework Helper

    No! The original problem used ##x,y## and the rotated problem used ##X,Y##. These are not at all the same, and should never, ever, be mixed up! I hope you are starting to learn that it is important to be more careful.
     
  5. Dec 18, 2017 #45

    epenguin

    User Avatar
    Homework Helper
    Gold Member

    As can be seen I didn’t get it immediately, maybe somebody has hinted it, but isn’t the easiest method the old quadratic inequalities tricks?

    Re-write the equation

    $$5x^2-6xy+5y^2=4$$
    as
    $$ 8\left( x^{2}+y^{2}\right) =4+3\left( x+y\right) ^{2}$$
    Then the smallest possible value of the squared distance from origin ##(x^2+y^2) ## is obtained when ##x=-y## and is ½. As ##x^2=y^2## at the points we easily obtain ##x=\pm \dfrac {1}{2},y= \mp \dfrac {1}{2}##, giving the required distance ##\sqrt {x^{2}+y^{2}}=\dfrac {1}{\sqrt {2}}##

    Finding the points of maximum distance is left as an exercise for the reader. :oldsmile:
     
    Last edited: Jan 8, 2018
  6. Dec 24, 2017 #46
    $$2X^2 + 8Y^2 = 4~\rightarrow~Y^2=\frac{1}{2}-\frac{1}{4}X^2$$
    $$s^2=X^2+Y^2=X^2+\frac{1}{2}-\frac{1}{4}X^2=\frac{3}{4}X^2+\frac{1}{2}$$
    $$s^2_{min}(X=0)=\frac{1}{4}~\rightarrow~s_{min}=\frac{1}{2}$$
    I just want to arrange the ##~GM \leq AM~## method.
    $$GM \leq AM~\rightarrow~\frac{x+y}{2}\geqslant \sqrt{xy}~\rightarrow~\frac{x^2+y^2}{2}\geqslant \sqrt{x^2 y^2}=xy~\rightarrow~2xy\leqslant x^2+y^2$$
    $$5(x^2+y^2)-6xy=4~\rightarrow~x^2+y^2=\frac{4}{5}-\frac{3}{5}\vert 2xy \vert \geqslant \frac{4}{5}-\frac{3}{5}(x^2y^2)$$
    $$\frac{8}{5}(x^2y^2)\geqslant \frac{4}{5}~\rightarrow~x^2+y^2 \geqslant \frac{1}{2}$$
    I will review now my original solution.
    $$5(x^2+y^2)-6xy=4~\rightarrow~10x-6(yy'+x)+10yy'=0~\rightarrow~y'=-\frac{x}{y}$$
    Why isn't that correct? i know now it's an ellipse but what is wrong with the derivative of the distance?
     
  7. Dec 25, 2017 #47

    Ray Vickson

    User Avatar
    Science Advisor
    Homework Helper

    $$5(x^2+y^2) - 6xy=4 \: \Rightarrow 10 x + 10 y y' - 6 y - 6 xy' = 0 \; \Rightarrow y' = \frac{5x-3y}{3x-5y}.$$
     
  8. Dec 26, 2017 #48
    $$y' = \frac{5x-3y}{3x-5y},~~y'=0~\rightarrow~5x-3y=0~\rightarrow~y=\frac{5}{3}x$$
    $$5(x^2+y^2)-6xy=4~\rightarrow~x^2=-\frac{18}{5}$$
     
  9. Dec 26, 2017 #49

    epenguin

    User Avatar
    Homework Helper
    Gold Member

    ##y’=0## is not the point you are looking for - it is in no way an answer to the question. Look at pictures of the ellipse, e.g. #28 to see what points ##y’=0## corresponds to.
     
  10. Dec 27, 2017 #50

    Ray Vickson

    User Avatar
    Science Advisor
    Homework Helper

    No, again. There are two expressions for ##y'##:
    (1) From the optimality condition:
    $$0 = \frac{d}{dx} (x^2+y^2) = 2 x + 2 y y' \Rightarrow y' = -\frac{x}{y}$$
    (2) From the constraint:
    $$ 0 = \frac{d}{dx} (5 x^2 + 5y^2 - 6 xy) = 10 x + 10 y y' - 6y - 6 xy' \Rightarrow y' = \frac{5x-3y}{3x-5y}$$
    How would you use those two formulas for ##y'## to get further along towards a solution?
     
  11. Dec 27, 2017 #51
    $$5(x^2+y^2) - 6xy=4 \: \Rightarrow \: s^2=x^2+y^2=\frac{4}{5}+\frac{6}{5}xy$$
    $$[s^2]'=\frac{6}{5}(y+xy')=\frac{6}{5}\left[ y+\frac{5x-3y}{3x-5y} \right]$$
    I can't express y(x)
     
  12. Dec 28, 2017 #52
    $$\frac{5x-3y}{3x-5y}=-\frac{x}{y}~\rightarrow~x^2=y^2$$
    $$x=y,~x=-y,~-x=y,~-x=-y$$
    The 4 solutions are contained in only two: ##~x=y,~x=-y~##. now to try each one in the original formula:
    $$x=y:~5x^2-6x^2+5x^2=4~\rightarrow~x=\pm 1$$
    $$x=-y:~5x^2+6x^2+5x^2=4~\rightarrow~x=\pm \frac{1}{2}$$
    The first is max. distance and the second min.
     
  13. Dec 29, 2017 #53

    epenguin

    User Avatar
    Homework Helper
    Gold Member

    You got it! To be pedantic a slight mistake in your last sentence which might lose you marks, not quite the answer to the question asked, but we know what you mean - you are probably exhausted by now.

    More important, the job is not finished! You need to apply a Polya principle:
    “4 look back on your work. How could it be better?“

    The last posts here are unnecessarily complicated. The calculation of ##\frac{d}{dx} (5 x^2 + 5y^2 - 6 xy)## is carried through in full without exploiting the fact that ##\frac{d}{dx} (x^2+y^2) = 0## (at the point of interest) so you only need to find the condition for ##\frac{d}{dx}(xy)=0 ## (which is essentially what I have done in #37). Since #15 I have been trying to prod you to recognise and exploit the fact that the distance function ##(x^2+y^2)## Is also part of the equation of the curve.

    The ‘Polya principles’ to which I often refer in this site are contained in the slim, cheap and popular book “How to Solve It“ by George Polya https://en.wikipedia.org/wiki/How_to_Solve_It which is worth at least a dozen or two maths lessons for giving you mathematical muscle. It is worth buying and not just reading but keeping by. Because when you read it you may think ah that’s fairly obvious – but then you forget it and don’t apply at it when needed. One tip in it is to ‘draw a picture’, I have the impression you didn’t at first and it would have helped see where you were going. As I say one forgets. A tip that has got me unstuck sometimes is ”are you using all the information available?“ - But then in the present case I had lost sight of another one: “Have you seen anything like it before?”. And sure I must have done lots of exercises at school and elsewhere on inequalities (and maxima and minima are inequalities) using squares whose minimum value is zero. And so probably have you, so you too did have the necessary background in theory. After a bit this came out of the back of my mind and I arrived at #45 which looks to be the most efficient solution possible. Which leads me to my final heuristic point.

    You were asked at the start of the thread #2 whether you knew the general method for constrained extrema. General methods are surely the biggest most powerful thing in maths. But when anything can be solved by a less general method, that will usually be more efficient because it is using more information about the specifics of the problem.
     
    Last edited: Jan 6, 2018
  14. Dec 29, 2017 #54

    WWGD

    User Avatar
    Science Advisor
    Gold Member

    Just curious. How about finding the solution like this:
    Find a circle C0 centered at the origin with radius r which intersects the ellipse at precisely one point? The value of r is then the shortest distance?

    EDIT: ##x^2+y^2=r^2 . 5x^2+5Y^2 -6XY=4 =5r^2-6x(\sqrt{r^2-x^2})=4##. Square both sides and find values of ##r## so that there is just one solution. ##5r^2-4 =6x(\sqrt{ r^2-x^2} \rightarrow 25r^4-10r^2+16=36x^2(r^2-x^2) \rightarrow -36x^4 +36x^2r^2 -25r^4 +10r^2 -16 =0 ## A bi-quadratic Set ##r^2=s## then we get :

    ##-36x^4 +36x^2s-25s^2 -10s-16=0. -25s^2-(10 -36x^2)s+ 36x^4-16=0 . s=10-36x^2 \pm \sqrt{}## . .
     
    Last edited by a moderator: Jan 4, 2018
  15. Dec 29, 2017 #55

    WWGD

    User Avatar
    Science Advisor
    Gold Member

    Re first point: always good to keep tweaking.

    RE second point, problem is that it takes a good amount of general mental computing resources and time to come up with customized methods. This is why, I would say, automation through standardization is so often used.
     
  16. Dec 29, 2017 #56

    StoneTemplePython

    User Avatar
    Science Advisor
    Gold Member

    +1 for a great Polya reference. I am big fan of trying to solve a problem in many different ways as well.

    There's something of an art to figuring out how to tailor your approach to the specifics of the problem. (I think people call this mathematical creativity.)
     
  17. Jan 1, 2018 #57
    $$5x^2-6xy+5y^2=4~\rightarrow~5y^2-(6x)y+(5x^2-4)=0$$
    $$y=\frac{6x\pm\sqrt{36x^2-20(5x^2-4)}}{10}=\frac{3x\pm 2\sqrt{5-4x^2}}{5}$$
    I choose the + first:
    $$s=x^2+y^2~\rightarrow~s_{+y}=x^2+\left[ \frac{3x+2\sqrt{5-4x^2}}{5} \right]^2=x^2+\frac{1}{25}[12x\sqrt{5-4x^2}+20-7x^2]$$
    $$s'=2x+\frac{1}{25}\left[ 12 \left( \sqrt{5-4x^2}-\frac{4x^2}{\sqrt{5-4x^2}} \right)-14x \right]$$
    $$s'=0~\rightarrow~x=\pm 1.1$$
     
  18. Jan 4, 2018 #58
    I posted a few days ago but nobody addressed
     
  19. Jan 4, 2018 #59

    epenguin

    User Avatar
    Homework Helper
    Gold Member

    Why I could almost have said the same thing myself a few times. :oldsmile:
    In your case just a few more words would have done something for comprehending where you are at (I mentioned ‘narrative’ before). Readers are left uncertain whether you mean at the end really one point one, or whether you meant just 1, which if I remember does correspond to a maximum of ##x##.You need to say (if this is what you mean) this is wrong, but say how you know it’s wrong. Otherwise people just only see a blank mass of calculation.

    And if they get that much into it they may well wonder how you got x from s’ = 0 - It looks like having to go through the fourth power palaver or worse again. I don’t suggest you set all the detail out but some words to indicate what you did would not be out of place.I wonder how many pages you have written? Without any words I think you won’t yourself know what you’ve done or why when you come back to it in six months.

    I am not very good at arithmetic, but it seems to be on the second line you made a maltranscription or something and under the square root you should have (52 - 42x2) - the squarings have slipped away.
     
    Last edited: Jan 4, 2018
  20. Jan 4, 2018 #60

    ehild

    User Avatar
    Homework Helper

    Karol, you knew your result was wrong. Why did you post it?
    How did you get that wrong result from your last correct formula?
     
    Last edited by a moderator: Jan 4, 2018
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted