Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
RNA_CentroidInfo.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/RNA_BaseBasePotential.cc
11 /// @brief Statistically derived rotamer pair potential class implementation
12 /// @author Phil Bradley
13 /// @author Andrew Leaver-Fay
14 
15 
16 // Unit headers
18 // AUTO-REMOVED #include <core/scoring/rna/RNA_CentroidInfo.fwd.hh>
19 
20 // Package headers
21 
22 // Project headers
23 #include <core/chemical/AA.hh>
24 // AUTO-REMOVED #include <core/chemical/VariantType.hh>
26 #include <core/pose/Pose.hh>
27 
28 // Utility headers
29 #include <numeric/xyzMatrix.hh>
30 
31 #include <utility/vector1.hh>
33 
34 
35 // C++
36 
37 ///////////////////////////////////////////////////////
38 // Keep track of some base geometry that is
39 // useful for RNA scoring.
40 ///////////////////////////////////////////////////////
41 
42 namespace core {
43 namespace scoring {
44 namespace rna {
45 
46 /// @details Copy constructors must copy all data, not just some...
48  CacheableData()
49 {
53 }
54 
56 
57 
58 ///////////////////////////////////////////////////////////////////////////////
59 Vector
61 {
62  bool const verbose = false;
63 
64  return get_rna_base_centroid( rsd, verbose);
65 }
66 
67 
70 {
71  return kinematics::Stub(get_rna_base_coordinate_system(rsd, centroid), centroid );
72 }
73 
74 //////////////////////////////////////////////////////////////////////////////////////
75 void
77 {
78 
79  base_centroids_.clear();
80  base_stubs_.clear();
81 
82  for (Size i = 1; i <= pose.total_residue(); i++ ){
83  conformation::Residue const & res_i ( pose.residue(i) );
84 
85  Vector centroid_i( 0.0 );
86  kinematics::Stub stub_i;
87 
88  if ( res_i.is_RNA() ) {
89  centroid_i = get_base_centroid( res_i );
90  stub_i = get_base_coordinate_system(res_i, centroid_i );
91  }
92 
93  base_centroids_.push_back( centroid_i );
94  base_stubs_.push_back( stub_i );
95 
96  }
97 
98 }
99 
100 //////////////////////////////////////////////////////////////////////////////////////
101 void
103 {
105 }
106 
107 
108 }
109 }
110 }