# vector to diagonal matrix operations/decomposition

I have a binary vector b $\in \{0,1\}^n$ , and C = diag(b) is a $n \times n$ diagonal matrix.

Is there any decomposition or transformation like bx = C , so that we can generalize x ?

-
If that is supposed to represent ordinary matrix multiplication, the answer is no, because $\mathbf{b}$ has rank at most $1$, and $\mathbf{C}$ can have any rank up to $n$. If you just are asking whether there is a linear tranformation that sends $\mathbf{b}$ to $\mathbf{C}$, the answer is yes, and it generalizes to sending an arbitrary $n$-tuple to the corresponding diagonal matrix. Could you please clarify what the question is? –  Jonas Meyer Feb 8 '11 at 17:49
yes, by x i mean transformation matrices/ vectors, that are required to obtain the diagonal matrix C –  user5978 Feb 9 '11 at 9:03
The way you have defined it, for all $i$ where $b_i=1$, $x$ must have a 1 on the main diagonal and zeros elsewhere. Is this what you mean by "generalize x"?