Main Content

dpss

Discrete prolate spheroidal (Slepian) sequences

Description

dpsSeq = dpss(seqLength,timeHalfBW) returns the first round(2*timeHalfBW) discrete prolate spheroidal (DPSS) or Slepian sequences of length seqLength.

[dpsSeq,lambda] = dpss(seqLength,timeHalfBW) returns the frequency-domain energy concentration ratios lambda of the column vectors in dpsSeq. The ratios represent the amount of energy in the passband [–W,W] to the total energy from [–Fs/2,Fs/2], where Fs is the sample rate.

[___] = dpss(seqLength,timeHalfBW,numSeq) returns the first numSeq Slepian sequences with a time-half-bandwidth product equal to timeHalfBW. The function returns the sequences in order of their energy concentration ratios.

example

[___] = dpss(seqLength,timeHalfBW,interpMethod) uses interpolation to compute the DPSSs from a user-created database of DPSSs. Create the database of DPSSs with dpsssave and ensure that the resulting file, dpss.mat, is in the MATLAB® search path.

example

[___] = dpss(___,dpssLength) interpolates from DPSSs of length dpssLength in the database dpss.mat.

[___] = dpss(___,"trace") prints the method used to compute the DPSSs in the command window. Possible methods include direct, spline interpolation, and linear interpolation.

example

Examples

collapse all

Construct the first four discrete prolate spheroidal sequences of length 512. Specify a time-half-bandwidth product of 2 and include the "trace" flag to print the algorithm used to compute the sequences.

seq_length = 512; 
time_halfbandwidth = 2;
num_seq = 4;
[dps_seq,lambda] = dpss(seq_length,time_halfbandwidth,num_seq,"trace");
Computing the DPSS using direct algorithm...

Plot the sequences and display the concentration ratios.

plot(dps_seq)
title("Slepian Sequences, N = 512, NW = 2")
axis([0 512 -0.15 0.15])
legend("1st","2nd","3rd","4th")

Figure contains an axes object. The axes object with title Slepian Sequences, N = 512, NW = 2 contains 4 objects of type line. These objects represent 1st, 2nd, 3rd, 4th.

concentration_ratios = lambda'
concentration_ratios = 1×4

    0.9999    0.9976    0.9594    0.7218

Use the dpsssave function with the time-half-bandwidth product, sequence length, and concentration ratios as inputs to create a database of Slepian sequences.

dpsssave(time_halfbandwidth,dps_seq,lambda); 

Compute discrete prolate spheroidal sequences of length 256 from dpss.mat using spline interpolation. Plot the results.

spline_dps_seq = dpss(256,time_halfbandwidth,"spline");
plot(spline_dps_seq)
title("Interpolated Slepian Sequences, N = 256, NW = 2")
axis([0 512 -0.15 0.15])
legend("1st","2nd","3rd","4th")

Figure contains an axes object. The axes object with title Interpolated Slepian Sequences, N = 256, NW = 2 contains 4 objects of type line. These objects represent 1st, 2nd, 3rd, 4th.

Input Arguments

collapse all

Sequence length, specified as a positive integer.

Data Types: single | double

Time-half-bandwidth product, specified as a positive scalar. This argument must be less than seqLength/2.

Data Types: single | double

Number of sequences to return, specified as a positive integer or two-element vector. If you specify numSeq as a two-element vector, then the output Slepian sequences range from numSeq(1) to numSeq(2).

Data Types: single | double

Interpolation method, specified as "spline" or "linear". The interpolation method uses the Slepian sequences in the database with a time-half-bandwidth product equal to timeHalfBW and length closest to seqLength.

Data Types: char | string

Length of the DPSSs, specified as a positive integer.

Data Types: single | double

Output Arguments

collapse all

Slepian sequences, returned as a matrix with a number of rows equal to seqLength and columns equal to round(2*timeHalfBW).

Frequency-domain energy concentration ratios, returned as a column vector of length equal to the number of Slepian sequences.

More About

collapse all

Extended Capabilities

expand all

Version History

Introduced before R2006a

expand all