A wave and its harmonics, with wavelengths where the amplitude is inversely proportional to the frequency.
The name of the harmonic series derives from the concept ofovertones or harmonicsin music: thewavelengths of the overtones of a vibrating string are,,, etc., of the string'sfundamental wavelength.[1][2] Every term of the harmonic series after the first is theharmonic mean of the neighboring terms, so the terms form aharmonic progression; the phrasesharmonic mean andharmonic progression likewise derive from music.[2]Beyond music, harmonic sequences have also had a certain popularity with architects. This was so particularly in theBaroque period, when architects used them to establish theproportions offloor plans, ofelevations, and to establish harmonic relationships between both interior and exterior architectural details of churches and palaces.[3]
The divergence of the harmonic series was first proven in 1350 byNicole Oresme.[2][4] Oresme's work, and the contemporaneous work ofRichard Swineshead on a different series, marked the first appearance of infinite series other than thegeometric series in mathematics.[5] However, this achievement fell into obscurity.[6] Additional proofs were published in the 17th century byPietro Mengoli[2][7] and byJacob Bernoulli.[8][9][10] Bernoulli credited his brotherJohann Bernoulli for finding the proof,[10] and it was later included in Johann Bernoulli's collected works.[11]
The harmonic series is the infinite seriesin which the terms are all of the positiveunit fractions. It is adivergent series: as more terms of the series are included inpartial sums of the series, the values of these partial sums grow arbitrarily large, beyond any finite limit. Because it is a divergent series, it should be interpreted as a formal sum, an abstract mathematical expression combining the unit fractions, rather than as something that can be evaluated to a numeric value. There are many different proofs of the divergence of the harmonic series, surveyed in a 2006 paper by S. J. Kifowit and T. A. Stamps.[13]Two of the best-known[1][13] are listed below.
There are infinite blue rectangles each with area 1/2, yet their total area is exceeded by that of the grey bars denoting the harmonic series
One way to prove divergence is to compare the harmonic series with another divergent series, where each denominator is replaced with the next-largestpower of two:Grouping equal terms shows that the second series diverges (because every grouping of convergent series is only convergent):Because each term of the harmonic series is greater than or equal to the corresponding term of the second series (and the terms are all positive), and since the second series diverges, it follows (by thecomparison test) that the harmonic series diverges as well. The same argument proves more strongly that, for everypositiveinteger,This is the original proof given byNicole Oresme in around 1350.[13] TheCauchy condensation test is a generalization of this argument.[14]
Rectangles with area given by the harmonic series, and the hyperbola through the upper left corners of these rectangles
It is possible to prove that the harmonic series diverges by comparing its sum with animproper integral. Specifically, consider the arrangement of rectangles shown in the figure to the right. Each rectangle is 1 unit wide and units high, so if the harmonic series converged then the total area of the rectangles would be the sum of the harmonic series. The curve stays entirely below the upper boundary of the rectangles, so the area under the curve (in the range of from one to infinity that is covered by rectangles) would be less than the area of the union of the rectangles. However, the area under the curve is given by a divergentimproper integral,Because this integral does not converge, the sum cannot converge either.[13]
In the figure to the right, shifting each rectangle to the left by 1 unit, would produce a sequence of rectangles whose boundary lies below the curve rather than above it.This shows that the partial sums of the harmonic series differ from the integral by an amount that is bounded above and below by the unit area of the first rectangle:Generalizing this argument, any infinite sum of values of a monotone decreasing positive functionof (like the harmonic series) has partial sums that are within a bounded distance of the values of the corresponding integrals. Therefore, the sum converges if and only if the integral over the same range of the same function converges. When this equivalence is used to check the convergence of a sum by replacing it with an easier integral, it is known as theintegral test for convergence.[15]
No harmonic numbers are integers except for.[17][18] One way to prove that is not an integer is to consider the highestpower of two in the range from1 to. If is theleast common multiple of the numbers from1 to, then can be rewritten as a sum of fractions with equal denominatorsin which only one of the numerators,, is odd and the rest are even, and(when) is itself even. Therefore, the result is a fraction with an odd numerator and an even denominator, which cannot be an integer.[17] More generally, any sequence of consecutive integers has a unique member divisible by a greater power of two than all the other sequence members, from which it follows by the same argument that no two harmonic numbers differ by an integer.[18]
Another proof that the harmonic numbers are not integers observes that the denominator of must be divisible by allprime numbers greater than and less than or equal to, and usesBertrand's postulate to prove that this set of primes is non-empty. The same argument implies more strongly that, except for,, and, no harmonic number can have aterminating decimal representation.[17] It has been conjectured that every prime number divides the numerators of only a finite subset of the harmonic numbers, but this remains unproven.[19]
Thedigamma function is defined as thelogarithmic derivative of thegamma functionJust as the gamma function provides a continuousinterpolation of thefactorials, the digamma function provides a continuous interpolation of the harmonic numbers, in the sense that.[20]This equation can be used to extend the definition to harmonic numbers with rational indices.[21]
Solution to the jeep problem for, showing the amount of fuel in each depot and in the jeep at each step
Thejeep problem or desert-crossing problem is included in a 9th-century problem collection byAlcuin,Propositiones ad Acuendos Juvenes (formulated in terms of camels rather than jeeps), but with an incorrect solution.[22] The problem asks how far into the desert a jeep can travel and return, starting from a base with loads of fuel, by carrying some of the fuel into the desert and leaving it in depots. The optimal solution involves placing depots spaced at distances from the starting point and each other, where is the range of distance that the jeep can travel with a single load of fuel. On each trip out and back from the base, the jeep places one more depot, refueling at the other depots along the way, and placing as much fuel as it can in the newly placed depot while still leaving enough for itself to return to the previous depots and the base. Therefore, the total distance reached on theth trip iswhere is theth harmonic number. The divergence of the harmonic series implies that crossings of any length are possible with enough fuel.[23]
For instance, for Alcuin's version of the problem,: a camel can carry 30 measures of grain and can travel one leuca while eating a single measure, where a leuca is a unit of distance roughly equal to 2.3 kilometres (1.4 mi). The problem has: there are 90 measures of grain, enough to supply three trips. For the standard formulation of the desert-crossing problem, it would be possible for the camel to travel leucas and return, by placing a grain storage depot 5 leucas from the base on the first trip and 12.5 leucas from the base on the second trip. However, Alcuin instead asks a slightly different question, how much grain can be transported a distance of 30 leucas without a final return trip, and either strands some camels in the desert or fails to account for the amount of grain consumed by a camel on its return trips.[22]
Theblock-stacking problem: blocks aligned according to the harmonic series can overhang the edge of a table by the harmonic numbers
In theblock-stacking problem, one must place a pile of identical rectangular blocks, one per layer, so that they hang as far as possible over the edge of a table without falling. The top block can be placed with of its length extending beyond the next lower block. If it is placed in this way, the next block down needs to be placed with at most of its length extending beyond the next lower block, so that thecenter of mass of the top two blocks is supported and they do not topple. The third block needs to be placed with at most of its length extending beyond the next lower block, so that the center of mass of the top three blocks is supported and they do not topple, and so on. In this way, it is possible to place the blocks in such a way that they extend lengths beyond the table, where is theth harmonic number.[24][25] The divergence of the harmonic series implies that there is no limit on how far beyond the table the block stack can extend.[25] For stacks with one block per layer, no better solution is possible, but significantly more overhang can be achieved using stacks with more than one block per layer.[26]
In 1737,Leonhard Euler observed that, as aformal sum, the harmonic series is equal to anEuler product in which each term comes from aprime number: where denotes the set of prime numbers. The left equality comes from applying thedistributive law to the product and recognizing the resulting terms as theprime factorizations of the terms in the harmonic series, and the right equality uses the standard formula for ageometric series. The product is divergent, just like the sum, but if it converged one could take logarithms and obtainHere, each logarithm is replaced by itsTaylor series, and the constant on the right is the evaluation of the convergent series of terms with exponent greater than one. It follows from these manipulations that the sum of reciprocals of primes, on the right hand of this equality, must diverge, for if it converged these steps could be reversed to show that the harmonic series also converges, which it does not. An immediate corollary is thatthere are infinitely many prime numbers, because a finite sum cannot diverge.[27] Although Euler's work is not considered adequately rigorous by the standards of modern mathematics, it can be made rigorous by taking more care with limits and error bounds.[28] Euler's conclusion that the partial sums of reciprocals of primes grow as adouble logarithm of the number of terms has been confirmed by later mathematicians as one ofMertens' theorems,[29] and can be seen as a precursor to theprime number theorem.[28]
Another problem innumber theory closely related to the harmonic series concerns the average number ofdivisors of the numbers in a range from 1 to, formalized as theaverage order of thedivisor function,The operation of rounding each term in the harmonic series to the next smaller integer multiple of causes this average to differ from the harmonic numbers by a small constant, andPeter Gustav Lejeune Dirichlet showed more precisely that the average number of divisors is (expressed inbig O notation). Bounding the final error term more precisely remains an open problem, known asDirichlet's divisor problem.[30]
Graph of number of items versus the expected number of trials needed to collect all items
Several common games or recreations involve repeating a random selection from a set of items until all possible choices have been selected; these include the collection oftrading cards[31][32] and the completion ofparkrun bingo, in which the goal is to obtain all 60 possible numbers of seconds in the times from a sequence of running events.[33] More serious applications of this problem include sampling all variations of a manufactured product for itsquality control,[34] and theconnectivity ofrandom graphs.[35] In situations of this form, once there are items remaining to be collected out of a total of equally-likely items, the probability of collecting a new item in a single random choice is and the expected number of random choices needed until a new item is collectedis. Summing over all values of fromdown to 1 shows that the total expected number of random choices needed to collect all itemsis, where is theth harmonic number.[36]
Animation of the average-case version of quicksort, with recursive subproblems indicated by shaded arrows and with pivots (red items and blue lines) chosen as the last item in each subproblem
Thequicksort algorithm for sorting a set of items can be analyzed using the harmonic numbers. The algorithm operates by choosing one item as a "pivot", comparing it to all the others, and recursively sorting the two subsets of items whose comparison places them before the pivot and after the pivot. In either itsaverage-case complexity (with the assumption that all input permutations are equally likely) or in itsexpected time analysis of worst-case inputs with a random choice of pivot, all of the items are equally likely to be chosen as the pivot. For such cases, one can compute the probability that two items are ever compared with each other, throughout the recursion, as a function of the number of other items that separate them in the final sorted order. If items and are separated by other items, then the algorithm will make a comparison between and only when, as the recursion progresses, it picks or as a pivot before picking any of the other items between them. Because each of these items is equally likely to be chosen first, this happens with probability. The total expected number of comparisons, which controls the total running time of the algorithm, can then be calculated by summing these probabilities over all pairs, giving[37]The divergence of the harmonic series corresponds in this application to the fact that, in thecomparison model of sorting used for quicksort, it is not possible to sort inlinear time.[38]
This function isclose to for values between and, with the to ten decimal places. It decreases asymptotically like anormal distribution for values greaterthan or lessthan. Intermediate between these ranges, at thevalues, the probability density is for a nonzero but very small value.[42][43]
The depleted harmonic series where all of the terms in which the digit 9 appears anywhere in the denominator are removed can be shown to converge to the value22.92067661926415034816....[44] In fact, when all the terms containing any particular string of digits (in anybase) are removed, the series converges.[45]
^abRice, Adrian (2011). "The harmonic series: A primer". In Jardine, Dick;Shell-Gellasch, Amy (eds.).Mathematical Time Capsules: Historical Modules for the Mathematics Classroom. MAA Notes. Vol. 77. Washington, DC: Mathematical Association of America. pp. 269–276.ISBN978-0-88385-984-1.
^Mengoli, Pietro (1650)."Praefatio [Preface]".Novae quadraturae arithmeticae, seu De additione fractionum [New arithmetic quadrature (i.e., integration), or On the addition of fractions] (in Latin). Bologna: Giacomo Monti.Mengoli's proof is by contradiction: Let denote the sum of the series. Group the terms of the series in triplets:. Since for,, then, which is impossible for any finite. Therefore, the series diverges.
^Bernoulli, Jacob (1689).Propositiones arithmeticae de seriebus infinitis earumque summa finita [Arithmetical propositions about infinite series and their finite sums]. Basel: J. Conrad.
^Bernoulli, Johann (1742)."Corollary III ofDe seriebus varia".Opera Omnia. Lausanne & Basel: Marc-Michel Bousquet & Co. vol. 4, p. 8.Johann Bernoulli's proof is also by contradiction. It uses a telescopic sum to represent each term as Changing the order of summation in the corresponding double series gives, in modern notation.
^abKnuth, Donald E. (1968). "1.2.7 Harmonic numbers".The Art of Computer Programming, Volume I: Fundamental Algorithms (1st ed.). Addison-Wesley. pp. 73–78. Knuth writes, of the partial sums of the harmonic series "This sum does not occur very frequently in classical mathematics, and there is no standard notation for it; but in the analysis of algorithms it pops up nearly every time we turn around, and we will consistently use the symbol ... The letter stands for "harmonic", and we call a "harmonic number" because [the infinite series] is customarily called the harmonic series."
^Roy, Ranjan (December 2007). "Review ofA Radical Approach to Real Analysis by David M. Bressoud".SIAM Review.49 (4):717–719.JSTOR20454048.One might point out that Cauchy's condensation test is merely the extension of Oresme's argument for the divergence of the harmonic series
^Gerke, Oke (April 2013). "How much is it going to cost me to complete a collection of football trading cards?".Teaching Statistics.35 (2):89–93.doi:10.1111/test.12005.S2CID119887116.
^Isaac, Richard (1995). "8.4 The coupon collector's problem solved".The Pleasures of Probability. Undergraduate Texts in Mathematics. New York: Springer-Verlag. pp. 80–82.doi:10.1007/978-1-4612-0819-8.ISBN0-387-94415-X.MR1329545.