Rosetta  2020.37
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
core::grid::CartGrid< T > Class Template Reference

#include <CartGrid.hh>

Inheritance diagram for core::grid::CartGrid< T >:
Inheritance graph
[legend]

Public Types

typedef numeric::xyzVector< int > GridPt
 This needs to be an int, as it can hold negative values. More...
 

Public Member Functions

 CartGrid ()
 
 CartGrid (CartGrid< T > const &other)
 
CartGridoperator= (CartGrid< T > const &other)
 
 ~CartGrid () override=default
 
void setBase (core::Real x, core::Real y, core::Real z)
 
void setDimensions (core::Size nX, core::Size nY, core::Size nZ, core::Real lX, core::Real lY, core::Real lZ)
 
void set_name (std::string const &name)
 
std::string get_name () const
 
core::Size longestSide () const
 
bool equalDimensions (CartGrid< T > const &rhs) const
 
bool equalBase (CartGrid< T > const &rhs) const
 
bool is_in_grid (core::Real x, core::Real y, core::Real z) const
 
bool setupZones ()
 
void translate (core::Real x, core::Real y, core::Real z)
 
void setValue (core::Size ix, core::Size iy, core::Size iz, T value)
 
void setValue (core::Real fx, core::Real fy, core::Real fz, T value)
 
getValue (core::Size ix, core::Size iy, core::Size iz) const
 
getValue (core::Real fx, core::Real fy, core::Real fz) const
 
void zero ()
 
void setFullOccupied (T value)
 
void clone (CartGrid< T > &copy) const
 
void reset_boundaries ()
 
void read (std::string const &filename)
 
void write (std::string const &filename) const
 
bool isFullyOccupied () const
 
bool isEmpty () const
 
utility::json_spirit::Value serialize () const
 
void deserialize (utility::json_spirit::mObject grid_data)
 
void sum (utility::vector0< utility::pointer::shared_ptr< CartGrid< T > > > const &list_grids)
 
void expand (int expansion)
 
core::Vector getBase () const
 
core::Vector getTop () const
 
void getNumberOfPoints (core::Size &x, core::Size &y, core::Size &z) const
 
core::Vector getNumberOfPoints () const
 
GridPt gridpt (Vector const &coords) const
 
Vector coords (GridPt const &gridpt) const
 
getValue (GridPt const &gridpt) const
 
getValue (Vector const &coords) const
 
getMinValue () const
 
getMaxValue () const
 
void setValue (GridPt const &gridpt, T value)
 
void setValue (Vector const &coords, T value)
 
void write_to_BRIX (std::string const &filename) const
 
void write_to_BRIX (std::ostream &out) const
 

Private Member Functions

void setTop ()
 
bool valid_index (core::Size index) const
 
void setValue (int ix, int iy, int iz, T value)
 
void setValue (core::Size index, T value)
 
getValue (int ix, int iy, int iz) const
 
getValue (core::Size index) const
 
core::Size get_index (core::Size ix, core::Size iy, core::Size iz) const
 
core::Size get_index (core::Real fx, core::Real fy, core::Real fz) const
 

Private Attributes

core::Size nX_
 
core::Size nY_
 
core::Size nZ_
 
core::Real lX_
 
core::Real lY_
 
core::Real lZ_
 
core::Real bX_
 
core::Real bY_
 
core::Real bZ_
 
core::Real tX_
 
core::Real tY_
 
core::Real tZ_
 
std::string name_
 
core::Size npoints_
 
bool fullyOccupied_
 
utility::vector0< T > zones_
 

Member Typedef Documentation

template<typename T>
typedef numeric::xyzVector< int > core::grid::CartGrid< T >::GridPt

This needs to be an int, as it can hold negative values.

Constructor & Destructor Documentation

template<typename T>
core::grid::CartGrid< T >::CartGrid ( )
inline
template<typename T>
core::grid::CartGrid< T >::CartGrid ( CartGrid< T > const &  other)
inline
template<typename T>
core::grid::CartGrid< T >::~CartGrid ( )
overridedefault

Member Function Documentation

template<typename T>
void core::grid::CartGrid< T >::clone ( CartGrid< T > &  copy) const
inline
template<typename T>
Vector core::grid::CartGrid< T >::coords ( GridPt const &  gridpt) const
inline
template<typename T>
void core::grid::CartGrid< T >::deserialize ( utility::json_spirit::mObject  grid_data)
inline
template<typename T>
bool core::grid::CartGrid< T >::equalBase ( CartGrid< T > const &  rhs) const
inline
template<typename T>
bool core::grid::CartGrid< T >::equalDimensions ( CartGrid< T > const &  rhs) const
inline
template<typename T>
void core::grid::CartGrid< T >::expand ( int  expansion)
inline
template<typename T>
core::Size core::grid::CartGrid< T >::get_index ( core::Size  ix,
core::Size  iy,
core::Size  iz 
) const
inlineprivate
template<typename T>
core::Size core::grid::CartGrid< T >::get_index ( core::Real  fx,
core::Real  fy,
core::Real  fz 
) const
inlineprivate
template<typename T>
std::string core::grid::CartGrid< T >::get_name ( ) const
inline
template<typename T>
core::Vector core::grid::CartGrid< T >::getBase ( ) const
inline
template<typename T>
T core::grid::CartGrid< T >::getMaxValue ( ) const
inline
template<typename T>
T core::grid::CartGrid< T >::getMinValue ( ) const
inline
template<typename T>
void core::grid::CartGrid< T >::getNumberOfPoints ( core::Size x,
core::Size y,
core::Size z 
) const
inline
template<typename T>
core::Vector core::grid::CartGrid< T >::getNumberOfPoints ( ) const
inline
template<typename T>
core::Vector core::grid::CartGrid< T >::getTop ( ) const
inline
template<typename T>
T core::grid::CartGrid< T >::getValue ( core::Size  ix,
core::Size  iy,
core::Size  iz 
) const
inline
template<typename T>
T core::grid::CartGrid< T >::getValue ( core::Real  fx,
core::Real  fy,
core::Real  fz 
) const
inline
template<typename T>
T core::grid::CartGrid< T >::getValue ( GridPt const &  gridpt) const
inline
template<typename T>
T core::grid::CartGrid< T >::getValue ( Vector const &  coords) const
inline
template<typename T>
T core::grid::CartGrid< T >::getValue ( int  ix,
int  iy,
int  iz 
) const
inlineprivate
template<typename T>
T core::grid::CartGrid< T >::getValue ( core::Size  index) const
inlineprivate
template<typename T>
GridPt core::grid::CartGrid< T >::gridpt ( Vector const &  coords) const
inline
template<typename T>
bool core::grid::CartGrid< T >::is_in_grid ( core::Real  x,
core::Real  y,
core::Real  z 
) const
inline
template<typename T>
bool core::grid::CartGrid< T >::isEmpty ( ) const
inline
template<typename T>
bool core::grid::CartGrid< T >::isFullyOccupied ( ) const
inline
template<typename T>
core::Size core::grid::CartGrid< T >::longestSide ( ) const
inline
template<typename T>
CartGrid& core::grid::CartGrid< T >::operator= ( CartGrid< T > const &  other)
inline
template<typename T>
void core::grid::CartGrid< T >::read ( std::string const &  filename)
inline
template<typename T>
void core::grid::CartGrid< T >::reset_boundaries ( )
inline
template<typename T>
utility::json_spirit::Value core::grid::CartGrid< T >::serialize ( ) const
inline
template<typename T>
void core::grid::CartGrid< T >::set_name ( std::string const &  name)
inline
template<typename T>
void core::grid::CartGrid< T >::setBase ( core::Real  x,
core::Real  y,
core::Real  z 
)
inline
template<typename T>
void core::grid::CartGrid< T >::setDimensions ( core::Size  nX,
core::Size  nY,
core::Size  nZ,
core::Real  lX,
core::Real  lY,
core::Real  lZ 
)
inline
template<typename T>
void core::grid::CartGrid< T >::setFullOccupied ( value)
inline
template<typename T>
void core::grid::CartGrid< T >::setTop ( )
inlineprivate
template<typename T>
bool core::grid::CartGrid< T >::setupZones ( )
inline
template<typename T>
void core::grid::CartGrid< T >::setValue ( core::Size  ix,
core::Size  iy,
core::Size  iz,
value 
)
inline
template<typename T>
void core::grid::CartGrid< T >::setValue ( core::Real  fx,
core::Real  fy,
core::Real  fz,
value 
)
inline
template<typename T>
void core::grid::CartGrid< T >::setValue ( GridPt const &  gridpt,
value 
)
inline
template<typename T>
void core::grid::CartGrid< T >::setValue ( Vector const &  coords,
value 
)
inline
template<typename T>
void core::grid::CartGrid< T >::setValue ( int  ix,
int  iy,
int  iz,
value 
)
inlineprivate
template<typename T>
void core::grid::CartGrid< T >::setValue ( core::Size  index,
value 
)
inlineprivate
template<typename T>
void core::grid::CartGrid< T >::sum ( utility::vector0< utility::pointer::shared_ptr< CartGrid< T > > > const &  list_grids)
inline
template<typename T>
void core::grid::CartGrid< T >::translate ( core::Real  x,
core::Real  y,
core::Real  z 
)
inline
template<typename T>
bool core::grid::CartGrid< T >::valid_index ( core::Size  index) const
inlineprivate
template<typename T>
void core::grid::CartGrid< T >::write ( std::string const &  filename) const
inline
template<typename T>
void core::grid::CartGrid< T >::write_to_BRIX ( std::string const &  filename) const
inline

This format was choosen because it's space-efficient for small integer values (such as are typically stored in grids) and PyMOL can read it. Typical extension is .brix or .omap

Referenced by protocols::qsar::scoring_grid::SingleGrid::dump_BRIX(), and core::grid::CartGrid< core::Real >::write_to_BRIX().

template<typename T>
void core::grid::CartGrid< T >::write_to_BRIX ( std::ostream &  out) const
inline
template<typename T>
void core::grid::CartGrid< T >::zero ( )
inline

Member Data Documentation

template<typename T>
core::Real core::grid::CartGrid< T >::bX_
private
template<typename T>
core::Real core::grid::CartGrid< T >::bY_
private
template<typename T>
core::Real core::grid::CartGrid< T >::bZ_
private
template<typename T>
bool core::grid::CartGrid< T >::fullyOccupied_
private
template<typename T>
core::Real core::grid::CartGrid< T >::lX_
private
template<typename T>
core::Real core::grid::CartGrid< T >::lY_
private
template<typename T>
core::Real core::grid::CartGrid< T >::lZ_
private
template<typename T>
std::string core::grid::CartGrid< T >::name_
private
template<typename T>
core::Size core::grid::CartGrid< T >::npoints_
private
template<typename T>
core::Size core::grid::CartGrid< T >::nX_
private
template<typename T>
core::Size core::grid::CartGrid< T >::nY_
private
template<typename T>
core::Size core::grid::CartGrid< T >::nZ_
private
template<typename T>
core::Real core::grid::CartGrid< T >::tX_
private
template<typename T>
core::Real core::grid::CartGrid< T >::tY_
private
template<typename T>
core::Real core::grid::CartGrid< T >::tZ_
private
template<typename T>
utility::vector0< T > core::grid::CartGrid< T >::zones_
private

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