Line

There are several formulations for expressing the concept of a line.

In the most general case, namely the multidimensional case, a line, the locus of points $\mathbf{x} \in \mathbb{R}^n$ of dimension 1, takes the form

\begin{displaymath}
\mathbf{x} = \mathbf{p} + t \mathbf{v}
\end{displaymath} (1.58)

where $\mathbf{p} \in \mathbb{R}^n$ is an arbitrary origin point, $\mathbf{v} \in \mathbb{R}^n$ is the direction vector, and $t \in \mathbb{R}$ is a scalar. In this case, it is called a parametric ray.

In many applications, the line is a concept associated with two-dimensional space. In this space, setting aside the explicit form of the line equation $y=mx + q$ because it has singularities, we focus on the line written in implicit form. The equation of a line in implicit form is:

\begin{displaymath}
a x + b y + c = 0
\end{displaymath} (1.59)

This representation is very useful because it handles both horizontal and vertical lines without any singularities. The parameter $c$ is zero when the line passes through the origin and, obviously, the line passes through a point $(x',y')$ when $c=-ax'-by'$.

In the two-dimensional case, the equation of the parametric ray (1.58) reduces to the implicit line equation with parameters

\begin{displaymath}
(a,b) \cdot \mathbf{v} = 0 \quad c = - (a,b) \cdot \mathbf{p}
\end{displaymath} (1.60)

The first of equations (1.60) shows that the vector formed by the parameters $(a,b)$ and the direction vector are orthogonal to each other. The vector generating the line is in fact proportional, for example, to $\mathbf{v} \propto (-b, a)$ or $\mathbf{v} \propto (\frac{1}{a},-\frac{1}{b})$. The vector $\mathbf{v}'$ orthogonal to the given line is simply $\mathbf{v}' \propto (a,b)$, and the line orthogonal to the given line has an implicit equation of the form

\begin{displaymath}
bx - ay + c' = 0
\end{displaymath} (1.61)

where $c'$ is obtained by selecting the point on the original line through which the perpendicular must pass.

The parameters of a line written in implicit form are homogeneous (equation (1.59) is in fact called the homogeneous equation of the line), that is, they represent a vector subspace of $\mathbb{R}^3$: any multiple of these parameters represents the same line. These parameters are therefore defined up to a multiplicative factor. This observation suggests another way of representing a line and a generic hyperplane.

Lines written in homogeneous implicit form must satisfy the equation (dot product):

\begin{displaymath}
\mathbf{l}^{\top} \mathbf{x} = 0
\end{displaymath} (1.62)

where $\mathbf{x} \in \mathbb{R}^{3}$ is a point in homogeneous coordinates and $\mathbf{l}=(a,b,c)^{\top}$ are the line parameters. For homogeneous coordinates, see the preceding section 1.5; for the implications of this formulation concerning point-line duality, see paragraph 1.6.7.

Since the implicit line is known up to a multiplicative factor, there are infinitely many ways of expressing the same line. One possible normalization of the line is obtained by dividing the parameters by the length $\sqrt{a^2 +b^2}$. This yields a particular representation of the line, since the parameters are those of a line written in polar coordinates using the same form as equation (1.82) and, consequently, under this normalization, the parameter $c$ represents the minimum distance between the line and the origin of the coordinate system.

Finally, since a line is a hyperplane in two dimensions, its equation can be written as in equation (1.85).

Paolo medici
2026-10-01