Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
MembraneTopology.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 core/scoring/methods/MembraneTopology.hh
11 /// @brief MembraneTopology
12 /// @author Bjorn Wallner
13 
14 
15 #ifndef INCLUDED_core_scoring_MembraneTopology_hh
16 #define INCLUDED_core_scoring_MembraneTopology_hh
17 
18 #include <core/types.hh>
19 
20 // Unit headers
22 
23 // Package headers
24 // AUTO-REMOVED #include <core/scoring/EnergyGraph.fwd.hh>
25 // AUTO-REMOVED #include <core/conformation/Residue.fwd.hh>
26 
27 // Project headers
28 // AUTO-REMOVED #include <core/pose/Pose.fwd.hh>
29 #include <core/pose/Pose.fwd.hh>
30 #include <basic/datacache/CacheableData.hh>
31 
32 // Utility headers
33 // AUTO-REMOVED #include <utility/vector1.hh>
34 
35 #include <ObjexxFCL/FArray1D.hh>
36 #include <ObjexxFCL/FArray2D.hh>
37 // AUTO-REMOVED #include <ObjexxFCL/FArray3D.hh>
38 // AUTO-REMOVED #include <ObjexxFCL/FArray4D.hh>
39 
40 #include <utility/vector1.hh>
41 
42 
43 // C++
44 
45 
46 namespace core {
47 namespace scoring {
48 
49 
50 
51 class MembraneTopology : public basic::datacache::CacheableData {
52 
53 public:
54  MembraneTopology(): LipoDefined_(false),init_(false),beta_barrel_(false),N_term_inside_(false),initialized_(false) {};
55 
56  MembraneTopology( MembraneTopology const & src);
57 
58  basic::datacache::CacheableDataOP
59  clone() const
60  {
61  return new MembraneTopology( *this );
62  }
63 
64 //pba
65  bool
66  initialized() const
67  {
68  return initialized_;
69  }
70 
71  bool &
73  {
74  return initialized_;
75  }
76 
77  Size
78  tmhelix() const {
79  return total_tmhelix_;
80  }
81 
82  Size
83  span_begin(Size n) const {
84  return span_(n,1);
85  }
86 
87  Size
88  span_end(Size n) const {
89  return span_(n,2);
90  }
91 
92  Size
93  helix_id(Size n) const {
94  return helix_id_(n);
95  }
96 
97  Size
98  relative_tmh_ori(Size const n, Size const m) const {
99  return(relative_tmh_ori(n,m));
100  }
101 
102  Real
103  depth(Size const seqpos) {
104  return depth_[ seqpos ];
105  }
106 
108  depth() {
109  return depth_;
110  }
111  void
112  initialize(std::string const & spanfile);
113 
114  //void
115  //initialize(pose::Pose & pose, std::string const & spanfile);
116  ///
117 
118  void
119  print() const;
120 
121  void
122  shift_span(Size shift);
123 
124  //void attach_to_pose(pose::Pose & pose);
125 
126 
127  void
129 
130  bool
131  allow_scoring(Size const seqpos) const
132  {
133  assert(seqpos <= allow_scoring_.size());
134  return allow_scoring_[seqpos];
135  }
136 /*
137  bool &
138  allow_scoring(Size const seqpos)
139  {
140  return allow_scoring_[seqpos];
141  }
142 */
143  Size
144  tmh_inserted() const
145  {
146  return tmh_inserted_;
147  }
148 
149  void
151  {
152  tmh_inserted_=0;
153  }
154  void
156  {
157  tmh_inserted_=0;
158  for(Size i=1;i<=allow_tmh_scoring_.size();++i)
159  {
160  allow_tmh_scoring_[i]=false;
161  }
162  for(Size i=1;i<=allow_scoring_.size();++i)
163  {
164  allow_scoring_[i]=false;
165  }
166 
167  }
168  void
170  {
172  }
173 
174  bool
175  tmregion(Size const pos) const
176  {
177  return tmregion_[pos];
178  }
179 
180  bool
181  allow_tmh_scoring(Size const tmh) const
182  {
183  return allow_tmh_scoring_[tmh];
184  }
185 
186  void
187  set_allow_tmh_scoring(Size const tmh,bool setting)
188  {
189  allow_tmh_scoring_[tmh]=setting;
190  }
191  void
192  set_allow_scoring(Size const pos, bool setting)
193  {
194  allow_scoring_[pos]=setting;
195  }
196 
197  Real
198  LipidExposure(Size const n) const {
199  return LipidExposure_[n];
200  }
201  Real
202  LipidBurial(Size const n) const {
203  return LipidBurial_[n];
204  }
205 
206  bool
207  LipoDefined() const {
208  return LipoDefined_;
209  }
210  /*
211  bool &
212  allow_tmh_scoring(Size const tmh)
213  {
214  return allow_tmh_scoring_[tmh];
215  }
216  bool &
217  allow_scoring(Size const pos)
218  {
219  return allow_scoring_[pos];
220  }
221  */
222  protected:
223 
224 
225 
226 /* Real const cen_dist_cutoff2;
227 
228 
229  CenListInfo const & cenlist_from_pose( pose::Pose const & ) const;
230  CenListInfo & nonconst_cenlist_from_pose( pose::Pose & ) const;
231 */
232 private:
233 
234 
235 private: // data
236 
237  ObjexxFCL::FArray1D< Size > helix_id_;
238  ObjexxFCL::FArray2D< Size > span_;
239  ObjexxFCL::FArray2D< Size > full_span_;
240  ObjexxFCL::FArray2D< Size > relative_tmh_ori_;
242  utility::vector1< core::Real > depth_; // this is just to speed up the cross talk between scoring fxns and pose.metrics.
246  bool init_;
249  bool initialized_; //pba
254 
255 
256 };
257 
258 //extern MembraneTopology & MembraneTopology_from_pose(core::pose:Pose const pose);
259 //pbadebug
262 
263 
264 } // ns scoring
265 } // ns core
266 
267 #endif