-- Nov 8 In-Class Exercise
`W’ = [[2,0,0], [0,0,-1], [0,3,0]]`
`x = [−1,3,−3]`
k=2 , h has one non-zero entry
Taking h which minimizes ||x- W'h||^2 gives us the solution
Let h = [c, 0, 0] = [-0.5, 0, 0]. (1)
`||x-W'h|| = (1+2c)^2 + 9 + 9` gives min. value = 18 when c = -1/2
Let h = [0, c, 0] = [0, -1, 0]. (2)
`||x-W'h|| = (3 + 3c)^2 + 1 + 9` gives min. value = 10 when c = -1
Let h = [0, 0, c] = [0, 0, -3] (3)
`||x-W'h|| = (3+c)^2 + 1 + 9` gives min. value = 10 when c = -3
Both (2) and (3) gives the answer
@BT@W’ = [[2,0,0], [0,0,-1], [0,3,0]]@BT@
@BT@x = [−1,3,−3]@BT@
k=2 , h has one non-zero entry
Taking h which minimizes ||x- W'h||^2 gives us the solution
Let h = [c, 0, 0] = [-0.5, 0, 0]. (1)
@BT@||x-W'h|| = (1+2c)^2 + 9 + 9@BT@ gives min. value = 18 when c = -1/2
Let h = [0, c, 0] = [0, -1, 0]. (2)
@BT@||x-W'h|| = (3 + 3c)^2 + 1 + 9@BT@ gives min. value = 10 when c = -1
Let h = [0, 0, c] = [0, 0, -3] (3)
@BT@||x-W'h|| = (3+c)^2 + 1 + 9@BT@ gives min. value = 10 when c = -3
Both (2) and (3) gives the answer