In general
$$
\sum_{m=1}^N\sum_{n=1}^N A_{ijmn}B_{mnkl} = \delta_{ik}\delta_{jl}
$$
for $i,j,k,l = 1,\ldots,N$. Now suppose the tensor $\mathbf{A}$ is unfolded as the $N^2\times N^2$ matrix given by
$$
A = \left[
\begin{array}{ccccccccc}
A_{1111} & A_{1112} & \cdots & A_{111N} & \cdots & A_{11N1} & A_{11N2} & \cdots & A_{11NN}\\
A_{1211} & A_{1212} & \cdots & A_{121N} & \cdots & A_{12N1} & A_{12N2} & \cdots & A_{12NN}\\
\vdots & \vdots & &\vdots & & \vdots & \vdots & & \vdots\\
A_{NN11} & A_{NN12} & \cdots & A_{NN1N} & \cdots & A_{NNN1} & A_{NNN2} & \cdots & A_{NNNN}\\
\end{array}
\right]
$$
If the same is done for $\mathbf{B}$, then the matrix product $AB$ corresponds to the unfolded tensor product $\mathbf{A} : \mathbf{B}$. Let $E$ be the same unfolding of the tensor identity matrix $\mathbf{I}$. Then
$$
\mathbf{A} : \mathbf{B} = \mathbf{I} \iff AB = E
$$
Similarly,
$$
\mathbf{B} : \mathbf{A} = \mathbf{I} \iff BA = E
$$
In order for such a matrix $B$ to exist it follows that $AB = BA$ must hold, i.e., the product of $A$ and $B$ must commute. Now suppose $A$ is invertible. Then $B$ must satisfy the equations
$$
B = A^{-1}E \quad\text{and}\quad B = EA^{-1} \iff A^{-1}E = EA^{-1} \iff EA = AE
$$
Thus, in the case that $A$ is invertible, the product of $A$ and $E$ must commute in order for such a matrix $B$ to exist. If these conditions are met, then you should be able to compute a unique $B$ from the equation $AB = E$ via the LU factorization or by some other matrix factorization.
Representing tensors using matrix notation is often confusing, but let's assume that
$Y = \begin{pmatrix}y^1_1&y^1_2\\v^2_1&y^2_2\end{pmatrix}$
and similarly for Z. If $W = Y \times Z$ then the components of $W$ are
$w^{ik}_{jl} = y^i_j z^k_l$
You have represented W as a 4x4 matrix, but it would be more accurate to represent it as a 2x2 matrix, each of whose entries is another 2x2 matrix.
Anyway, the four possible contractions of W are:
(1): $w^{ik}_{il} = y^i_i z^k_l$
(2): $w^{ik}_{jk} = y^i_j z^k_k$
(3): $w^{ik}_{ji} = y^i_j z^k_i$
(4): $w^{ij}_{jl} = y^i_j z^j_l$
In terms of matrix operations:
(1) is the component representation of $Tr(Y)Z$
(2) is the component representation of $Tr(Z)Y$
(3) is the component representation of $YZ$
(4) is the component representation of $ZY$
Best Answer
There is no relation whatsoever between $X^{ijk}$ and $X^{jik}$ as stated. A given tensor need not be symmetric or skew-symmetric for any choices of indices.
Also, your $X^{jik}g_j = X^{ik}$ is not correct, as the metric tensor is a tensor of order $2$. What would make sense is to write $X^{jik}g_{k\ell} = X^{ji}_{\phantom{ji}\ell}$ instead.
For better or worse, I have some notes about tensors on vector spaces, you might find that useful.