53 #include <numeric/constants.hh>
54 #include <basic/Tracer.hh>
59 static basic::Tracer
TR(
"protocols.simple_moves.PeptideStapleMover" );
64 #include <utility/vector1.hh>
73 namespace simple_moves {
76 protocols::moves::
Mover(),
77 seqpos_(staple_start),
78 staple_gap_(staple_gap)
91 TR <<
"A staple gap of " <<
staple_gap_ <<
" runs off the end of the pose. Aborting staple insertion at residue " <<
seqpos_ << std::endl;
97 TR <<
"Staple insertion is not supported at chain terminii. Aborting staple insertion at residue " <<
seqpos_ << std::endl;
103 TR <<
"Secondary structure at residue " << i <<
" is " << pose.
secstruct(i) <<
", but stapling along non-helix residues is untested!" << std::endl;
106 TR <<
"Peptide stapling across jumps is untested!" << std::endl;
114 if ( staple_gap_ == 4 ) {
115 stapleA_type = residue_set.name_map(
"STAPLE08A") ;
116 stapleB_type = residue_set.name_map(
"STAPLE08B") ;
133 return "PeptideStapleMover";
142 using namespace core::scoring::constraints;
143 using namespace core::chemical;
144 using namespace core::id;
168 AtomID( jj_conn_atom, jj ),
179 Real
const jj_ideal_angle = numeric::constants::d::pi - pose.
residue( jj ).
type().
icoor( jj_vc_atom ).
theta();
181 TR <<
"seqpos_conn_atom_base: " << seqpos_conn_atom_base <<
" " << pose.
residue(
seqpos_ ).
atom_name( seqpos_conn_atom_base ) <<
" " << seqpos_ideal_angle << std::endl;
182 TR <<
"jj_conn_atom_base: " << jj_conn_atom_base <<
" " << pose.
residue( jj ).
atom_name( jj_conn_atom_base ) <<
" " << jj_ideal_angle << std::endl;
187 AtomID( jj_conn_atom_base, jj ),
193 AtomID( jj_conn_atom, jj ),
199 Real cross_connection_dihedral_val (0);
207 AtomID( jj_conn_atom, jj ),
208 AtomID( jj_conn_atom_base, jj ),
209 new CircularHarmonicFunc( cross_connection_dihedral_val * numeric::constants::d::pi / 180.0, 0.1 ) );
213 for ( Size kk = 1; kk <= seqpos_chi.size(); ++kk ) {
215 TR <<
"seqpos ideal dihedral: " << ideal_dihedral <<
" " << ideal_dihedral * 180 / numeric::constants::d::pi << std::endl;
226 for ( Size kk = 1; kk <= jj_chi.size(); ++kk ) {
228 TR <<
"jj ideal dihedral: " << ideal_dihedral <<
" " << ideal_dihedral * 180 / numeric::constants::d::pi << std::endl;
230 AtomID( jj_chi[ kk ][ 1 ], jj ),
231 AtomID( jj_chi[ kk ][ 2 ], jj ),
232 AtomID( jj_chi[ kk ][ 3 ], jj ),
233 AtomID( jj_chi[ kk ][ 4 ], jj ),
245 using namespace core::scoring;
252 TR <<
"Total score before staple minimization: " << (*scorefxn)( pose ) << std::endl;
259 true ,
false ,
false );
260 min_mover.
min_options()->nblist_auto_update(
true );
261 min_mover.
apply( pose );
263 TR <<
"Total score after staple minimization: " << (*scorefxn)( pose ) << std::endl;