51 lines
811 B
Matlab
51 lines
811 B
Matlab
function F = fracF_dpw(f,...
|
|
Achirp,...
|
|
AchirpOut,...
|
|
H,...
|
|
scale)
|
|
%#codegen
|
|
%
|
|
% fracF_dpw
|
|
%
|
|
% Matrix FrFT processing for an entire DPW.
|
|
%
|
|
% INPUT:
|
|
% f [1024 x Nframes] complex(single)
|
|
% Achirp [1024 x 1]
|
|
% AchirpOut [512 x 1]
|
|
% H [2048 x 1]
|
|
% scale scalar
|
|
%
|
|
% OUTPUT:
|
|
% F [512 x Nframes]
|
|
|
|
N = 1024;
|
|
Nfft = 2048;
|
|
|
|
Nframes = size(f,2);
|
|
|
|
%% First chirp multiplication
|
|
|
|
g = f .* Achirp;
|
|
|
|
%% Zero-padding
|
|
|
|
g_pad = complex(zeros(Nfft,Nframes,'single'));
|
|
|
|
g_pad(1:N,:) = g;
|
|
|
|
%% FFT convolution
|
|
|
|
Gfft = fft(g_pad);
|
|
|
|
G = ifft(Gfft .* H);
|
|
|
|
%% Extract valid region and decimate
|
|
|
|
G_valid = G(N+1:2:end,:);
|
|
|
|
%% Final chirp multiplication
|
|
|
|
F = scale .* G_valid .* AchirpOut;
|
|
|
|
end |