# Two ways of obtaining Dynamic Mode Decomposition modes - are they equivalent?

In this lecture prof. Kutz gives the Dynamic Mode Decomposition modes:

$$\Phi = X' V_r \Sigma_r^{-1} W$$

which are the eigenvectors of the linear propagator matrix. This results from splitting the full data matrix $$X$$ into $$X' = X(:,2:\text{end})$$ and $$X_1 = X(:,1:\text{end}-1)$$. $$U_r$$, $$\Sigma_r$$ and $$V_r$$ are matrices resulting from the SVD of the data matrix $$X_1$$ and rank-$$r$$ truncation afterwards. $$W$$ is the approximation to the eigenvectors of the linear propagator matrix.

However, in the textbook by prof. Kutz Data-driven modeling and scientific computation, this formula is given for the DMD modes:

$$\Phi = U_r W$$

and this is also the formulation that was originally given by Peter Schmid.

I don't see them being equivalent equations, but perhaps I overlook something. To my understanding, they would be equivalent if in the first equation we used the rank-$$r$$ approximation matrix $$X_{1 r} \approx X_1$$ instead of $$X'$$:

$$X_{1 r} V_r \Sigma_r^{-1} W = U_r \Sigma_r V_r^T V_r \Sigma_r^{-1} W = U_r W$$

since $$V_r$$ is both orthogonal and orthonormal, and $$\Sigma_r$$ is a diagonal matrix.

Could you please explain the logic/intuition behind both approaches and if and how these two approaches differ from each other?

There's two issues here. First, are we using X(:,2:end) or X(:,1:end−1)? I have no idea.

Second, are we using the rank r approximation or the full matrix? Turns out it doesn't matter. The missing bit is actually 0. Let $$USV^T$$ be the full SVD of $$X_1$$. Let $$S_r$$, $$U_r$$, and $$V_r$$ be identical to $$S$$, $$U$$, and $$V$$ except that columns $$r+1$$ and onwards are set to 0. So, $$U_rS_rV_r^T$$ is a truncated SVD, but the individual matrices all stay at their original (non-truncated) dimensions. This allows me to show how they interact with one another. Let $$S_{r+1}$$, $$U_{r+1}$$ and $$V_{r+1}$$ be the remainders: they equal $$S$$, $$U$$ and $$V$$ respectively but with the first $$r$$ columns set to 0. By looking back at the outer product form of the SVD:

$$\sum_r u_r s_r v_r^T$$

... you'll hopefully see that

$$X_1 = U_{r} S_{r}V_{r}^T + U_{r+1} S_{r+1}V_{r+1}^T= X_{1r} + U_{r+1} S_{r+1}V_{r+1}^T$$.

The key to seeing why

$$X_{1}V_{r} = X_{1r}V_{r}$$

is that the remainder term, ending in $$V_{r+1}^T$$, will completely cancel with $$V_r$$.