Trilateration and the Intersection of Three Spheres

​
sphere radii
r
1
1.85
r
2
1.5
r
3
1.85
center distance
O
1
O
2
1.25
center location
O
3
viewpoint
default
front
above
side
opacity
0.5
show axes
Trilateration is used in technologies such as GPS to find the exact location of a point on Earth or in space. It determines a location by means of three distances to known points in space, such as orbiting satellites.
This Demonstration illustrates how trilateration can be done using the intersection of three spheres. Each pair of spheres either do not intersect or intersect in a point (when the spheres are tangent) or a circle. Assuming no spheres are tangent, there are three pairs of spheres, thus there are possibly 0, 1, 2, or 3 circles of intersection.
A location can be determined if there are three circles of intersection, with a triple crossing at two points, which are shown in red. The exact location is then selected from the two points by some other criterion, such as when only one of the points is on the surface of the Earth.

Details

All three centers of the spheres are in the plane
z=0
:
O
1
at
(0,0,0)
,
O
2
at
(d,0,0)
,
O
3
at
(e,f,0)
.
2
r
1
=
2
x
+
2
y
+
2
z
,
2
r
2
=
2
(x-d)
+
2
y
+
2
z
,
2
r
3
=
2
(x-e)
+
2
(y-f)
+
2
z
.
The two intersection points are found by solving these three equations for
x
,
y
, and
z
.
The intersection circles have the parametric form of a circle on a sphere, centered at the origin and with the
x
axis as its normal, rotated by an angle
ψ
around the
y
axis and
ζ
around the
z
axis:
rcos(α)cos(ζ)cos(ψ)+sin(α)(cos(ζ)cos(t)sin(ψ)-sin(ζ)sin(t))
,
rsin(ζ)(cos(α)cos(ψ)+sin(α)cos(t)sin(ψ))+sin(α)cos(ζ)sin(t)
,
r-cos(α)sin(ψ)+sin(α)cos(t)cos(ψ)
,
where
α
is the angular radius of the circle,
ψ
is the rotation around the
y
axis,
ζ
is the rotation around the
z
axis,
and
t
is a parameter running around the circle, from 0 to
2π
.

Permanent Citation

Erik Mahieu
​
​"Trilateration and the Intersection of Three Spheres"​
​http://demonstrations.wolfram.com/TrilaterationAndTheIntersectionOfThreeSpheres/​
​Wolfram Demonstrations Project​
​Published: December 8, 2015