If we assume that the definition of the inner product of the normalized vectors #hatu_1# and #hatu_2# is #2u_1^2 + u_2^2# (these are vector components), how do you use the Gram-Schmidt process to generate orthonormal vectors from #vecv_1# and #vecv_2#?

#vecv_1 = (2,1)#
#vecv_2 = (5,-7)#

2 Answers
Jul 31, 2017

See below.

Explanation:

Following the Gram-Schmidt orthonormalization process, given #{vec u_1, vec u_2}# we begin by one of then, for instance #vec u_1# and define

#vec v_1 = (vec u_1)/norm(vec u_1)_q#

and then

#vec v_2 = (vec u_2 - << vec u_2,vec v_1 >>_q vec v_1)/norm( vec u_2 - << vec u_2,vec v_1 >>_q vec v_1)_q#

so if

#{(vec u_1=(2,1)),(vec u_2=(5,-7)):}#

we obtain

#{(vec v_1 =(2/3, 1/3) ),(vec v_2 =(sqrt 2/3, -(2 sqrt[2])/3) ):}#

NOTE: Here #<< cdot, cdot >>_q# applied to two vectors #vec u, vec v# gives #<< vec u, q cdot vec v >># and

#norm(vec u)_q = sqrt(<< vec u, q cdot vec u >>)# with #q# a definite positive matrix.

In the present case #q = ((2,0),(0,1))#

Jul 31, 2017

I did your question from the beginning and got:

#hatu_1 = (2/3,1/3)#

#hatu_2 = (1/(3sqrt2), -4/(3sqrt2))#


The Gram-Schmidt process for two vectors first involves orthogonalizing them:

#vecu_1 = vecv_1#, #" "" "" "" "" "" "" "hatu_1 = vecu_1/||vecu_1||#

#vecu_2 = vecv_2 - "proj"_(vecu_1)vecv_2#, #" "" "hatu_2 = vecu_2/||vecu_2||#

And if you had more than two vectors #vecu_i#, you would match the subscript of #vecu_i# with #vecv_i#, then sequentially subtract the projection of the current #vecv_i# (highest index #i#) onto the previous #vecu_i#'s.

You have been given

  • #vecv_1 = (2, 1)#
  • #vecv_2 = (5, -7)#

Now, you already have #hatu_1#. Due to the definition of your inner product, the norm is not the usual definition (difference highlighted in red):

#|| vecu ||^2 = << vecu, vecu >> = color(red)(2)u_1u_1 + u_2u_2#

#=> color(blue)(hatu_1) = ((2", "1))/(sqrt(color(red)(2) xx (2)^2 + 1^2)) = ulcolor(blue)((2/3, 1/3)" ")#,

which indeed has a norm of #1# under YOUR inner product definition.

To proceed, we define the projection of #bb(vecv_2)# onto #bb(vecu_1)#:

#"proj"_(vecu_1)vecv_2 = (<< vecv_2, vecu_1 >>)/(<< vecu_1, vecu_1 >>) vecu_1#

How I remember it is that the vector that is projected (mapped), #vecv_2#, is the only different term in the projection definition.

We continue by finding the inner product of #vecv_2# with #vecu_1#, using YOUR definition, which is again, not quite the dot product of the vectors:

#<< vecv_2, vecu_1 >> = color(red)(2)v_(21)u_(11) + v_(22)u_(12)#

#= color(red)(2) xx 5 cdot 2 + -7 cdot 1#

#= 13#

And the inner product of #vecu_1# with itself is the norm squared:

#<< vecu_1, vecu_1 >> = ||vecu_1||^2 = 3^2 = 9#

As a result, the projection of #vecv_2# onto #vecu_1# is:

#"proj"_(vecu_1)vecv_2 = 13/9 cdot (2, 1)#

#= (26/9, 13/9)#

and so, the vector #vecu_2# would be found as:

#color(red)(vecu_2) = vecv_2 - "proj"_(vecu_1)vecv_2#

#= (5, -7) - (26/9, 13/9)#

#= (45/9, -63/9) - (26/9, 13/9)#

#= color(red)((19/9, -76/9)" ")#

Note that this is NOT normalized yet. The normalization of this is then:

#color(blue)(hatu_2) = (vecu_2)/(||vecu_2||)#

#= ((19/9", "-76/9))/sqrt(color(red)(2) xx (19/9)^2 + (-76/9)^2)#

#= (19/(19 sqrt2/3 cdot 9)", "-76/(19 sqrt2/3 cdot 9))#

#= ulcolor(blue)((1/(3sqrt2)", "-4/(3sqrt2))" ")#

And indeed this has a magnitude of #1# under this inner product definition.

Lastly, to check whether we are correct, we should see if the inner product of #hatu_1# and #hatu_2# is #0# (for orthogonality only). We already know these vectors are properly normalized in this particular inner product space.

#0 stackrel(?" ")(=) << hatu_1, hatu_2 >>#

#= color(red)(2) xx 2/3 cdot 1/(3sqrt2) + 1/3 cdot -4/(3sqrt2)#

#= 4/(9sqrt2) + (-4/(9sqrt2)) = 0# #color(blue)(sqrt"")#

So, this should be correct! (If you wish, you can check that #<< hatu_1, hatu_1 >> = << hatu_2, hatu_2 >> = 1#, which is again, #color(red)(2)u_(11)^2 + u_(12)^2#, and #color(red)(2)u_(21)^2 + u_(22)^2#, respectively.)