IMP  2.0.1
The Integrative Modeling Platform
DensityFillingRestraint.h
Go to the documentation of this file.
1 /**
2  * \file IMP/em/DensityFillingRestraint.h
3  * \brief Score how well the particles fill the density
4  *
5  * Copyright 2007-2013 IMP Inventors. All rights reserved.
6  *
7  */
8 
9 #ifndef IMPEM_DENSITY_FILLING_RESTRAINT_H
10 #define IMPEM_DENSITY_FILLING_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 DensityFillingRestraint : 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  \note Particles that are rigid-bodies are interpolated and not resampled.
37  This significantly reduces the running time but is less accurate.
38  If the user prefers to get more accurate results, provide
39  its members as input particles and not the rigid body.
40  \todo we currently assume rigid bodies are also molecular hierarchies.
41  */
42  DensityFillingRestraint(Particles ps,
43  DensityMap *em_map,Float threshold);
44 
46 
47  IMP_LIST(private, Particle, particle, Particle*, Particles);
48 private:
49  IMP::OwnerPointer<DensityMap> target_dens_map_;
50  algebra::BoundingBoxD<3> target_bounding_box_;
51  // reference to the IMP environment
52  IMP::core::XYZs xyz_;
53  Particles ps_;
54  Float threshold_;
55 };
56 
57 IMPEM_END_NAMESPACE
58 
59 #endif /* IMPEM_DENSITY_FILLING_RESTRAINT_H */