Clipper
clipper::CHKL_info Class Reference

HKL list and indexing object container. More...

#include <container_hkl.h>

Inheritance diagram for clipper::CHKL_info:
clipper::Container clipper::HKL_info

Public Member Functions

 CHKL_info (const String name="", const Spacegroup &spacegroup=NullSpacegroup, const Cell &cell=NullCell, const Resolution &resolution=NullResolution, const bool &generate=false)
 constructor: make null object or top object in tree
 CHKL_info (Container &parent, const String name="", const bool &generate=false)
 constructor: inherit spacegroup, cell and resolution
void init (const Spacegroup &spacegroup, const Cell &cell, const Resolution &resolution, const bool &generate=false)
 initialiser: supply or inherit spacegroup, cell and resolution
void generate_hkl_list ()
 synthesize hkl list and update children
void update ()
 hierarchical update
Public Member Functions inherited from clipper::Container
 Container (const String name="")
 constructor: make null object or top object in a tree
 Container (Container &parent, const String &path)
 constructor: from any other member and a relative path
String path () const
 get the path of this tree object
String name () const
 get the name of this tree object
void set_name (const String &name)
 set the name of this tree object
bool is_destroyed_with_parent () const
 is this object to be destroyed when parent is destroyed?
void set_destroyed_with_parent (const bool d=true)
 set this object to be destroyed when parent is destroyed
void move (const String &path)
 'move' method moves this object to somewhere else in the hierarchy
bool has_parent () const
 test if this object has a parent
const Containerparent () const
 get the parent of this object
Containerparent ()
 get the parent of this object
int num_children () const
 return number of children
const Containerchild (const int &i) const
 get the i'th child of this object
Containerchild (const int &i)
 get the i'th child of this object
const Containerultimate_parent () const
 get the ultimate parent of this object - the top of the tree
Containerultimate_parent ()
 get the ultimate parent of this object - the top of the tree
Containerparent_ptr ()
 get the parent of this object (NULL on fail)
template<class T>
T * parent_of_type_ptr ()
 search up the tree for a parent of the specified type (NULL on fail)
Containerfind_path_ptr (const String &path)
 find an object using a directory-like path (NULL on fail)
virtual ~Container ()
 destructor: virtual
void debug ()
Public Member Functions inherited from clipper::HKL_info
 HKL_info ()
 null constructor
 HKL_info (const Spacegroup &spacegroup, const Cell &cell, const Resolution &resolution, const bool &generate=false)
 constructor: Takes spacegroup, cell, and resolution
void init (const Spacegroup &spacegroup, const Cell &cell, const Resolution &resolution, const bool &generate=false)
 initialiser: Takes spacegroup, cell, and resolution
void init (const Spacegroup &spacegroup, const Cell &cell, const HKL_sampling &hkl_sampling, const bool &generate=true)
 initialiser: Takes spacegroup, cell, and HKL_sampling
bool is_null () const
 test if object has been initialised
const Cellcell () const
 get the cell
const Spacegroupspacegroup () const
 get the spacegroup
const HKL_samplinghkl_sampling () const
 [CLIPPER2] get HKL_sampling
const Resolutionresolution () const
 get the resolution
void generate_hkl_list ()
 synthesize hkl list
void add_hkl_list (const std::vector< HKL > &add)
 add new reflections to the list
int num_reflections () const
 get number of reflections in the object
const HKLhkl_of (const int &index) const
 reflection hkl from index
int index_of (const HKL &rfl) const
 reflection index from hkl
const ftype32 & invresolsq (const int &index) const
 get reflection resolution using lookup
const Range< ftype > & invresolsq_range () const
 get resolution limits of the list
const HKL_classhkl_class (const int &index) const
 get reflection class using lookup
HKL find_sym (const HKL &rfl, int &sym, bool &friedel) const
 find symop no and friedel to bring an HKL into ASU
HKL_reference_index first () const
 return HKL_reference_index pointing to first reflection
void debug () const

Additional Inherited Members

Protected Member Functions inherited from clipper::HKL_info
void update_hkl_list ()
 finalise reflection list
Protected Attributes inherited from clipper::HKL_info
Spacegroup spacegroup_
 spacegroup
Cell cell_
 unit cell
HKL_sampling hkl_sampling_
 hkl sampling
Resolution resolution_
 resolution limit
std::vector< Isymopisymop
 integer symops
std::vector< HKLhkl
 the reflection list
std::vector< HKL_classhkl_class_lookup
 fast epsilon/centricity lookup table
std::vector< ftype32 > invresolsq_lookup
 fast resolution lookup table
HKL_lookup lookup
 fast reflection lookup table
Range< ftypeinvresolsq_range_
 resolution limit of the current reflection list

Detailed Description

HKL list and indexing object container.

CHKL_info: This is the reflection list object for reflection data objects to reference in order to identify their data entries.

Constructor & Destructor Documentation

◆ CHKL_info() [1/2]

clipper::CHKL_info::CHKL_info ( const String name = "",
const Spacegroup & spacegroup = NullSpacegroup,
const Cell & cell = NullCell,
const Resolution & resolution = NullResolution,
const bool & generate = false )

constructor: make null object or top object in tree

Construct and initialise as the top object in a tree.

Parameters
spacegroupThe spacegroup.
cellThe cell.
resolutionThe resolution.
generateGenerate reflection list if true.

◆ CHKL_info() [2/2]

clipper::CHKL_info::CHKL_info ( Container & parent,
const String name = "",
const bool & generate = false )

constructor: inherit spacegroup, cell and resolution

The object is constructed at the given location in the hierarchy. An attempt is made to initialise the object using information from its parents in the hierarchy.

Parameters
parentAn object in the hierarchy (usually the parent of the new object).
nameThe path from parent to the new object (usually just the name of the new object).

Member Function Documentation

◆ init()

void clipper::CHKL_info::init ( const Spacegroup & spacegroup,
const Cell & cell,
const Resolution & resolution,
const bool & generate = false )

initialiser: supply or inherit spacegroup, cell and resolution

An attempt is made to initialise the object using information from the supplied parameters, or if they are Null, from its parents in the hierarchy.

Parameters
spacegroupThe spacegroup.
cellThe cell.
resolutionThe resolution.
generateGenerate reflection list if true.

◆ generate_hkl_list()

void clipper::CHKL_info::generate_hkl_list ( )

synthesize hkl list and update children

The reflection list is sythesized to match the given spacegroup, cell, and resolution, and a hierarchical update is triggered to update the sizes of the reflection lists for all dependent HKL_data objects.

◆ update()

void clipper::CHKL_info::update ( )
virtual

hierarchical update

Hierarchical update. If this object is uninitialised, an attempt is made to initialise the object using information from its parents in the hierarchy. The childen of the object are then updated.

Reimplemented from clipper::Container.


The documentation for this class was generated from the following files: