IMP
2.1.1
The Integrative Modeling Platform
IMP Mainpage
All IMP Modules
Related Pages
Modules
Namespaces
Classes
Files
Examples
Indexes
File List
File Members
vonMisesKappaJeffreysRestraint.h
Go to the documentation of this file.
1
/**
2
* \file IMP/isd/vonMisesKappaJeffreysRestraint.h
3
* \brief Jeffreys prior for \f$\kappa\f$ in the von Mises distribution.
4
*
5
* Copyright 2007-2013 IMP Inventors. All rights reserved.
6
*
7
*/
8
9
#ifndef IMPISD_VON_MISES_KAPPA_JEFFREYS_RESTRAINT_H
10
#define IMPISD_VON_MISES_KAPPA_JEFFREYS_RESTRAINT_H
11
12
#include <IMP/isd/isd_config.h>
13
#include <
IMP/SingletonScore.h
>
14
#include <
IMP/kernel/Restraint.h
>
15
#include <
IMP/restraint_macros.h
>
16
17
IMPISD_BEGIN_NAMESPACE
18
19
//! Jeffreys prior for the \f$\kappa\f$ concentration parameter of a von Mises
20
//! distribution.
21
//! \f[p(\kappa) = \sqrt{\frac{I_1(\kappa)}{I_0(\kappa)}
22
// \left[
23
// \kappa
24
// -\frac{I_1(\kappa)}{I_0(\kappa)}
25
// -kappa\left(\frac{I_1(\kappa)}{I_0(\kappa)}\right)^2
26
// \right]}\f]
27
//!
28
29
class
IMPISDEXPORT
vonMisesKappaJeffreysRestraint
:
public
kernel::Restraint
30
{
31
base::Pointer<kernel::Particle>
kappa_;
32
double
old_kappaval;
33
double
I0_,I1_;
34
35
public
:
36
//! Create the restraint.
37
vonMisesKappaJeffreysRestraint
(
kernel::Model
*m,
kernel::Particle
*kappa);
38
39
/** This macro declares the basic needed methods: evaluate and show
40
*/
41
virtual
double
42
unprotected_evaluate(
IMP::kernel::DerivativeAccumulator
*accum)
43
const IMP_OVERRIDE;
44
virtual IMP::kernel::
ModelObjectsTemp
do_get_inputs() const IMP_OVERRIDE;
45
IMP_OBJECT_METHODS
(
vonMisesKappaJeffreysRestraint
);
46
47
virtual
double
get_probability() const;
48
49
private:
50
51
void
update_bessel(
double
kappaval);
// update memoized bessel values
52
53
};
54
55
IMPISD_END_NAMESPACE
56
57
#endif
/* IMPISD_VON_MISES_KAPPA_JEFFREYS_RESTRAINT_H */
IMP::kernel::DerivativeAccumulator
Class for adding derivatives from restraints to the model.
Definition:
kernel/DerivativeAccumulator.h:25
IMP::kernel::ModelObjectsTemp
IMP::base::Vector< IMP::base::WeakPointer< kernel::ModelObject > > ModelObjectsTemp
Definition:
kernel/base_types.h:82
IMP::base::Pointer
A smart pointer to a reference counted object.
Definition:
base/Pointer.h:87
restraint_macros.h
Import IMP/kernel/restraint_macros.h in the namespace.
Restraint.h
Abstract base class for all restraints.
IMP::isd::vonMisesKappaJeffreysRestraint
Definition:
vonMisesKappaJeffreysRestraint.h:29
IMP::kernel::Restraint
A restraint is a term in an IMP ScoringFunction.
Definition:
kernel/declare_Restraint.h:52
IMP_OBJECT_METHODS
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition:
base/object_macros.h:25
IMP::kernel::Particle
Class to handle individual model particles.
Definition:
kernel/declare_Particle.h:34
SingletonScore.h
Import IMP/kernel/SingletonScore.h in the namespace.
IMP::kernel::Model
Class for storing model, its restraints, constraints, and particles.
Definition:
kernel/declare_Model.h:72