# Inner Product on F[a,b]

1. Apr 9, 2013

### Smazmbazm

1. The problem statement, all variables and given/known data

For f and g in F[a,b], we define an inner product on F[a,b] by

<f,g> = ∫$^{b}_{a}$ f(x)g(x)dx

a) Find the angle between the functions f(t) = 5t - 3 and g(t) = t$^{3}$ - t$^{2}$ in F[0,1].

b) Find an orthonormal basis for the subspace of F[0,1] spanned by {1, e$^{-x}$, e$^{-2x}$}

3. The attempt at a solution

I'm not sure where to start with this problem. I don't know what the question means by F[a,b] and trying to find the angle between the functions f(t) and g(t) in F[0,1]. I know the angle can be found by using cosθ = <u,v>/||u|| ||v|| but what are u and v? Just a point in the right direction would be helpful.

2. Apr 9, 2013

### Dick

u is f(x). v=g(x). You've been given the definition of <f,g>. ||f||=sqrt(<f,f>) and ||g||=sqrt(<g,g>). Just work it all out.

3. Apr 10, 2013

### Smazmbazm

Thanks for the help, Dick. This is what I get

cos θ = $∫^{b}_{a}$$(5t - 3)(t^{3} - t^{2})$ / ( $\sqrt{∫^{b}_{a}(5t - 3)(5t - 3)}$ * $\sqrt{∫^{b}_{a}(t^{3} - t^{2})(t^{3} - t^{2})}$ )

After integration and simplification I get

cos θ = $\frac{5t^{6}}{8} -\frac{19t^{5}}{12} + t^{4}$ / $\sqrt{\frac{25t^{4}}{4} - 15t^{3} + 9t^{2}}$ * $\sqrt{\frac{t^{8}}{16} - \frac{t^{7}}{6} + \frac{t^{6}}{9}}$

When t = 1, I get

cos θ = 0.0416 / (0.5 * 0.0833)

∴ θ = $\arccos{(0.0416 / (0.5 * 0.0833))}$

θ = 0 degrees

Is this correct?

4. Apr 10, 2013

### Dick

You are doing the right kind of things but I can't make any sense out of the answers. How did you get $\int_0^1 (5t-3)(t^3-t^2) dt=0.416$?

5. Apr 10, 2013

### Smazmbazm

Yea, was integrating before multiplying both brackets together, not sure why -.- Should be

$cos θ = \frac{5t^{5} - 10t^{4} + 5t^{3}}{5} /$ $\sqrt{\frac{25t^{3}}{4} - 15t^{2} + 9t}$ * $\sqrt{\frac{t^{7}}{7} - \frac{t^{6}}{3} + \frac{t^{5}}{5}}$

This gives

$θ = \arccos(0 / (0.5 * 0.09759))$

So θ = 90 degrees

6. Apr 10, 2013

### Dick

That's better. I don't think you got the <f,f> part right, but since the numerator is zero, it doesn't matter.

7. Apr 10, 2013

### Smazmbazm

Yea should be divided by 3 not 4. Thanks again for the help

8. Apr 10, 2013

### Smazmbazm

So for part b) I'm assuming I use the Gram–Schmidt process to find the orthonormal basis?

$S\{v_{1},v_{2},v_{3}\} = S\{1,e^{-x},e^{-2x}\}$

$u_{1} = 1$

$u_{2} = e^{-x} - \left(∫^{1}_{0} 1*e^{-x} / ∫^{1}_{0} 1 * 1\right)*1$

$u_{3} = e^{-2x} - \left(∫^{1}_{0} 1*e^{-2x} / ∫^{1}_{0} 1 * 1\right)*1 - proj_{u2}(v_{3})$

Then normalize them all and that's the orthonormal basis. Correct?

9. Apr 10, 2013

### Dick

Sure, Gram-Schmidt is the way to go. It'll be easy to check when you are done. Just check that all of the inner products are either 0 or 1.

10. Apr 10, 2013

### Smazmbazm

Well I started doing it this way and get $u_{2} = e^{-x} - 0.6321$

Is this correct? Want to confirm before I continue with $u_{3}$, seems like it's going to be messy.

11. Apr 10, 2013

### Dick

I told it's going to be easy to check. Just check if $<u_1,u_2>=0$. At least as close to zero as you would expect from rounding off 1-1/e to 0.6321. You might be better off keeping the numbers in symbolic form instead of converting to decimals.