Page 1 of 1

Measuring distances, angles, and torsion angles

Posted: Wed Jun 19, 2024 7:27 pm
by fgygi
It often happens that one wants to measure some geometric property (distance, angle or torsion) after running a simulation or geometry optimization. If this is known in advance of the simulation, it can be done by including the appropriate distance, angle or torsion command in the input file. If this was not done, the quantity can be extracted from the output file using the qbox_distance.py, qbox_angle.py or qbox_torsion.py scripts, for example

Code: Select all

$ qbox_distance.py  N1 C3_222 file.r
5.0903
5.0908
5.0908
5.0908
5.0910
5.0911
5.0917
5.0926
5.0928
5.0932
Note that the scripts can also be used on a restart file, or a stripped version of a restart file created using the get_atomset.sh script

Code: Select all

$ get_atomset.sh file.xml > file_atomset.xml
$ qbox_distance.py N1 C3_222 file_atomset.xml
5.0942
Note that the value saved in the restart file is not exactly the same as the last value found in the output file, which is computed from atomic positions before the last step was done.