Sums of periodic functions

A real function is said to be periodic if there exists a real number P > 0 so that f(x+P) = f(x) for all x. The number P is said to be a period of the function. The most familiar examples of periodic functions are the trigonometric functions sine, cosine, and tangent.

Note that if P is a period of a function, then 2P, 3P, 4P, \ldots are also periods. If a periodic function is continuous and nonconstant, then it has a least period, and all other periods are positive integer multiples of the least period.

There are discontinuous periodic functions that have no least period. The most famous example is the Dirichlet function, defined by D(x) = 1 if x is rational, D(x) = 0 if x is irrational. Every positive rational number is a period of the Dirichlet function, so there is no least period.

Sums of periodic functions are often periodic

The sum of two periodic functions is often periodic, but not always. Suppose that f is periodic with least period P, and g is periodic with least period Q. If P and Q have a common multiple R, then f+g is periodic with period R. However, R is not necessarily the least period of f+g. To give an extreme example, \sin(x) + -\sin(x) has no least period.

Some readers may have heard of biorhythm theory, which was popular in the 1970s. The theory claims that humans are influenced by three fundamental cycles: a physical cycle of 23 days, an emotional cycle of 28 days, and an intellectual cycle of 33 days. These cycles are usually modeled as sine waves that start on one’s day of birth. We might suppose that a person’s happiness on day x is the sum of these three cycles.

h(x) = \sin\frac{2\pi x}{23} + \sin\frac{2\pi x}{28} + \sin\frac{2\pi x}{33}

biorhythm

The figure shows a portion of the graph of this function. It appears to be quite irregular but in fact it repeats every 21,252 days, since 21,252 is the least common multiple of 23, 28, and 33. (View this graph on Desmos.)

Sums of periodic functions are not always periodic

If the periods of two periodic functions do not have a common multiple, then their sum is not periodic. Perhaps the simplest example is \sin(x) + \sin(\pi x), whose terms have least periods 2π and 2 respectively.

Polynomials are finite sums of periodic functions

Sums of periodic functions can be peculiar indeed. In fact, we can prove the following astonishing theorem: If P is a polynomial function of a real variable, and the degree of P is n, then P is the sum of n+1 periodic functions.

It is clear that a non-constant polynomial cannot be expressed as a finite sum of continuous periodic functions, since a continuous periodic function is bounded, and a finite sum of bounded functions is bounded. In fact, it can be shown that an unbounded continuous function cannot be expressed as a finite sum of Lebesgue measurable periodic functions. Consequently, we will need to use the Axiom of Choice.

R as a vector space over Q

The statement that every vector space has a basis is equivalent to the Axiom of Choice. Since \mathbb{R} is a vector space over \mathbb{Q}, there is a subset A of \mathbb{R}, called a Hamel basis, so that every real number can be written uniquely as a finite linear combination of elements of A with rational coefficients.

For each x \in \mathbb{R}, we write x = \sum_{a\in A} (x,a) a where (x,a) is rational and \{a \in A: (x,a) \ne 0\} is finite for every x.

Periodicity of (x,a)

It is readily seen that (x+y,a)=(x,a)+(y,a) for all x,y \in \mathbb{R} and all a \in A.  Moreover (a,b)=0 for distinct a,b \in A. It follows that (x+b,a)=(x,a) for all x \in \mathbb{R} and distinct a,b \in A. In other words, the function x \mapsto (x,a) is periodic with period b for any b \in A\setminus a.

The identity function is the sum of two periodic functions

Choose two distinct elements c,d \in A. Then x = (x,c)c + \sum_{a \in A\setminus c} (x,a) a.

Let f_1(x) = (x,c) c and f_2(x) = \sum_{a \in A\setminus c} (x,a)a.

Then f_1 has period d, f_2 has period c, and f_1 + f_2 is the identity function.

x^2 is the sum of three periodic functions

Note that x^2 = \sum_{a, b \in A} (x,a)(x,b) ab. Choose three distinct elements c,d,e \in A. The term (x,a)(x,b)ab has period c, unless a=c or b=c. Since no term involves all three of c,d,e, it follows that each term has a period of either c, d, or e.

Let C be the sum of all terms which have period c; let D be the sum of all terms which have period d but not c; and let E be the sum of all terms which do not have period c or d. Such terms must have period e.  More specifically,

C = \sum_{a, b \in A\setminus c} (x,a)(x,b)ab

D = (x,c)^2 c^2 + 2\sum_{a \in A\setminus\{c,d\}} (x,a)(x,c)ac

E = 2(x,c) (x,d) cd

Then x^2 = C + D + E is a representation of x^2 as the sum of three periodic functions.

A polynomial of degree n is the sum of n+1 periodic functions

Let P be a polynomial of degree n. Using the identity x = \sum_{a\in A} (x,a)a we can express P(x) as a linear combination of products (x,a)(x,b)(x,c)\ldots with a,b,c,\ldots \in A. Each term involves at most n distinct elements of A.

Let a_0, a_1, \ldots, a_n be n+1 distinct elements of A. No product (x,a)(x,b)(x,c)\cdots in the expansion can involve ALL of a_0, a_1, \ldots, a_n. Therefore, we can group the terms into n+1 sums, P_0, P_1, \ldots, P_n, so that no term in P_i involves a_i.

Thus, we have P(x) = P_0(x) + P_1(x) + \cdots + P_n(x), and each P_i has period a_iQED.

A polynomial of degree n cannot be written as the sum of n periodic functions

Suppose that for some n, there is a polynomial P of degree n which is the sum of n periodic functions. Let p be one of the periods. Then P(x+p) - P(x) is a polynomial of degree n-1, and it is also the sum of n-1 periodic functions, since one of the terms cancels. By repeating this, we eventually obtain a polynomial of degree 1 that is the sum of 1 periodic function. But this is absurd.

e^x is not the sum of periodic functions

Suppose that e^x is the sum of n periodic functions. Let p be one of the periods. Then e^{x+p} - e^x is the sum of n-1 periodic functions, since the term with period p cancels out. But e^{x+p} - e^x is a constant multiple of e^x, so we conclude that e^x is the sum of n-1 periodic functions. By repeating this, we find that e^x is the sum of 1 periodic function. But this is absurd.

Reference

Stefano Mortola and Roberto Peirone, The Sum of Periodic Functions, Topology Atlas Document # vaaa-21