I have a matrix $q(m,n)$, where $m$ represents the vertical direction and $n$ is the horizontal direction. I need to perform the following three operations:
- take FFT of matrix $q$ in the vertical direction,
- take STFT of the output of the FFT performed in step 1 in the horizontal direction,
- For each STFT output, sum the output of STFT in the vertical direction.
I have implemented the above three steps in Matlab. I am trying to mathematically express these steps. Kindly check if I am mathematically presenting it in the correct way. Kindly suggest if the expressions really explain the aforementioned operation.
Approach 1
$Q_n(k) = \sum_{m=0}^{M-1} q_n(m)e^{-j2\pi \frac{k}{M}m}$ for $0\le n \le N-1$, where n is the columns of matrix $q$. The output of this FFT operation is arranged as $Q(k, n)$, where $k$ stands for the NFFT bins.
$P_{k}(z,l) = \sum_{n=0}^{N-1} w(n)Q_k(n+lH)e^{-j2\pi\frac{z}{N}n}$ for $0\le k \le K-1$. I take STFT on each row of $Q(k, n)$. The output is arranged as 3-dimensional, such as $P(k,z,l)$.
$P(l,z) = \sum_{k=0}^{K-1} P_k(z,l) $
Approach 2
$Q(k,n) = \sum_{m=0}^{M-1} q_n(m, n)e^{-j2\pi \frac{k}{M}m}$ for $0\le n \le N-1$, where n is the columns of matrix $q$.
$P(k,z,l) = \sum_{n=0}^{N-1} w(n)Q_k(n+lH)e^{-j2\pi\frac{z}{N}n}$ for $0\le k \le K-1$. I take STFT on each row of $Q(k, n)$.
$P(l,z) = \sum_{k=0}^{K-1} P_k(z,l) $