\begin{align}
\label{elbo1}
    \text{ELBO}(\hat{\beta}_k, \hat{R}_k,\hat{\mu}_k, \hat{Q}_k, \phi_{t_k}) & =  \mathbb{E}_q \left[ \text{log }  p(\boldsymbol\beta, \boldsymbol\mu , \text{\bf{c}}, \text{\bf{x}}, \text{\bf{y}}) \right]
    - \mathbb{E}_q \left[ \text{log } q(\boldsymbol\beta, \boldsymbol\mu , \text{\bf{c}}) \right]
    \nonumber \\
   & = \sum_{k=1}^K \mathbb{E}_q \left[ \text{log} \ p(\mu_k) \right] +  \sum_{k=1}^K \mathbb{E}_q \left[ \text{log} \ p(\beta_k) \right] \nonumber \\
    & + \sum_{t=1}^T \Big( \mathbb{E}_q \left[ \text{log} \ p(c_t) \right] + \mathbb{E}_q \left[ \text{log} \ p(x_t |\boldsymbol\mu, c_t) \right] + \mathbb{E}_q \left[ \text{log} \ p(y_{t+1} |\boldsymbol\beta, x_t, c_t) \right] \Big) \nonumber \\
    & - \sum_{t=1}^T \mathbb{E}_q \left[ \text{log} \ q_c(c_t) \right] - \sum_{k=1}^K \mathbb{E}_q \left[ \text{log} \ q_\mu(\mu_k) \right] - \sum_{k=1}^K \mathbb{E}_q \left[ \text{log} \ q_\beta (\beta_k) \right] 
\end{align}
