# MMTK User's Guide

Konrad Hinsen
Centre de Biophysique Molculaire
Centre National de la Recherche Scientifique
Rue Charles Sadron
45071 Orlans Cedex 2
France
E-Mail: hinsen@cnrs-orleans.fr
Last revision: 2002-6-14

### Introduction

The Molecular Modelling Toolkit (MMTK) presents a new approach to molecular simulations. It is not a "simulation program" with a certain set of functions that can be used by writing more or less flexible "input files", but a collection of library modules written in an easy-to-learn high-level programming language, Python. This approach offers three important advantages:

- Application programs can use the full power of a general and well-designed programming language.

- Application programs can profit from the large set of other libraries that are available for Python. These may be scientific or non-scientific; for example, it is very easy to write simulation or analysis programs with graphical user interfaces (using the module `Tkinter` in the Python standard library), or couple scientific calculations with a Web server.

- Any user can provide useful additions in separate modules, whereas adding features to a monolithic program requires at least the cooperation of the original author.

To further encourage collaborative code development, MMTK uses a very unrestrictive licensing policy, just like Python. Although MMTK is copyrighted, anyone is allowed to use it for any purpose, including commercial ones, as well as to modify and redistribute it (a more precise description is given in the copyright statement that comes with the code).

This manual describes version 2.2 of MMTK. The 2.x versions contain some incompatible changes with respect to earlier versions (1.x), most importantly a package structure that reduces the risk of name conflicts with other Python packages, and facilitates future enhancements. There are also many new features and improvements to existing functions.

Using MMTK requires a basic knowledge of object-oriented programming and Python. Newcomers to this subject should have a look at the introductory section in this manual and at the Python tutorial (which also comes with the Python interpreter). There are also numerous books on Python that are useful in getting started. Even without MMTK, Python is a very useful programming language for scientific use, allowing rapid development and testing and easy interfacing to code written in low-level languages such as Fortran or C.

This manual consists of several introductory chapters and a Module Reference. The introductory chapters explain how common tasks are handled with MMTK, but they do not describe all of its features, nor do they contain a full documentation of functions or classes. This information can be found in the Module Reference, which describes all classes and functions intended for end-user applications module by module, using documentation extracted directly from the source code. References from the introductory sections to the module reference facilitate finding the relevant documentation.

- Overview

- Constructing a molecular system

- Minimization and Molecular Dynamics

- Normal modes

- Analysis operations

- Miscellaneous operations

- Constructing the database

- Threads and parallelization

- Reference for Module MMTK

- Examples

- Glossary

- References