Primary Beam Position Conventions

This document compares the conventions for defining the primary beam position in a number of data processing and display programs. If you only wish to know how to convert the primary beam position from one program to another you can go to the Summary at the end. The primary beam position for each program was calculated using a single wax image taken using the ADSC Quantum-4 CCD detector, at a sample to detector distance of 280 mm, using x-rays of wavelength 0.87 Å. Each program allowed positions on the wax ring to be measured in mm, pixels, or both and from four positions around the wax ring the primary beam position was calculated. The CCD detector is 2304 by 2304 pixels (or 188 by 188 mm) in size with each pixel being 0.0816 mm. The terms 1st and 2nd pixel or 1st and 2nd mm refer to the 1st and 2nd coordinates of the primary beam position (or indeed any position on the image, in pixels or mm's) and are used to avoid confusion over X beam and Y beam naming conventions.

ADXV

The adxv program is the display package that comes with the ADSC Quantum-4 CCD detector. Using this program the positions on the image can be determined in pixels or mm and the primary beam position thus calculated in both. The origin is different for pixels and mm as shown below.

From the wax image the primary beam position was calculated to be: 94.4 92.25 mm or 1156 1173.5 pixels. Due to the different origin for mm and pixels the mm to pixel conversion is not straightforward. For the first coordinate the value in mm must be divided by 0.0816 to give the value in pixels. The second coordinate must be subtracted from 188 and the result divided by 0.0816 to give the value in pixels.

Ipdisp

The ipdisp program may be used to display the CCD images provided the correct spdfil is available. This program displays positions in mm and pixels but has different conventions for each as shown below.

Using this program the primary beam position was calculated to be: 96 94.65 mm or 1160 1176.5 pixels. To convert mm to pixels the first and second coordinates must be swapped around and then divided by 0.0816.

Mosflm

This program can be used to display and process the data. Positions are again given in mm or pixels and both have the same origin and conventions, as shown below.

Using mosflm the primary beam position was calculated to be: 95.55 94.45mm or 1172 1157 pixels. Conversion of mm to pixels is done by dividing by 0.0816.

Denzo

This is another program allowing image display and processing. Positions in the image are given in mm and pixels. The convention is shown below.

From denzo the primary beam position was calculated to be 95.7 94.4 mm or 1156.8 1173 pixels. Conversion of mm to pixels is done by dividing by 0.0816 and then swapping the 1st and 2nd coordinates around.

D*trek

This program allows image display and processing, including fine phi slicing. Positions are given in mm and pixels ('image coordinates'). Different conventions are used for each as shown below.

Using the display package of d*trek the primary beam position was calculated to be 1155.65 1174 pixels and -1.375 -1.305 mm.

Image Viewing Conventions

The above programs have different conventions for viewing an image. Some view from the 'front', others from the 'back' and some even rotate the image through 90°. The differences between the programs are shown below using a lysozyme image as an example.

ADXV

Ipdisp

Mosflm

Denzo

D*trek

As can be seen from the above, adxv, ipdisp and denzo all display the image from the same viewpoint. Mosflm rotates the image by 90° anticlockwise and then views it from 'behind'. D*trek also views the image from 'behind'.

Primary beam position comparisons between the programs

The programs adxv, ipdisp, mosflm, denzo and d*trek all give positions in pixels. If we imagine changing the viewing direction of the programs until they are all equivalent we get the results shown below. Here 1st and 2nd pixel refer to the 1st and 2nd coordinates of the primary beam position (or indeed any other position on the image).

From this we can see that, in pixels, the primary beam position should be the same in adxv, ipdisp, denzo and d*trek. The Mosflm primary beam position must have it's coordinates swapped around to be compatible with the other programs.

The programs adxv, ipdisp, mosflm and denzo all give positions in mm. Again, if we imagine changing the viewing direction of the programs unitl they are all equivalent we get the results shown below. Here 1st and 2nd mm refer to the 1st and 2nd coordinates of the primary beam position (or indeed any other position on the image).

From this we can see that the primary beam position in mm should be the same in ipdisp, mosflm and denzo. The adxv primary beam position may be converted to be compatible with the other programs by the following: 188 minus the 2nd coordinate from adxv becomes the 1st coordinate of the other programs. The 1st coordinate of adxv then becomes the 2nd coordinate of the other programs.

Disagreement between the values quoted comes from the inaccuracy involved in using the cursor to determine the four positions required to work out the primary beam position.

Summary

Primary Beam Position in mm

The primary beam position in mm should be the same in ipdisp, mosflm and denzo. To convert the adxv primary beam position to be compatible with the other programs do the following. To get the first coordinate, take 188 minus the 2nd coordinate of adxv. For the second coordinate take the first coordinate of adxv.

Primary Beam Position in Pixels

The primary beam position in pixels should be the same in adxv, ipdisp, denzo and d*trek. To be compatible with the other programs mosflm coordinates must be swapped around (i.e. first coordinate becomes second coordinate and second becomes first).

Conversion of mm to Pixels

Adxv

Ipdisp Mosflm Denzo D*trek