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
coarse
CoarseEtable.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
11
/// @author Oliver Lange
12
13
#ifndef INCLUDED_core_coarse_CoarseEtable_hh
14
#define INCLUDED_core_coarse_CoarseEtable_hh
15
16
17
// Project headers
18
// AUTO-REMOVED #include <core/chemical/AtomTypeSet.hh>
19
#include <
core/chemical/ResidueTypeSet.fwd.hh
>
20
#include <
core/conformation/Atom.hh
>
21
#include <
core/conformation/Residue.fwd.hh
>
22
#include <
core/scoring/EnergyMap.fwd.hh
>
23
// Utility headers
24
// AUTO-REMOVED #include <utility/vector1.hh>
25
#include <utility/pointer/access_ptr.hh>
26
#include <utility/pointer/owning_ptr.hh>
27
#include <utility/pointer/ReferenceCount.hh>
28
29
// unit headers
30
#include <
core/coarse/CoarseEtable.fwd.hh
>
31
32
// Objexx Headers
33
#include <ObjexxFCL/FArray3D.hh>
34
#include <ObjexxFCL/FArray2D.hh>
35
36
// std headers
37
// AUTO-REMOVED #include <ostream>
38
39
40
// AUTO-REMOVED #include <basic/Tracer.hh>
41
42
//Auto Headers
43
#include <
core/chemical/AtomTypeSet.fwd.hh
>
44
45
46
47
48
49
namespace
core {
50
namespace
coarse {
51
// Unit headers
52
53
class
CoarseEtable
:
public
utility::pointer::ReferenceCount
{
54
public
:
55
CoarseEtable
(
chemical::AtomTypeSetCAP
atom_set
,
std::string
tag);
56
void
dump_oldstyle_type_table
(std::ostream &os,
const
chemical::ResidueTypeSet
&);
57
void
read_files
(
std::string
resolve,
std::string
etable,
std::string
dtable);
58
59
/// @brief setup before atom_pair functions can be called
60
void
set_residue_pair
(
conformation::Residue
const
&rsd1,
conformation::Residue
const
&rsd2)
const
;
61
62
void
print_residue_info
(
conformation::Residue
const
&rsd1,
conformation::Residue
const
&rsd2)
const
;
63
64
bool
handles
(
conformation::Atom
const
&atom1,
conformation::Atom
const
&atom2)
const
65
{
return
get_eID
(atom1,atom2,
seq_dist_
)>0; }
66
67
/// @brief atom_pair evaluations
68
/// they return false if atom_pair is not evaluated by coarse table --> use normal etable instead
69
/// WARNING, atom_pair evaluations require to call set_residue_pair first !
70
/// Okay that is a bit dirty, but otherwise we need to change quite a lot of the mini-scoring methods
71
/// --- do that when this stuff is established
72
bool
atom_pair_energy
(
73
int
disbin,
74
Real
frac,
75
conformation::Atom
const
&atom1,
76
conformation::Atom
const
&atom2,
77
Energy
&bb
78
)
const
;
79
80
Real
eval_dE_dR
(
81
int
disbin,
82
Real
frac,
83
conformation::Atom
const
&atom1,
84
conformation::Atom
const
&atom2,
85
const
scoring::EnergyMap
&weights
86
)
const
;
87
88
void
check_atomset_compatibility
(
chemical::AtomTypeSetCAP
normal)
const
;
89
90
chemical::AtomTypeSetCAP
91
atom_set
()
const
92
{
93
return
atom_set_
;
94
}
95
96
97
private
:
98
99
/// @brief get entry index in table
100
int
get_eID
(
101
conformation::Atom
const
&atom1,
102
conformation::Atom
const
&atom2,
103
int
seq_dist
104
)
const
105
{
106
if
((atom1.
type
()<=
maxType
) && (atom2.
type
()<=
maxType
)) {
107
int
const
dist = seq_dist >
maxDist
? 0 : seq_dist;
108
assert(dist>=0);
109
110
/* basic::T("coarse.scoring") << "coarse score requested for "
111
<< (*atom_set_)[atom1.type()].name() << ' '
112
<< (*atom_set_)[atom2.type()].name() << ' '
113
<< dist << " ( " << maxDist << " ) " << std::endl;
114
basic::T("coarse.scoring") << resolve_(atom1.type(),atom2.type(),dist+1) << std::endl;
115
*/
116
return
resolve_
(atom1.
type
(),atom2.
type
(),dist+1);
117
}
else
return
0;
118
}
119
120
121
public
:
122
chemical::AtomTypeSetCAP
atom_set_
;
123
private
:
124
ObjexxFCL::FArray3D< uint >
resolve_
;
// find entry in energy table
125
ObjexxFCL::FArray2D< Real >
etable_
;
// energies
126
ObjexxFCL::FArray2D< Real >
dtable_
;
// derivatives
127
int
maxID
;
int
maxType
;
int
maxDist
;
128
mutable
int
seq_dist_
;
129
130
};
131
132
133
134
}
// namespace coarse
135
}
// namespace core
136
137
#endif
Generated on Sat Jun 1 2013 11:32:20 for Rosetta 3.5 by
1.8.4