Skip to content

Modeling and Simulation

Modeling and simulation are two of the main tasks performed in SAMSON.

Models and simulators are nodes in SAMSON document.

You can try the following interactive tutorial in SAMSON (Help > Tutorials): "Modeling: launching simulations".

Please refer to the Models section to learn about model nodes in SAMSON.

Simulators#

Simulators (potentially interactive ones) are used to build physically-based models, and predict properties.

A simulator is applied to a dynamical model, an interaction model, and a state updater. When you start interactive simulation, SAMSON goes through all simulators added to the document and calls their state updaters to update the state of the attached dynamical model. The simulator contains dynamical model, interaction model, state updater, and synchronizes these different models.

In SAMSON, force fields are named interaction models and integrators are named state updaters. Simulations in SAMSON are interactive in the sense that users can still act on the atoms while the simulation is running.

Performing a simulation

Applying simulators#

Prerequisites: Please refer to the Building molecules section to learn how to build molecules in SAMSON.

Let's apply a simulator to a simple system, to see how the simulation affects its geometry.

Add any molecule from the Asset Browser or simply switch to the Add editor (add editor) in the left-side menu of the viewport and click anywhere in the viewport to add an atom (by default it should be Carbon).

To add a simulator:

  1. click Edit > Add simulator (shortcut: Ctrl+Shift+M on Windows and Linux, Cmd+Shift+M on Mac).
  2. Select an interaction model: Universal Force Field.
  3. Select a state updater: Interactive modeling.
  4. Specify the simulator name if you would like to.
  5. Press OK.

Add simulator

Note

Please refer to doi:10.1002/jcc.24309 for more information on the Universal Force Field (UFF) implementation in SAMSON.

You should see a property window for the Universal Force Field interaction model and you can view the properties of the Interactive modeling state updater by selecting it and opening the Inspector:

Properties of the UFF interaction model and the Interactive modeling state updater

Start/Stop simulation

To launch the simulation:

  • click Edit > Start simulation
  • shortcut: X.

To stop the simulation:

  • click Edit > Stop simulation
  • shortcut: X.

The newly created simulator including the interaction model, state updater, and the associated dynamical model will be added in the Document view:

Simulator in the document view

In the image above you can see the following:

Select an atom in the Methane molecule and try to drag it slowly, you should see the interactive simulation in action - the molecule should follow the dragged atom.

Interactive simulation with UFF and interactive modeling state updater

For the Interactive modeling state updater you can modify the step size and the number of steps. You can increase the number of simulations steps to increase the stiffness of the system. Try modifying the number of steps and the step size for the Interactive modeling state updater.

Conformations#

In SAMSON, conformations are used to store a state (positions) of a structural model or a group of atoms. It is like a single frame in a trajectory.

To save the current state of a structural model or group of atoms:

  1. Select this structural model or this group of atoms.
  2. Click on Edit > Conformation (shortcut: S).

A new conformation node should appear in the Document view:

Conformation

You can restore a conformation by double-clicking on it in the Document view or right-click on it and choose Restore conformation:

Restore a conformation

You can create a path (a trajectory) from a set of conformations given that they store information for the same set of atoms:

  1. Select a set of conformations.
  2. Right-click on the selection and, in the context menu, go to Conformation > Create path from conformations.

Combine conformations in a path

Note

When you save a document in a .sam or .samx file, then all the conformations are saved as well.