FunctionPeriod[f,x]
gives a period p of the function f over the reals such that
.
FunctionPeriod[f,x,dom]
gives a period with x restricted to the domain dom.
FunctionPeriod[{f1,f2,…},{x1,x2,…},…]
gives periods {p1,p2,…} for {x1,x2,…} such that
.
FunctionPeriod
FunctionPeriod[f,x]
gives a period p of the function f over the reals such that
.
FunctionPeriod[f,x,dom]
gives a period with x restricted to the domain dom.
FunctionPeriod[{f1,f2,…},{x1,x2,…},…]
gives periods {p1,p2,…} for {x1,x2,…} such that
.
Examples
open all close allBasic Examples (3)
Find a period of the sine function:
FunctionPeriod[Sin[x], x]Plot[Sin[x], {x, -2Pi, 2Pi}, Ticks -> {{-2Pi, -Pi, 0, Pi, 2Pi}, {-1, 1}}]FunctionPeriod[Mod[n, 8], n, Integers]DiscretePlot[Mod[n, 8], {n, 0, 15}]Find periods for multidimensional functions:
FunctionPeriod[Cos[x] + Sin[y], {x, y}]ContourPlot[Cos[x] + Sin[y], {x, -2Pi, 2Pi}, {y, -2Pi, 2Pi}]Scope (10)
Basic Uses (5)
FunctionPeriod[(-1) ^ n, n, Integers]FunctionPeriod[Sin[n 2π / 17 + 3], n, Integers]FunctionPeriod[Mod[2n, 18], n, Integers]Table[DiscretePlot[f, {n, 35}, PlotLabel -> f, PlotTheme -> "Minimal"], {f, {(-1) ^ n, Sin[n 2π / 17 + 3], Mod[2n, 18]}}]FunctionPeriod[Sin[x], x, Reals]FunctionPeriod[Tan[x], x, Reals]FunctionPeriod[SquareWave[x], x, Reals]Table[Plot[f, {x, 0, 4π}, PlotLabel -> f, PlotTheme -> "Minimal", Exclusions -> None], {f, {Sin[x], Tan[x], SquareWave[x]}}]FunctionPeriod[Exp[z], z, Complexes]FunctionPeriod[Cosh[z], z, Complexes]FunctionPeriod[JacobiCD[z / 2, 2], z, Complexes]Table[Plot3D[Re[f], {x, -4π, 4π}, {y, -4π, 4π}, PlotLabel -> Re[f], PlotTheme -> "Minimal"], {f, {Exp[x + I y], Cosh[x + I y], JacobiCD[(x + I y) / 2, 2]}}]Periods of functions with parameters:
Assuming[a > 0, FunctionPeriod[Sin[a x], x]]Plot[{Sin[x], Sin[x / 2], Sin[x / 3]}, {x, 0, 6Pi}, PlotLegends -> "Expressions"]Periods of multivariate mappings:
FunctionPeriod[{Tan[x + y], Cos[x - 2y]}, {x, y}]Periodic Functions over the Integers (5)
Basic periodic sequences include Mod:
p = FunctionPeriod[Mod[n / 2 + 7, 11], n, Integers]DiscretePlot[Mod[n / 2 + 7, 11], {n, 3p}]Mod of a polynomial:
p = FunctionPeriod[Mod[n^3 + 7n^2 + 3, 11], n, Integers]DiscretePlot[Mod[n^3 + 7n^2 + 3, 11], {n, 5p}]FunctionPeriod[(-1)^n, n, Integers]And in general powers of roots of unity, i.e. roots of the polynomial
:
Solve[x^7 == 1, x]FunctionPeriod[Power[(-1)^2 / 7, n], n, Integers]Table[DiscretePlot[f, {n, 20}, PlotTheme -> "Minimal"], {f, {Re[Power[(-1)^2 / 7, n]], Im[Power[(-1)^2 / 7, n]]}}]A common way to express these are
:
FunctionPeriod[Exp[n 2π I / 7], n, Integers]Trigonometric functions with a rational multiple of their real period:
trigs = {Sin[n 2π / 10], Cos[n 2π / 10], Csc[n 2π / 10 + 1], Sec[n 2π / 10 + 1], Tan[n π / 10 + 1], Cot[n π / 10 + 1]};FunctionPeriod[#, n]& /@ trigsTable[DiscretePlot[f, {n, 30}, PlotTheme -> "Minimal"], {f, trigs}]A function
where
is periodic over the reals with period
and
rational:
τ = FunctionPeriod[TriangleWave[x / 2], x, Reals]FunctionPeriod[TriangleWave[n / 2 1 / 5], n, Integers]DiscretePlot[TriangleWave[n / 2 1 / 5], {n, 30}]It works similarly for a function periodic over the complexes:
τ = FunctionPeriod[Cosh[x], x, Complexes]FunctionPeriod[Cosh[n 2π I / 10], n, Integers]DiscretePlot[Re[Cosh[n 2π I / 10]], {n, 30}]Any finite sum of periodic sequences is periodic:
FunctionPeriod[Mod[n, 3] + 3 Sin[n 2π / 5], n, Integers]DiscretePlot[Mod[n, 3] + 3 Sin[n 2π / 5], {n, 60}]Any finite product of periodic sequences is periodic:
FunctionPeriod[Mod[n, 3]3 Sin[n 2π / 5]^2, n, Integers]DiscretePlot[Mod[n, 3]3 Sin[n 2π / 5]^2, {n, 60}]Any function combination
of periodic sequences is periodic:
FunctionPeriod[Mod[n, 3]^2(Sin[n 2π / 5] + Cos[n 2π / 3]) + Mod[n ^ 2, 4], n, Integers]DiscretePlot[Mod[n, 3]^2(Sin[n 2π / 5] + Cos[n 2π / 3]) + Mod[n ^ 2, 4], {n, 300}, PlotRange -> All]See Also
FunctionDomain FunctionRange DifferenceDelta Differences FourierSeries FindRepeat FindTransientRepeat
Function Repository: FunctionPeriodPlot FunctionOverview
Related Guides
History
Text
Wolfram Research (2014), FunctionPeriod, Wolfram Language function, https://reference.wolfram.com/language/ref/FunctionPeriod.html.
CMS
Wolfram Language. 2014. "FunctionPeriod." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/FunctionPeriod.html.
APA
Wolfram Language. (2014). FunctionPeriod. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/FunctionPeriod.html
BibTeX
@misc{reference.wolfram_2026_functionperiod, author="Wolfram Research", title="{FunctionPeriod}", year="2014", howpublished="\url{https://reference.wolfram.com/language/ref/FunctionPeriod.html}", note=[Accessed: 13-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_functionperiod, organization={Wolfram Research}, title={FunctionPeriod}, year={2014}, url={https://reference.wolfram.com/language/ref/FunctionPeriod.html}, note=[Accessed: 13-June-2026]}