Rosetta 3.5
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
core
scoring
constraints
GaussianFunc.hh
Go to the documentation of this file.
1
// -*- mode:c++;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
2
// vi: set ts=2 noet:
3
//
4
// (c) Copyright Rosetta Commons Member Institutions.
5
// (c) This file is part of the Rosetta software suite and is made available under license.
6
// (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
7
// (c) For more information, see http://www.rosettacommons.org. Questions about this can be
8
// (c) addressed to University of Washington UW TechTransfer, email: license@u.washington.edu.
9
10
/// @file src/core/scoring/constraints/GaussianFunc.hh
11
/// @brief Definition for functions used in definition of constraints.
12
/// @author James Thompson
13
14
#ifndef INCLUDED_core_scoring_constraints_GaussianFunc_hh
15
#define INCLUDED_core_scoring_constraints_GaussianFunc_hh
16
17
#include <
core/scoring/constraints/Func.hh
>
18
#include <
core/types.hh
>
19
20
namespace
core {
21
namespace
scoring {
22
namespace
constraints {
23
24
/// @brief Derived class of class Func representing a Gaussian distribution with a user-specified
25
/// mean and standard deviation.
26
class
GaussianFunc
:
public
Func
{
27
public
:
28
29
/*!
30
* Constuctor for GaussianFunc. Arguments to the constructor are:
31
* - mean: parameter representing the mean of this function.
32
* - sd: parameter representing the standard deviation of this function.
33
*/
34
35
GaussianFunc
(
36
Real
const
mean,
37
Real
const
sd
38
) :
39
mean_
( mean ),
40
sd_
( sd ),
41
use_log_score_
( true )
42
{}
43
44
/// @brief returns a clone of this GaussianFunc
45
FuncOP
clone
()
const
{
return
new
GaussianFunc
( *
this
); }
46
47
/// @brief Returns the value of this GaussianFunc evaluated at distance x.
48
Real
func
(
Real
const
x )
const
;
49
50
/// @brief Returns the value of the first derivative of this GaussianFunc at distance x.
51
Real
dfunc
(
Real
const
x )
const
;
52
53
/// @brief show the definitio of this GaussianFunc to the specified output stream.
54
virtual
void
show_definition
( std::ostream &out )
const
;
55
56
/// @brief Calls show( out ) on this GaussianFunc.
57
friend
std::ostream&
operator<<
(std::ostream& out,
const
GaussianFunc
& f ) {
58
f.
show
( out );
59
return
out;
60
}
// operator<<
61
62
63
/// @brief
64
/// The parameters are:
65
/*!
66
* Initializes this GaussianFunc from the given istream. An example
67
* of the type of string from which the istream should be constructed is:
68
* "GAUSSIANFUNC 19.396 7.643". The interpretation is to
69
* create initialize this GaussianFunc object with the following parameters:
70
* - mean 19.396
71
* - sd 7.643
72
*/
73
void
read_data
( std::istream& in );
74
75
private
:
76
Real
mean_
;
77
Real
sd_
;
78
bool
use_log_score_
;
79
};
80
81
82
83
}
// constraints
84
}
// scoring
85
}
// core
86
87
#endif
Generated on Sat Jun 1 2013 11:35:33 for Rosetta 3.5 by
1.8.4