Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
MembraneCbetaEnergy.cc
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 core/scoring/methods/EnvPairEnergy.cc
11 /// @brief Statistically derived rotamer pair potential class implementation
12 /// @author Phil Bradley
13 /// @author Andrew Leaver-Fay
14 
15 
16 // Unit headers
17 // AUTO-REMOVED #include <core/scoring/methods/util.hh>
20 
21 // Package headers
25 // AUTO-REMOVED #include <core/scoring/EnergyGraph.hh>
26 
27 // Project headers
28 #include <core/pose/Pose.hh>
30 // AUTO-REMOVED #include <core/conformation/Conformation.hh>
32 #include <basic/datacache/BasicDataCache.hh>
33 
34 #include <core/kinematics/Jump.hh>
36 #include <utility/vector1.hh>
37 
38 
39 // Utility headers
40 
41 // C++
42 
43 namespace core {
44 namespace scoring {
45 namespace methods {
46 
47 
48 /// @details This must return a fresh instance of the MembraneCbetaEnergy class,
49 /// never an instance already in use
53 ) const {
54  return new MembraneCbetaEnergy;
55 }
56 
59  ScoreTypes sts;
60  sts.push_back( Mcbeta );
61  return sts;
62 }
63 
64 
65 /// c-tor
68  potential_( ScoringManager::get_instance()->get_MembranePotential() )
69 {}
70 
71 
72 /// clone
75 {
76  return new MembraneCbetaEnergy;
77 }
78 
79 
80 /////////////////////////////////////////////////////////////////////////////
81 // scoring
82 /////////////////////////////////////////////////////////////////////////////
83 
84 
85 ///
86 void
88 {
89  // compute interpolated number of neighbors at various distance cutoffs
92 
93  //No need to calculate embedding...
94 
95 }
96 
97 
98 ///////////////////////////////////////
99 //
100 // ENV SCORE
101 void
103  conformation::Residue const & rsd,
104  pose::Pose const & pose,
105  EnergyMap & emap
106 ) const
107 {
108  //Real env_score( 0.0 ),
109  Real cb_score( 0.0 ); //, cb_score12( 0.0 ), cb_score( 0.0 );
110  if ( rsd.aa() == core::chemical::aa_vrt ) {
111  emap[ Mcbeta ] = cb_score;// * rsd_wt;
112  return;
113  }
114 
116  {
117 
118 // potential_.evaluate_env( pose, rsd, env_score);
119  potential_.evaluate_cbeta( pose, rsd,cb_score);
120 
121  //env_score *= 2.019;
122  cb_score = 2.667 * ( cb_score ) * 0.3;
123  }
124  //bw is this something we like?
125  //core::Real rsd_wt = get_residue_weight_by_ss( pose.conformation().secstruct( rsd.seqpos() ) );
126 
127  ///emap[ Menv ] = env_score;// * rsd_wt;
128  //std::cout << "CB " << MembraneTopology_from_pose( pose ).allow_scoring(rsd.seqpos()) << " " << rsd.seqpos() << " " << cb_score << "\n";
129  emap[ Mcbeta ] += cb_score;// * rsd_wt;
130 
131 } // residue_energy
132 
133 void
135  pose::Pose & pose,
136  ScoreFunction const &,
137  EnergyMap &
138 ) const
139 {
140  potential_.finalize( pose );
141 }
142 
143 /*
144  bool
145  MembraneCbetaEnergy::allow_scoring(Size const seqpos) const
146  {
147 
148  return ((*( static_cast< MembraneTopology const * >( pose.data().get_const_ptr( basic::MEMBRANE_TOPOLOGY )() ))).allow_scoring(seqpos));
149  }
150  */
151 MembraneTopology const &
153 {
154  //using core::pose::datacache::CacheableDataType::MEMBRANE_TOPOLOGY;
155  return *( static_cast< MembraneTopology const * >( pose.data().get_const_ptr( core::pose::datacache::CacheableDataType::MEMBRANE_TOPOLOGY )() ));
156 }
159 {
160  return 1; // Initial versioning
161 }
162 
163 }
164 }
165 }