3D ポイントの任意のコレクションがあります。それらが同一平面上にあることはわかっていますが、その平面をどのように計算すればよいですか?
5 に答える
それらがすべて平面でない場合は、最小二乗法を使用して平面の係数を計算します。
平面の方程式は Ax + By + Cz = D なので、ポイントを入力して 4 つの未知の係数を解きます。
更新: 好奇心が強い - すべてのポイントが同じ平面にあることをどのように「知る」のですか? 何があなたをそう確信させるのですか?
それらが同一平面上にあると仮定して、3 つの点を選び、これを試してください。
http://www.jtaylor1142001.net/calcjat/Solutions/VPlanes/VP3Pts.htm
同一線上にない任意の 3 点が平面を定義するため、考えられる答えは...
同一線上にない最初の 3 点をつかむだけです。
Another way to define a plane is a function from two parameters to a point. If you have three points A,B,C, then the function f(i,j) = A + (B-A)i + (C-A)j
covers all the points on the plane.
Depending on your application it may be useful to normalise the b = (B-A)
and c = (C-A)
vectors to be perpendicular and of unit length. Unit length is easy.
In order to make them perpendicular, first normalise b, then take the dot product of b and c. This is the amount the the c vector points in the same direction as b, so substract this from c. c = c - (b.c)b
Finally normalise c (i.e. divide by it's length)