% ola - Overlap and Add
%
% Y = ola(X,sShift,hWindow,Dim)
%
% Performs the overlap and add method on the input matrix X to create the
% output array Y.
%
% Example
% Fs = 10000; % Sampling frequency
% t = (0:2*Fs)/Fs; % Time vector
%
% A = [0.25 0.5 1 0.5 0.25]; % Amplitudes
% F = [100 125 150 175 425]; % Frequencies
% x = A*sin(2*pi*F.'*t); % Signal
%
% Framesize = 256; % Frame size
% pOverlap = 0.4; % Precentage overlap
% sOverlap = fix(Framesize*(1-pOverlap)); % Sample overlap
% sShift = Framesize - sOverlap; % Sample shift
% hWindow = @hamming; % Windowing function
%
% X = buffer(x,Framesize,sOverlap,'nodelay'); % Framed signal
% nFrames = size(X,2); % Number of frames
% X = X.*repmat(hWindow(Framesize),1,nFrames); % Apply window
%
% % Normal overlap and add
% Y1 = ola(X,sShift,[],1); % Reconstructed signal
%
% % Allen & Rabiner's method
% Y2 = ola(X,sShift,@hamming,1);
% Y2 = olaar(X,sShift,@hamming,1);
%
% % Griffin & Lim's method
% Y3 = olagl(X,sShift,@hamming,1);
%
% figure
% hold all
% plot(x,'bx')
% plot(Y1,'r')
% plot(Y2,'g')
% plot(Y3,'c')
% legend('Original','ola','olaar','olagl')
%
% See also
% ola olaar olagl
%% Author Information
% Pierce Brady
% Smart Systems Integration Group - SSIG
% Cork Institute of Technology, Ireland.
%
%% Reference
% SSBoll79 function by Esfandiar Zavarehei
% FRAMES2VEC function by Kamil Wojcicki, UTD, July 2011
%
Zitieren als
Pierce Brady (2024). ola (https://www.mathworks.com/matlabcentral/fileexchange/32684-ola), MATLAB Central File Exchange. Abgerufen.
Kompatibilität der MATLAB-Version
Plattform-Kompatibilität
Windows macOS LinuxKategorien
Tags
Quellenangaben
Inspiriert von: Boll Spectral Subtraction, Framing Routines
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Live Editor erkunden
Erstellen Sie Skripte mit Code, Ausgabe und formatiertem Text in einem einzigen ausführbaren Dokument.
ola/
Version | Veröffentlicht | Versionshinweise | |
---|---|---|---|
1.0.0.0 |