OpenStructure
contact_overlap.hh
Go to the documentation of this file.
1 #ifndef OST_MOL_ALG_CONTACT_HH
2 #define OST_MOL_ALG_CONTACT_HH
3 
4 #include <boost/shared_ptr.hpp>
5 
6 #include <ost/mol/entity_view.hh>
7 #include <ost/img/image.hh>
9 
10 
11 #include "module_config.hh"
12 #include "similarity_matrix.hh"
13 
14 namespace ost { namespace mol { namespace alg {
15 
16 struct Contact {
17  Contact(): atom_a(), atom_b() {}
19  atom_a(a), atom_b(b)
20  { }
23 
24  bool operator==(const Contact& rhs) const
25  {
26  return atom_a==rhs.atom_a && atom_b==rhs.atom_b;
27  }
28 
29  bool operator!=(const Contact& rhs) const
30  {
31  return !this->operator==(rhs);
32  }
33 };
34 
35 typedef std::vector<Contact> ContactList;
36 
39 Contacts(const ost::mol::EntityView& ent, Real min_dist,
40  Real max_dist);
41 
42 typedef enum {
49 
50 struct LDT {
54 };
55 
56 class DistanceMatrix;
57 
58 typedef boost::shared_ptr<DistanceMatrix> DistanceMatrixPtr;
59 
61 public:
64  int index=1);
65 private:
67  DistanceMatrix(const ost::seq::AlignmentHandle& aln, int index);
68 
69 };
70 
71 
73  const DistanceMatrixPtr& rhs,
74  Real tolerance,
76  Real dist_limit=1e6);
77 
78 
81  const ost::mol::EntityView& ref,
82  Real max_dist,
83  Real tolerance=0.02,
84  bool only_complete=false);
85 
88  Real tolerance, int idx_a, int idx_b);
89 
92  Real tolerance, OverlapMode mode=OM_RELATIVE,
93  Real max_dist=1e6);
94 
96 ContactOverlapMap(const DistanceMatrix& dmat1, const DistanceMatrix& dmat2,
97  Real tolerance, OverlapMode mode=OM_RELATIVE,
98  Real max_dist=1e6);
99 
100 
101 //ost::img::ImageHandle
104  Real tolerance, int idx_a=-1, int idx_b=-1);
105 
106 }}}
107 
108 #endif
triangular matrix template
Definition: tri_matrix.hh:13
Handle to atom datatype.
Definition: atom_handle.hh:37
definition of EntityView
Definition: entity_view.hh:86
static DistanceMatrixPtr Create(const ost::seq::ConstSequenceHandle &s)
static DistanceMatrixPtr FromAln(const ost::seq::AlignmentHandle &a, int index=1)
representation of a multiple sequence alignemnt consisting of two or more sequences
float Real
Definition: base.hh:44
#define DLLEXPORT_OST_MOL_ALG
std::vector< Contact > ContactList
void DLLIMPORT CalcContactNodeDegree(const ContactList &contacts)
calculates and assigns the contact node degree as the int property 'degree' for each atom
ContactList DLLIMPORT Contacts(const ost::mol::EntityView &ent, Real min_dist, Real max_dist)
returns a a list of contacts between C-alpha atoms
SimilarityMatrix DLLIMPORT ContactOverlapMap(const ost::seq::AlignmentHandle &target_tpl_aln, Real tolerance, int idx_a, int idx_b)
Real DLLIMPORT ContactOverlap(const DistanceMatrixPtr &lhs, const DistanceMatrixPtr &rhs, Real tolerance, OverlapMode mode=OM_RELATIVE, Real dist_limit=1e6)
Real DLLIMPORT LocalDistanceTest(const ost::mol::EntityView &mdl, const ost::mol::EntityView &ref, Real max_dist, Real tolerance=0.02, bool only_complete=false)
void DLLIMPORT DomainsFromCOM(const SimilarityMatrix &sim, ost::seq::AlignmentHandle aln, Real tolerance, int idx_a=-1, int idx_b=-1)
boost::shared_ptr< DistanceMatrix > DistanceMatrixPtr
Definition: base.dox:1
ost::mol::AtomHandle atom_b
ost::mol::AtomHandle atom_a
bool operator==(const Contact &rhs) const
bool operator!=(const Contact &rhs) const
Contact(ost::mol::AtomHandle a, ost::mol::AtomHandle b)