Say I have a square symmetric positive definite matrix $M \in R^n \times R^n$. If I want the matrix A obtained after the following transformation:
$$ a_{ij} = \log(m_{ij}) \ \forall i,j \ \ \text{if} \ \ m_{ij} \neq 0 $$ $$ a_{ij} = 0 \ \text{otherwise} $$
to be positive definite, do I need extra conditions on the matrix A or M ?
Edit: $m_{ij} \geq 0 \ \forall i,j$
I suppose that you mean $a_{ij} = log(m_{ij}) \ \forall i,j \ \ \text{if} \ \ m_{ij} > 0.$
Consider the case $n=2$ with $m_{11}=e, m_{12}=m_{21}=0$ and $m_{22}=e^{-1}.$ Then $M$ is positive definite, but
$$A=\begin{pmatrix} 1 & 0\\ 0 & -1 \end{pmatrix}$$
is indefinite.