The **versine** or **versed sine** is a trigonometric function already appearing in some of the earliest trigonometric tables. It is written as **versin(***θ*), **sinver(***θ*), **vers(***θ*), **ver(***θ*) or **siv(***θ*). In Latin, it is known as the *sinus versus* (flipped sine), *versinus*, *versus* or the *sagitta* (arrow).

Expressed in terms of the meanwhile more commonly used "vertical" sines (*sinus rectus*) and cosines (*cosinus rectus*) functions, the versine is equal to 1 − cos(*θ*), or 2 sin^{2}(*θ*/2).

There are several related functions corresponding to the versine:

The **versed cosine**, or **vercosine**, written **vercosin(***θ*), **vercos(***θ*) or **vcs(***θ*)
The **coversed sine**, **coversine**, **cosinus versus** or **coversinus**, written **coversin(***θ*), **covers(***θ*), **cosiv(***θ*) or **cvs(***θ*)
The **coversed cosine** or **covercosine**, written **covercosin(***θ*) or **covercos(***θ*) or **cvc(***θ*)
In full analogy to the above-mentioned four functions another set of four "half-value" functions exists as well:

The **haversed sine**, **haversine** or **semiversus**, written **haversin(***θ*), **semiversin(***θ*), **semiversinus(***θ*), **havers(***θ*), **hav(***θ*), **hvs(***θ*), **sem(***θ*) or **hv(***θ*), most famous from the haversine formula used historically in navigation
The **haversed cosine** or **havercosine**, written **havercosin(***θ*), **havercos(***θ*), **hac(***θ*) or **hvc(***θ*)
The **hacoversed sine**, also called **hacoversine** or **cohaversine** and written **hacoversin(***θ*), **semicoversin(***θ*), **hacovers(***θ*), **hacov(***θ*) or **hcv(***θ*)
The **hacoversed cosine**, also called **hacovercosine** or **cohavercosine** and written **hacovercosin(***θ*), **hacovercos(***θ*) or **hcc(***θ*)
The ordinary *sine* function (see note on etymology) was sometimes historically called the *sinus rectus* ("vertical sine"), to contrast it with the versed sine (*sinus versus*). The meaning of these terms is apparent if one looks at the functions in the original context for their definition, a unit circle:

For a vertical chord *AB* of the unit circle, the sine of the angle *θ* (representing half of the subtended angle *Δ*) is the distance *AC* (half of the chord). On the other hand, the versed sine of *θ* is the distance *CD* from the center of the chord to the center of the arc. Thus, the sum of cos(*θ*) (equal to the length of line *OC*) and versin(*θ*) (equal to the length of line *CD*) is the radius *OD* (with length 1). Illustrated this way, the sine is vertical (*rectus*, literally "straight") while the versine is horizontal (*versus*, literally "turned against, out-of-place"); both are distances from *C* to the circle.

This figure also illustrates the reason why the versine was sometimes called the *sagitta*, Latin for arrow, from the Arabic usage *sahem* of the same meaning. This itself comes from the Indian word 'sara' (arrow) that was commonly used to refer to "utkrama-jya". If the arc *ADB* of the double-angle *Δ* = 2*θ* is viewed as a "bow" and the chord *AB* as its "string", then the versine *CD* is clearly the "arrow shaft".

In further keeping with the interpretation of the sine as "vertical" and the versed sine as "horizontal", *sagitta* is also an obsolete synonym for the abscissa (the horizontal axis of a graph).

In 1821, Cauchy used the terms *sinus versus* (*siv*) for the versine and *cosinus versus* (*cosiv*) for the coversine.

Historically, the versed sine was considered one of the most important trigonometric functions.

As *θ* goes to zero, versin(*θ*) is the difference between two nearly equal quantities, so a user of a trigonometric table for the cosine alone would need a very high accuracy to obtain the versine in order to avoid catastrophic cancellation, making separate tables for the latter convenient. Even with a calculator or computer, round-off errors make it advisable to use the sin^{2} formula for small *θ*.

Another historical advantage of the versine is that it is always non-negative, so its logarithm is defined everywhere except for the single angle (*θ* = 0, 2π,...) where it is zero—thus, one could use logarithmic tables for multiplications in formulas involving versines.

In fact, the earliest surviving table of sine (half-chord) values (as opposed to the chords tabulated by Ptolemy and other Greek authors), calculated from the Surya Siddhantha of India dated back to the 3rd century BC, was a table of values for the sine and versed sine (in 3.75° increments from 0 to 90°).

The versine appears as an intermediate step in the application of the half-angle formula sin^{2}(*θ*/2) = 1/2versin(*θ*), derived by Ptolemy, that was used to construct such tables.

The haversine, in particular, was important in navigation because it appears in the haversine formula, which is used to accurately compute distances within reason on an astronomic spheroid (see issues with the earth's radius vs. sphere) given angular positions (e.g., longitude and latitude). One could also use sin^{2}(*θ*/2) directly, but having a table of the haversine removed the need to compute squares and square roots.

An early utilization by José de Mendoza y Ríos of what later would be called haversines is documented in 1801.

The first known English equivalent to a table of haversines was published by James Andrew in 1805.

In 1835, the term *haversine* (notated as *log. haversine*, *log. havers.* and *hav.*) was coined by James Inman in the third edition of his work *Navigation and Nautical Astronomy: For the Use of British Seamen* to simplify the calculation of distances between two points on the surface of the earth using spherical trigonometry for applications in navigation. Inman also used the terms *nat. versine* and *nat. vers.* for versines.

Other high-regarded tables of haversines were those of Richard Farley in 1856 and John Caulfield Hannyngton in 1876.

The haversine continues to be used in navigation and has even found new applications in recent decades, like in Bruce D. Stark's method for clearing lunar distances utilizing Gaussian logarithms since 1995 or in a more compact method for sight reduction since 2014.

Whilst the usage of the versine, coversine and haversine as well as their inverse functions can be traced back centuries, the names for the other five cofunctions appear to be of much younger origin.

One period (0 < *θ* < π/2) of a versine or, more commonly, a haversine (or havercosine) waveform is also commonly used in signal processing and control theory as the shape of a pulse or a window function (including Hann, Hann–Poisson and Tukey windows), because it smoothly (continuous in value and slope) "turns on" from zero to one (for haversine) and back to zero. In these applications, it is named Hann function or raised-cosine filter. Likewise, the havercosine is used in raised-cosine distributions in probability theory and statistics.

In the form of sin^{2}(*θ*) the haversine of the double-angle *Δ* describes the relation between spreads and angles in rational trigonometry, a proposed reformulation of metrical planar and solid geometries by Norman John Wildberger since 2005.

As sagitta and cosagitta, double-angle *Δ* variants of the haversine and havercosine have also found new uses in describing the correlation and anti-correlation of correlated photons in quantum mechanics.

Inverse functions like **arcversine** (arcversin, arcvers, avers, aver), **arcvercosine** (arcvercosin, arcvercos, avercos, avcs), **arccoversine** (arccoversin, arccovers, acovers, acvs), **arccovercosine** (arccovercosin, arccovercos, acovercos, acvc), **archaversine** (archaversin, archav, haversin^{−1}, invhav, ahav, ahvs, ahv, hav^{−1}), **archavercosine** (archavercosin, archavercos, ahvc), **archacoversine** (archacoversin, ahcv) or **archacovercosine** (archacovercosin, archacovercos, ahcc) exist as well:

arcversin
(
y
)
=
arccos
(
1
−
y
)
=
arctan
(
2
y
−
y
2
1
−
y
)
(for 0 ≤

*y* ≤ 2)

arcvercos
(
y
)
=
arccos
(
1
+
y
)
arccoversin
(
y
)
=
arcsin
(
1
−
y
)
=
arctan
(
1
−
y
2
y
−
y
2
)
(for 0 ≤

*y* ≤ 2)

arccovercos
(
y
)
=
arcsin
(
1
+
y
)
archaversin
(
y
)
=
2
arcsin
(
y
)
=
arctan
(
2
y
−
y
2
1
−
2
y
)
(for 0 ≤

*y* ≤ 1)

archavercos
(
y
)
=
2
arccos
(
y
)
These functions can be extended into the complex plane.

Maclaurin series:

versin
(
z
)
=
∑
k
=
1
∞
(
−
1
)
k
−
1
z
2
k
(
2
k
)
!
haversin
(
z
)
=
∑
k
=
1
∞
(
−
1
)
k
−
1
z
2
k
2
(
2
k
)
!
When the versine *v* is small in comparison to the radius *r*, it may be approximated from the half-chord length *L* (the distance *AC* shown above) by the formula

v
≈
L
2
2
r
.

Alternatively, if the versine is small and the versine, radius, and half-chord length are known, they may be used to estimate the arc length *s* (*AD* in the figure above) by the formula

s
≈
L
+
v
2
r
This formula was known to the Chinese mathematician Shen Kuo, and a more accurate formula also involving the sagitta was developed two centuries later by Guo Shoujing.

A more accurate approximation used in engineering is

v
≈
s
3
2
L
1
2
8
r
The term *versine* is also sometimes used to describe deviations from straightness in an arbitrary planar curve, of which the above circle is a special case. Given a chord between two points in a curve, the perpendicular distance *v* from the chord to the curve (usually at the chord midpoint) is called a *versine* measurement. For a straight line, the versine of any chord is zero, so this measurement characterizes the straightness of the curve. In the limit as the chord length *L* goes to zero, the ratio 8*v*/*L*^{2} goes to the instantaneous curvature. This usage is especially common in rail transport, where it describes measurements of the straightness of the rail tracks and it is the basis of the Hallade method for rail surveying.

The term *sagitta* (often abbreviated *sag*) is used similarly in optics, for describing the surfaces of lenses and mirrors.