1. Not finding help here? Sign up for a free 30min 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!

Gram-Schmidt problem - I'm stuck

  1. Dec 4, 2007 #1
    I am stuck on a problem.. I keep obtaining the incorrect answer and I am unsure of where my calculation went wrong??? I have the 2 vectors v1 [4,0,3] and v2 [25,0,-25]

    I first obtain (1/||v1||)v1 = [4/5 0 3/5] = z1

    I then proceed to do: (v2 - (z1 . v2)z1)/||v2 - (z1 . v2)|| = [25 0 -25] - 5 [4/5 0 3/5] = [25 0 -25] + [-4 0 -3] = [21 0 -28] = u2

    then 1/||u2|| = sqrt(21^2 + 0^2 + -28^2) = 35

    So i should get (1/35)[25 0 -25]

    But in the book it shows the correct answer to be:

    (1/5)[3 0 -4]?? I don't see where I went wrong.. I went over it several times.. I just must be missing something??
     
  2. jcsd
  3. Dec 4, 2007 #2
    it's so difficult to understand what you wrote but if you want to project [itex]\vec{u_1}[/itex] onto [itex]\vec{u_2}[/itex] you do this:

    [tex] \frac{\vec{u_1} \bullet \vec{u_2}}{\vec{u_1} \bullet \vec{u_1}} \vec{u_1}[/tex]

    then the orthogonal compliment is just [itex] u_1 - proj[/itex]
     
  4. Dec 5, 2007 #3
    blahh.. I don't get it.. I did and still not the right answer is produced.. can someone help.. I don't know what I am missing

    The main question is to just perform Gram-Schmidt on those first two vectors:
    4
    0
    3
    and
    25
    0
    -25

    I did it in the first post and just did it again.. I still i get a different answer then what is in the book.
     
  5. Dec 5, 2007 #4

    JasonRox

    User Avatar
    Homework Helper
    Gold Member

    I suggest taking your sweet ass time when doing the Gram-Schmidt process. It's so easy to make a mistake and one mistake just carries on.

    Do it slowly and double check and check again.
     
  6. Dec 5, 2007 #5
    I did this.. just want to make sure my formula is right for vector 2.. where u1 = what you received for the first vector.

    V2 =
    v2 - (u1 (dot product) v2)u1
    ~~~~~~~~~~~~~~~~~~~~
    ||v2 - (u1 (dot product) v2)u1||

    where ~~~~ = divide.

    I did this over and over again and seem to get (1/35)v2
     
  7. Dec 5, 2007 #6

    Galileo

    User Avatar
    Science Advisor
    Homework Helper

    EDIT: Nevermind, your first post works out doesn't it?

    You have u_2=[21 0 -28]=7[3 0 -4]

    so normalize it to get the right answer.
     
    Last edited: Dec 5, 2007
  8. Dec 5, 2007 #7
    i get how you got 7[3 0 -4]

    but for the answer it shows:

    (1/5) [3 0 -4]

    So I am still not sure how the hell they got the (1/5)
     
  9. Dec 5, 2007 #8

    Chris Hillman

    User Avatar
    Science Advisor

    What is [itex]3^2+(-4)^2[/itex]?

    Jason: in this context, is 2000 or 2007 the more memorable number? :wink:
     
  10. Dec 5, 2007 #9
    ahhhhhhhhhhhhhh alright i think i got it.. thank you all for your help.. But what happens to the 7???
     
  11. Dec 8, 2007 #10

    Galileo

    User Avatar
    Science Advisor
    Homework Helper

    You are just normalizing the vector, i.e. scale it so becomes of unit length.
    If v is a nonzero vector, then clearly v/|v| is a unit vector, where |v| is the norm of v.
    So what is the norm of 7[3 0 -4] ?
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?



Similar Discussions: Gram-Schmidt problem - I'm stuck
  1. Gram Schmidt (Replies: 2)

  2. Gram–Schmidt process (Replies: 3)

  3. Gram-Schmidt Process (Replies: 5)

Loading...