Derivation of transformation law for vectors

With respect to the two different bases, we can write $\v u$ as $$ \sum_{i=1}^n u_i\v e_i = \v u = \sum_{j=1}^n u_j' \v e_j'. $$ Using the change-of-basis matrix $u_j' = P_{ij}u_i$, the equation becomes $$\begin{align*} \sum_{i=1}^n u_i\v e_i &= \sum_{j=1}^n u_j' \Big(\sum_{i=1}^n P_{ij} \v e_i\Big) \\ &= \sum_{i=1}^n\Big(\sum_{j=1}^n P_{ij} u_j'\Big)\v e_i. \end{align*}$$ By linear independence of $\v e_i$, $$ u_i = P_{ij}u_j'. $$

Warning: the vector is the same, but we are representing the components in different basis as $\v u$ and $\v u'$.

Then $$ \v u = P\v u', \qquad \v u' = P\inv \v u.$$