On Mar 12, 4:56 pm, "kk KKsingh" <akikumar1...@gmail.com>
wrote:
> Greg Heath <he...@alumni.brown.edu> wrote in message <5c77c6c52da348bea2c75c1d23aff...@e1g2000yqh.googlegroups.com>...
> > On Mar 4, 4:50 am, "kk KKsingh" <akikumar1...@gmail.com> > > wrote:
> > > Can any one provide me a file submitted where
> > > Signal is reconstructed in Fourier domain!
>
> > Is the original signal uniformly sampled in time?
> > Is the spectrum estimated uniformly in frequency?
> > Is the spectrum estimated using Least Squares or
> > the Fourier formula?
>
> Suppose I obtain spectrum for irregular signal by
> some method ...may be one of your dftgh code
For the new version of that code x,t and f have to
be periodically extended (Thanks to AJJohnson) so that
x(N+1) = x(1); % Periodic extension
dt0 = (t(N)t(1))/(N1)
t(N+1) = t(N) + dt0;
df0 = (f(M)f(1))/(M1)
f(M+1) = f(M) + df0;
then
dt = diff(t); % asymmetric "dt"
dts = 0.5*([dt; 0]+[0; dt]); % symmetric "dt"
W = exp(2*pi*j*f(:)*t(:)'); % size(W)=[M+1 N+1]
XDFT = W * ( x .* dts ); % XDFT(M+1) = X(1)
If
1. t is uniformly spaced, i.e., dt = dt0*ones(N+1,1);
2. M = N
3. f is uniformly spaced; i,e,. df = df0*ones(N+1,1);
with df0 = 1/(N*dt0)
then
XDFT = dt0*ifft(x);
There are two general leastsquare reconstruction
formulae:
xQR = ( W \ XDFT ) ./ dts;
xPINV = ( pinv(W) * XDFT ) ./ dts;
> i saw in community...that spectrum is approximate
> now i want to obtain correct spectrum by using
> least square then what should i do !
Invert
x = W' * ( XLS .* dfs );
to obtain either
XLS = XQR = ( W' \ x ) .*/ dfs;
or
XLS = XPINV = ( pinv(W') * x ) .*/ dfs;
> in one of signal processing paper........they
> applied some thing like this (sic)
>
> a = A^H*W*y % approximate spectrum
changing back to my notation
XDFT = W * diag(dts) * x;
= W * ( x .* dts );
> and
> a = inv(A^H *W*A)*A^H*W*y % a is correct spectrum
No.
Define
Dfs = diag(dfs)
IDfs = inv(Dfs) = diag( 1./dfs )
then
x = W' * ( XLS .* dfs );
= W' * Dfs * XLS
W * W' * Dfs * XLS = W * x
Now if W is full rank,
XLS = inv( W * W' * Dfs) * W * x
= IDfs * inv( W * W') * W * x
= IDfs * pinv( W' ) * x
= ( pinv( W' ) * x ) .*/ dfs;
= XPINV
which agrees with my more general formula.
> so here i am constructing my spectrum in Frequency domain
> a_y=ifft(a)
I hope you meant
BEGIN QUOTE
" ... so here i am reconstructing my time domain
signal from the spectrum in the Frequency domain
via
y=ifft(a)"
END QUOTE
Otherwise the sentence makes no sense.
Regardless, as stated above, you can only use ifft
when the following conditions are satisfied:
dt is constant, M = N, df= 1/(N*dt). This should be
obvious since ifft(x) only has x and N (implicitly)
as imputs.
> where A^H is my forward Fourier kernel, W is weights
> based on distance between the samples, y is irregular
> sample position..in time.....i tired this but didnt
> worked for me...
Use the the XQR and XPINV formulas that I derived above.
Hope this helps.
Greg
