Coordinate systems

Using numbers to represent vectors

Let \(\vec{v}\) be a vector on a plane. Let’s assume that there exist some other vectors \(\vec{i}\) and \(\vec{j}\) on the same plane such that, for some values of \(x, y \in \mathbb{R} \) we can express \(\vec{v}\) as:

$$ \vec{v} = x \vec{i} + y \vec{j} $$

In such a scenario, we can call the ordered list \((\vec{i}, \vec{j})\) a coordinate system for the plane and we call the pair \((x, y)\) the coordinates of \(\vec{v}\) in that coordinate system.

In general it is much easier for us humans, to do linear algebra without relying on coordinates; stuff with coordinates get complicated very quickly. On the plane every vector is described by two coordinates; but in the space you need three coordinates; which becomes four if you want to model the concepts of translation and/or projection (more on this in an upcoming post) and in computer graphics you most likely want to.

With that said, there are a few things that are easier using coordinates, provided that you chose a nice coordinate system. Nice coordinate systems are made of vectors whose length is \(1\) and are at right angles between each other. We call such coordinate systems orthonormal coordinate systems.

Length of a vector

Let’s choose an orthonormal coordinate system \((\vec{i}, \vec{j})\) on a plane.

By the Pythagorean theorem, the length \(v\) of a vector on a plane \(\vec{v}\) with coordinates \((x, y)\) is given by:

$$ v = \sqrt{x^2 + y^2} $$

This is also true in a space for a vector \(\vec{v}\) with coordinates \((x, y, z)\) according to some orthonormal coordinate system \((\vec{i}, \vec{j}, \vec{k})\):

$$ v = \sqrt{x^2 + y^2 + z^2} $$

Angle between two vectors

Let’s choose an orthonormal coordinate system \((\vec{i}, \vec{j})\) on a plane. Let’s take a a vector \(\vec{v}\) with coordinates \((x, y)\) and length \(1\).

$$ v = \sqrt{x^2 + y^2} = 1 $$

The tip of such vector must lie on a circle with radius \(1\) centered on the origin. Let’s call \(\theta\) the angle, in radians, between \(\vec{i}\) \(\vec{v}\). Then we must have:

$$ x = \cos{\theta} ~~~~~~~~ y = \sin{\theta} $$


comments powered by Disqus