{+ file: ncs.def +} {+ directory: auxiliary +} {+ description: Defines non-crystallographic constraints or restraints +} {+ authors: Axel T. Brunger, and Paul D. Adams +} {+ copyright: Yale University +} {- begin block parameter definition -} define( {============================ NCS type ===============================} {* NCS type *} {+ choice: "strict" "restrain" +} {===>} ncs_type="restrain"; {===================== strict NCS (Skew matrix) ======================} {* Skew matrix *} {* use the skew matrix *} {+ choice: true false +} {===>} skew_use=false; {* real-space skew matrix *} {===>} skew_matrix=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space skew vector *} {===>} skew_vector=( 0 0 0 ); {=============== strict NCS (X-ray and nonbonded terms) ==============} {* these operators are used to generate the complete asymmetric unit for structure factor and nonbonded energy calculations *} {* NCS operator 1 - the identity operator *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_1=false; {* real-space rotation matrix *} {===>} ncs_matrix_1=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_1=( 0 0 0 ); {* NCS operator 2 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_2=false; {* real-space rotation matrix to rotate A molecule to B *} {===>} ncs_matrix_2=( 0.53240 0.84601 0.02849 ) ( -0.84613 0.53285 -0.01133 ) ( -0.02477 -0.01807 0.99953); {* real-space translation vector *} {===>} ncs_vector_2=( -44.18569 112.02095 5.04233 ); {* NCS operator 3 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_3=false; {* real-space rotation matrix to rotate A to C *} {===>} ncs_matrix_3=( -0.46622 0.88467 0.00215 ) ( -0.88159 -0.46439 -0.08451 ) ( -0.07376 -0.04130 0.99642 ); {* real-space translation vector *} {===>} ncs_vector_3=( 39.15040 222.62829 12.94606 ); {* NCS operator 4 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_4=false; {* real-space rotation matrix *} {===>} ncs_matrix_4=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_4=( 0 0 0 ); {* NCS operator 5 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_5=false; {* real-space rotation matrix *} {===>} ncs_matrix_5=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_5=( 0 0 0 ); {* NCS operator 6 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_6=false; {* real-space rotation matrix *} {===>} ncs_matrix_6=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_6=( 0 0 0 ); {* NCS operator 7 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_7=false; {* real-space rotation matrix *} {===>} ncs_matrix_7=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_7=( 0 0 0 ); {* NCS operator 8 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_8=false; {* real-space rotation matrix *} {===>} ncs_matrix_8=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_8=( 0 0 0 ); {* NCS operator 9 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_9=false; {* real-space rotation matrix *} {===>} ncs_matrix_9=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_9=( 0 0 0 ); {* NCS operator 10 *} {* use this operator *} {+ choice: true false +} {===>} ncs_op_10=false; {* real-space rotation matrix *} {===>} ncs_matrix_10=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} ncs_vector_10=( 0 0 0 ); {================= strict NCS (nonbonded term only) ==================} {* these operators can be used to generate the full nonbonded environment around the protomer *} {* NCS nonbonded operator 1 *} {* use this operator *} {+ choice: true false +} {===>} nb_ncs_op_1=false; {* real-space rotation matrix *} {===>} nb_ncs_matrix_1=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} nb_ncs_vector_1=( 0 0 0 ); {* NCS nonbonded operator 2 *} {* use this operator *} {+ choice: true false +} {===>} nb_ncs_op_2=false; {* real-space rotation matrix *} {===>} nb_ncs_matrix_2=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} nb_ncs_vector_2=( 0 0 0 ); {* NCS nonbonded operator 3 *} {* use this operator *} {+ choice: true false +} {===>} nb_ncs_op_3=false; {* real-space rotation matrix *} {===>} nb_ncs_matrix_3=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} nb_ncs_vector_3=( 0 0 0 ); {* NCS nonbonded operator 4 *} {* use this operator *} {+ choice: true false +} {===>} nb_ncs_op_4=false; {* real-space rotation matrix *} {===>} nb_ncs_matrix_4=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} nb_ncs_vector_4=( 0 0 0 ); {* NCS nonbonded operator 5 *} {* use this operator *} {+ choice: true false +} {===>} nb_ncs_op_5=false; {* real-space rotation matrix *} {===>} nb_ncs_matrix_5=( 1 0 0 ) ( 0 1 0 ) ( 0 0 1 ); {* real-space translation vector *} {===>} nb_ncs_vector_5=( 0 0 0 ); {====================== NCS restraint group 1[ N Domain ] ========================} {* NCS-restraint weight *} {N Domain NCS Weight} {===>} group.1.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.1.sigb=2; {* equivalence selection 1 *} {===>} group.1.equiv.1=(known and segid A and (resid 27:58 or resi 67:205)); {* equivalence selection 2 *} {===>} group.1.equiv.2=(known and segid B and (resid 27:58 or resi 67:205)); {* equivalence selection 3 *} {===>} group.1.equiv.3=(known and segid C and (resid 27:58 or resi 67:205)); {====================== NCS restraint group 2 D1 a/b domain========================} {* NCS-restraint weight *} {D1abdomain weight} {===>} group.2.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.2.sigb=2; {* equivalence selection 1 *} {===>} group.2.equiv.1=(known and segid A and (resid 206:299 or resid 321:370)); {* equivalence selection 2 *} {===>} group.2.equiv.2=(known and segid B and (resid 206:299 or resid 321:370)); {* equivalence selection 3 *} {===>} group.2.equiv.3=(known and segid C and (resid 206:299 or resid 321:370)); {====================== NCS restraint group 3 D1alpha ========================} {* NCS-restraint weight *} {D1 alpha domain weight} {===>} group.3.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.3.sigb=2; {* equivalence selection 1 *} {comment - the gap was left because of a xtl-xtl contact that is} {comment - different amongst the 3 protomers} {===>} group.3.equiv.1=(known and segid A and (resid 371:430 or resid 438:460)); {* equivalence selection 2 *} {===>} group.3.equiv.2=(known and segid B and (resid 371:430 or resid 438:460)); {* equivalence selection 3 *} {===>} group.3.equiv.3=(known and segid C and (resid 371:430 or resid 438:460)); {====================== NCS restraint group 4 D1D2 linker ========================} {* NCS-restraint weight *} {D1D2 linkerdomain weight} {===>} group.4.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.4.sigb=2; {* equivalence selection 1 *} {===>} group.4.equiv.1=(known and segid A and (resid 468:480)); {* equivalence selection 2 *} {===>} group.4.equiv.2=(known and segid B and (resid 468:480)); {* equivalence selection 3 *} {===>} group.4.equiv.3=(known and segid C and (resid 468:480)); {====================== NCS restraint group 5 D2ab section 1========================} {* NCS-restraint weight *} {D2 abdomain weight} {===>} group.5.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.5.sigb=2; {* equivalence selection 1 *} {===>} group.5.equiv.1=(known and segid A and (resid 481:564)); {* equivalence selection 2 *} {===>} group.5.equiv.2=(known and segid B and (resid 481:564)); {* equivalence selection 3 *} {===>} group.5.equiv.3=(known and segid C and (resid 481:564)); {====================== NCS restraint group 6 D2 abdomain section 2 ========================} {* NCS-restraint weight *} {D2 abdomain weight} {===>} group.6.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.6.sigb=2; {* equivalence selection 1 *} {===>} group.6.equiv.1=(known and segid A and (resid 598:645)); {* equivalence selection 2 *} {===>} group.6.equiv.2=(known and segid B and (resid 598:645)); {* equivalence selection 3 *} {===>} group.6.equiv.3=(known and segid C and (resid 598:645)); {====================== NCS restraint group 7 D2adomain section 1 ========================} {* NCS-restraint weight *} {D2 alphadomain weight} {===>} group.7.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.7.sigb=2; {* equivalence selection 1 *} {===>} group.7.equiv.1=(known and segid A and (resid 646:701)); {* equivalence selection 2 *} {===>} group.7.equiv.2=(known and segid B and (resid 646:701)); {* equivalence selection 3 *} {===>} group.7.equiv.3=(known and segid C and (resid 646:701)); {====================== NCS restraint group 8 D2adomain section 2 ========================} {* NCS-restraint weight *} {D2 alphadomain weight} {===>} group.8.weight= 300 ; {* target sigma for NCS related B-values *} {===>} group.8.sigb=2; {* equivalence selection 1 *} {===>} group.8.equiv.1=(known and segid A and (resid 733:759)); {* equivalence selection 2 *} {===>} group.8.equiv.2=(known and segid B and (resid 733:759)); {* equivalence selection 3 *} {===>} group.8.equiv.3=(known and segid C and (resid 733:759)); {===========================================================================} { things below this line do not normally need to be changed } {===========================================================================} ) {- end block parameter definition -} set message ? end evaluate ($message_old=$result) set echo ? end evaluate ($echo_old=$result) if ( $log_level = verbose ) then set message=normal echo=on end else set message=off echo=off end end if checkversion 1.3 if ( &ncs_type = "strict" ) then ncs strict if ( &skew_use = true ) then skew matrix=&skew_matrix translation=&skew_vector end end if evaluate ($counter=1) evaluate ($done=false) while ( $done = false ) loop xncs if ( &exist_ncs_op_$counter = true ) then if ( &ncs_op_$counter = true ) then xncsrel matrix=&ncs_matrix_$counter translation=&ncs_vector_$counter end end if else evaluate ($done=true) end if evaluate ($counter=$counter+1) end loop xncs evaluate ($counter=1) evaluate ($done=false) while ( $done = false ) loop ncs if ( &exist_nb_ncs_op_$counter = true ) then if ( &nb_ncs_op_$counter = true ) then ncsrel matrix=&nb_ncs_matrix_$counter translation=&nb_ncs_vector_$counter end end if else evaluate ($done=true) end if evaluate ($counter=$counter+1) end loop ncs end ncs strict ? end elseif ( &ncs_type = "restrain" ) then evaluate ($1=1) evaluate ($group=1) evaluate ($done=false) while ( $done = false ) loop ncs if ( &exist_group.$group.equiv.1 = true ) then evaluate ($nequiv=0) evaluate ($counter=1) evaluate ($innerdone=false) while ( $innerdone = false ) loop equiv if ( &exist_group.$group.equiv.$counter = true ) then show sum(1) (&group.$group.equiv.$counter) if ( $result > 0 ) then evaluate ($nequiv=$nequiv+1) else evaluate ($innerdone=true) end if else evaluate ($innerdone=true) end if evaluate ($counter=$counter+1) end loop equiv ncs restraint group evaluate ($counter=1) while ( $counter <= $nequiv ) loop equiv equiv=(&group.$group.equiv.$counter) evaluate ($counter=$counter+1) end loop equiv weight=&group.$group.weight sigb=&group.$group.sigb end ? end else evaluate ($done=true) end if evaluate ($group=$group+1) end loop ncs flags include ncs end else display >>> Error: unknown NCS type, aborting abort end if set message=$message_old echo=$echo_old end