What does it mean to multiply a real matrix by a complex scalar? In this answer https://math.stackexchange.com/a/219508/27609 it is noted, that multiplying a matrix $A$ by a scalar $s$ is the same as multiplying a matrix $A$ by a diagonal matrix ${\rm diag}(c,c,\ldots, c)$ of the appropriate size. But is this also the case, if $s$ is a complex number? What does it mean when one multiplies a matrix by e.g. the imaginary unit $i$. Does it simply mean $$i *\pmatrix{a&b\\c&d} = \pmatrix{i&0\\0&i} \pmatrix{a&b\\c&d}?$$ Or does it mean $$i *\pmatrix{a&b\\c&d} = \pmatrix{0&1\\-1&0} \pmatrix{a&b\\c&d}?$$ The latter could also make sense, because the imaginary unit $i$ is equivalent to the 2x2 matrix $J=\pmatrix{0&1\\-1&0},$ since $J^2=\pmatrix{-1&0\\0&-1}$ (see e.g. Relation of this antisymmetric matrix $r = \left(\begin{smallmatrix}0 &1\\-1&0\end{smallmatrix}\right)$ to $i$), but this would obviously give a different result when multiplying with a matrix.
 A: Each matrix element is multiplied by the scalar, not matter if it is real-valued or complex.
A: You're mixing up two different views of the complex numbers here $\mathbb{C}$.
The complex numbers form a field, just like the real numbers (and the rational numbers too) do, and as such you can form vector spaces over $\mathbb{C}$. In other words, $\mathbb{C}$ can be the field of scalars of some vector space $V$. Since multiplying a vector or matrix with a scalar simply means multiplying all components with that scalar, you have that $$
  i \cdot \begin{pmatrix} a_{11} & \ldots & a_{1n} \\ \vdots & \ddots & \vdots \\ a_{m1} & \ldots & a_{mn} \end{pmatrix} =
  \begin{pmatrix} i & 0 & \ldots & 0 \\ 0 & i & \ddots & \vdots\\ \vdots & \ddots & \ddots & 0 \\ 0 & \ldots & 0 & i \end{pmatrix} \cdot \begin{pmatrix} a_{11} & \ldots & a_{1n} \\ \vdots & \ddots & \vdots \\ a_{m1} & \ldots & a_{mn} \end{pmatrix} =
\begin{pmatrix} i\cdot a_{11} & \ldots & i\cdot a_{1n} \\ \vdots & \ddots & \vdots \\ i\cdot a_{m1} & \ldots & i\cdot a_{mn} \end{pmatrix}
$$
But you can also view the complex numbers as a vector space over the real numbers, i.e. view $\mathbb{C}$ as $\mathbb{R}^2$. That is the view that people usually have in mind if they talk about the complex plane. The real unit then $1$ corresponds to the vector $(1,0)^T$ and the imaginary unit $i$ to the vector $(0,1)^T$. Multiplication of with a fixed complex number $c$ then is a linear transformation on this two-dimensional vector space, and as such can be represented by a matrix. If $c \in \mathbb{C}$ and $x_z=(\textrm{Re }z, \textrm{Im } z)^T$ is the vector corresponding to the complex number $z$, then the vector corresponding to $c \cdot z$ is $$
  x_{c\cdot z} = M_c \cdot x_{z} = \underbrace{\begin{pmatrix}
    \textrm{Re } c & -\textrm{Im } c \\
    \textrm{Im } c & \textrm{Re } c
  \end{pmatrix}}_{=M_c} \cdot \underbrace{\begin{pmatrix}
    \textrm{Re }z \\ \textrm{Im } z
  \end{pmatrix}}_{x_z} \text{.}
$$
In particular, the matrix corresponding to a multiplication with $i$ is $$
  M_i = \begin{pmatrix}
    0 & -1 \\
    1 & 0
  \end{pmatrix} \text{.}
$$
