Phil, here's the idea. I'm pretty sure this a comprehensive solution for
you.

2D or 3D:

It doesn't matter how you draw the structure.

It doesn't matter if you include extra hydrogen atoms or not, because what
Jmol is doing is creating a topologically (though not dimensionally) correct
model from the SMILES string, then checking it. So it doesn't matter how you
indicate H atoms or what order the stereochemical notation of the SMILES
string ends up being. It should work.

Jmol should give a definitive answer as to whether the structure drawn
matches your specified SMILES string, as long as your string is valid. Or,
if you wish, it can tell you if a subset of the SMILES string is some
particular grouping of atoms, with or without stereochemistry.

JmolSmilesApplet.jar
-----------------------------

You can see a demo of this at
http://chemapps.stolaf.edu/jmol/docs/examples-11/JmolSmiles.htm

This page uses a mini-version of Jmol that I just made that JUST does ONE
THING -- checks SMILES strings for patterns. It's just 41K in size. But you
can use Jmol itself if you want. This mini version just has one function:

var retValue = document.getElementById("JmolSmiles1").find("pattern",
"smilesString", asSMARTS, isAll)

where

asSMARTS (true or false) indicates whether you want a substructure search
(SMARTS, true) or an exact search (SMILES, false)

isAll indicates whether you want Jmol to return the total number of matches
or just the number 1 indicating a match and 0 indicating no match. (-1 means
there was an error handling the string)


3D:

Jmol will also check a 3D model against a SMILES string or a SMARTS pattern.
Within Jmol, this is done within the SELECT command using the smiles()
function (for exact match) or using the search() function (for a
substructure search). You can also use this construct within Jmol:

  Var x = {*/1.1}.find("smarts","C=O", true)

This function is actually VERY powerful and can return either a set of all
matching atoms (false) or a list of sets of atoms (true).  I've added one
bit to SMARTS -- so I'm calling it now "3D-SEARCH" -- that allows you to
select out WHICH atoms you want returned. To do this, just add { } around
the atoms you want returned.

So, for example:

print {*}.find("a")      # all aromatic atoms

print {*}.find("{C}=O")     # all carbonyl carbons

print {*}.find("{C}=CC(=O)[O,N]")     # all beta carbons on alpha-beta
conjugated esters or amides

Cool, huh?

The only problem with matching a 3D structure may be with what other
programs use to define "aromatic". Jmol should do just fine with structures
that are typically aromatic. In addition, though, it will assign all the
ring carbons of quinone to be aromatic as well (which is what JME does).
Basically it defines aromatic as "flat ring that is all sp2-hybridized"
regardless of what the bonding indicates. (This is kind of cool, because you
can then use it in PDB files to find all the aromatic rings in HIS, TYR,
TRP, A, T, C, G, etc.)

Bob

------------------------------------------------------------------------------

>
>
> _______________________________________________
> Jmol-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>
>


-- 
Robert M. Hanson
Professor of Chemistry
St. Olaf College
1520 St. Olaf Ave.
Northfield, MN 55057
http://www.stolaf.edu/people/hansonr
phone: 507-786-3107


If nature does not answer first what we want,
it is better to take what answer we get.

-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
------------------------------------------------------------------------------

_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to