# Homework Help: Subspaces and inner products

1. Jan 2, 2006

### Benny

Hi, can someone shed some light on the following question. It's been bothering me for a while and I'd like to know where I went wrong. Here is what I can remember of the question.

The following is an inner product for polynomials in P_3(degree <= 3): $$\left\langle {f,g} \right\rangle = \int\limits_{ - 1}^1 {f\left( x \right)g\left( x \right)} dx$$

Let W be the subspace of the vector space P_3, spanned by {x^2, x^3}.

Find the orthogonal projection of a polynomial $$p\left( x \right) = a_0 + a_1 x + a_2 x^2 + a_3 x^3 \in P_3$$ onto W. Find also the polynomial $$q\left( x \right) \in W$$ which minimises the integral $$\int\limits_{ - 1}^1 {\left( {3 + 5x - q\left( x \right)} \right)^2 } dx$$.

I think that q(x) is some kind of projection onto W. I kind of drew an analogy with 'distance' when I did this question. But obviously something's wrong with that approach. Does anyone have suggestions as to how to find q?

2. Jan 2, 2006

### AKG

The first question is a really basic one, just compute the orthogonal projection of p onto W using the definition of orthogonal projection. The second question looks like it has nothing to do with linear algebra, it's just high school calculus, at least, that's how I solved it.

3. Jan 3, 2006

### Benny

I included the first question to provide a context for the second question. I know that it's just using the definition.

Looking at the problem from another perspective - Suppose that U is a subspace of some real vector space V spanned by two unit vectors b and c and d is just some element of V (not necessarily in the span of b and c). Then the projection of d onto U is e = <d,b>b + <d,c>c. The vector orthogonal to that projection is simply d - e. I was thinking that it might have something to do with projections.

4. Jan 3, 2006

### AKG

It would be interesting to see if there were an algebraic approach to solving the second question. However, the analytic approach is simple and obvious, albeit inelegant. If you need to just do the problem, you can do it using calculus. If you want to know if there is an algebraic solution, I can't think of one off the top of my head

5. Jan 3, 2006

### HallsofIvy

The orthogonal projection of $$p\left( x \right) = a_0 + a_1 x + a_2 x^2 + a_3 x^3 \in P_3$$ on W is, of course, $a_2x^2+ a_3x^3$.

3+ 5x- q(x)= 0 when q(x)= 3- 5x. If q(x)= 3+ 5x, the integral is 0. That's the minimum isn't it?

6. Jan 3, 2006

### Muzza

Halls, q must lie in W = span{x^2, x^3}.