Mediant (mathematics)

Fraction made by summing the numerator and denominator of two fractions

Not to be confused with Median.

In mathematics, the mediant of two fractions, generally made up of four positive integers

a c {\displaystyle {\frac {a}{c}}\quad } and  b d {\displaystyle \quad {\frac {b}{d}}\quad } is defined as  a + b c + d . {\displaystyle \quad {\frac {a+b}{c+d}}.}

That is to say, the numerator and denominator of the mediant are the sums of the numerators and denominators of the given fractions, respectively. It is sometimes called the freshman sum, as it is a common mistake in the early stages of learning about addition of fractions.

Technically, this is a binary operation on valid fractions (nonzero denominator), considered as ordered pairs of appropriate integers, a priori disregarding the perspective on rational numbers as equivalence classes of fractions. For example, the mediant of the fractions 1/1 and 1/2 is 2/3. However, if the fraction 1/1 is replaced by the fraction 2/2, which is an equivalent fraction denoting the same rational number 1, the mediant of the fractions 2/2 and 1/2 is 3/4. For a stronger connection to rational numbers the fractions may be required to be reduced to lowest terms, thereby selecting unique representatives from the respective equivalence classes.

In fact, mediants commonly occur in the study of continued fractions and in particular, Farey fractions. The nth Farey sequence Fn is defined as the (ordered with respect to magnitude) sequence of reduced fractions a/b (with coprime a, b) such that b ≤ n. If two fractions a/c < b/d are adjacent (neighbouring) fractions in a segment of Fn then the determinant relation  b c − a d = 1 {\displaystyle bc-ad=1} mentioned above is generally valid and therefore the mediant is the simplest fraction in the interval (a/c, b/d), in the sense of being the fraction with the smallest denominator. Thus the mediant will then (first) appear in the (c + d)th Farey sequence and is the "next" fraction which is inserted in any Farey sequence between a/c and b/d. This gives the rule how the Farey sequences Fn are successively built up with increasing n.

The Stern–Brocot tree provides an enumeration of all positive rational numbers via mediants in lowest terms, obtained purely by iterative computation of the mediant according to a simple algorithm.

## Properties

[edit]

* The mediant inequality: An important property (also explaining its name) of the mediant is that it lies strictly between the two fractions of which it is the mediant: If  a / c < b / d {\displaystyle a/c<b/d} and  c ⋅ d > 0 {\displaystyle c\cdot d>0} , then  a c < a + b c + d < b d . {\displaystyle {\frac {a}{c}}<{\frac {a+b}{c+d}}<{\frac {b}{d}}.} This property follows from the two relations  a + b c + d − a c = b c − a d c ( c + d ) = d c + d ( b d − a c ) {\displaystyle {\frac {a+b}{c+d}}-{\frac {a}{c}}={{bc-ad} \over {c(c+d)}}={d \over {c+d}}\left({\frac {b}{d}}-{\frac {a}{c}}\right)} and  b d − a + b c + d = b c − a d d ( c + d ) = c c + d ( b d − a c ) . {\displaystyle {\frac {b}{d}}-{\frac {a+b}{c+d}}={{bc-ad} \over {d(c+d)}}={c \over {c+d}}\left({\frac {b}{d}}-{\frac {a}{c}}\right).}
* Componendo and Dividendo Theorems: If  a / c = b / d {\displaystyle a/c=b/d} and  c ≠ 0 , d ≠ 0 {\displaystyle c\neq 0,\ d\neq 0} , then[1] a c = b d = a + b c + d {\displaystyle {\frac {a}{c}}={\frac {b}{d}}={\frac {a+b}{c+d}}}

* Componendo:[1]

a + c c = b + d d {\displaystyle {\frac {a+c}{c}}={\frac {b+d}{d}}}

* Dividendo:[1]

a − c c = b − d d {\displaystyle {\frac {a-c}{c}}={\frac {b-d}{d}}}

* Assume that the pair of fractions a/c and b/d satisfies the determinant relation  b c − a d = 1 {\displaystyle bc-ad=1} . Then the mediant has the property that it is the simplest fraction in the interval (a/c, b/d), in the sense of being the fraction with the smallest denominator. More precisely, if the fraction  a ′ / c ′ {\displaystyle a'/c'} with positive denominator c' lies (strictly) between a/c and b/d, then its numerator and denominator can be written as  a ′ = λ 1 a + λ 2 b {\displaystyle a'=\lambda _{1}a+\lambda _{2}b} and  c ′ = λ 1 c + λ 2 d {\displaystyle c'=\lambda _{1}c+\lambda _{2}d} with two positive real (in fact rational) numbers  λ 1 , λ 2 {\displaystyle \lambda _{1},\,\lambda _{2}} . To see why the  λ i {\displaystyle \lambda _{i}} must be positive note that  λ 1 a + λ 2 b λ 1 c + λ 2 d − a c = λ 2 b c − a d c ( λ 1 c + λ 2 d ) {\displaystyle {\frac {\lambda _{1}a+\lambda _{2}b}{\lambda _{1}c+\lambda _{2}d}}-{\frac {a}{c}}=\lambda _{2}{{bc-ad} \over {c(\lambda _{1}c+\lambda _{2}d)}}} and  b d − λ 1 a + λ 2 b λ 1 c + λ 2 d = λ 1 b c − a d d ( λ 1 c + λ 2 d ) {\displaystyle {\frac {b}{d}}-{\frac {\lambda _{1}a+\lambda _{2}b}{\lambda _{1}c+\lambda _{2}d}}=\lambda _{1}{{bc-ad} \over {d(\lambda _{1}c+\lambda _{2}d)}}} must be positive. The determinant relation  b c − a d = 1 {\displaystyle bc-ad=1\,} then implies that both  λ 1 , λ 2 {\displaystyle \lambda _{1},\,\lambda _{2}} must be integers, solving the system of linear equations  a ′ = λ 1 a + λ 2 b {\displaystyle a'=\lambda _{1}a+\lambda _{2}b} c ′ = λ 1 c + λ 2 d {\displaystyle c'=\lambda _{1}c+\lambda _{2}d} for  λ 1 , λ 2 {\displaystyle \lambda _{1},\lambda _{2}} . Therefore,  c ′ ≥ c + d . {\displaystyle c'\geq c+d.}
* The converse is also true: assume that the pair of reduced fractions a/c < b/d has the property that the reduced fraction with smallest denominator lying in the interval (a/c, b/d) is equal to the mediant of the two fractions. Then the determinant relation bc − ad = 1 holds. This fact may be deduced e.g. with the help of Pick's theorem which expresses the area of a plane triangle whose vertices have integer coordinates in terms of the number vinterior of lattice points (strictly) inside the triangle and the number vboundary of lattice points on the boundary of the triangle. Consider the triangle  Δ ( v 1 , v 2 , v 3 ) {\displaystyle \Delta (v_{1},v_{2},v_{3})} with the three vertices v1 = (0, 0), v2 = (a, c), v3 = (b, d). Its area is equal to  area ( Δ ) = b c − a d 2 . {\displaystyle {\text{area}}(\Delta )={{bc-ad} \over 2}\,.} A point  p = ( p 1 , p 2 ) {\displaystyle p=(p_{1},p_{2})} inside the triangle can be parametrized as  p 1 = λ 1 a + λ 2 b , p 2 = λ 1 c + λ 2 d , {\displaystyle p_{1}=\lambda _{1}a+\lambda _{2}b,\;p_{2}=\lambda _{1}c+\lambda _{2}d,} where  λ 1 ≥ 0 , λ 2 ≥ 0 , λ 1 + λ 2 ≤ 1. {\displaystyle \lambda _{1}\geq 0,\,\lambda _{2}\geq 0,\,\lambda _{1}+\lambda _{2}\leq 1.} The Pick formula  area ( Δ ) = v i n t e r i o r + v b o u n d a r y 2 − 1 {\displaystyle {\text{area}}(\Delta )=v_{\mathrm {interior} }+{v_{\mathrm {boundary} } \over 2}-1} now implies that there must be a lattice point q = (q1, q2) lying inside the triangle different from the three vertices if bc − ad > 1 (then the area of the triangle is  ≥ 1 {\displaystyle \geq 1} ). The corresponding fraction q1/q2 lies (strictly) between the given (by assumption reduced) fractions and has denominator  q 2 = λ 1 c + λ 2 d ≤ max ( c , d ) < c + d {\displaystyle q_{2}=\lambda _{1}c+\lambda _{2}d\leq \max(c,d)<c+d} as  λ 1 + λ 2 ≤ 1. {\displaystyle \lambda _{1}+\lambda _{2}\leq 1.}
* Relatedly, if p/q and r/s are reduced fractions on the unit interval such that |ps − rq| = 1 (so that they are adjacent elements of a row of the Farey sequence) then  ? ( p + r q + s ) = 1 2 ( ? ( p q ) + ? ( r s ) ) {\displaystyle ?\left({\frac {p+r}{q+s}}\right)={\frac {1}{2}}\left(?\left({\frac {p}{q}}\right)+{}?\left({\frac {r}{s}}\right)\right)} where ? is Minkowski's question mark function.

## Graphical determination of mediants

[edit]

Determining the mediant of two rational numbers graphically. The slopes of the blue and red segments are two rational numbers; the slope of the green segment is their mediant.

A positive rational number is one in the form  a / b {\displaystyle a/b} where  a , b {\displaystyle a,b} are positive natural numbers; i.e. a , b ∈ N + {\displaystyle a,b\in \mathbb {N} ^{+}} . The set of positive rational numbers  Q + {\displaystyle \mathbb {Q} ^{+}} is, therefore, the Cartesian product of  N + {\displaystyle \mathbb {N} ^{+}} by itself; i.e. Q + = ( N + ) 2 {\displaystyle \mathbb {Q} ^{+}=(\mathbb {N} ^{+})^{2}} . A point with coordinates  ( b , a ) {\displaystyle (b,a)} represents the rational number  a / b {\displaystyle a/b} , and the slope of a segment connecting the origin of coordinates to this point is  a / b {\displaystyle a/b} . Since  a , b {\displaystyle a,b} are not required to be coprime, point  ( b , a ) {\displaystyle (b,a)} represents one and only one rational number, but a rational number is represented by more than one point; e.g. ( 4 , 2 ) , ( 60 , 30 ) , ( 48 , 24 ) {\displaystyle (4,2),(60,30),(48,24)} are all representations of the rational number  1 / 2 {\displaystyle 1/2} . This is a slight modification of the formal definition of rational numbers, restricting them to positive values, and flipping the order of the terms in the ordered pair  ( b , a ) {\displaystyle (b,a)} so that the slope of the segment becomes equal to the rational number.

Two points  ( b , a ) ≠ ( d , c ) {\displaystyle (b,a)\neq (d,c)} where  a , b , c , d ∈ N + {\displaystyle a,b,c,d\in \mathbb {N} ^{+}} are two representations of (possibly equivalent) rational numbers  a / b {\displaystyle a/b} and  c / d {\displaystyle c/d} . The line segments connecting the origin of coordinates to  ( b , a ) {\displaystyle (b,a)} and  ( d , c ) {\displaystyle (d,c)} form two adjacent sides in a parallelogram. The vertex of the parallelogram opposite to the origin of coordinates is the point  ( b + d , a + c ) {\displaystyle (b+d,a+c)} , which is the mediant of  a / b {\displaystyle a/b} and  c / d {\displaystyle c/d} .

The area of the parallelogram is  b c − a d {\displaystyle bc-ad} , which is also the magnitude of the cross product of vectors  ⟨ b , a ⟩ {\displaystyle \langle b,a\rangle } and  ⟨ d , c ⟩ {\displaystyle \langle d,c\rangle } . It follows from the formal definition of rational number equivalence that the area is zero if  a / b {\displaystyle a/b} and  c / d {\displaystyle c/d} are equivalent. In this case, one segment coincides with the other, since their slopes are equal. The area of the parallelogram formed by two consecutive rational numbers in the Stern–Brocot tree is always 1.[2]

## Generalization

[edit]

The notion of mediant can be generalized to n fractions, and a generalized mediant inequality holds,[3] a fact that seems to have been first noticed by Cauchy. More precisely, the weighted mediant  m w {\displaystyle m_{w}} of n fractions  a 1 / b 1 , … , a n / b n {\displaystyle a_{1}/b_{1},\ldots ,a_{n}/b_{n}} is defined by  ∑ i w i a i ∑ i w i b i {\displaystyle {\frac {\sum _{i}w_{i}a_{i}}{\sum _{i}w_{i}b_{i}}}} (with  w i > 0 {\displaystyle w_{i}>0} ). It can be shown that  m w {\displaystyle m_{w}} lies somewhere between the smallest and the largest fraction among the  a i / b i {\displaystyle a_{i}/b_{i}} .

## See also

[edit]

* Mediant
* Padé approximant
* Stern–Brocot tree

## References

[edit]

1. ^ a b c Milburn, R. M. (1880). Mathematical Formulae: For the Use of Candidates Preparing for the Army, Civil Service, University, and Other Examinations. Longmans, Green & Company. pp. 18–19.18-19&rft.pub=Longmans,+Green+&+Company&rft.date=1880&rft.aulast=Milburn&rft.aufirst=R.+M.&rft_id=https://books.google.com/books?id=eAo4AAAAMAAJ&pg;=PA18&rfr_id=info:sid/en.wikipedia.org:Mediant+(mathematics)" class="Z3988">
2. ^ Austin, David. Trees, Teeth, and Time: The mathematics of clock making, Feature Column from the AMS
3. ^ Bensimhoun, Michael (2013). "A note on the mediant inequality" (PDF). Retrieved 2023-12-25.

## External links

[edit]

[1]

* Mediant Fractions at cut-the-knot
* MATHPAGES, Kevin Brown: Generalized Mediant