球面上的3个点的球心和半径 [英] Sphere center point and radius from 3 points on the surface

查看:93
本文介绍了球面上的3个点的球心和半径的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以从表面上的3个点找到球的中心及其半径?

Is it possible to find he center of sphere and its radius from 3 points on the surface ?

我正在为分段的大脑结构建立模型,因为这三个点将在结构内;头,尾巴和中间.

I'm building a model for a segmented brain structure were the three points would be within the structure; head, tail and middle.

谢谢

推荐答案

表示球体的中心与三个给定点等距并且与它们共面(假设三个给定点在一个大圆上)./p>

Express that the center of the sphere is equidistant to the three given points and coplanar with them (assuming that the three given points are on a great circle).

(X - Xa)² + (Y - Ya)² + (Z - Za)² = R²    
(X - Xb)² + (Y - Yb)² + (Z - Zb)² = R²    
(X - Xc)² + (Y - Yc)² + (Z - Zc)² = R²    

|X  Y  Z  1|
|Xa Ya Za 1|
|Xb Yb Zb 1| = 0
|Xc Yc Zc 1|

从第二个和第三个方程中减去第一个方程,就可以消除二次项.

Subtracting the first equation from the second and the third, you get rid of the quadratic terms.

(2X - Xb - Xa)(Xb - Xa) + (2Y - Yb - Ya)(Yb - Ya) + (2Z - Zb - Za)(Zb - Za) = 0
(2X - Xc - Xa)(Xc - Xa) + (2Y - Yc - Ya)(Yc - Ya) + (2Z - Zc - Za)(Zc - Za) = 0

现在您有了一个由3个方程组成的简单线性系统,其中包含3个未知数.

Now you have an easy linear system of 3 equations in 3 unknowns.

为简洁起见,您可以翻译这三个点,以便 Xa = Ya = Za = 0 ,等式简化为

For conciseness you can translate the three points so that Xa=Ya=Za=0, and the equations simplify as

|X  Y  Z |
|Xb Yb Zb| = 0
|Xc Yc Zc|

(2X - Xb) Xb + (2Y - Yb) Yb + (2Z - Zb) Zb = 0
(2X - Xc) Xc + (2Y - Yc) Yc + (2Z - Zc) Zc = 0

(Yb Zc - Yc Zb) X + (Zb Xc - Zc Xb) Y + (Xb Yc - Xc Yb) Z = 0
       2 Xb     X +        2 Yb     Y +        2 Zb     Z = Xb² + Yb² + Zb²
       2 Xc     X +        2 Yc     Y +        2 Zc     Z = Xc² + Yc² + Zc²

然后,R²=X²+Y²+Z²,并且别忘了将其翻译回去.

Then, R² = X² + Y² + Z², and don't forget to translate back.

这篇关于球面上的3个点的球心和半径的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆