Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
AmbiguousNMRConstraint.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/constraints/AmbiguousNMRConstraint.hh
11 /// @brief contains declarations for a type of constraint that holds multiple
12 /// other constrains that belong to each other and are all evaluate at once
13 /// @author Florian Richter (floric@u.washington.edu, march 2008)
14 
15 
16 #ifndef INCLUDED_core_scoring_constraints_AmbiguousNMRConstraint_hh
17 #define INCLUDED_core_scoring_constraints_AmbiguousNMRConstraint_hh
18 
20 
21 // Unit header
24 // AUTO-REMOVED #include <core/scoring/constraints/XYZ_Func.hh>
26 
27 #include <core/id/AtomID.hh>
30 #include <core/pose/Pose.fwd.hh>
31 
32 //Utility Headers
33 #include <numeric/xyzVector.fwd.hh>
34 
35 // STL Headers
36 #include <map>
37 
38 #include <utility/vector1.hh>
39 
40 
41 namespace core {
42 namespace scoring {
43 namespace constraints {
44 
45 
47 public:
48 
49  /// @brief default Constructor
50  AmbiguousNMRConstraint( FuncOP func = NULL );
51 
52  /// @brief Constructor
53  AmbiguousNMRConstraint( const ConstraintCOPs & cst_in, FuncOP func );
54 
55 // /// @brief
56 // void
57 // init_cst_score_types();
58 
59  ///
60  virtual
61  ConstraintOP clone() const {
62  if ( size() > 0 ) {
64  } else {
65  return new AmbiguousNMRConstraint( func_ );
66  }
67  }
68 
69  ///
70  virtual
71  ConstraintOP clone( FuncOP func ) const {
72  if ( size() > 0 ) {
73  return new AmbiguousNMRConstraint( member_constraints_, func );
74  } else {
75  return new AmbiguousNMRConstraint( func );
76  }
77  }
78 
79  virtual
81  return new AmbiguousNMRConstraint( get_func().clone() );
82  }
83 
84  virtual std::string type() const {
85  return "AmbiguousNMRConstraint";
86  }
87 
88 
89  /// @brief compute score
90  virtual
91  void
92  score( XYZ_Func const & xyz_func, EnergyMap const & weights, EnergyMap & emap ) const;
93 
94 
95  virtual
97  dist( core::pose::Pose const & pose ) const;
98 
99  virtual
100  core::Real
101  dist( XYZ_Func const & xyz ) const;
102 
103  ///@brief add individual constraint into AmbiguousNMRConstraint
104  virtual
105  void
107 
108  virtual
110  remap_resid( core::id::SequenceMapping const &seqmap ) const;
111 
112  /// @brief compute atom deriv
113  virtual
114  void
115  fill_f1_f2(
116  AtomID const & atom,
117  XYZ_Func const & xyz,
118  Vector & F1,
119  Vector & F2,
120  EnergyMap const & weights
121  ) const;
122 
123  /// @brief Returns the Func object associated with this Constraint object.
124  virtual
125  Func const & get_func() const {
126  runtime_assert( func_ );
127  return *func_;
128  }
129 
130 
131 
132 
133 // virtual
134 // void show( std::ostream& out ) const;
135 
136 ////////////////////////////////////////////////////////////////////////////////////////////////////
137 ///@details read definition of a multiconstraint. Since a MultiConstraint is essentially a vector of
138  virtual void
139  read_def(
140  std::istream& data,
141  core::pose::Pose const& pose,
142  FuncFactory const & func_factory
143  );
144 
145  virtual
146  void show_def( std::ostream& out, pose::Pose const& pose ) const;
147 
148  virtual
149  Size show_violations( std::ostream & out, pose::Pose const & pose, Size verbose_level, Real threshold = 1.0 ) const;
150 
151 // ConstraintCOPs const &
152 // member_constraints() const {
153 // return member_constraints_;
154 // }
155 
156 // virtual ConstraintOP remapped_clone(
157 // pose::Pose const& /*src*/,
158 // pose::Pose const& /*dest*/,
159 // id::SequenceMappingCOP map=NULL ) const;
160 
161 private:
163 
164 }; //AmbiguousNMRConstraint
165 
166 } //constraints
167 } //scoring
168 } //core
169 
170 #endif