IMP logo
IMP Reference Guide  develop.29b24c6ad6,2021/05/15
The Integrative Modeling Platform
DihedralSingletonScore.h
Go to the documentation of this file.
1 /**
2  * \file IMP/atom/DihedralSingletonScore.h
3  * \brief A score on a dihedral angle.
4  *
5  * Copyright 2007-2021 IMP Inventors. All rights reserved.
6  */
7 
8 #ifndef IMPATOM_DIHEDRAL_SINGLETON_SCORE_H
9 #define IMPATOM_DIHEDRAL_SINGLETON_SCORE_H
10 
11 #include <IMP/atom/atom_config.h>
12 #include <IMP/SingletonScore.h>
13 #include <IMP/singleton_macros.h>
14 
15 IMPATOM_BEGIN_NAMESPACE
16 
17 //! Score the dihedral angle.
18 /** This scores the dihedral using information stored in its Dihedral
19  decorator. The form of the score is \f[
20  \frac{1}{2} s|s| + s^2\cos(\chi m + \chi_i))
21  \f] where \f$s\f$ is the stiffness, \f$m\f$ the multiplicity, \f$\chi_i\f$
22  the ideal value of the dihedral, and \f$\chi\f$ the actual value.
23 
24  \note This score matches the CHARMM definition, but may not match
25  other forcefields. The stiffness can be negative, which corresponds
26  to CHARMM forcefield entries with negative force constants.
27 
28  \see CHARMMParameters::create_dihedrals(), Dihedral.
29  */
30 class IMPATOMEXPORT DihedralSingletonScore : public SingletonScore {
31  public:
33  virtual double evaluate_index(Model *m, ParticleIndex p,
36  Model *m, const ParticleIndexes &pis) const IMP_OVERRIDE;
39  ;
40 };
41 
43 
44 IMPATOM_END_NAMESPACE
45 
46 #endif /* IMPATOM_DIHEDRAL_SINGLETON_SCORE_H */
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition: object_macros.h:25
Macros for various classes.
A more IMP-like version of the std::vector.
Definition: Vector.h:40
Class for storing model, its restraints, constraints, and particles.
Definition: Model.h:72
Abstract class for scoring object(s) of type ParticleIndex.
#define IMP_SINGLETON_SCORE_METHODS(Name)
virtual ModelObjectsTemp do_get_inputs(Model *m, const ParticleIndexes &pis) const =0
Overload this method to specify the inputs.
Define SingletonScore.
#define IMP_OBJECTS(Name, PluralName)
Define the types for storing lists of object pointers.
Definition: object_macros.h:44
virtual double evaluate_index(Model *m, ParticleIndex vt, DerivativeAccumulator *da) const =0
Compute the score and the derivative if needed.
#define IMP_OVERRIDE
Cause a compile error if this method does not override a parent method.
Class for adding derivatives from restraints to the model.