def _R_tensor(a, b, c): return kron(irr_repr(order_out, a, b, c), irr_repr(order_in, a, b, c))
def _sylvester_submatrix(J, a, b, c): ''' generate Kronecker product matrix for solving the Sylvester equation in subspace J ''' R_tensor = _R_tensor(a, b, c) # [m_out * m_in, m_out * m_in] R_irrep_J = irr_repr(J, a, b, c) # [m, m] return kron(R_tensor, torch.eye(R_irrep_J.size(0))) - \ kron(torch.eye(R_tensor.size(0)), R_irrep_J.t()) # [(m_out * m_in) * m, (m_out * m_in) * m]
def _R_tensor(a, b, c): return kron(irr_repr(order_out, a, b, c), irr_repr(order_in, a, b, c)) def _sylvester_submatrix(J, a, b, c):