Clipper
Public Member Functions | List of all members
clipper::CXmap< T > Class Template Reference

Crystallographic map container. More...

#include <container_map.h>

Inheritance diagram for clipper::CXmap< T >:
clipper::Container clipper::Xmap< T > clipper::Xmap_base

Public Member Functions

 CXmap ()
 null constructor
 
 CXmap (Container &parent, const String name="")
 constructor: inherit spacegroup, cell and grid More...
 
void init (const Spacegroup &spacegroup, const Cell &cell, const Grid_sampling &grid_sampling)
 initialiser: supply or inherit spacegroup, cell and grid More...
 
void update ()
 hierarchical update More...
 
- 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::Xmap< T >
 Xmap ()
 Null constructor, for later initialisation.
 
 Xmap (const Spacegroup &spacegroup, const Cell &cell, const Grid_sampling &grid_sam)
 constructor: from spacegroup, cell, and grid
 
void init (const Spacegroup &spacegroup, const Cell &cell, const Grid_sampling &grid_sam)
 initialiser: from spacegroup, cell, and grid
 
const T & operator[] (const Xmap_base::Map_reference_index &ix) const
 get data by Map_reference_index
 
T & operator[] (const Xmap_base::Map_reference_index &ix)
 set data by Map_reference_index
 
const T & operator[] (const Xmap_base::Map_reference_coord &ix) const
 get data by Map_reference_coord
 
T & operator[] (const Xmap_base::Map_reference_coord &ix)
 set data by Map_reference_coord
 
const T & get_data (const Coord_grid &pos) const
 get a density value for an arbitrary position More...
 
void set_data (const Coord_grid &pos, const T &val)
 set a density value for an arbitrary position More...
 
const T & get_data (const int &index) const
 get data by index (not recommended) More...
 
bool set_data (const int &index, const T &val)
 set data by index (not recommended) More...
 
template<class I >
interp (const Coord_frac &pos) const
 get map value for fractional coord using supplied interpolator More...
 
template<class I >
void interp_grad (const Coord_frac &pos, T &val, Grad_frac< T > &grad) const
 get map value and grad for fractional coord using supplied interpolator More...
 
template<class I >
void interp_curv (const Coord_frac &pos, T &val, Grad_frac< T > &grad, Curv_frac< T > &curv) const
 get map value and curv for fractional coord using supplied interpolator More...
 
template<class I >
interp (const Coord_map &pos) const
 get map value for map coord using supplied interpolator More...
 
template<class I >
void interp_grad (const Coord_map &pos, T &val, Grad_map< T > &grad) const
 get map value and grad for map coord using supplied interpolator More...
 
template<class I >
void interp_curv (const Coord_map &pos, T &val, Grad_map< T > &grad, Curv_map< T > &curv) const
 get map value and curv for map coord using supplied interpolator More...
 
template<class H >
void fft_from (const H &fphidata, const FFTtype type=Default)
 FFT from reflection list to map. More...
 
template<class H >
void fft_to (H &fphidata, const FFTtype type=Default) const
 FFT from map to reflection list. More...
 
const Cellcell () const
 
const Spacegroupspacegroup () const
 
const Grid_samplinggrid_sampling () const
 
const Grid_rangegrid_asu () const
 
Coord_grid coord_of (const int &index) const
 
int index_of (const Coord_grid &coord) const
 
const int multiplicity (const Coord_grid &pos) const
 
const Coord_grid to_map_unit (const Coord_grid &pos) const
 
const Map_reference_index first () const
 
const Map_reference_coord first_coord () const
 
const T & operator= (const T &value)
 assignment operator: assigns a single value to the whole map More...
 
const Xmap< T > & operator+= (const Xmap< T > &other)
 add another map to this one More...
 
const Xmap< T > & operator-= (const Xmap< T > &other)
 subtract another map from this one More...
 
- Public Member Functions inherited from clipper::Xmap_base
bool is_null () const
 test if object has been initialised More...
 
const Cellcell () const
 get the cell
 
const Spacegroupspacegroup () const
 get the spacegroup
 
const Grid_samplinggrid_sampling () const
 get the cell grid
 
const Grid_rangegrid_asu () const
 get the ASU grid
 
Coord_grid coord_of (const int &index) const
 map coordinate from index More...
 
int index_of (const Coord_grid &coord) const
 map index from coordinate More...
 
Coord_grid to_map_unit (const Coord_grid &pos) const
 function to pick right cell repeat for any grid coord
 
const RTopoperator_orth_grid () const
 return the orthogonal-to-grid coordinate operator (translation is zero)
 
const RTopoperator_grid_orth () const
 return the grid-to-orthogonal coordinate operator (translation is zero)
 
Coord_orth coord_orth (const Coord_map &cm) const
 convert map coordinate to orthogonal More...
 
Coord_map coord_map (const Coord_orth &co) const
 convert orthogonal coordinate to map More...
 
bool in_map (const Coord_grid &) const
 (This method is for compatibility with NXmap - it always returns true)
 
template<class I >
bool in_map (const Coord_map &cm) const
 (This method is for compatibility with NXmap - it always returns true)
 
int multiplicity (const Coord_grid &pos) const
 get multiplicity of a map grid point More...
 
Map_reference_index first () const
 return a Map_reference_index for this map
 
Map_reference_coord first_coord () const
 return a Map_reference_coord for this map
 

Additional Inherited Members

- Public Types inherited from clipper::Xmap_base
enum  FFTtype { Default, Normal, Sparse }
 
- Static Public Member Functions inherited from clipper::Xmap_base
static FFTtype & default_type ()
 set/get default backend type
 
- Protected Member Functions inherited from clipper::Xmap_base
 Xmap_base ()
 Null constructor, for later initialisation. More...
 
void init (const Spacegroup &spacegroup, const Cell &cell, const Grid_sampling &grid_sam)
 initialiser More...
 
void find_sym (const Coord_grid &base, int &index, int &sym) const
 
void asu_error (const Coord_grid &pos) const
 
- Protected Attributes inherited from clipper::Xmap_base
ObjectCache< Xmap_cacheobj >
::Reference 
cacheref
 object cache reference
 
const unsigned char * asu
 fast access ptr
 
const Isymopisymop
 fast access ptr
 
const int * du
 fast access ptr
 
const int * dv
 fast access ptr
 
const int * dw
 fast access ptr
 
Grid_range asu_grid
 fast access copy
 
Grid_range map_grid
 fast access copy
 
int nsym
 fast access copy
 
Cell cell_
 unit cell
 
Spacegroup spacegroup_
 spacegroup
 
Grid_sampling grid_sam_
 grid for the whole cell
 
RTop rt_orth_grid
 orth->grid operator
 
RTop rt_grid_orth
 grid->orth operator
 
- Static Protected Attributes inherited from clipper::Xmap_base
static FFTtype default_type_ = Xmap_base::Sparse
 default backend type
 

Detailed Description

template<class T>
class clipper::CXmap< T >

Crystallographic map container.

CXmap: This is a crystallographic map.

Constructor & Destructor Documentation

template<class T >
clipper::CXmap< T >::CXmap ( Container parent,
const String  name = "" 
)

constructor: inherit spacegroup, cell and grid

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

template<class T >
void clipper::CXmap< T >::init ( const Spacegroup spacegroup,
const Cell cell,
const Grid_sampling grid_sampling 
)

initialiser: supply or inherit spacegroup, cell and grid

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 for the map.
nameThe cell for the map.
gridThe grid for the map.
template<class T >
void clipper::CXmap< T >::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 file: