I have two matrices $A$ and $B$. $A$ is a diagonal matrix and $B$ is not.
e.g.
$A = \begin{bmatrix} a_{11} &0 \\ 0 & a_{22} \end{bmatrix}$ and $B = \begin{bmatrix} b_{11} &b_{12} \\ b_{21} & b_{22} \end{bmatrix}$
I want to obtain $a_{11}\sqrt{b_{11}} + a_{22}\sqrt{b_{22}}$ by applying some matrix operations to $A$ and $B$. How can I do that? Thanks!