This example demostrates how topological analysis can be used to identify interaction sites i.e. different kind of chemical bonds in molecules. Using simulations and experiments, the electron density field denoted as
Rho can be estimated for a molecule. Topological analysis of this scalar field can reveal important features in the data. For example, the maxima of this field correspond to the atom locations while saddles occur along the covalent bonds. However, for identification of non-covalent interactions like ionic bonds, analysis of the density field
Rho is not enough. A derived scalar field from
Rho called reduced density gradeint denoted by
s is suggested in literature which can reveal non-covalent interation sites in a molecule. In this example, we will extract and compare the critical points for the
s scalar fields for a simple molecule 1,2-ethanediol.
First a VTI file is loaded which contains two scalar fields namely
log(s). Then using ScalarFieldCriticalPoints, the critical points for
log(Rho) are computed which are then converted into spheres using IcospheresFromPoints. They are shown as bigger transluscent green and white spheres in the screenshot above. Note that these critical points identify the atoms and covalent bonds in the molecule.
Next, we analyse
log(s), the reduced gradient scalar field. Here, the PersistenceCurve is computed (top right view in the above screenshot). Then, the PersistenceDiagram for
log(s) is computed and thresholds are applied based on persistence to maintain only the most persistent features. This results in a simplified persistence diagram (bottom right view in the above screenshot).
The simplified persistence diagram is then used as a constraint for the TopologicalSimplification of the input scalar data. The simplified data is then used as input to ContourTree (FTM) to compute the join tree for the data. The join tree captures the topological changes in sub-level sets of the scalar field and therefore consists of leaves corresponding to minima and internal nodes corresponding to saddles, the points where sublevel sets merge. The nodes of this join tree are selected and highlighted as smaller opaque blue and white spheres using IcospheresFromPoints. Similarly, the arcs of the join tree are also extracted and shown as thin grey tubes in the screenshot above.
Using topological analysis of
log(s), we identify an outlying minimum which is not close to the atom locations. This corresponds to a non-covalent interaction site in the molecule which is not identifiable using direct toplogical analysis of electron density field
Rho. Lastly, we extract the segmented region corresponding to this particular minimum (shown as transluscent blue surface in the screenshot).
To reproduce the above screenshot, go to your ttk-data directory and enter the following command:
$ paraview --state=states/interactionSites.pvsm
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
- BuiltInExample2.vti: 3D scalar fields corresponding to electron density distribution
Rhoand the reduced density gradient
saround a simple molecule 1,2-ethanediol.
logRhoCriticalPoints.vtp: All the scalar field critical points computed for
logSPersistenceCurve.csv: The output persistence curve for
logSPersistenceDiagram.vtu: The output persistence diagram for
logSJoinTreeCriticalPoints.vtp: The critical points in the join tree of
logSJoinTreeArcs.vtp: The arcs of the join tree of
NonCovalentInteractionSite.vtp: The non-covalent interaction site region identified using the join tree of
Note that you are free to change the VTK file extensions to that of any other supported file format (e.g.
csv) in the above python script.