Warning: Trying to access array offset on value of type null in /home/site/wwwroot/lib/plugins/move/action/rename.php on line 42

Warning: Cannot modify header information - headers already sent by (output started at /home/site/wwwroot/lib/plugins/move/action/rename.php:42) in /home/site/wwwroot/inc/actions.php on line 38
tls_refinement [topas wiki]

User Tools

Site Tools


tls_refinement

TLS refinement

You will find here a link to source code that can be compiled into many different executables which can do (among many other things) the following:

1. After the last TOPAS run with the 6th input file from DASH, change the .inp file such that it generates all output needed for Acta Cryst. C. For example, it switches on all parameters, removes Durbin Watson, adds R(Bragg). Note: it switches OFF the refinement of all atomic coordinates, because you usually first want to play around with the preferred orientation.

2. After the last TOPAS run, create a more or less finished .cif file for submission to Acta Cryst. C. It writes an input file for the Open Source program “R” to generate a high-resolution .tif file of the Rietveld plot. It renumbers atoms. It replaces the hydrogen atom positions with calculated hydrogen atom positions (e.g. read structure into Mercury, normalise all X-H bond lengths then save then feed the new .cif file as “<Basename>_Hmi.cif” to the program). There is an example for Pigment Yellow 110 (CSD refcode FEGDOL). The “experimental” powder pattern is calculated and its scale does not match the calculated pattern.

3. Write input files for TLS refinement. What is also nice: it calculates the corrected atomic coordinates: the atomic coordinates of the underlying rigid-body object if it would not be moving. I then use those coordinates to calculate the bond lengths and valence angles for the restraints. So no matter how much thermal motion there is, you can use the bond lengths and valence angles from a T = 0 K calculation for the restraints.

4. Calculate the libration vectors from the output of the TLS refinement.

All the code works as follows:

- The input files must have been written with DASH and you have not made any substantial manual changes to the .inp file (minor changes are fine). - There is one molecule in a general position, there is one crystal structure, there is one powder pattern. - The code cannot interpret a TOPAS file, the entire processing is text-based.

The code can be compiled with Dev-C++ 5.11, which can be downloaded for free and which is easy to install on Windows. Dev-C++ 5.11 is in fact a development environment, but it also comes with a compiler. Just create a new project (a Win32 Console target), delete the main.cpp file that is automatically created, add all .h and .cpp files to that project and click “Execute” | “Compile”, should work first time.

To create different executables doing different things: all executables are in the function

int main( int argc, char** argv )

in Main.cpp, but only the one at the top is compiled. Each executable starts with

try // <some comment>

and ends with

MACRO_END_GAME

. Just cut-and-paste the functionality you are interested in to the top of the function

int main( int argc, char** argv )

(but after the line

char a;

) and compile. An executable with the name “Project1.exe” will be created.

The source code was written by Jacco van de Streek. Using Google, it should not be that difficult to find me and my e-mail address.

tls_refinement.txt · Last modified: 2022/11/03 15:08 by 127.0.0.1