IMP  2.0.1
The Integrative Modeling Platform
EnvelopePenetrationRestraint.h
Go to the documentation of this file.
1 /**
2  * \file IMP/em/EnvelopePenetrationRestraint.h
3  * \brief Score how well a protein is inside its density
4  *
5  * Copyright 2007-2013 IMP Inventors. All rights reserved.
6  *
7  */
8 
9 #ifndef IMPEM_ENVELOPE_PENETRATION_RESTRAINT_H
10 #define IMPEM_ENVELOPE_PENETRATION_RESTRAINT_H
11 
12 #include <IMP/em/em_config.h>
13 #include "DensityMap.h"
14 #include <IMP/atom/Hierarchy.h>
15 #include <IMP/atom/Atom.h>
16 #include <IMP/atom/Mass.h>
17 #include <IMP/core/XYZR.h>
18 #include <IMP/Model.h>
19 #include <IMP/Restraint.h>
20 #include <IMP/VersionInfo.h>
21 #include <IMP/Refiner.h>
22 
23 IMPEM_BEGIN_NAMESPACE
24 
25 //! Calculate score based on fit to EM map
26 /** \ingroup exp_restraint
27 
28  */
29 class IMPEMEXPORT EnvelopePenetrationRestraint : public Restraint
30 {
31 public:
32  //! Constructor
33  /**
34  \param[in] ps The particles participating in the fitting score
35  \param[in] em_map The density map used in the fitting score
36 
37  \note Particles that are rigid-bodies are interpolated and not resampled.
38  This significantly reduces the running time but is less accurate.
39  If the user prefers to get more accurate results, provide
40  its members as input particles and not the rigid body.
41  \todo we currently assume rigid bodies are also molecular hierarchies.
42  */
43  EnvelopePenetrationRestraint(Particles ps,
44  DensityMap *em_map,Float threshold);
45 
47 
48 #ifndef SWIG
49  IMP_LIST(private, Particle, particle, Particle*, Particles);
50 #endif
51 private:
52  IMP::OwnerPointer<DensityMap> target_dens_map_;
53  algebra::BoundingBoxD<3> target_bounding_box_;
54  // reference to the IMP environment
55  IMP::core::XYZs xyz_;
56  Particles ps_;
57  Float threshold_;
58 };
59 
60 IMPEM_END_NAMESPACE
61 
62 #endif /* IMPEM_ENVELOPE_PENETRATION_RESTRAINT_H */