a Function with several periods

A periodic function is given by $f(x+nT)=f(x)$, with 'n' an integer and T the period.

My question is if we can define a non-constant function with several periods; by that, I mean

$f(x+T_{i})=f(x)$ with $i=1,2,3,4,\dots$ a set of different numbers.

For example, a function that satisfies $f(x+2)=f(x)$, as well as $f(x+5.6)=f(x)$ and $f(x+ \sqrt 2) =f(x)$, but $f(x)$ is NOT a constant.

-

There are the elliptic functions, which are functions that have two (in general) complex periods. It is a deep theorem of the theory of elliptic functions that the ratio of these two periods is necessarily not real. This was proven by C.G.J. Jacobi in 1835, who also showed that there cannot be a single-valued function of one variable that has more than two periods.

-
See this as well. – J. M. Jun 9 '12 at 13:31

If we work with functions from the real line to itself, we have several cases. Since the set of periods of a function is a subgroup of the additive group of the real, it is either dense in $\Bbb R$ (for the usual topology) or discrete (of the form $a\Bbb Z$ for some $a\in\Bbb R$.

If $G$ is a subgroup of $\Bbb R$, then the characteristic function of $G$ is $g$-periodic for each $g\in G$.

The group of the periods of a continuous function is either $\Bbb R$ (constant functions) or discrete.

-
OK, discrete, and what? – Anixx Nov 7 '15 at 17:32

Dirichlet function is not a constant and has both 2 and 5.6 as its periods. But there is no smallest period.

-
Dirichlet function is a periodic function with no definite period. – SchrodingersCat Nov 7 '15 at 17:57
@Aniket it has no smallest period but has other periods. – Anixx Nov 7 '15 at 18:01
What do you mean by "it has no smallest period"? – SchrodingersCat Nov 8 '15 at 6:56