This example file contains links to the complete descriptions of the BTCL commands. The BTCL language. Added comments that were not part of the original file are in italics.
Default values that are not specified in the command input file appear in the output file.
#BIOSYM btcl 3 set PROJECT butane begin # Output distance between C1 and C2 and system energy molGeom get distance d12 "*:1:C1" "*:1:C2" set ener [energy] echo d12 = [object d12] echo energy = $ener lappend energies $ener lappend dists [object d12] # Alter distance between C1 and C2 and output # new distance and system energy molGeom set distance relative 0.2 "*:1:C1" "*:1:C2" molGeom get distance d12 "*:1:C1" "*:1:C2" set ener [energy] echo d12 = [object d12] echo energy = $ener lappend energies $ener lappend dists [object d12]Minimize the conformation:
minimize \ iteration_limit = 10 movement_limit = 0.200 \ sd \ convergence = 1000.0 line_search_precision = 0.100 \ cg \ convergence = 10.0 method = polak \ line_search_precision = 0.100 \ newton \ convergence = 0.001 method = bfgs \ line_search_precision = 0.900 max_atoms = 200 \ final_convergence = 0.001 # Output distance and system energy after minimization molGeom get distance d12 "*:1:C1" "*:1:C2" set ener [energy] echo d12 = [object d12] echo energy = $ener lappend energies $ener lappend dists [object d12] # Apply a distance restraint between C1 and C2 restraint create rstr distance *:1:C1 *:1:C2 restraint function rstr quadratic 100.0 500.0 restraint target rstr relative 0.2Minimize again:
minimize \ iteration_limit = 10 movement_limit = 0.200 \ sd \ convergence = 1000.0 line_search_precision = 0.100 \ cg \ convergence = 10.0 method = polak \ line_search_precision = 0.100 \ newton \ convergence = 0.001 method = bfgs \ line_search_precision = 0.900 max_atoms = 200 \ final_convergence = 0.001 # Output distance and system energy after minimization # with restraint molGeom get distance d12 "*:1:C1" "*:1:C2" set ener [energy] echo d12 = [object d12] echo energy = $ener lappend energies $ener lappend dists [object d12]Final output:
echo number of data points: [llength $energies] echo energies: $energies echo dists: $dists
Lesson on
understanding & creating BTCL scripts, Introduction
Lesson on
understanding & creating BTCL scripts, Section 3
Copyright Biosym/MSI