# Trying to understand SMILES(?) patterns

In the example calculation from the conformer search package fafoom is a mysterious pattern that I'd like to understand.

The SMILES code of the given example structure is:

CC(=O)N[C@H](C(=O)NC)C

There is a first not so hard pattern for the smart_cistrans pattern identifier

C~[$(C=O)]-[$(NC)]~[C]

which tells the program that peptide bonds behave like cis-trans isomers. That is relatively easy to see but I don't really understand it to adapt it on further problems.

But there is another identifier for torsion angles that for me is even harder to understand:

[*]~[!$(*#*)&!D1]-&!@[!$(*#*)&!D1]~[*]

The [*]'s at the beginning and at the end look like defining any atom ... but the cursing signs in the middle don't tell me anything.

Dear reader, if you understand how those patterns are generated, I would ask you break them down piece for piece that I can use them afterwards on my own.

• Interesting to see the link to fafoom.. I'll have to investigate that further to compare to other tools I have. – Geoff Hutchison Aug 4 '15 at 21:50
• I found it yesterday, there is a related arXiv-paper. – pH13 - Yet another Philipp Aug 5 '15 at 7:22
• @GeoffHutchison, may I ask what other tools you have? :) – pH13 - Yet another Philipp Aug 5 '15 at 9:19

First off this is SMARTS not SMILES.

Think of SMARTS as like a regular expression language for molecules (e.g., SMILES).

So let's break down some of those characters:

• ~ is "any bond"
• ! is "not"
• $indicates a recursive SMARTS expression. • @ indicates "any ring bond" The$(*#*) means "two atoms with a triple bond between them". The !D1 means and not an atom with one explicit bond.

Taken as a whole, [*]~[!\$(*#*)&!D1] means any atom with a bond to an atom that doesn't have just one explicit bond or a triple bond.

Basically, the pattern is trying to find a single bond in the middle with some rotatable side-groups: [*]~[...]-&[..]~[*]

There's a very nice tool called SMARTS Viewer that can help to debug and construct SMARTS.

Seems like there are also now more polished commercial versions called SMARTStools through BioSolveIT including an editor.