User:Eric Martz/How JSmol works: Difference between revisions
Eric Martz (talk | contribs) |
Eric Martz (talk | contribs) |
||
Line 19: | Line 19: | ||
Such molecular structure data files are called [[atomic coordinate files]]. JSmol is able to read more than 50 formats of such files. The most common are XYZ format for small organic compounds (usually <100 atoms), and [[PDB file|PDB or mmCIF formats]] for macromolecules. | Such molecular structure data files are called [[atomic coordinate files]]. JSmol is able to read more than 50 formats of such files. The most common are XYZ format for small organic compounds (usually <100 atoms), and [[PDB file|PDB or mmCIF formats]] for macromolecules. | ||
==Covalent Bonds== | |||
Interestingly, the common data formats (XYZ, PDB) do not specify where covalent bonds occur. JSmol determines when a covalent bond occurs between a pair of atoms based on the inter-atomic distance and the chemical elements involved. | |||
JSmol does not determine whether covalent bonds are single, double, triple, or delocalized (e.g. aromatic). However, bond order information is available for every residue present in the [[Protein Data Bank]], and can be loaded along with the PDB file on request to JSmol. When loaded, JSmol is capable of displaying single, double, triple and delocalized covalent bonds appropriately. | |||
JSmol can also determine the positions of hydrogen bonds and display them as dotted bonds. | |||
==Rendering and Coloring== | |||
[https://chemapps.stolaf.edu/jmol/docs/ JSmol script commands] specify how different portions of the molecule are to be rendered (ball and stick, wireframe, backbone trace, ribbon trace, etc. etc.) and colored. The command language is extensive and complex. The [[Scene Authoring Tools]] of Proteopedia free authors of molecular scenes from learning the command language. | |||
Green links in Proteopedia use JavaScript to send scripts of commands to JSmol to change the rendering and coloring of the molecular scene, as well as the center of rotation, the degree of zooming, and many other options. In other web pages (e.g. Proteopedia's [[Scene Authoring Tools]], [[FirstGlance in Jmol]], or the simple.htm example mentioned above), buttons and forms use JavaScript to send command scripts to JSmol. |