0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Scipy > Delaunay > cocircular > 定義 | cospherical

Last updated at Posted at 2017-11-18
動作環境
GeForce GTX 1070 (8GB)
ASRock Z170M Pro4S [Intel Z170chipset]
Ubuntu 16.04 LTS desktop amd64
TensorFlow v1.2.1
cuDNN v5.1 for Linux
CUDA v8.0
Python 3.5.2
IPython 6.0.0 -- An enhanced Interactive Python.
gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
GNU bash, version 4.3.48(1)-release (x86_64-pc-linux-gnu)
scipy v0.19.1
geopandas v0.3.0
MATLAB R2017b (Home Edition)

データ

https://github.com/gradywright/spherepts
getIcosNode.mを用いて[x0, tri0] = getIcosNodes(4,0)とした時に、tri = delaunay(x)で使われるxが以下となる。

delaunay_input_171118.txt
   0.0000000e+00   8.5065081e-01   5.2573111e-01
   0.0000000e+00  -8.5065081e-01   5.2573111e-01
   0.0000000e+00   8.5065081e-01  -5.2573111e-01
   0.0000000e+00  -8.5065081e-01  -5.2573111e-01
   5.2573111e-01   0.0000000e+00   8.5065081e-01
  -5.2573111e-01   0.0000000e+00   8.5065081e-01
   5.2573111e-01   0.0000000e+00  -8.5065081e-01
  -5.2573111e-01   0.0000000e+00  -8.5065081e-01
   8.5065081e-01   5.2573111e-01   0.0000000e+00
  -8.5065081e-01   5.2573111e-01   0.0000000e+00
   8.5065081e-01  -5.2573111e-01   0.0000000e+00
  -8.5065081e-01  -5.2573111e-01   0.0000000e+00

code

上記のxの値をScipyで処理する。

test_scipy_delaunay_171119.py
import numpy as np
from scipy.spatial import Delaunay


IN_FILE = 'delaunay_input_171118.txt'
xyz = np.genfromtxt(IN_FILE, delimiter='  ')
print("---xyz---")
print(xyz)

print("---dln---")
dln = Delaunay(xyz, qhull_options="Qt Qbb Qc")
#print(dln)

run
$ python3 test_scipy_delaunay_171119.py 
(中略)
Traceback (most recent call last):
  File "test_scipy_delaunay_171119.py", line 11, in <module>
    dln = Delaunay(xyz, qhull_options="Qt Qbb Qc")
  File "scipy/spatial/qhull.pyx", line 1882, in scipy.spatial.qhull.Delaunay.__init__ (scipy/spatial/qhull.c:18174)
  File "scipy/spatial/qhull.pyx", line 434, in scipy.spatial.qhull._Qhull.__init__ (scipy/spatial/qhull.c:5799)
scipy.spatial.qhull.QhullError: QH6019 qhull input error: can not scale last coordinate.  Input is cocircular
   or cospherical.   Use option 'Qz' to add a point at infinity.

While executing:  | qhull d Qt Qc Qbb
Options selected for Qhull 2015.2.r 2016/01/18:
  run-id 18630392  delaunay  Qtriangulate  Qcoplanar-keep  Qbbound-last
  _pre-merge  _zero-centrum  Qinterior-keep  Pgood

疑問

上記の「Input is cocircular or cospherical. Use option 'Qz' to add a point at infinity.」における「cocircular」とは何か。

Definition 5.3 (cocircular point set) Let $P$ be a finite set of points in three-dimensional space $R^{3}$. More than three coplanar points are said to be cocircular in $R^{3}$ if and only if they are located on the perimeter of a two-dimensional circle $s$ in $R^{3}$ where $s$ defines a disk which contains no other points in $P$.

三次元の点ではあるが、二次元の円の円周上にのみ配置されている時に「cocircular」と呼ばれると理解した。

同様に、三次元の球の球殻上にのみ配置された時に「cospherical」と呼ばれるのだろう。

現在のターゲットは球の積分を効率的に行うための球殻上の点を扱っている。cosphericalなのだろう。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?