## Friday, September 7, 2007

### Math Without Math: Cartesian Coordinates

As I said before, math seems hard to a lot of people because it requires learning a new language ... a language of symbols and notations evolved over centuries. In fact, the American Mathematical Society has a specialized typesetting system for authors to use in writing mathematical papers, so they can get that notation correct. The symbols are important to mathematicians because they have very precise meanings, and everyone who understands that language will interpret the symbols in the same way. Luckily, we don't have to worry about this. We don't need such precise, unambiguous language. We can describe in plain English the ideas behind the mathematical notation.

So here we explain a lot of concepts taken from various fields of advanced math. A lot of this often gets lumped under the heading engineering math, because ... well, it's math that's used by engineers. When engineers study this, it's divided into various subfields and specializations. Here, we're just present some topics that come up in our work.

Some of this stuff will be familiar, because you've seen it in school. Other stuff you probably haven't seen before, but you'll be able to pick it up. The goal is not to make you a mathematician. The goal is to give you a visual understanding of some mathematical ideas that show up in computer graphics all the time.

Cartesian coordinates

When you describe a picture on a page, you might say something is in the upper left corner, or the lower right, etc. In other words, you can use two positions to name a location. On position says how far up or down the page, and one says how far to the left or right. You could think of a page as having areas like this:

 TopLeft TopCenter TopRight MiddleLeft MiddleCenter MiddleRight BottomLeft BottomCenter BottomRight

If we divide the page up even more, we can give a location more precisely. Trying to name each part of the page gets pretty messy though ... "the lower right corner of the middle center area."
To deal with that, we use numbers:

You may think it's kind of weird to count rows from bottom to top, but that's the tradition in math. Blame it on a guy named Rene Descartes, who's the same guy who said "I think therefore I am," so he must have been pretty smart (or at least he thought he was.) This whole system of identifying locations by two numbers is called Cartesian coordinates after him, and each number is a coordinate. It's also the tradition to give the horizontal coordinate first, and then the vertical. So when you see something like (47,92), it means 47 units from the left, and 92 units from the bottom.

This ability to describe any location on the page by two numbers is very important in both art and math. A vast amount of computer graphics programming depends on this, and there are some cool math tricks that take advantage of this way of looking at space. We'll look at some of this stuff later.