Next Contents Previous

3. Transforming coordinates

Now that computerized data reductions of digital images (e.g., CCD frames) are commonplace, it is frequently necessary to transform positions of stars from one cartesian coordinate system to another. For most practical purposes we need only consider that the coordinate systems of two CCD frames (possibly from different telescopes) are related by a translation of the origin, a rotation, a scale change, and possibly a flip (for instance, if one frame is from a prime focus and the other is from a cassegrain focus), since the effects of higher-order distortions are usually negligible in a typical five-arcminute field of view. Therefore, our transformation equations can be written in the form

Equation 58

So, if we have n stars, we have 2n equations in four unknowns: A, B, rho, and theta. The chintzy way out is to solve the x and y equations separately:

Equation 59

and then to fool around with Chat, Dhat, Ehat, and Fhat to get some compromise average values for rho and theta. There's a more elegant way to do it, however.

First, let's rewrite our original equations a bit: letting C = rho cos(theta) and D = rho sin(theta), we get

Equation 60

(forgetting for the moment the possibility of a flip - I presume you'll know ahead of time when you've got one). These can be rewritten again,

Equation 61

and yet again,

Equation 62


Equation 63

Remember: I told you the tj, i can be anything you can assign a numerical value to. Now we can use vanilla least squares to get the answers we want:

Equation 64

If you really want to know them, you can now compute rhohat = sqrt(Chat2 + Dhat2) and thetahat = arctan(Dhat / Chat) - no muss, no fuss, no compromises, just good, clean least squares straight from where you are to where you want to go.

Next Contents Previous