Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
SequenceProfileConstraint.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/SequenceProfileConstraint.hh
11 /// @brief This is a constraint that refers to a core::sequence::SequenceProfile? in order to influence the scoring of amino acid types based on multiple sequence alignments (i.e. for biasing amino acid choices during design).
12 /// @author ashworth
13 
14 #ifndef INCLUDED_core_scoring_constraints_SequenceProfileConstraint_hh
15 #define INCLUDED_core_scoring_constraints_SequenceProfileConstraint_hh
16 
19 
20 // AUTO-REMOVED #include <core/chemical/AA.hh>
21 // AUTO-REMOVED #include <core/sequence/SequenceProfile.hh>
22 
23 // AUTO-REMOVED #include <utility/vector1.hh>
24 
25 #include <core/id/AtomID.hh>
27 #include <utility/vector1.hh>
28 
29 
30 namespace core {
31 namespace scoring {
32 namespace constraints {
33 
34 ///@brief
36 public:
46 
47 public:
48 
50 
52  Pose const &,
53  core::Size,
54  SequenceProfileCOP profile = NULL,
55  core::id::SequenceMappingCOP mapping = NULL // current pose numbers onto profile numbers.
56  );
57 
59  core::Size,
60  SequenceProfileCOP profile = NULL,
61  core::id::SequenceMappingCOP mapping = NULL // current pose numbers onto profile numbers.
62  );
63 
65 
66  virtual ConstraintOP clone() const;
67 
68  virtual std::string type() const { return "SequenceProfile"; }
69 
70  ///@brief used by ConstraintIO and ConstraintFactory to construct this constraint from a input file stream (constraint file)
71  virtual void
72  read_def(
73  std::istream &,
74  Pose const &,
75  FuncFactory const &
76  );
77 
78  virtual void show_def( std::ostream &, Pose const & ) const;
79 
80  virtual void show( std::ostream & out ) const;
81 
82  core::Size seqpos() const { return seqpos_; }
83 
84  //hk
87  }
88  //hk end
89 
93 
94  virtual core::Size natoms() const { return 0; }
95  virtual AtomID const & atom( core::Size const ) const {
96  utility_exit_with_message("SequenceProfileConstraint is not atom-based!.");
97  return core::id::BOGUS_ATOM_ID; // required for compilation on Windows
98  };
99 
101 
102  virtual ConstraintOP remap_resid( SequenceMapping const & ) const;
103  virtual ConstraintOP remapped_clone(pose::Pose const& src, pose::Pose const& dest, id::SequenceMappingCOP map=NULL ) const;
104 
105  virtual void
106  score(
107  XYZ_Func const &,
108  EnergyMap const &,
109  EnergyMap &
110  ) const;
111 
112  virtual void
113  fill_f1_f2(
114  AtomID const &,
115  XYZ_Func const &,
116  core::Vector &,
117  core::Vector &,
118  EnergyMap const &
119  ) const;
120 
121  void weight( core::Real const w );
122  core::Real weight() const;
123 
124 private:
126  // COP is deliberate, as sequence profiles are typically shared amoung many constraints, and as such probably shouldn't be fiddled with
128  /// @brief A mapping of current pose numbers onto profile numbers.
130  core::Real weight_; //dflt 1; allows weighting the profile's contribution according to different criteria, for instance according to whether the position is close or far from the active site
131 };
132 
133 } // namespace constraints
134 } // namespace scoring
135 } // namespace protocols
136 
137 #endif // INCLUDED_core_scoring_constraints_SequenceProfileConstraint_HH