- #1

- 5

- 0

## Homework Statement

Find the orthogonal projection projWy

u1 = [-1; 3; 1; 1], u2 = [3; 1; 1; -1], u3 = [-1; -1; 3; -1], y = [1; 0; 0; 1]

where {u1, u2, u3} is an orthogonal basis.

## Homework Equations

yhat = [dot(y,U1)/dot(U1,U1)]U1 + ....... [dot(y,Un)/dot(Un,Un)]Un

## The Attempt at a Solution

I used the equation above and I ended up getting:

0u1 + 1/6[3; 1; 1;-1] + 1/6[-1; -1; 3; -1] = 1/6[2; 0; 4; -2]

the answer given by my professor is 1/6[-1; -1; 3; -1] and I don't understand why. I can get that answer by not adding dot(y,U3)/dot(U3,U3)]U3 to yhat, but I suspect that isn't the right way to do it. Where am I going wrong?