home
about
news
download
doc
source
systems
tests
bugs
contact
IMP Reference Guide
2.20.2
The Integrative Modeling Platform
IMP Manual
Reference Guide
Tutorial Index
Modules
Classes
Examples
include
IMP
atom
version 2.20.2
CAAngleRestraint.h
Go to the documentation of this file.
1
/**
2
* \file IMP/atom/CAAngleRestraint.h
3
* \brief Angle restraint between three residues in CA-only representation.
4
*
5
* Copyright 2007-2022 IMP Inventors. All rights reserved.
6
*
7
*/
8
9
#ifndef IMPATOM_CA_ANGLE_RESTRAINT_H
10
#define IMPATOM_CA_ANGLE_RESTRAINT_H
11
12
#include <IMP/atom/atom_config.h>
13
14
#include <
IMP/Restraint.h
>
15
#include <
IMP/Particle.h
>
16
#include <
IMP/generic.h
>
17
#include <map>
18
19
IMPATOM_BEGIN_NAMESPACE
20
21
//! Angle restraint between three residues in CA-only representation
22
/** This restraint is designed to be used in conjunction with a CA-only
23
representation; each restraint is applied to three CA atoms that
24
correspond to three residues that are adjacent in sequence.
25
A simple statistical potential is applied to score the angle.
26
Currently, no splining or other smoothing is done and no derivatives
27
are calculated.
28
*/
29
class
IMPATOMEXPORT
CAAngleRestraint
:
public
Restraint
30
{
31
public
:
32
//! Create the angle restraint.
33
/** The value of the restraint is simply score[n] where phi0[n]
34
is the closest angle in phi0 to that between p1-p2-p3.
35
\param[in] m Model
36
\param[in] p1 First CA atom (in previous residue)
37
\param[in] p2 Second CA atom (in current residue)
38
\param[in] p3 Third CA atom (in next residue)
39
\param[in] phi0 List of angles for which scores are available
40
\param[in] score List of scores that correspond to phi0
41
*/
42
CAAngleRestraint
(
Model
*m,
ParticleIndexAdaptor
p1,
ParticleIndexAdaptor
p2,
43
ParticleIndexAdaptor
p3,
Floats
phi0,
Floats
score);
44
45
virtual
double
46
unprotected_evaluate
(
IMP::DerivativeAccumulator
*accum)
47
const override
;
48
virtual
IMP::ModelObjectsTemp
do_get_inputs
()
const override
;
49
IMP_OBJECT_METHODS
(
CAAngleRestraint
);
50
51
private
:
52
ParticleIndex
p_[3];
53
Floats
phi0_;
54
Floats
score_;
55
56
double
get_distance
(
double
v0,
double
v1)
const
;
57
int
get_closest(std::vector<double>
const
& vec,
double
value)
const
;
58
59
};
60
61
IMPATOM_END_NAMESPACE
62
63
#endif
/* IMPATOM_CA_ANGLE_RESTRAINT_H */
IMP_OBJECT_METHODS
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition:
object_macros.h:25
IMP::ParticleIndexAdaptor
Take Decorator, Particle or ParticleIndex.
Definition:
particle_index.h:32
IMP::Index< ParticleIndexTag >
IMP::Restraint::unprotected_evaluate
virtual double unprotected_evaluate(DerivativeAccumulator *da) const
Return the unweighted score for the restraint.
IMP::Vector< Float >
IMP::Model
Class for storing model, its restraints, constraints, and particles.
Definition:
Model.h:86
Particle.h
Classes to handle individual model particles. (Note that implementation of inline functions is in int...
IMP::atom::CAAngleRestraint
Angle restraint between three residues in CA-only representation.
Definition:
CAAngleRestraint.h:29
Restraint.h
Abstract base class for all restraints.
IMP::algebra::get_distance
double get_distance(const Line3D &s, const Vector3D &p)
Get closest distance between a line and a point.
IMP::ModelObject::do_get_inputs
virtual ModelObjectsTemp do_get_inputs() const =0
IMP::DerivativeAccumulator
Class for adding derivatives from restraints to the model.
Definition:
DerivativeAccumulator.h:24
IMP::Restraint
A restraint is a term in an IMP ScoringFunction.
Definition:
Restraint.h:56
generic.h
Compile-time generic restraint and constraint support.