Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
1# flake8: noqa
2import numpy as np
5# Jmol colors. See: http://jmol.sourceforge.net/jscolors/#color_U
6jmol_colors = np.array([
7(1.000,0.000,0.000) ,# None
8(1.000,1.000,1.000), # H
9(0.851,1.000,1.000), # He
10(0.800,0.502,1.000), # Li
11(0.761,1.000,0.000), # Be
12(1.000,0.710,0.710), # B
13(0.565,0.565,0.565), # C
14(0.188,0.314,0.973), # N
15(1.000,0.051,0.051), # O
16(0.565,0.878,0.314), # F
17(0.702,0.890,0.961), # Ne
18(0.671,0.361,0.949), # Na
19(0.541,1.000,0.000), # Mg
20(0.749,0.651,0.651), # Al
21(0.941,0.784,0.627), # Si
22(1.000,0.502,0.000), # P
23(1.000,1.000,0.188), # S
24(0.122,0.941,0.122), # Cl
25(0.502,0.820,0.890), # Ar
26(0.561,0.251,0.831), # K
27(0.239,1.000,0.000), # Ca
28(0.902,0.902,0.902), # Sc
29(0.749,0.761,0.780), # Ti
30(0.651,0.651,0.671), # V
31(0.541,0.600,0.780), # Cr
32(0.612,0.478,0.780), # Mn
33(0.878,0.400,0.200), # Fe
34(0.941,0.565,0.627), # Co
35(0.314,0.816,0.314), # Ni
36(0.784,0.502,0.200), # Cu
37(0.490,0.502,0.690), # Zn
38(0.761,0.561,0.561), # Ga
39(0.400,0.561,0.561), # Ge
40(0.741,0.502,0.890), # As
41(1.000,0.631,0.000), # Se
42(0.651,0.161,0.161), # Br
43(0.361,0.722,0.820), # Kr
44(0.439,0.180,0.690), # Rb
45(0.000,1.000,0.000), # Sr
46(0.580,1.000,1.000), # Y
47(0.580,0.878,0.878), # Zr
48(0.451,0.761,0.788), # Nb
49(0.329,0.710,0.710), # Mo
50(0.231,0.620,0.620), # Tc
51(0.141,0.561,0.561), # Ru
52(0.039,0.490,0.549), # Rh
53(0.000,0.412,0.522), # Pd
54(0.753,0.753,0.753), # Ag
55(1.000,0.851,0.561), # Cd
56(0.651,0.459,0.451), # In
57(0.400,0.502,0.502), # Sn
58(0.620,0.388,0.710), # Sb
59(0.831,0.478,0.000), # Te
60(0.580,0.000,0.580), # I
61(0.259,0.620,0.690), # Xe
62(0.341,0.090,0.561), # Cs
63(0.000,0.788,0.000), # Ba
64(0.439,0.831,1.000), # La
65(1.000,1.000,0.780), # Ce
66(0.851,1.000,0.780), # Pr
67(0.780,1.000,0.780), # Nd
68(0.639,1.000,0.780), # Pm
69(0.561,1.000,0.780), # Sm
70(0.380,1.000,0.780), # Eu
71(0.271,1.000,0.780), # Gd
72(0.188,1.000,0.780), # Tb
73(0.122,1.000,0.780), # Dy
74(0.000,1.000,0.612), # Ho
75(0.000,0.902,0.459), # Er
76(0.000,0.831,0.322), # Tm
77(0.000,0.749,0.220), # Yb
78(0.000,0.671,0.141), # Lu
79(0.302,0.761,1.000), # Hf
80(0.302,0.651,1.000), # Ta
81(0.129,0.580,0.839), # W
82(0.149,0.490,0.671), # Re
83(0.149,0.400,0.588), # Os
84(0.090,0.329,0.529), # Ir
85(0.816,0.816,0.878), # Pt
86(1.000,0.820,0.137), # Au
87(0.722,0.722,0.816), # Hg
88(0.651,0.329,0.302), # Tl
89(0.341,0.349,0.380), # Pb
90(0.620,0.310,0.710), # Bi
91(0.671,0.361,0.000), # Po
92(0.459,0.310,0.271), # At
93(0.259,0.510,0.588), # Rn
94(0.259,0.000,0.400), # Fr
95(0.000,0.490,0.000), # Ra
96(0.439,0.671,0.980), # Ac
97(0.000,0.729,1.000), # Th
98(0.000,0.631,1.000), # Pa
99(0.000,0.561,1.000), # U
100(0.000,0.502,1.000), # Np
101(0.000,0.420,1.000), # Pu
102(0.329,0.361,0.949), # Am
103(0.471,0.361,0.890), # Cm
104(0.541,0.310,0.890), # Bk
105(0.631,0.212,0.831), # Cf
106(0.702,0.122,0.831), # Es
107(0.702,0.122,0.729), # Fm
108(0.702,0.051,0.651), # Md
109(0.741,0.051,0.529), # No
110(0.780,0.000,0.400), # Lr
111(0.800,0.000,0.349), # Rf
112(0.820,0.000,0.310), # Db
113(0.851,0.000,0.271), # Sg
114(0.878,0.000,0.220), # Bh
115(0.902,0.000,0.180), # Hs
116(0.922,0.000,0.149), # Mt
117])
119# CPK colors in units of RGB values:
120cpk_colors = np.array([
121(1.000,0.000,0.000) ,# None
122(1.000,1.000,1.000) ,# H
123(1.000,0.753,0.796) ,# He
124(0.698,0.133,0.133) ,# Li
125(1.000,0.078,0.576) ,# Be
126(0.000,1.000,0.000) ,# B
127(0.784,0.784,0.784) ,# C
128(0.561,0.561,1.000) ,# N
129(0.941,0.000,0.000) ,# O
130(0.855,0.647,0.125) ,# F
131(1.000,0.078,0.576) ,# Ne
132(0.000,0.000,1.000) ,# Na
133(0.133,0.545,0.133) ,# Mg
134(0.502,0.502,0.565) ,# Al
135(0.855,0.647,0.125) ,# Si
136(1.000,0.647,0.000) ,# P
137(1.000,0.784,0.196) ,# S
138(0.000,1.000,0.000) ,# Cl
139(1.000,0.078,0.576) ,# Ar
140(1.000,0.078,0.576) ,# K
141(0.502,0.502,0.565) ,# Ca
142(1.000,0.078,0.576) ,# Sc
143(0.502,0.502,0.565) ,# Ti
144(1.000,0.078,0.576) ,# V
145(0.502,0.502,0.565) ,# Cr
146(0.502,0.502,0.565) ,# Mn
147(1.000,0.647,0.000) ,# Fe
148(1.000,0.078,0.576) ,# Co
149(0.647,0.165,0.165) ,# Ni
150(0.647,0.165,0.165) ,# Cu
151(0.647,0.165,0.165) ,# Zn
152(1.000,0.078,0.576) ,# Ga
153(1.000,0.078,0.576) ,# Ge
154(1.000,0.078,0.576) ,# As
155(1.000,0.078,0.576) ,# Se
156(0.647,0.165,0.165) ,# Br
157(1.000,0.078,0.576) ,# Kr
158(1.000,0.078,0.576) ,# Rb
159(1.000,0.078,0.576) ,# Sr
160(1.000,0.078,0.576) ,# Y
161(1.000,0.078,0.576) ,# Zr
162(1.000,0.078,0.576) ,# Nb
163(1.000,0.078,0.576) ,# Mo
164(1.000,0.078,0.576) ,# Tc
165(1.000,0.078,0.576) ,# Ru
166(1.000,0.078,0.576) ,# Rh
167(1.000,0.078,0.576) ,# Pd
168(0.502,0.502,0.565) ,# Ag
169(1.000,0.078,0.576) ,# Cd
170(1.000,0.078,0.576) ,# In
171(1.000,0.078,0.576) ,# Sn
172(1.000,0.078,0.576) ,# Sb
173(1.000,0.078,0.576) ,# Te
174(0.627,0.125,0.941) ,# I
175(1.000,0.078,0.576) ,# Xe
176(1.000,0.078,0.576) ,# Cs
177(1.000,0.647,0.000) ,# Ba
178(1.000,0.078,0.576) ,# La
179(1.000,0.078,0.576) ,# Ce
180(1.000,0.078,0.576) ,# Pr
181(1.000,0.078,0.576) ,# Nd
182(1.000,0.078,0.576) ,# Pm
183(1.000,0.078,0.576) ,# Sm
184(1.000,0.078,0.576) ,# Eu
185(1.000,0.078,0.576) ,# Gd
186(1.000,0.078,0.576) ,# Tb
187(1.000,0.078,0.576) ,# Dy
188(1.000,0.078,0.576) ,# Ho
189(1.000,0.078,0.576) ,# Er
190(1.000,0.078,0.576) ,# Tm
191(1.000,0.078,0.576) ,# Yb
192(1.000,0.078,0.576) ,# Lu
193(1.000,0.078,0.576) ,# Hf
194(1.000,0.078,0.576) ,# Ta
195(1.000,0.078,0.576) ,# W
196(1.000,0.078,0.576) ,# Re
197(1.000,0.078,0.576) ,# Os
198(1.000,0.078,0.576) ,# Ir
199(1.000,0.078,0.576) ,# Pt
200(0.855,0.647,0.125) ,# Au
201(1.000,0.078,0.576) ,# Hg
202(1.000,0.078,0.576) ,# Tl
203(1.000,0.078,0.576) ,# Pb
204(1.000,0.078,0.576) ,# Bi
205(1.000,0.078,0.576) ,# Po
206(1.000,0.078,0.576) ,# At
207(1.000,1.000,1.000) ,# Rn
208(1.000,1.000,1.000) ,# Fr
209(1.000,1.000,1.000) ,# Ra
210(1.000,1.000,1.000) ,# Ac
211(1.000,0.078,0.576) ,# Th
212(1.000,1.000,1.000) ,# Pa
213(1.000,0.078,0.576) ,# U
214(1.000,1.000,1.000) ,# Np
215(1.000,1.000,1.000) ,# Pu
216(1.000,1.000,1.000) ,# Am
217(1.000,1.000,1.000) ,# Cm
218(1.000,1.000,1.000) ,# Bk
219(1.000,1.000,1.000) ,# Cf
220(1.000,1.000,1.000) ,# Es
221(1.000,1.000,1.000) ,# Fm
222(1.000,1.000,1.000) ,# Md
223(1.000,1.000,1.000) ,# No
224(1.000,1.000,1.000) # Lw
225])