In
geometry
Geometry (; ) is a branch of mathematics concerned with properties of space such as the distance, shape, size, and relative position of figures. Geometry is, along with arithmetic, one of the oldest branches of mathematics. A mathematician w ...
, a hypercube is an
''n''-dimensional analogue of a
square
In geometry, a square is a regular polygon, regular quadrilateral. It has four straight sides of equal length and four equal angles. Squares are special cases of rectangles, which have four equal angles, and of rhombuses, which have four equal si ...
(
) and a
cube
A cube or regular hexahedron is a three-dimensional space, three-dimensional solid object in geometry, which is bounded by six congruent square (geometry), square faces, a type of polyhedron. It has twelve congruent edges and eight vertices. It i ...
(
); the special case for
is known as a ''
tesseract
In geometry, a tesseract or 4-cube is a four-dimensional hypercube, analogous to a two-dimensional square and a three-dimensional cube. Just as the perimeter of the square consists of four edges and the surface of the cube consists of six ...
''. It is a
closed,
compact
Compact as used in politics may refer broadly to a pact or treaty; in more specific cases it may refer to:
* Interstate compact, a type of agreement used by U.S. states
* Blood compact, an ancient ritual of the Philippines
* Compact government, a t ...
,
convex
Convex or convexity may refer to:
Science and technology
* Convex lens, in optics
Mathematics
* Convex set, containing the whole line segment that joins points
** Convex polygon, a polygon which encloses a convex set of points
** Convex polytop ...
figure whose 1-
skeleton
A skeleton is the structural frame that supports the body of most animals. There are several types of skeletons, including the exoskeleton, which is a rigid outer shell that holds up an organism's shape; the endoskeleton, a rigid internal fra ...
consists of groups of opposite
parallel line segment
In geometry, a line segment is a part of a line (mathematics), straight line that is bounded by two distinct endpoints (its extreme points), and contains every Point (geometry), point on the line that is between its endpoints. It is a special c ...
s aligned in each of the space's
dimension
In physics and mathematics, the dimension of a mathematical space (or object) is informally defined as the minimum number of coordinates needed to specify any point within it. Thus, a line has a dimension of one (1D) because only one coo ...
s,
perpendicular
In geometry, two geometric objects are perpendicular if they intersect at right angles, i.e. at an angle of 90 degrees or π/2 radians. The condition of perpendicularity may be represented graphically using the '' perpendicular symbol'', � ...
to each other and of the same length. A unit hypercube's longest diagonal in ''n'' dimensions is equal to
.
An ''n''-dimensional hypercube is more commonly referred to as an ''n''-cube or sometimes as an ''n''-dimensional cube. The term measure polytope (originally from Elte, 1912) is also used, notably in the work of
H. S. M. Coxeter who also labels the hypercubes the γ
n polytopes.
The hypercube is the special case of a
hyperrectangle
In geometry, a hyperrectangle (also called a box, hyperbox, k-cell or orthotopeCoxeter, 1973), is the generalization of a rectangle (a plane figure) and the rectangular cuboid (a solid figure) to higher dimensions. A necessary and sufficient cond ...
(also called an ''n-orthotope'').
A ''unit hypercube'' is a hypercube whose side has length one
unit
Unit may refer to:
General measurement
* Unit of measurement, a definite magnitude of a physical quantity, defined and adopted by convention or by law
**International System of Units (SI), modern form of the metric system
**English units, histo ...
. Often, the hypercube whose corners (or ''vertices'') are the 2
''n'' points in R
''n'' with each coordinate equal to 0 or 1 is called ''the'' unit hypercube.
Construction
By the number of dimensions
A hypercube can be defined by increasing the numbers of dimensions of a shape:
:0 – A point is a hypercube of dimension zero.
:1 – If one moves this point one unit length, it will sweep out a line segment, which is a unit hypercube of dimension one.
:2 – If one moves this line segment its length in a
perpendicular
In geometry, two geometric objects are perpendicular if they intersect at right angles, i.e. at an angle of 90 degrees or π/2 radians. The condition of perpendicularity may be represented graphically using the '' perpendicular symbol'', � ...
direction from itself; it sweeps out a 2-dimensional square.
:3 – If one moves the square one unit length in the direction perpendicular to the plane it lies on, it will generate a 3-dimensional cube.
:4 – If one moves the cube one unit length into the fourth dimension, it generates a 4-dimensional unit hypercube (a unit
tesseract
In geometry, a tesseract or 4-cube is a four-dimensional hypercube, analogous to a two-dimensional square and a three-dimensional cube. Just as the perimeter of the square consists of four edges and the surface of the cube consists of six ...
).
This can be generalized to any number of dimensions. This process of sweeping out volumes can be formalized mathematically as a
Minkowski sum
In geometry, the Minkowski sum of two sets of position vectors ''A'' and ''B'' in Euclidean space is formed by adding each vector in ''A'' to each vector in ''B'':
A + B = \
The Minkowski difference (also ''Minkowski subtraction'', ''Minkowsk ...
: the ''d''-dimensional hypercube is the Minkowski sum of ''d'' mutually perpendicular unit-length line segments, and is therefore an example of a
zonotope
In geometry, a zonohedron is a convex polyhedron that is point symmetry, centrally symmetric, every face of which is a polygon that is centrally symmetric (a zonogon). Any zonohedron may equivalently be described as the Minkowski addition, Minkows ...
.
The 1-
skeleton
A skeleton is the structural frame that supports the body of most animals. There are several types of skeletons, including the exoskeleton, which is a rigid outer shell that holds up an organism's shape; the endoskeleton, a rigid internal fra ...
of a hypercube is a
hypercube graph
In graph theory, the hypercube graph is the graph formed from the vertices and edges of an -dimensional hypercube. For instance, the cubical graph, cube graph is the graph formed by the 8 vertices and 12 edges of a three-dimensional cube.
has ...
.
Vertex coordinates

A unit hypercube of dimension
is the
convex hull
In geometry, the convex hull, convex envelope or convex closure of a shape is the smallest convex set that contains it. The convex hull may be defined either as the intersection of all convex sets containing a given subset of a Euclidean space, ...
of all the
points whose
Cartesian coordinates
In geometry, a Cartesian coordinate system (, ) in a plane is a coordinate system that specifies each point uniquely by a pair of real numbers called ''coordinates'', which are the signed distances to the point from two fixed perpendicular o ...
are each equal to either
or
. These points are its
vertices. The hypercube with these coordinates is also the
cartesian product
In mathematics, specifically set theory, the Cartesian product of two sets and , denoted , is the set of all ordered pairs where is an element of and is an element of . In terms of set-builder notation, that is
A\times B = \.
A table c ...
of
copies of the unit
interval