Rotating x,y points 45 degrees I have a two dimensional data set that I would like to rotate 45 degrees such that a 45 degree line from the points (0,0 and 10,10) becomes the x-axis. For example, the x,y points (1,1), (2,2), and (3,3) would be transformed to the points (0,1), (0,2), and (0,3), respectively, such that they now lie on the x-axis. The points (1,0), (2,0), and (3,0) would be rotated to the points  (1,1), (2,2), and (3,3). How can I calculate how to rotate a series of x,y point 45 degrees?

Here is some good background about this topic in wikipedia:
Rotation Matrix
