IMP
2.3.1
The Integrative Modeling Platform
IMP Mainpage
Modules
Applications
Related Pages
Groups
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-2014 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
16
IMPISD_BEGIN_NAMESPACE
17
18
//! Jeffreys prior for the \f$\kappa\f$ concentration parameter of a von Mises
19
//! distribution.
20
//! \f[p(\kappa) = \sqrt{\frac{I_1(\kappa)}{I_0(\kappa)}
21
// \left[
22
// \kappa
23
// -\frac{I_1(\kappa)}{I_0(\kappa)}
24
// -kappa\left(\frac{I_1(\kappa)}{I_0(\kappa)}\right)^2
25
// \right]}\f]
26
//!
27
28
class
IMPISDEXPORT
vonMisesKappaJeffreysRestraint
:
public
kernel::Restraint
{
29
base::Pointer<kernel::Particle>
kappa_;
30
double
old_kappaval;
31
double
I0_, I1_;
32
33
public
:
34
//! Create the restraint.
35
vonMisesKappaJeffreysRestraint
(
kernel::Model
*m,
kernel::Particle
*kappa);
36
37
/** This macro declares the basic needed methods: evaluate and show
38
*/
39
virtual
double
unprotected_evaluate(
IMP::kernel::DerivativeAccumulator
*accum)
40
const
IMP_OVERRIDE
;
41
virtual
IMP::kernel::ModelObjectsTemp
do_get_inputs
()
const
IMP_OVERRIDE
;
42
IMP_OBJECT_METHODS
(
vonMisesKappaJeffreysRestraint
);
43
44
virtual
double
get_probability()
const
;
45
46
private
:
47
void
update_bessel(
double
kappaval);
// update memoized bessel values
48
};
49
50
IMPISD_END_NAMESPACE
51
52
#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_OBJECT_METHODS
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition:
object_macros.h:25
IMP::base::Pointer
A smart pointer to a reference counted object.
Definition:
Pointer.h:87
IMP::base::Vector
Definition:
Vector.h:37
Restraint.h
Abstract base class for all restraints.
IMP::isd::vonMisesKappaJeffreysRestraint
Definition:
vonMisesKappaJeffreysRestraint.h:28
IMP::kernel::Restraint
A restraint is a term in an IMP ScoringFunction.
Definition:
kernel/Restraint.h:52
IMP::kernel::Particle
Class to handle individual model particles.
Definition:
kernel/Particle.h:37
SingletonScore.h
Import IMP/kernel/SingletonScore.h in the namespace.
IMP::kernel::ModelObject::do_get_inputs
virtual ModelObjectsTemp do_get_inputs() const =0
IMP_OVERRIDE
#define IMP_OVERRIDE
Cause a compile error if this method does not override a parent method.
Definition:
compiler_macros.h:75
IMP::kernel::Model
Class for storing model, its restraints, constraints, and particles.
Definition:
kernel/Model.h:73