PeriodogramArray[list]
returns the squared magnitude of the discrete Fourier transform (power spectrum) of list.
PeriodogramArray[list,n]
averages the power spectra of non-overlapping partitions of length n.
PeriodogramArray[list,n,d]
uses partitions with offset d.
PeriodogramArray[list,n,d,wfun]
applies a smoothing window wfun to each partition.
PeriodogramArray[list,n,d,wfun,m]
pads partitions with zeros to length m prior to the computation of the transform.
PeriodogramArray[image,…]
returns the squared power spectrum of image.
PeriodogramArray[audio,…]
returns the squared power spectrum of audio.
PeriodogramArray[video,…]
returns the squared power spectrum of the first audio track in video.
PeriodogramArray
PeriodogramArray[list]
returns the squared magnitude of the discrete Fourier transform (power spectrum) of list.
PeriodogramArray[list,n]
averages the power spectra of non-overlapping partitions of length n.
PeriodogramArray[list,n,d]
uses partitions with offset d.
PeriodogramArray[list,n,d,wfun]
applies a smoothing window wfun to each partition.
PeriodogramArray[list,n,d,wfun,m]
pads partitions with zeros to length m prior to the computation of the transform.
PeriodogramArray[image,…]
returns the squared power spectrum of image.
PeriodogramArray[audio,…]
returns the squared power spectrum of audio.
PeriodogramArray[video,…]
returns the squared power spectrum of the first audio track in video.
Details and Options
- PeriodogramArray works with numeric arrays of any rank, 2D and 3D images, and sound objects.
- In PeriodogramArray[list,n,d,wfun], the smoothing window wfun can be specified using a window function that will be sampled between
and
or a list of length n. The default window is DirichletWindow, which effectively does no smoothing. - PeriodogramArray[list,n] is equivalent to PeriodogramArray[list,n,n,DirichletWindow,n].
- PeriodogramArray[list,{n1,n2,…}] partitions a nested list into blocks of size n1×n2×….
- For multidimensional arrays, n is taken to be equivalent to {n,n,…}.
- PeriodogramArray works with numeric lists, as well as Audio and Sound objects.
- For multichannel sounds and images, PeriodogramArray is computed for each channel separately.
- PeriodogramArray accepts the FourierParameters option. The default setting is FourierParameters->{0,1}.
Examples
open all close allBasic Examples (3)
PeriodogramArray[{0, 1, 0, -1, 0, 1, 0, -1}]Power spectrum of a noisy dataset:
data = Table[0.7 Sin[0.2 π n] + Sin[0.5 π n] + RandomReal[{-1, 1}], {n, 0, 127}];ListLinePlot[PeriodogramArray[data], PlotRange -> All]Power spectrum of a texture image:
s = PeriodogramArray[[image]];
ImageAdjust[Image[Log10[s]]]Scope (5)
PeriodogramArray[{0, 1, 0, -1, 0, 1, 1, -1}, 4]PeriodogramArray[{0, 1, 0, -1, 0, 1, 1, -1}, 4, 2]PeriodogramArray[{0, 1, 0, -1, 0, 1, 1, -1}, 4, 2, HammingWindow]Use a numerical array as a custom smoothing window:
PeriodogramArray[{0, 1, 0, -1, 0, 1, 1, -1}, 4, 2, {.5, 1, 1, .2}]Increase the length of the discrete Fourier transform to smooth the power spectrum data:
data = Table[0.7 Sin[0.2 π n] + Sin[0.5 π n] + RandomReal[{-1, 1}], {n, 0, 127}];Table[ListLinePlot[10 Log[10, PeriodogramArray[data, 32, 32, DirichletWindow, m][[1 ;; Floor[m / 2]]]], PlotRange -> All], {m, {32, 128}}]PeriodogramArray[[image]]//MatrixFormVisualization of a 3D power spectrum of a modulated pulse:
data3D = PadRight[ConstantArray[1, {15, 15, 20}], {64, 64, 64}] Table[Cos[(π/32)11z]Cos[(π/32) 9 y] Cos[(π/32) 15 x] , {z, 0, 63}, {y, 0, 63}, {x, 0, 63}];power3 = PeriodogramArray[data3D][[1 ;; 32, 1 ;; 32, 1 ;; 32]];
Image3D[power3, ImageSize -> 200, Axes -> True, AxesLabel -> {"x", "y", "z"}]Process the audio track of a video:
PeriodogramArray[\!\(\*VideoBox[""]\), 200]//ListLinePlotOptions (1)
FourierParameters (1)
Change in the first Fourier parameter affects scaling:
PeriodogramArray[{1, 0, 0, 0, 0, 0, 0, 0}, FourierParameters -> {0, -1}]PeriodogramArray[{1, 0, 0, 0, 0, 0, 0, 0}, FourierParameters -> {1, -1}]Change in the second Fourier parameter does not affect the result:
PeriodogramArray[{1, 0, 0, 0, 0, 0, 0, 0}, FourierParameters -> {0, 1}]Properties & Relations (4)
Verification of Parseval's theorem:
x = RandomReal[{-1, 1}, 8];
Total[x ^ 2] == Total[PeriodogramArray[x]]Comparison with ListFourierSequenceTransform:
x = Table[Sin[0.45 π n + 1.] + RandomReal[{-1, 1}], {n, 0, 31}];dtft = Abs[ListFourierSequenceTransform[x, ω] ^ 2] / 32;dft = PeriodogramArray[x];{ListLinePlot[dft, DataRange -> {0, 2Pi}, PlotRange -> All], Plot[dtft, {ω, 0, 2Pi}, PlotRange -> All]}With partitions longer than the list, a zero-padded version of the list is used:
PeriodogramArray[{0, 1, 0, -1, 0, 1, 0, -1}, 16]Use logarithmic scaling to visualize the power spectra of an image:
s = PeriodogramArray[[image]];
ImageAdjust[Image[Log10[RotateLeft[#, {64, 64}]]]]& /@ sColorCombine[%]Possible Issues (1)
When averaging over partitions, Parseval's theorem may be violated:
x = Table[Sin[0.45 π n + 1.] + RandomReal[{-1, 1}], {n, 0, 31}];Total[x ^ 2] / Length[x] == Total[p = PeriodogramArray[x]] / Length[p]Total[x ^ 2] / Length[x] == Total[p = PeriodogramArray[x, 30]] / Length[p]Neat Examples (1)
3D visualization of a stack of 2D power spectra of a modulated pulse:
data3D = Table[PadRight[ConstantArray[1, {15, 10}], {64, 64}] Table[Cos[(π/32) u[[1]] n] Cos[(π/32) u[[2]] m] , {n, 0, 63}, {m, 0, 63}], {u, Table[Round[{10 Cos[θ], 10 Sin[θ]} + 16], {θ, 0, 4 π - (2π/64), (2π/32)}]}];
power = PeriodogramArray[#][[1 ;; 32, 1 ;; 32]]& /@ data3D;
Graphics3D[Raster3D[power, ColorFunction -> "AvocadoColorsOpacity"], ImageSize -> 200]See Also
Periodogram ImagePeriodogram Fourier Partition SpectrogramArray DirichletWindow
Function Repository: IrregularPeriodogram WelchSpectralEstimate
Related Guides
History
Introduced in 2012 (9.0) | Updated in 2014 (10.0) ▪ 2016 (11.0) ▪ 2024 (14.1)
Text
Wolfram Research (2012), PeriodogramArray, Wolfram Language function, https://reference.wolfram.com/language/ref/PeriodogramArray.html (updated 2024).
CMS
Wolfram Language. 2012. "PeriodogramArray." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2024. https://reference.wolfram.com/language/ref/PeriodogramArray.html.
APA
Wolfram Language. (2012). PeriodogramArray. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/PeriodogramArray.html
BibTeX
@misc{reference.wolfram_2026_periodogramarray, author="Wolfram Research", title="{PeriodogramArray}", year="2024", howpublished="\url{https://reference.wolfram.com/language/ref/PeriodogramArray.html}", note=[Accessed: 12-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_periodogramarray, organization={Wolfram Research}, title={PeriodogramArray}, year={2024}, url={https://reference.wolfram.com/language/ref/PeriodogramArray.html}, note=[Accessed: 12-June-2026]}