BALL  1.5.0
structureMapper.h
Go to the documentation of this file.
1 // -*- Mode: C++; tab-width: 2; -*-
2 // vi: set ts=2:
3 //
4 
5 #ifndef BALL_STRUCTURE_STRUCTUREMAPPER_H
6 #define BALL_STRUCTURE_STRUCTUREMAPPER_H
7 
8 #ifndef BALL_COMMON_H
9 # include <BALL/common.h>
10 #endif
11 
12 #ifndef BALL_CONCEPT_PROCESSOR_H
13 # include <BALL/CONCEPT/processor.h>
14 #endif
15 
16 #ifndef BALL_STRUCTURE_GEOMETRICTRANSFORMATIONS_H
18 #endif
19 
20 #ifndef BALL_DATATYPE_STRING_H
21 # include <BALL/DATATYPE/string.h>
22 #endif
23 
24 #ifndef BALL_KERNEL_PROTEIN_H
25 # include <BALL/KERNEL/protein.h>
26 #endif
27 
28 #ifndef BALL_KERNEL_ATOM_H
29 # include <BALL/KERNEL/atom.h>
30 #endif
31 
32 #ifndef BALL_MATHS_MATRIX44_H
33 # include <BALL/MATHS/matrix44.h>
34 #endif
35 
36 #ifndef BALL_STRUCTURE_ATOMBIJECTION_H
38 #endif
39 
40 #include <vector>
41 #include <map>
42 
43 namespace BALL
44 {
45 
51  {
52  public:
53 
57 
61 
65 
68  virtual ~StructureMapper();
69 
71 
75 
78  double calculateRMSD();
79 
82  double calculateRMSD(const AtomBijection& new_bijection);
83 
88 
91  void calculateDefaultBijection(bool limit_to_selection = false);
92 
95  const AtomBijection& getBijection() const { return bijection_; }
96 
100  (const vector<Fragment*>& A, const vector<Fragment*>& B);
101 
105  (const vector<Fragment*>& A, const vector<Fragment*>& B,
106  Matrix4x4* transformation, double upper_bound = 8.0, double lower_bound = 2.5);
107 
117  (const Vector3& w1, const Vector3& w2, const Vector3& w3,
118  const Vector3& v1, const Vector3& v2, const Vector3& v3);
119 
122  static Matrix4x4 matchBackboneAtoms(const Residue& r1, const Residue& r2);
123 
126  Size mapResiduesByBackbone(const list<Residue*>& l1, const list<Residue*>& l2);
127 
130  vector<vector<Fragment*> >& searchPattern
131  (vector<Fragment*>& pattern, AtomContainer& composite,
132  double max_rmsd = 4.0, double max_center_tolerance = 2.0,
133  double upper_bound = 8.0, double lower_bound = 4.0);
134 
138  (Protein& P1, Protein& P2,
139  std::map<String, Size>& type_map,
140  Size& no_matched_ca,
141  double& rmsd,
142  double upper_bound = 8.0,
143  double lower_bound = 4.0,
144  double tolerance = 0.6);
145 
146  protected:
147  // Count the fragments in an AtomContainer -- this is not implemented
148  // in AtomContainer!
150 
151  /*_ The first of two composites - the "original"
152  */
154 
155  /*_ The second composites - the "copy" to be mapped
156  */
158 
159  /*_ The current atom bijection.
160  Required for the caclulation of the RMSD.
161  */
163 
164  /*_ The rmsd of the last mapping executed
165  */
166  double rmsd_;
167  };
168 
169 } // namespace BALL
170 
171 #endif // BALL_STRUCTURE_STRUCTUREMAPPER_H
172 
BALL_EXPORT
#define BALL_EXPORT
Definition: COMMON/global.h:50
BALL::StructureMapper::StructureMapper
StructureMapper()
BALL::AtomContainer
Definition: atomContainer.h:32
atomBijection.h
BALL::StructureMapper::set
void set(AtomContainer &A, AtomContainer &B)
BALL::TMatrix4x4< float >
BALL::Residue
Definition: residue.h:38
BALL::StructureMapper::mapProteins
Matrix4x4 mapProteins(Protein &P1, Protein &P2, std::map< String, Size > &type_map, Size &no_matched_ca, double &rmsd, double upper_bound=8.0, double lower_bound=4.0, double tolerance=0.6)
BALL::StructureMapper::mapFragments
bool mapFragments(const vector< Fragment * > &A, const vector< Fragment * > &B, Matrix4x4 *transformation, double upper_bound=8.0, double lower_bound=2.5)
BALL::StructureMapper::searchPattern
vector< vector< Fragment * > > & searchPattern(vector< Fragment * > &pattern, AtomContainer &composite, double max_rmsd=4.0, double max_center_tolerance=2.0, double upper_bound=8.0, double lower_bound=4.0)
BALL::StructureMapper::rmsd_
double rmsd_
Definition: structureMapper.h:166
BALL::Protein
Definition: protein.h:30
BALL::StructureMapper::StructureMapper
StructureMapper(AtomContainer &A, AtomContainer &B)
BALL
Definition: constants.h:13
BALL::StructureMapper::A_
AtomContainer * A_
Definition: structureMapper.h:153
BALL::StructureMapper::bijection_
AtomBijection bijection_
Definition: structureMapper.h:162
protein.h
BALL::StructureMapper::calculateRMSD
double calculateRMSD(const AtomBijection &new_bijection)
BALL::StructureMapper::calculateRMSD
double calculateRMSD()
BALL::StructureMapper::B_
AtomContainer * B_
Definition: structureMapper.h:157
BALL_SIZE_TYPE
BALL::TVector3< float >
BALL::StructureMapper::matchPoints
static Matrix4x4 matchPoints(const Vector3 &w1, const Vector3 &w2, const Vector3 &w3, const Vector3 &v1, const Vector3 &v2, const Vector3 &v3)
BALL::StructureMapper::calculateTransformation
bool calculateTransformation()
BALL::AtomBijection
Definition: atomBijection.h:47
atom.h
string.h
processor.h
BALL::TransformationProcessor
Definition: geometricTransformations.h:89
common.h
BALL::StructureMapper::countFragments_
Size countFragments_(const AtomContainer &ac) const
matrix44.h
BALL::StructureMapper::getBijection
const AtomBijection & getBijection() const
Definition: structureMapper.h:95
BALL::StructureMapper::~StructureMapper
virtual ~StructureMapper()
BALL::StructureMapper::calculateFragmentBijection
AtomBijection calculateFragmentBijection(const vector< Fragment * > &A, const vector< Fragment * > &B)
BALL::StructureMapper
Definition: structureMapper.h:51
BALL::StructureMapper::matchBackboneAtoms
static Matrix4x4 matchBackboneAtoms(const Residue &r1, const Residue &r2)
BALL::StructureMapper::calculateDefaultBijection
void calculateDefaultBijection(bool limit_to_selection=false)
geometricTransformations.h
BALL::StructureMapper::mapResiduesByBackbone
Size mapResiduesByBackbone(const list< Residue * > &l1, const list< Residue * > &l2)