擅长:python、mysql、java
<p>对于“更精确”:<a href="http://code.activestate.com/recipes/393090/" rel="noreferrer">this recipe in the Python Cookbook</a>有求和算法,可以保持完全的精度(通过跟踪小计)。代码是用Python编写的,但即使您不了解Python,也可以很清楚地适应任何其他语言。</p>
<p>所有细节都在<a href="http://www-2.cs.cmu.edu/afs/cs/project/quake/public/papers/robust-arithmetic.ps" rel="noreferrer">this paper</a>中给出。</p>