In mathematics, a curve (also called a curved line in older texts) is an object similar to a line, but that does not have to be straight.
Intuitively, a curve may be thought of as the trace left by a moving point. This is the definition that appeared more than 2000 years ago in Euclid's Elements: "The [curved] line [a] is […] the first species of quantity, which has only one dimension, namely length, without any width nor depth, and is nothing else than the flow or run of the point which […] will leave from its imaginary moving some vestige in length, exempt of any width." 
This definition of a curve has been formalized in modern mathematics as: A curve is the image of an interval to a topological space by a continuous function. In some contexts, the function that defines the curve is called a parametrization, and the curve is a parametric curve. In this article, these curves are sometimes called topological curves to distinguish them from more constrained curves such as differentiable curves. This definition encompasses most curves that are studied in mathematics; notable exceptions are level curves (which are unions of curves and isolated points), and algebraic curves (see below). Level curves and algebraic curves are sometimes called implicit curves, since they are generally defined by implicit equations.
Nevertheless, the class of topological curves is very broad, and contains some curves that do not look as one may expect for a curve, or even cannot be drawn. This is the case of space-filling curves and fractal curves. For ensuring more regularity, the function that defines a curve is often supposed to be differentiable, and the curve is then said to be a differentiable curve.
A plane algebraic curve is the zero set of a polynomial in two indeterminates. More generally, an algebraic curve is the zero set of a finite set of polynomials, which satisfies the further condition of being an algebraic variety of dimension one. If the coefficients of the polynomials belong to a field k, the curve is said to be defined over k. In the common case of a real algebraic curve, where k is the field of real numbers, an algebraic curve is a finite union of topological curves. When complex zeros are considered, one has a complex algebraic curve, which, from the topological point of view, is not a curve, but a surface, and is often called a Riemann surface. Although not being curves in the common sense, algebraic curves defined over other fields have been widely studied. In particular, algebraic curves over a finite field are widely used in modern cryptography.
Interest in curves began long before they were the subject of mathematical study. This can be seen in numerous examples of their decorative use in art and on everyday objects dating back to prehistoric times.  Curves, or at least their graphical representations, are simple to create, for example with a stick on the sand on a beach.
Historically, the term line was used in place of the more modern term curve. Hence the terms straight line and right line were used to distinguish what are today called lines from curved lines. For example, in Book I of Euclid's Elements, a line is defined as a "breadthless length" (Def. 2), while a straight line is defined as "a line that lies evenly with the points on itself" (Def. 4). Euclid's idea of a line is perhaps clarified by the statement "The extremities of a line are points," (Def. 3).  Later commentators further classified lines according to various schemes. For example: 
The Greek geometers had studied many other kinds of curves. One reason was their interest in solving geometrical problems that could not be solved using standard compass and straightedge construction. These curves include:
A fundamental advance in the theory of curves was the introduction of analytic geometry by René Descartes in the seventeenth century. This enabled a curve to be described using an equation rather than an elaborate geometrical construction. This not only allowed new curves to be defined and studied, but it enabled a formal distinction to be made between algebraic curves that can be defined using polynomial equations, and transcendental curves that cannot. Previously, curves had been described as "geometrical" or "mechanical" according to how they were, or supposedly could be, generated. 
Conic sections were applied in astronomy by Kepler. Newton also worked on an early example in the calculus of variations. Solutions to variational problems, such as the brachistochrone and tautochrone questions, introduced properties of curves in new ways (in this case, the cycloid). The catenary gets its name as the solution to the problem of a hanging chain, the sort of question that became routinely accessible by means of differential calculus.
In the eighteenth century came the beginnings of the theory of plane algebraic curves, in general. Newton had studied the cubic curves, in the general description of the real points into 'ovals'. The statement of Bézout's theorem showed a number of aspects which were not directly accessible to the geometry of the time, to do with singular points and complex solutions.
Since the nineteenth century, curve theory is viewed as the special case of dimension one of the theory of manifolds and algebraic varieties. Nevertheless, many questions remain specific to curves, such as space-filling curves, Jordan curve theorem and Hilbert's sixteenth problem.
A topological curve can be specified by a continuous function from an interval I of the real numbers into a topological space X. Properly speaking, the curve is the image of However, in some contexts, itself is called a curve, especially when the image does not look like what is generally called a curve and does not characterize sufficiently
For example, the image of the Peano curve or, more generally, a space-filling curve completely fills a square, and therefore does not give any information on how is defined.
A curve is closed  or is a loop if and . A closed curve is thus the image of a continuous mapping of a circle.
If the domain of a topological curve is a closed and bounded interval , the curve is called a path, also known as topological arc (or just arc).
A curve is simple if it is the image of an interval or a circle by an injective continuous function. In other words, if a curve is defined by a continuous function with an interval as a domain, the curve is simple if and only if any two different points of the interval have different images, except, possibly, if the points are the endpoints of the interval. Intuitively, a simple curve is a curve that "does not cross itself and has no missing points" (a continuous non-self-intersecting curve). 
A plane curve is a curve for which is the Euclidean plane—these are the examples first encountered—or in some cases the projective plane. A space curve is a curve for which is at least three-dimensional; a skew curve is a space curve which lies in no plane. These definitions of plane, space and skew curves apply also to real algebraic curves, although the above definition of a curve does not apply (a real algebraic curve may be disconnected).
A plane simple closed curve is also called a Jordan curve. It is also defined as a non-self-intersecting continuous loop in the plane.  The Jordan curve theorem states that the set complement in a plane of a Jordan curve consists of two connected components (that is the curve divides the plane in two non-intersecting regions that are both connected).
The definition of a curve includes figures that can hardly be called curves in common usage. For example, the image of a simple curve can cover a square in the plane ( space-filling curve) and thus have a positive area.  Fractal curves can have properties that are strange for the common sense. For example, a fractal curve can have a Hausdorff dimension bigger than one (see Koch snowflake) and even a positive area. An example is the dragon curve, which has many other unusual properties.
Roughly speaking a differentiable curve is a curve that is defined as being locally the image of an injective differentiable function from an interval I of the real numbers into a differentiable manifold X, often
More precisely, a differentiable curve is a subset C of X where every point of C has a neighborhood U such that is diffeomorphic to an interval of the real numbers.[ clarification needed] In other words, a differentiable curve is a differentiable manifold of dimension one.
In Euclidean geometry, an arc (symbol: ⌒) is a connected subset of a differentiable curve.
Arcs of lines are called segments, rays, or lines, depending on how they are bounded.
A common curved example is an arc of a circle, called a circular arc.
In a sphere (or a spheroid), an arc of a great circle (or a great ellipse) is called a great arc.
If is the -dimensional Euclidean space, and if is an injective and continuously differentiable function, then the length of is defined as the quantity
The length of a curve is independent of the parametrization .
In particular, the length of the graph of a continuously differentiable function defined on a closed interval is
More generally, if is a metric space with metric , then we can define the length of a curve by
where the supremum is taken over all and all partitions of .
A rectifiable curve is a curve with finite length. A curve is called natural (or unit-speed or parametrized by arc length) if for any such that , we have
If is a Lipschitz-continuous function, then it is automatically rectifiable. Moreover, in this case, one can define the speed (or metric derivative) of at as
and then show that
While the first examples of curves that are met are mostly plane curves (that is, in everyday words, curved lines in two-dimensional space), there are obvious examples such as the helix which exist naturally in three dimensions. The needs of geometry, and also for example classical mechanics are to have a notion of curve in space of any number of dimensions. In general relativity, a world line is a curve in spacetime.
If is a differentiable manifold, then we can define the notion of differentiable curve in . This general idea is enough to cover many of the applications of curves in mathematics. From a local point of view one can take to be Euclidean space. On the other hand, it is useful to be more general, in that (for example) it is possible to define the tangent vectors to by means of this notion of curve.
If is a smooth manifold, a smooth curve in is a smooth map
This is a basic notion. There are less and more restricted ideas, too. If is a manifold (i.e., a manifold whose charts are times continuously differentiable), then a curve in is such a curve which is only assumed to be (i.e. times continuously differentiable). If is an analytic manifold (i.e. infinitely differentiable and charts are expressible as power series), and is an analytic map, then is said to be an analytic curve.
A differentiable curve is said to be regular if its derivative never vanishes. (In words, a regular curve never slows to a stop or backtracks on itself.) Two differentiable curves
are said to be equivalent if there is a bijective map
such that the inverse map
is also , and
for all . The map is called a reparametrization of ; and this makes an equivalence relation on the set of all differentiable curves in . A arc is an equivalence class of curves under the relation of reparametrization.
Algebraic curves are the curves considered in algebraic geometry. A plane algebraic curve is the set of the points of coordinates x, y such that f(x, y) = 0, where f is a polynomial in two variables defined over some field F. One says that the curve is defined over F. Algebraic geometry normally considers not only points with coordinates in F but all the points with coordinates in an algebraically closed field K.
If C is a curve defined by a polynomial f with coefficients in F, the curve is said to be defined over F.
In the case of a curve defined over the real numbers, one normally considers points with complex coordinates. In this case, a point with real coordinates is a real point, and the set of all real points is the real part of the curve. It is therefore only the real part of an algebraic curve that can be a topological curve (this is not always the case, as the real part of an algebraic curve may be disconnected and contain isolated points). The whole curve, that is the set of its complex point is, from the topological point of view a surface. In particular, the nonsingular complex projective algebraic curves are called Riemann surfaces.
The points of a curve C with coordinates in a field G are said to be rational over G and can be denoted C(G). When G is the field of the rational numbers, one simply talks of rational points. For example, Fermat's Last Theorem may be restated as: For n > 2, every rational point of the Fermat curve of degree n has a zero coordinate.
Algebraic curves can also be space curves, or curves in a space of higher dimension, say n. They are defined as algebraic varieties of dimension one. They may be obtained as the common solutions of at least n–1 polynomial equations in n variables. If n–1 polynomials are sufficient to define a curve in a space of dimension n, the curve is said to be a complete intersection. By eliminating variables (by any tool of elimination theory), an algebraic curve may be projected onto a plane algebraic curve, which however may introduce new singularities such as cusps or double points.
A plane curve may also be completed to a curve in the projective plane: if a curve is defined by a polynomial f of total degree d, then wdf(u/w, v/w) simplifies to a homogeneous polynomial g(u, v, w) of degree d. The values of u, v, w such that g(u, v, w) = 0 are the homogeneous coordinates of the points of the completion of the curve in the projective plane and the points of the initial curve are those such that w is not zero. An example is the Fermat curve un + vn = wn, which has an affine form xn + yn = 1. A similar process of homogenization may be defined for curves in higher dimensional spaces.
Except for lines, the simplest examples of algebraic curves are the conics, which are nonsingular curves of degree two and genus zero. Elliptic curves, which are nonsingular curves of genus one, are studied in number theory, and have important applications to cryptography.