メタン(CH4)の分子を 3D グラフィックスで描く

次の本にメタン(CH4)の分子を 3D グラフィックスで描く例が載っていたのでここに載せる。

Getting Started with Mathematica, Third Edition , C-K. Cheung et al., Wiley, ISBN 978-0-470-45687-3

p.123 とp.182 にメタン(CH4)の分子の例が載っている。

h1 = {0, 0, 0}; 
h2 = {2, 0, 0};
h3 = {1, Sqrt[3], 0};
h4 = {1, 1/Sqrt[3], Sqrt[96]/6};
c = {1, 1/Sqrt[3], 1/Sqrt[6]};   (* coordinate of the carbon atom *)
g1 = Graphics3D[{GrayLevel[0.5], Sphere[h1, 0.15]}];
g2 = Graphics3D[{GrayLevel[0.5], Sphere[h2, 0.15]}];
g3 = Graphics3D[{GrayLevel[0.5], Sphere[h3, 0.15]}];
g4 = Graphics3D[{GrayLevel[0.5], Sphere[h4, 0.15]}];
g5 = Graphics3D[{GrayLevel[0.5], Sphere[c, 0.25]}];
g6 = Graphics3D[{Thickness[0.03], GrayLevel[0.5],
    Line[{c, h1}], Line[{c, h2}], Line[{c, h3}], Line[{c, h4}]}];
g7 = Graphics3D[{Thickness[0.005], Dashing[{0.03, 0.03}],
    GrayLevel[0.3], Line[{h1, h2}], Line[{h1, h3}],
    Line[{h1, h4}], Line[{h2, h3}], Line[{h2, h4}],
    Line[{h3, h4}] }];
grfMethan = Show[g1, g2, g3, g4, g5, g6, g7, ViewPoint -> {2, 8, 1},
  BoxRatios -> Automatic, Boxed -> False, Axes -> False, 
  AxesLabel -> {"x", "y", "z"}, PlotRangePadding -> 0.2]

演習

  • 問1.  2 個の水素の座標 h1と h2 を次とする。 h1 = {0, 0, 0};  h2 = {2, 0, 0}; 正4面体の頂点にある3番目の水素 h3 の座標を求める。

  • 問2. 正4面体の頂点にある4番目の水素 h4 の座標を求める。
  • 問3. 正4面体の中心にある炭素の座標を求める。正4面体の頂点にある水素から等距離になることを利用する。
  • 問4. 分子結合間の角度(水素 - 炭素 - 水素を結ぶ水素間の角度)を求める。

目次へ