Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Crazy optimization/Lagrange questino

  1. Nov 4, 2004 #1
    Ok this is the question I had on a test today:

    given this constraint equation z^2-xy+1=0 find the min. distance from the origin using Lagrange method.

    so basically you use D^2=x^2+y^2+z^2 as the other equation. however, it basically goes nuts from there. especially if you set it up like you are suppose to.
    Fx=(lambda)Gx
    Fy=(lambda)Gy
    Fz=(lambda)Gz
    g=0

    (capitals are partial derivatives)

    with f as the distance formual and g as the constraint

    this one sucks but if someone could help it would be greatly appreciated
     
  2. jcsd
  3. Nov 8, 2004 #2

    Galileo

    User Avatar
    Science Advisor
    Homework Helper

    Try not to minimize [itex]D=\sqrt{x^2+y^2+z^2}[/itex], but [itex]D^2=x^2+y^2+z^2[/itex].
     
  4. Nov 8, 2004 #3

    HallsofIvy

    User Avatar
    Staff Emeritus
    Science Advisor

    1. Why was this posted under "differential equations"?

    2. You want to minimize F= x2+ y2+ z2 subject to the condition G= z^2-xy+1=0.
    Okay, grad F= 2xi+ 2yj+ 2zk= λgrad G= &lambda(-yi- xj+ 2zk)
    so 2x= -λy, 2y= -λx, and 2z= -2λz

    Divide the first equation by the second, x/y= y/x so x2= y[/sup]2[/sup] and y= x or y= -x.
    From 2z= -2λz, either z= 0 or &lambda= -1.

    With x= y, z= 0, since z^2-xy+1=0, we have -x2+ 1= 0 so x= +1 or -1:
    (1, 1, 0) and (-1,-1,0) are possible points.

    With x= -y, z= 0, since z^2-xy+1=0, we have x2+ 1=0 which is impossible.

    If z is not 0, then &lambda= -1 so 2x= -λy become 2x= y and 2y= -λx becomes 2y= x: 2y= 2(2x)= 4x= x so x= y= 0. In that case z^2-xy+1=0 becomes z2+ 1= 0 which is impossible.

    The two minimum distance points are (1,1, 0) and (-1,-1,0). The are both distance √(2) from (0,0,0).
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?



Similar Discussions: Crazy optimization/Lagrange questino
  1. Euler Lagrange ODE (Replies: 5)

  2. Newton Lagrange Method (Replies: 0)

Loading...