0

Suppose $B$ is an $N\times N$ matrix and $V$ is an $N\times 1$ vector.

I need to find a matrix representation for $V$:

$V_k = \sum_{j}B_{kj}^4 + 2\sum_{i\neq j}\sum_{j}B_{ki}^2B_{kj}^2$

Previously, I asked a somewhat similar question here: Need to find matrix formulation and I can't find the answer of this one either.

  • 2
    What do you mean by $B^4_{kj}$? Is it the components of the 4th power of the matrix $(B^4){kj}$, or the 4th power of the components of the matrix $(B{kj})^4$? Are you multiplying matrices or numbers? – mr_e_man Sep 29 '18 at 14:14
  • 4th power of the components of matrix B $(B_{kj})^4$, I am multiplying numbers – farhadpti Sep 29 '18 at 19:35

1 Answers1

0

For typing convenience, define $$A=\big(B\odot B\big)$$ where $\odot$ represents the elementwise/Hadamard product.

Then the vector can be written in matrix notation as $$\eqalign{ v &= (A\odot A)\,e + \big(2Ae\big)\odot\big(Ae-{\rm diag}(A)\big) \cr }$$ where $e$ is the vector whose elements are all equal to unity.

greg
  • 35,825