Hacker News new | past | comments | ask | show | jobs | submit login

I know this isn't the point of the post, but I'm learning me some linear algebra from online video lectures now and wanted to check my answer for the bonus question, part b. Is it [[-3/2 2 -1/2] [-1/2 0 1/2] [1/2 -2 3/2]]?

My method was to represent f(x) as ax^2+bx+c, giving v = [c, a + b + c, 4a + 2b + c] as the vector in the coordinate system and dv/dx = [b, 2a + b, 4a + b] as the derivative. Then d/dx * v = dv/dx. Then split both vectors into a product of a 3x3 number matrix and [a b c], cancel the [a b c] from both sides, find the inverse of the left matrix, and multiply it by the right. I did the inverse by hand so I might have made an arithmetic mistake. Am I on the right track or did I totally misunderstand the question?




That is correct.

Your double check is to take the vectors for the polynomials 1, x, and x^2 (namely [1, 1, 1], [0, 1, 2], [0, 1, 4]) and multiply out to see that you get the vectors for the polynomials 0, 1, 2x.

Your verbal description does not make sense to me. But you appear to have done the right operations.

The approach that my class universally took was to realize that if we take the coordinate system whose basis is (1, x, x^2) then the answer is easy to write down. After that you apply change of basis matrices to each side to get the answer in the requested basis.


Cool. I haven't gotten to the change of basis lecture video yet, or I might have tried that :)


If you do the linear function/notation thing right, the idea of a change of basis comes for free. The basic idea is this. Suppose that we have a linear function F between two vector spaces (which might be the same), and we have coordinate systems on the vector spaces (which might be the same). Then we can take the elements of the first basis, v1, v2, ..., vn, and write out a matrix whose columns are F(v1), F(v2), ... F(vn) in the second coordinate system.

This matrix uniquely represents F. The function F can be applied to a vector by writing out the vector in the first coordinate system, putting that on the right of the matrix, then doing matrix multiplication. You get an answer in the second coordinate system. And the operation of matrix multiplication turns out (if the coordinate systems match up) to be exactly the same as composition of functions.

(This is no coincidence, this relationship is the motivation for matrix multiplication being defined as it is.)

OK, with all of that mess, what is a change of basis matrix? It is simply the matrix you get for the identity function going from one coordinate system to another.

Now in this case the matrix A = [[1 0 0] [1 1 1] [1 2 4]] is the matrix to change from the basis where a+bx+cx^2 is represented by [a b c] to the basis where it is represented by [a a+b+c a+2b+4c] (ie [p(0) p(1) p(2)]). Its inverse is the change of basis the other way. And B = [[0 1 0] [0 0 2] [0 0 0]] is, of course, in the [a b c] basis the representation of the function d/dx.

Then A B A^(-1) represents change from pointwise coordinates to coefficients, then differentiate in coefficient coordinates, then change from coefficient coordinates back to pointwise coordinates. (Remember, the matrices are applied right to left, so you do A^(-1) first.)

If you can keep that straight, you now understand change of basis matrices.


looks right to me (just checking by multiplying v by your answer - it gives v'). also, you and i seem to understand the question in the same way. but whether that's the most elegant way to solve the problem, i don't know.

also, you could do the proof by explicitly checking with two polynomial expressions. again i don't know if there's a simpler way (maybe you can just say that differentiation is distributive blah blah...)


...what was the question?


"Let V be the vector space of all polynomials of degree at most 2. a) Prove that d/dx is a linear operator on V. b) You can put a coordinate system on V by mapping p(x) to (p(0), p(1), p(2)). (Please imagine that flipped 90 degrees so it is a column.) Find the matrix that represents d/dx in this coordinate system."


Which online video lectures are you following?


The MIT ones taught by Strang, my new favorite professor. http://www.youtube.com/watch?v=ZK3O402wf1c




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: