ゴミのやま

完全自分向け雑記

SMARTSってなんやねん(化学)

参考:

magattaca.hatenablog.com

www.molsis.co.jp

要は

SMILES

  • 分子の二次元構造を文字列で記述
  • ワイルドカード表記はできない(多分…?)
  • 一つの化合物構造に対して複数のsmilesがありえる(一対一対応するものはcanonical SMILESと呼ばれる)

SMARTS

  • SMILESを検索クエリ用に拡張
  • ワイルドカードで表記できる
  • 同一記法でもSMILESとは意味が異なる可能性あり

「SMILE語」の文法を学ぶ

語学を学ぶには最低限の文法理解は必要, ということで以下のテーブルをざっくり理解。

原子表記(atomic primitives)

SMARTS Atomic Primitives
Symbol Symbol name Atomic property requirements Default
* wildcard any atom (no default)
a aromatic aromatic (no default)
A aliphatic aliphatic (no default)
D<n> degree <n> explicit connections exactly one
H<n> total-H-count <n> attached hydrogens exactly one1
h<n> implicit-H-count <n> implicit hydrogens at least one
R<n> ring membership in <n> SSSR rings any ring atom
r<n> ring size in smallest SSSR ring of size <n> any ring atom2
v<n> valence total bond order <n> exactly one2
X<n> connectivity <n> total connections exactly one2
x<n> ring connectivity <n> total ring connections at least one2
- <n> negative charge -<n> charge -1 charge (-- is -2, etc)
+<n> positive charge +<n> formal charge +1 charge (++ is +2, etc)
#n atomic number atomic number <n> (no default)2
@ chirality anticlockwise anticlockwise, default class2
@@ chirality clockwise clockwise, default class2
@<c><n> chirality chiral class <c> chirality <n> (nodefault)
@<c><n>? chiral or unspec chirality <c><n> or unspecified (no default)
<n> atomic mass explicit atomic mass unspecified mass

原子表記の例

C

aliphatic carbon atom

c

aromatic carbon atom

a

aromatic atom

[#6]

carbon atom

[Ca]

calcium atom

[++]

atom with a +2 charge

 

[R]

atom in any ring

[D3]

atom with 3 explicit bonds (implicit H's don't count)

[X3]

atom with 3 total bonds (includes implicit H's)

[v3]

atom with bond orders totaling 3 (includes implicit H's)

C[C@H](F)O

match chirality (H-F-O anticlockwise viewed from C)

C[C@?H](F)O

matches if chirality is as specified or is not specified

 

結合表記(bond primitive)

こっちは原子表記より少ないので楽

Symbol Atomic property requirements
- single bond (aliphatic)
/ directional bond "up"1
\ directional bond "down"1
/? directional bond "up or unspecified"
\? directional bond "down or unspecified"
= double bond
# triple bond
: aromatic bond
~ any bond (wildcard)
@ any ring bond1

結合表記の例:

C any aliphatic carbon
cc any pair of attached aromatic carbons
c:c aromatic carbons joined by an aromatic bond
c-c aromatic carbons joined by a single bond (e.g. biphenyl)

省略されると

 

引用元:

www.daylight.com

 

SMARTS官能基当てクイズ

Q:

  1. [CX4]
  2. [CX3]=[OX1]
  3. [NX3][CX3](=[OX1])[#6]

A:

  1. 4つ結合がある脂肪族炭素
    ⇒ アルキル基
  2. (3つ結合がある脂肪族炭素)二重結合(結合を一つもつ酸素)
    ⇒ カルボニル基
  3. (3つ結合がある窒素)(3つ結合がある炭素)(=二重結合(結合を一つもつ酸素))(原子番号6の原子)
    ⇒ アミド基

あとは適宜わからんのが出てきたら学ぶ。

引用:

www.daylight.com

SMARTSを可視化する

大量に可視化したい場合はRDkitなどを使う必要があるのだろうが, ひとまず以下のサイトでお手軽に可視化できる。

https://smartsview.zbh.uni-hamburg.de