This article needs additional citations for
verification. (February 2022) |

In the theory of analytic geometry for real three-dimensional space, the curve formed from the intersection between a sphere and a cylinder can be a circle, a point, the empty set, or a special type of curve.

For the analysis of this situation, assume (
without loss of generality) that the axis of the cylinder coincides with the *z*-axis; points on the cylinder (with radius ) satisfy

We also assume that the sphere, with radius is centered at a point on the positive x-axis, at point . Its points satisfy

The intersection is the collection of points satisfying both equations.

If , the sphere lies entirely in the interior of the cylinder. The intersection is the empty set.

If the sphere is smaller than the cylinder () and , the sphere lies in the interior of the cylinder except for one point. The intersection is the single point .

If the center of the sphere lies on the axis of the cylinder, . In that case, the intersection consists of two circles of radius . These circles lie in the planes

If , the intersection is a single circle in the plane .

Subtracting the two equations given above gives

Since is a quadratic function of , the projection of the intersection onto the xz-plane is the section of an orthogonal parabola; it is only a section due to the fact that . The vertex of the parabola lies at point , where

If , the condition cuts the parabola into two segments. In this case, the intersection of sphere and cylinder consists of two closed curves, which are mirror images of each other.
Their projection in the *xy*-plane are circles of radius .

Each part of the intersection can be parametrized by an angle :

The curves contain the following extreme points:

If , the intersection of sphere and cylinder consists of a single closed curve. It can be described by the same parameter equation as in the previous section, but the angle must be restricted to , where .

The curve contains the following extreme points:

In the case , the cylinder and sphere are tangential to each other at point . The intersection resembles a figure eight: it is a closed curve which intersects itself. The above parametrization becomes

where now goes through two full revolutions.

In the special case , the intersection is known as Viviani's curve. Its parameter representation is

The volume of the intersection of the two bodies, sometimes called Viviani's volume, is^{
[1]}
^{
[2]}
^{
[3]}

- Viviani's curve
- Graefe, Eva-Maria; Korsch, Hans J.; Strzys, Martin P. (2014). "Bose-Hubbard dimers, Viviani's windows and pendulum dynamics".
*J. Phys. A: Math. Theor*.**47**(8): 085304. arXiv: 1308.3569. Bibcode: 2014JPhA...47h5304G. doi: 10.1088/1751-8113/47/8/085304. S2CID 55754306.

**^**Lamarche, F.; Leroy, Claude (1990). "Evaluation of the volume of intersection of a sphere with a cylinder by elliptic integrals".*Comput. Phys. Commun*.**59**(2): 359–369. Bibcode: 1990CoPhC..59..359L. doi: 10.1016/0010-4655(90)90184-3.**^**Viviani, V. (1692), """",*Acta Eruditorum*: 273–279**^**Woodhouse, Robert (1801). "VII. Demonstration of a theorem, by which such portions of the solidity of a sphere are assigned as admit an algebraic expression".*Philos. Trans. R. Soc. Lond*.**91**: 153. doi: 10.1098/rstl.1801.0009. S2CID 122654753.