# Entropy Analysis of a Flexible Markovian Queue with Server Breakdowns
## 2 Model Formulation and Previous Results
### Entropy Solution Using the Second Moment  
In this subsection, we use (2) to calculate the second moment \(E(X^{2})\) and we will show that the use of the second moment instead of the first moment as an extra constraint leads to an initial steady state probability vector that is also closer to the initial steady state probability vector obtained analytically. We find that the second moment is given by  
\[E(X^{2})=\left(1+\frac{\alpha_{2}}{\beta_{2}}\right)W^{\prime\prime}(1)+\left( \frac{\alpha_{1}}{\beta_{1}}-\frac{\alpha_{2}}{\beta_{2}}\right)S^{\prime\prime }_{1}(1)+E(X), \tag{14}\]  
where  
\[W^{\prime\prime}(1)=\frac{V^{\prime\prime}(1)U^{\prime\prime\prime}(1)-U^{ \prime\prime}(1)V^{\prime\prime\prime}(1)}{3V^{\prime\prime}(1)^{2}},\]  
with  
\[V^{\prime\prime}(1) = 2(c\mu_{2}-\lambda)^{2}\] \[U^{\prime\prime}(1) = D^{\prime}(1)N^{\prime\prime}(1)-N^{\prime}(1)D^{\prime\prime \prime}(1)\] \[V^{\prime\prime\prime}(1) = 6c(c\mu_{2}-\lambda)\left[(c-1)\mu_{2}-\lambda\right]\] \[U^{\prime\prime\prime}(1) = 2[D^{\prime}(1)N^{\prime\prime\prime}(1)-N^{\prime}(1)D^{\prime \prime\prime}(1)]\] \[A^{\prime\prime\prime}_{1}(1) = (c-1)(c-2)\left(c\mu_{2}-3\mu_{1}\right)\] \[A^{\prime\prime\prime}_{2}(1) = \frac{\lambda c(c-1)(c-2)}{\mu_{2}-\mu_{1}}\] \[A^{\prime\prime\prime}_{3}(1) = \frac{\mu_{1}^{2}(c-1)(c-2)(c-3)}{\mu_{1}-\mu_{2}}\] \[D^{\prime\prime\prime}(1) = c(c-1)\left[(c-2)\mu_{2}-3\lambda\right]\] \[W^{\prime\prime}(1)=\frac{V^{\prime\prime}(1)U^{\prime\prime\prime}(1)-U^{ \prime\prime}(1)V^{\prime\prime\prime}(1)}{3V^{\prime\prime}(1)^{2}},\]0 \[W^{\prime\prime}(1)=\frac{V^{\prime\prime}(1)U^{\prime\prime\prime}(1)-U^{ \prime\prime}(1)V^{\prime\prime\prime}(1)}{3V^{\prime\prime}(1)^{2}},\]1 \[W^{\prime\prime}(1)=\frac{V^{\prime\prime}(1)U^{\prime\prime\prime}(1)-U^{ \prime\prime}(1)V^{\prime\prime\prime}(1)}{3V^{\prime\prime}(1)^{2}},\]2 \[W^{\prime\prime}(1)=\frac{V^{\prime\prime}(1)U^{\prime\prime\prime}(1)-U^{ \prime\prime}(1)V^{\prime\prime\prime}(1)}{3V^{\prime\prime}(1)^{2}},\]3 \begin{table}
\begin{tabular}{c c c c c c c} \hline \hline \multicolumn{6}{c}{**c = 5**} \\ \hline \(\lambda\) & \multicolumn{3}{c}{\(\lambda=\textbf{0.5}\)} & \multicolumn{3}{c}{\(\lambda=\textbf{5.5}\)} \\ \hline  & **Exact** & **Approx. 1** & **PE 1** & **Exact** & **Approx. 1** & **PE 1** \\ \hline \(p_{0}\) & 0.7519 & 0.7265 & 0.0338 & 0.1077 & 0.2349 & 1.1815 \\ \(p_{1}\) & 0.1876 & 0.1794 & 0.0441 & 0.1561 & 0.2147 & 0.3748 \\ \(p_{2}\) & 0.0465 & 0.0653 & 0.4049 & 0.1776 & 0.1438 & 0.1906 \\ \(p_{3}\) & 0.0112 & 0.0206 & 0.8346 & 0.1799 & 0.1023 & 0.4316 \\ \(p_{4}\) & 0.0024 & 0.0065 & 1.6986 & 0.1572 & 0.0727 & 0.5373 \\ \hline Average & \multicolumn{3}{c}{0.6032} & \multicolumn{3}{c}{0.5432} \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Initial probability vectors comparison. The nonlinear maximization problem to solve in this case is the following:  
\[ \begin{array}{ll}\text{max}&Z=-\sum_{i=0}^{\infty}p_{i}\ln p_{i}\\ \text{s.t.}&\sum_{n=0}^{c-1}a_{n}p_{n}=1+\frac{\alpha_{1}}{\beta_{1}}\\ (EP2)&\sum_{i=0}^{\infty}i^{2}p_{i}=E(X^{2})\\ &p_{i}\geq 0,\text{ for all }\;i.\end{array}  \tag{15}\]  
Similarly to the case where we only used the first moment, we use the classical method of Lagrange. The following system of nonlinear equations, where the unknowns are the Lagrange multipliers \((\lambda_{1},\lambda_{2})\) is obtained:  
\[e^{a_{0}\lambda_{1}}+e^{a_{1}\lambda_{1}+\lambda_{2}}+e^{a\lambda _{1}}\sum_{k=2}^{c-1}e^{k^{2}\lambda_{2}}+\sum_{k=\epsilon}^{\infty}e^{k^{2} \lambda_{2}}-e = 0\] \[e^{a_{1}\lambda_{1}+\lambda_{2}}+e^{a\lambda_{1}}\sum_{k=2}^{c-1 }k^{2}e^{k^{2}\lambda_{2}}+\sum_{k=\epsilon}^{\infty}k^{2}e^{k^{2}\lambda_{2} }-eE(X^{2}) = 0\]  
This system can be solved numerically. Once we have the values of \((\lambda_{1},\lambda_{2})\), we replace these values in the following formula to obtain the probabilities \(p_{k}\):  
\[p_{k}=e^{-1}e^{a_{k}\lambda_{1}}e^{k^{2}\lambda_{2}},\quad k=0,1,2,\cdots. \tag{17}\]  
**Example 2**.