4.8.5 - Predicted Laue Spots List - JdlPredictedLaueSpotsList

John W. Campbell

4.8.5.1 Introduction

This class stores a list of predicted spots for a Laue X-ray crystallographic image. The class has methods for adding/deleting spots, sorting the spots list and calculating which spots will be spatially overlapped for a given spot size. In general, spots are handled as JdlPredictedLaueSpot objects.

Class, constructors and methods:

Class Details
Accessible Fields
Constructors
Manipulate Spot List
Get Spot Data
Sort Spot List
Spatial Overlaps
Convert Indices
Predict Deconvolution

4.8.5.2 Class Details

Package:
Jdl.JdlPX;
Class name:
JdlPredictedLaueSpotsList
Class definition:
public class JdlPredictedLaueSpotsList
Extends:
Object
Implements:
JdlLaueSpotOutputHandler
Actions:
none

4.8.5.3 Accessible Fields

No fields with public, package or protected access defined.

4.8.5.4 Constructors

4.8.5.4.1 Introduction

Constructors are available to construct a JdlPredictedLaueSpotsList object with either a default capacity or a user specified capacity.

Constructors:

Default Constructor
Standard Constructor

4.8.5.4.2 Default Constructor

This constructs a JdlPredictedLaueSpotsList object with an initial capacity for 1000 spots to be incremented in blocks of 1000 spots as required.

Constructor Definition:
public JdlPredictedLaueSpotsList()
Parameters List:
none

4.8.5.4.3 Standard Constructor

This constructs a JdlPredictedLaueReflList object with a user specified initial capacity and a user specified increment if the list needs to be expanded.

Constructor Definition:
public JdlPredictedLaueSpotsList (int nr, int inc)
Parameters List:
nr
The initial capacity required (number of spots).
inc
The increment in number of spots required each time the list needs to be expanded.

4.8.5.5 Manipulate Spot List

4.8.5.5.1 Introduction

This section has methods to clear the list and to add/delete/insert replace spots in the list.

Methods:

Clear list - clearList
Add spot - addSpot
Insert spot - insertSpot
Replace spot - replaceSpot
Delete spot - deleteSpot
Delete spots - deleteImageSpots

4.8.5.5.2 Clear list - clearList

This method clears the spots list (i.e. removes all entries though does not decrease its capacity).

Method Definition:
public void clearList()
Parameters List:
none

4.8.5.5.3 Add spot - addSpot

This method adds a spot to the end of the list.

Method Definition:
public void addSpot (JdlPredictedLaueSpot refl)
Parameters List:
refl
The spot to be added.

4.8.5.5.4 Insert spot - insertSpot

This method inserts a spot at a given position within the list.

Method Definition:
public void insertSpot (JdlPredictedLaueSpot refl, int iref)
Parameters List:
refl
The spot to be inserted.
iref
The position within the list where the spot is to be inserted (spot positions numbered from 1 upwards).

4.8.5.5.5 Replace spot - replaceSpot

This method replaces a spot at a given position within the list.

Method Definition:
public void replaceSpot (JdlPredictedLaueSpot refl, int iref)
Parameters List:
refl
The spot to replace a current spot.
iref
The position within the list where the spot is to be replaced (spot positions numbered from 1 upwards).

4.8.5.5.6 Delete spot - deleteSpot

This method deletes a spot from the list.

Method Definition:
public void deleteSpot (int iref)
Parameters List:
iref
The position within the list of the spot to be deleted (spot positions numbered from 1 upwards).

4.8.5.5.7 Delete spots - deleteImageSpots

This method deletes all spots for a given image number.

Method Definition:
public void deleteImageSpots (int imgnum)
Parameters List:
imgnum
The image number of the image for which the spots are to be deleted.

4.8.5.6 Get Spot Data

4.8.5.6.1 Introduction

This section has methods to retrieve data from the spots list.

Methods:

Get number of spots - getNumberOfSpots
Get number of spots - getNumberOfImageSpots
Get number of spatial overlaps - getNumberOfSpatialOverlaps
Get spot reference - getSpot
Get spot copy - getSpotCopy
Get sort order - getSortOrder

4.8.5.6.2 Get number of spots - getNumberOfSpots

This method returns the number of spots currently in the spot list.

Method Definition:
public int getNumberOfSpots()
Parameters List:
none
Method Return:
The number of spots in the list.

4.8.5.6.3 Get number of spots - getNumberOfImageSpots

This method returns the number of spots currently in the spot list for a selected crystal and image number.

Method Definition:
public int getNumberOfImageSpots(int icrys, int imgnum)
Parameters List:
icrys
The selected crystal number.
imgnum
The selected image number.
Method Return:
The number of spots in the list for the requested crystal and image.

4.8.5.6.4 Get number of spatial overlaps - getNumberOfSpatialOverlaps

This method returns the number of spatially overlapped spots currently in the spot list for a selected crystal and image number. The spatial overlaps must have been calculated using the setSpatialOverlaps(..) method directly or via the predictSpots(..) method with 'spat' set to true;

Method Definition:
public int getNumberOfSpatialOverlaps(int icrys, int imgnum)
Parameters List:
icrys
The selected crystal number (-1 = all crystal numbers).
imgnum
The selected image number (-1 = all image numbers).
Method Return:
The number of spots in the list for the requested crystal and image.

4.8.5.6.5 Get spot reference - getSpot

This method returns a reference to the store JdlPredictedLaueSpot object for a spot at a selected position in the list.

Method Definition:
public JdlPredictedLaueSpot getSpot (int iref)
Parameters List:
The
position in the list of the spot to be returned (from 1 upwards).
Method Return:
The JdlPredictedLaueSpot object for the spot (reference to stored object - not a copy/clone).

4.8.5.6.6 Get spot copy - getSpotCopy

This method returns a copy of the JdlPredictedLaueSpot object for a spot at a selected position in the list.

Method Definition:
public JdlPredictedLaueSpot getSpotCopy (int iref)
Parameters List:
iref
The position in the list of the spot to be returned (from 1 upwards).
Method Return:
A JdlPredictedLaueSpot object for the spot. This is a clone (copy) of the stored object.

4.8.5.6.7 Get sort order - getSortOrder

This method returns the current sort order.

Method Definition:
public int getSortOrder()
Parameters List:
none
Method Return:
The sort order:
= 1, Sorted on h, k and l
= 2, Sorted on nh, nk and nl (nodal indices)
= 3, Sorted on axis 1 coordinate
= 4, Sorted on axis 2 coordinate
= 5, Sorted on 'h'
= 6, Sorted on 'k'
= 7, Sorted on 'l'
= 8, Sorted on 'nh'
= 9, Sorted on 'nk'
= 10, Sorted on 'nl'
= 11, Sorted on lambda - ascending
= 12, Sorted on lambda - descending
= 0, May not be sorted.

4.8.5.7 Sort Spot List

4.8.5.7.1 Introduction

This section has a single method to sort the spot list using one of the available sort options.

Method:

Sort spot list - sortSpotList

4.8.5.7.2 Sort spot list - sortSpotList

This method sorts the spot list based on the selected option.

Method Definition:
public void sortSpotList (int srt_opt)
Parameters List:
sort_opt
Sort order option:
= 1, Sort on h, k and l
= 2, Sort on nh, nk and nl (nodal indices)
= 3, Sort on axis 1 coordinate
= 4, Sort on axis 2 coordinate
= 5, Sort on 'h'
= 6, Sort on 'k'
= 7, Sort on 'l'
= 8, Sort on 'nh'
= 9, Sort on 'nk'
= 10, Sort on 'nl'
= 11, Sort on lambda - ascending
= 12, Sort on lambda - descending

4.8.5.8 Spatial Overlaps

4.8.5.8.1 Introduction

This section has a single method to set the spatial overlap flags for the spots in the list.

Method:

Spatial overlaps - setSpatialOverlaps
Predict spot list - predictSpots
Predict spot list - predictSpots
Predict spots set - predictSpotsSet
Predict spots set - predictSpotsSet

4.8.5.8.2 Spatial overlaps - setSpatialOverlaps

This method determines the spatially overlapped spots (and sets an internal flag) for the spots of a given crystal and image. The overlap criterion is based on the given spot diameter. The number of spatially overlapped spots is returned.

Method Definition:
public int setSpatialOverlaps (int icrys, int img_id, double spotd)
Parameters List:
icrys
The selected crystal number.
img_id
The selected image number or identifier as stored when the spot list was predicted.
spotd
The spot diameter for the image im mm.
Method Return:
The number of spatially overlapped spots found for the image.

4.8.5.8.3 Predict spot list - predictSpots

This method predicts and stores a spot list using the parameters stored in a JdlDiffractionDataModule object. Note that the image identifiers stored may be found from the range and image numbers using the JdlDiffractionDataModule.setImageID(..) method.

Method Definition:
public void predictSpots(JdlDiffractionDataModule ddm, int iset, int irange, int imgnum, boolean spat, boolean append)
Parameters List:
ddm
The JdlDiffractionDataModule object containing the detector and crystal data.
iset
The set number within the Diffraction Data Module.
irange
The rotation range number.
imgnum
The number of the image (> 0, within the requested rotation range) for which the prediction is to be carried out.
spat
If true calculate spatial overlap flags after generating the spot list, if false do not.
append
If true, append the spots to any spots already stored. If false clear any stored spots before creating the list.

4.8.5.8.4 Predict spot list - predictSpots

This method predicts and stores a spot list using the parameters stored in JdlPositionedDetector and JdlPositionedCrystal objects. Note that the image identifiers stored may be found from the range and image numbers using the JdlDiffractionDataModule.setImageID(..) method.

Method Definition:
public void predictSpots(JdlPositionedDetector posdet, JdlPositionedCrystal poscrys, int icrys, int irange, double rotstart, double ang_inc, int imgnum, double rmin, double xmin, double xmax, double ymin, double ymax, boolean spat, boolean append)
Parameters List:
posdet
A JdlPositionedDetector object containing details of the positioned detector, gonioneter and X-ray source.
poscrys
A JdlPositionedCrystal containing details of the crystal cell, symmetry and setting.
icrys
The crystal number >0 (The image may be identified by the crystal number and image number).
irange
A rotation range number for which 'rotstart' is the start angle.
rotstart
The start rotation angle for the range in degrees (see also imgnum).
ang_inc
The angle increment between images in degrees.
imgnum
The number of the image for which the prediction is to be carried out from 1 up within the requested range (The rotation angle used will be rotstart + (imgnum-1)*ang_inc).
rmin
Minimum radius for prediction in mm.
xmin
Minimum 'x' limit for prediction in mm (ignored if xmin = xmax)
xmax
Maximum 'x' limit for prediction in mm (ignored if xmax = xmin)
ymin
Minimum 'y' limit for prediction in mm (ignored if ymin = ymax)
ymax
Maximum 'y' limit for prediction in mm (ignored if ymax = ymin)
spat
If true calculate spatial overlap flags after generating the spot list, if false do not.
append
If true, append the spots to any spots already stored. If false clear any stored spots before creating the list.

4.8.5.8.5 Predict spots set - predictSpotsSet

This method predicts and stores a spots list using the parameters stored in a JdlDiffractionDataModule object. The prediction is carried out for a set of images covering a given 'rotation' range. Note that the image identifiers stored may be found from the range and image numbers using the JdlDiffractionDataModule.setImageID(..) method. The generated reflections are added to any currently in the spots list.

Method Definition:
public void predictSpotsSet(JdlDiffractionDataModule ddm, int iset, int irange, int setting_opt, boolean spat, JdlProgressHandler progress)
Parameters List:
ddm
The JdlDiffractionDataModule object containing the detector and crystal data.
iset
The set number within the Diffraction Data Module.
irange
The 'rotation' range number.
setting_opt
This determines the exact setting parameters used for each image prediction:
= 0, Use the setting parameters defined for the first image of the complete dataset
= 1, Use the setting parameters defined for the first image of the specified range
= 2, Use the setting parameters defined for each individual image
Note that, in most cases, it is likely that the setting parameters for all images of the set will in fact be identical.
spat
If true calculate spatial overlap flags after generating the reflection list, if false do not.
progress
Progress handler (may be null if not required).

4.8.5.8.6 Predict spots set - predictSpotsSet

This method predicts and stores a spots list using the parameters stored in JdlPositionedDetector and JdlPositionedCrystal objects. The prediction is carried out for a set of images covering a given 'rotation' range. The method clears the spots list prior to the predictions. Note that the image identifiers stored may be found from the range and image numbers using the JdlDiffractionDataModule.setImageID(..) method. The generated reflections are added to any currently in the spots list.

Method Definition:
public void predictSpotsSet(JdlPositionedDetector posdet, JdlPositionedCrystal poscrys, int icrys, int irange, double rotstart, double rotend, double anginc, double rmin, double xmin, double xmax, double ymin, double ymax, boolean spat, JdlProgressHandler progress)
Parameters List:
posdet
A JdlPositionedDetector object containing details of the positioned detector, gonioneter and X-ray source.
poscrys
A JdlPositionedCrystal containing details of the crystal cell, symmetry and setting.
icrys
The crystal number (The image may be identified by the crystal number and image identifier).
irange
a range number > 0 to be associated with the given 'rotation' range.
rotstart
The start rotation angle in degrees.
rotend
The end rotation angle in degrees.
anginc
The angle increment between images in degrees.
rmin
Minimum radius for prediction in mm.
xmin
Minimum 'x' limit for prediction in mm (ignored if xmin = xmax)
xmax
Maximum 'x' limit for prediction in mm (ignored if xmax = xmin)
ymin
Minimum 'y' limit for prediction in mm (ignored if ymin = ymax)
ymax
Maximum 'y' limit for prediction in mm (ignored if ymax = ymin)
spat
If true calculate spatial overlap flags for each image, if false do not.
progress
Progress handler (may be null if not required).

4.8.5.9 Convert Indices

4.8.5.9.1 Introduction

This section has methods to convert the reflection entries between measured and unique indices (+ symmetry number).

Methods:

Convert to unique - indicesToUnique
Convert to measured - indicesToMeasured

4.8.5.9.2 Convert to unique - indicesToUnique

This method converts the measured indices to unique indices + symmetry numbers. If a reflection has already been converted (symmetry number set), no action will be taken for that reflection.

Method Definition:
public boolean indicesToUnique (JdlSymmetry symm)
Parameters List:
symm
The symmetry (must be complete).
Method Return:
Returns true ik Ok, false if symmetry not complete.

4.8.5.9.3 Convert to measured - indicesToMeasured

This method converts the unique indices (+stored symmetry) to measured indices. If a reflection is not stored as unique (symmetry number not set), no action will be taken for that reflection.

Method Definition:
public boolean indicesToMeasured (JdlSymmetry symm)
Parameters List:
symm
The symmetry (must be complete).
Method Return:
Returns true ik Ok, false if symmetry not complete.

4.8.5.10 Predict Deconvolution

4.8.5.10.1 Introduction

This section has a method predict the potential for Laue harmonics deconvolution based on multiple measurements and a given wavelength normalisation curve.

Methods:

Predict deconvolution - deconvPredict

4.8.5.10.2 Predict deconvolution - deconvPredict

This method predicts possible harmonics deconvolution from the stored spots and a supplied wavelength normalisation curve. The indices in the spots list must be converted to their unique form prior to calling this method. A new spots list of the singles and deconvoluted multiples is output. Note that this method sorts the current spots list by nodal index. Note that spatial overlaps calculations should have been done for the input spots list(s) prior to this deconvolution.

Method Definition:
public JdlPredictedLaueSpotsList deconvPredict(JdlChebyshevPolynomial curv, double sc_max)
Parameters List:
curv
A wavelength normalisation curve to be used in the deconvolution prediction.
sc_max
A maximum scale factor (derived from the wavelength normalisation curve) to be used e.g. 25.0.
Method Return:
Returns a new spot list containing the singles and and 'deconvoluted' multiples.

⇑ Up 2   ⇑ Up 1   ⇑ Top of this