Vector Tutorial for Beginners

Started by
4 comments, last by Ravyne 14 years, 5 months ago
I have posted a small tutorial on vector basics at my blog here. Comments or suggestions for improvement are welcome.
Advertisement
Its a decent enough entry-level tutorial to cover the basics. One thing I'd recommend for sure is to maybe stress the fact that subtraction of vectors is non-commutative -- you essentially say this, but I think stressing this in mathimatical parlance is important.

Another thing you may want to consider is that it most certainly *is* possible to multiply vectors -- which you say specifically cannot be done. For all vectors, you have the dot-product, and for vectors of dimensions 3 and 7 you have the cross product -- both forms of multiplication. It's further worth mentioning that, while the cross product does not officially exist in other dimensions, its analogue may have a meaningful interpretation. For example, in 2 dimensions, the analogue of the cross product is 0 if the vectors are in alignment, and negative or positive depending on whether the vector A is oriented counter-clockwise or clockwise relative to vector B. This is how hidden-surface removal works -- if you know the way the triangles of a 3D model are wound, then you can compare this to the value of the "psuedo" cross-product of the triangle edges once they are projected into 2D to determine whether the visible "face" of the triangle is towards the screen or turned away from the screen (in which case it doesn't need to be drawn). I'd recommend either talking about these products, or leaving them to another tutorial; but I wouldn't leave your tutorial stating that it can't be done.

You can also do a straight-across, or 'piece-wise' multiplication between two vectors of any dimension, which results in a non-uniform scaling of the target vector. Geometrically, I don't think its terribly useful in practice, but it does have usees in other domains -- remember that vectors are used in many, many applications, not just ones which are more-or-less geometric in nature.

[Edited by - Ravyne on November 12, 2009 2:20:43 AM]

throw table_exception("(? ???)? ? ???");

Quote:Another thing you may want to consider is that it most certainly *is* possible to multiply vectors -- which you say specifically cannot be done. For all vectors, you have the cross-product, and for vectors of dimensions 3 and 7 you have the dot product -- both forms of multiplication. It's further worth mentioning that, while the dot product does not officially exist in other dimensions, its analogue may have a meaningful interpretation. For example, in 2 dimensions, the analogue of the dot product is 0 if the vectors are in alignment, and negative or positive depending on whether the vector A is oriented counter-clockwise or clockwise relative to vector B. This is how hidden-surface removal works -- if you know the way the triangles of a 3D model are wound, then you can compare this to the value of the "psuedo" cross-product of the triangle edges once they are projected into 2D to determine whether the visible "face" of the triangle is towards the screen or turned away from the screen (in which case it doesn't need to be drawn). I'd recommend either talking about these products, or leaving them to another tutorial; but I wouldn't leave your tutorial stating that it can't be done.
I think you swapped dot for cross and vice versa in a couple of places. (It's clear what you meant, but it might be confusing to those who aren't already familiar with the material :)
D'oh! Thanks for pointing that out... I've fixed my original reply.

throw table_exception("(? ???)? ? ???");

Thank you very much for your replies. I have updated the tutorial based on the suggestions provided. That was a good call on the vector multiplication. I never really thought about how the dot product is really just a component wise multiplication of 2 vectors. Amazing how that slipped my mind...
I don't know if I'd call the dot product a "component-wise" multiplication... since it's the sum of several component multiplications.

"component-wise" in my mind, is interchangable with "piece-wise", both of which are better suited to describing the non-uniform scaling operation I described earlier.

I'd Stick to calling it the "Dot product" and leave the mathematical illiteration for the mathematicians [wink]

throw table_exception("(? ???)? ? ???");

This topic is closed to new replies.

Advertisement