-
Notifications
You must be signed in to change notification settings - Fork 0
/
cipw.html
171 lines (152 loc) · 9.77 KB
/
cipw.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
<!DOCTYPE html>
<html class="no-js" lang="zh">
<head>
<title>ChinaGeology</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0">
<link rel="stylesheet" id="responsive-style-css" href='/theme/css/style.css' type="text/css" media="all" />
<link rel="stylesheet" id="responsive-style-css" href='/theme/css/highlight.css' type="text/css" media="all" />
<link href="/feeds/all.atom.xml" type="application/atom+xml" rel="alternate" title="ChinaGeology Full Atom Feed" />
<link href="/feeds/work.atom.xml" type="application/atom+xml" rel="alternate" title="ChinaGeology Categories Atom Feed" />
</head>
<body id="index" class="blog">
<div id="container" class="hfeed">
<header id="header" >
<div id="logo">
<h1><img src="/theme/image/default-logo.png" width="300" height="100" alt="CycleUser" />
ChinaGeology</h1>
</div> <!-- /#logo-->
<nav id="menu" class="main-nav"><ul class="menu">
<li class="active"><a href="http://chinageology.com">Homepage</a></li>
<li class="active"><a href="http://chinageology.com/categories.html">Categories</a></li>
<li class="active"><a href="http://chinageology.com/tags.html">Tags</a></li>
<li class="active"><a href="http://chinageology.com/archives.html">Archives</a></li>
<li class="active"><a href="http://chinageology.com/about.html">About</a></li>
</ul></nav><!-- /#menu -->
</header>
<section id="wrapper" class="clearfix">
<section id="content" class="grid col-620" >
<section class="breadcrumb-list">
<a href="">Blog</a> ›<a href="category/work.html">Work</a> ›CIPW
</section>
<section id="post" class="post hentry">
<header>
<h2 class="post-title" >CIPW</h2>
<div class="post-meta">
<span class="meta-prep">Post in</span>
<abbr class="date" title="2017-04-06T00:00:00+08:00">
<a href="/archive/2017/ 4/index.html">四 06 四月 2017 </a>
</abbr>
<span class="meta-prep"> |Tags</span>
<a href="/tag/geopython.html">GeoPython</a>
<a href="/tag/python.html">Python</a>
<!-- TOBE COMMENTS -->
</div>
</header>
<div class="post-entry">
<h1>关于 CIPW 计算</h1>
<p>CIPW 的设计初衷真不错,而且在那么久之前就有这种程序化的一步一步来拼的思路,很适合编程实现。</p>
<p>不过目前来看,国外流传比较广的计算表格是<a href="http://minerva.union.edu/hollochk/kth/">美国联合学院的Kurt Hollocher</a>这位老兄的,下载地址在<a href="https://pan.baidu.com/s/1skN5ugd">这里</a>。</p>
<p>他的这个 Excel 表格做的非常细致,每一步都很清晰,不过其中有两处标注出了错,但我检查过,应该是不影响计算的。实际上我就是把他的表格中的算法抽了出来重新实现了,又加了批量计算的几个循环体。</p>
<p>国内估计用的比较多的是路远发老师的GeoKit进行计算,但是路老师的计算过程,如果按照<a href="geokit.net/CIPW.htm">他的网站上面的流程</a>,似乎和 Kurt 的有所差别,尤其是在 Sr 和 Ni 等元素的处理上,步骤完全不一样。</p>
<p>Kurt 的这个表格是 Leon Bagas 分享给我的,他个人推荐用这个,目前我也暂时先用这个来计算了。</p>
<p>我的 <a href="https://github.com/chinageology/GeoPython">GeoPython</a> 里面还是选择了用 Kurt 的计算思路,因为其中的计算流程更清晰一些。</p>
<p>在计算结果上,我在 <a href="https://github.com/chinageology/GeoPython">GeoPython</a> 里面使用了 ChemPy 来获取元素的原子量以及各种矿物的分子量,而 Kurt 原版是选择了小数点后两位小数的近似值。所以 GeoPython 里面用的原子量和分子量可能会更精确一些,这在 CIPW 计算结果上会体现在个位数的偶尔差异,以及小数点后数值的明显差异。 ChemPy 是一个化学方面的 Python 模块,我比较推荐使用;而 Kurt 的计算表格中由于使用了 Excel 等原因,数位有所取舍。</p>
<p><a href="https://github.com/chinageology/GeoPython">GeoPython</a> 的 CIPW 模块是这样设计的:数据输入用一个 CIPW.xlsx 或者 CIPW.csv,其中一定要注意的是单位问题,Sr、Ba、Ni、Cr、Zr 这几个元素用的是 ppm,而其他的项目都是质量百分比。</p>
<p>计算出来的结果用额外的文件来存储。生成的四个 csv 文件,Claced 的是计算出来的各种岩石参数,比如 DI 值、 Mg# 等等;Result 是计算出来的摩尔数,也就是直接的结算结果;Volume 和 Weight 分别是转成 体积分数和质量分数的结果。</p>
<p><a href="https://github.com/chinageology/GeoPython/blob/master/Download.md">下载链接请点击这里</a></p>
<p>其实不太推荐大家用打包好的 exe 或者 app,而更推荐从 pip 上面来安装 GeoPython,因为每次最新的版本都会首先更新到 pip 上面去,另外打包的版本由于要包含 Python 解释器以及所有依赖包,体积很大,Windows 版本接近 200MB, OSX 版本更是有 800MB 之大。</p>
<p>当然如果没有 Python 使用经验的话,暂时只能下载打包好的程序了。</p>
<p>我非常鼓励地学同行们一起来学习和使用 Python,我们不必要非常精通,只要能用 Python 来解决一些日常的问题就可以了。</p>
</div><!-- /.entry-content -->
<footer class="post-meta">
<span class="meta-prep">Category:</span>
<abbr class="category">
<a href="/category/work.html">Work</a>
</abbr>
</footer>
<section id="respond">
<div id="disqus_thread">
<script type="text/javascript">
var disqus_identifier = "cipw.html";
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = 'http://ChinaGeology.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
</script>
</div>
<script id='nodebb-comments-script' ourl="https://v2mm.tech" ocid="53" blogger='cycleuser' src="https://v2mm.tech/plugins/nodebb-plugin-blog-comments2/lib/simple-pelican.js"></script>
</section>
</section>
</section><!-- #content -->
<section id="widgets" class="grid col-300 fit" >
<!--
<section id="widget-search" class="widget-wrapper widget_search">
<form id="searchform" action="http://www.google.com/search" method="get">
<input id="q" class="field" type="text" placeholder="Search Blog" name="q" ></input>
<input id="ie" name="ie" type="hidden" value="utf-8" ></input>
<input id="oe" name="oe" type="hidden" value="utf-8" ></input>
<input id="channel" name="channel" type="hidden" value="suggest" ></input>
<input id="searchsubmit" class="submit" type="submit" value="">
</form>
</section>
-->
<section id="widget-category" class="widget-wrapper widget_archive">
<div class="widget-title">
Category
</div>
<ul>
<li><a href="/category/milestone.html" >MileStone </a></li>
<li><a href="/category/work.html" >Work </a></li>
</ul>
</section>
<section id="widget-tagcloud" class="widget-wrapper widget_archive">
<div class="widget-title">
Tagcloud
</div>
<div>
</div>
</section>
<section id="widget-links" class="widget-wrapper widget_archive">
<div class="widget-title">
Links
</div>
<ul>
<li><a href="https://blog.cycleuser.org">CycleUser</a></li>
<li><a href="https://fanzheng.org">Fan</a></li>
<li><a href="http://o00o.site">FlagPlus</a></li>
<li><a href="http://blog.cosli.top">CosLi</a></li>
<li><a href="http://akagi201.org">Akagi201</a></li>
<li><a href="http://xuanwo.org/">XuanWo</a></li>
<li><a href="https://blog.daftme.com">4Orange</a></li>
<li><a href="http://blog.riverrun.xyz/">River</a></li>
<li><a href="http://v2mm.tech/">V2MM</a></li>
</ul>
</section>
</section><!-- widgets -->
</section><!-- /#wrapper -->
<footer id="footer" class="clearfix"><section class="footer-wrapper">
<div class="grid col-940" >
<div class="grid col-540"></div>
<div class="grid col-380 fit" >
<ul class="social-icons">
<!-- TO BE CONTINUED -->
</ul>
</div>
</div>
<div class="grid col-300 copyright" >
<a href="http://creativecommons.org/licenses/by-nc-sa/3.0/" rel="license">
<img src="http://i.creativecommons.org/l/by-nc-sa/3.0/88x31.png" style="border-width:0" alt="知识共享许可协议"></img>
</a>
</div>
<div class="grid col-300 ">
</div>
<div class="grid col-300 fit powered">
Powered by <a href="http://getpelican.com/">Pelican</a> <br />
which takes great advantage of <a href="http://python.org">Python</a>
</div>
</section></footer>
</div>
</body>
</html>