Skip to content

FunctionPeriod ​

The fundamental period of f in x, or 0 if f is provably not periodic.

✓ checked against that system · ! checked, with disagreements (hover a chip)Wolfram LanguageFunctionPeriod✓
FunctionPeriod(f, x)the smallest positive p with f(x+p) = f(x) for every x, or 0 when f is not periodic.
Typed signatures
TypePackageApplies
(expression, symbol) -> expressionanalyticalways

Domain: Elementary functions

Details
  • A nonconstant polynomial, a genuine rational function, Sqrt, Ln, and Exp of a nonconstant affine argument are all provably non-periodic (each is monotonic or unbounded), so this answers 0 for them rather than declining.
  • Sin/Cos(a x + b) has period 2π/∣a∣2\pi/|a|; Tan(a x + b) has period π/∣a∣\pi/|a|.
  • Does not yet combine periods across a sum of trig terms with different (even commensurate) frequencies, such as sin⁡x+cos⁡2x\sin x + \cos 2x — that composition is outside the single-shape classifier this file is built on, and is declined.

Examples

1 more kept as data, checked against the oracles
Basic #

Sine's period is 2*pi

live ↗
InFunctionPeriod(sin⁡(x),x)\mathrm{FunctionPeriod}(\sin(x), x)Out2π2π

Known value · Wolfram 15.0.0, hand cross-checked

Tangent's period is pi, half of sine's

live ↗
InFunctionPeriod(tan⁡(x),x)\mathrm{FunctionPeriod}(\tan(x), x)Outππ

Known value · Wolfram 15.0.0, hand cross-checked

Doubling the argument halves the period

live ↗
InFunctionPeriod(sin⁡(2x),x)\mathrm{FunctionPeriod}(\sin(2x), x)Outππ

Known value · Wolfram 15.0.0, hand cross-checked

Exp is monotonic, hence not periodic

live ↗
InFunctionPeriod(ex,x)\mathrm{FunctionPeriod}(e^{x}, x)Out00

Known value · Wolfram 15.0.0, hand cross-checked

Scope #

With a symbolic frequency the period is left unevaluated even under a>0a>0

live ↗
InAssuming(a>0,FunctionPeriod(sin⁡(ax),x))\mathrm{Assuming}(a\gt0, \mathrm{FunctionPeriod}(\sin(ax), x))OutFunctionPeriod(sin⁡(ax),x)\mathrm{FunctionPeriod}(\sin(ax), x)
About
Examples6
Checked againstWolfram Language 6 agree
CrosswalkWolfram Language