# Entropy-Based Algorithm for Supply-Chain Complexity Assessment
## 2 Basic Definitions
For the process of sequentially computing of the relative entropy variation (REV), for any fixed value \(\varepsilon\), there exists the layer number s* for which it holds: \(|REV(s*)|<\varepsilon\). **Proof. ** For simplicity, we assume that the entropy of any layer depends only upon the information of the neighbor layers, that is,  
\[H^{*}(L_{s}|L_{s+1},L_{s+2},\ldots L_{k})=H^{*}(L_{s}|L_{s+1}),\quad s=0,1,2, \ldots,k-1\]  
Let us exploit the following Formula for the entropy of combined system (see [21]):  
\[p_{s}(u,f)=N_{s}(u,f)/R_{s}(u). \tag{13}\]0  
Applying it for the entropy \(H^{*}(C_{s})\) of cut \(C_{s}\). We have  
\[ \begin{array}{l}H^{*}(C_{s})=H^{*}(L_{s},L_{s-1},L_{s-2},\ldots,L_{0})=\\ =H^{*}(L_{s})+H^{*}(L_{s-1}|L_{s})+H^{*}(L_{s-2}|L_{s-1},L_{s})+\ldots+H^{*}(L _{0}|L_{1},L_{2},\ldots L_{s})=\\ =H^{*}(L_{s})+H^{*}(L_{s-1}|L_{s})+H^{*}(L_{s-2}|L_{s-1})+\ldots+H^{*}(L_{0}| L_{1})\end{array}  \tag{20}\]  
Using the latter Formula for cut \(C_{s-1}\), we obtain  
\[H^{*}(C_{s-1})=H^{*}(L_{s-1})+H^{*}(L_{s-2}|L_{s-1})+H^{*}(L_{s-3}|L_{s-2})+ \ldots+H^{*}(L_{0}|L_{1}) \tag{21}\]From Formulas (20) and (21), we obtain that  
\[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]  
Here \(H^{*}(L_{s-1}|L_{s})\) denotes the conditional entropy of the layer \(s-1\) under the condition that the probabilities and entropy of layer \(s\) are found. Denote, for convenience, \(H(C_{s})=H(s)\) and \(H^{*}(C_{s})=H^{*}(s)\). Using the definition of the weighted entropy and Formula (21), we obtain  
\[H(s)=c(s)H^{*}(s)=c(s)(H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}| L_{s})).\]  
Using the Formula of the conditional entropy, the definitions of events \(A_{i}(s)\), probabilities \(p_{i}(s)\) and matrices \(M^{(2)}(s)\), we can write that  
\[H^{*}(L_{s-1}|L_{s})=-\sum\limits_{i=1}^{N}\left(p(A_{i}(s))\cdot \sum\limits_{j=1}^{N}P\big{(}A_{j}(s-1)|A_{i}(s)\big{)}\cdot\log\!\big{(}A_{j}( s-1)|A_{i}(s)\big{)}\right)\] \[=-\sum\limits_{i=1}^{N}\left(p_{i}(s)\cdot\sum\limits_{j=1}^{N} \hat{p}_{ij}^{(1)}(s-1)\cdot\log\!\big{(}\hat{p}_{ij}^{(1)}(s-1)\big{)}\right)\] \[H^{*}(L_{s-1}|L_{s})=-\sum\limits_{i=1}^{N}\left(p_{i}(s)\cdot \sum\limits_{j=1}^{N}\hat{p}_{ij}^{(1)}(s-1)\cdot\log\!\big{(}\hat{p}^{(1)}(s- 1)\big{)}\right) \tag{23}\]  
Using Formula (22) we can write  
\[H(s)=c(s)\left(H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})-\sum \limits_{i=1}^{N}\left(p_{i}(s)\cdot\sum\limits_{j=1}^{N}\hat{p}_{ij}^{(1)}(s -1)\cdot\log\!\big{(}\hat{p}_{ij}^{(1)}(s-1)\big{)}\right)\right) \tag{24}\] \[s=1,2,\ldots\] \[H(s-1)-H(s)=\] \[=H(s-1)-c(s)\left(H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})- \sum\limits_{i=1}^{N}\left(p_{i}(s)\cdot\sum\limits_{j=1}^{N}\hat{p}_{ij}^{(1 )}(s-1)\cdot\log\!\big{(}\hat{p}_{ij}^{(1)}(s-1)\big{)}\right)\right)=\] \[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]0  
We obtain that  
\[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]1  
\[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]2  
Since the following relations are valid,  
\[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]3 \[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]4 \[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]5 \[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]6  
we obtain that  
\[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]7Therefore, for any accuracy level \(\varepsilon\), we can select the number of a cut \(s_{1}\) for which  
\[H^{*}(C_{s})=H^{*}(C_{s-1})+H^{*}(L_{s})-H^{*}(L_{s-1})+H^{*}(L_{s-1}|L_{s}) \tag{22}\]8  
The truncated part of the SC containing only layers of the cut \((s_{1}-1)\) possesses the required level of the entropy variation. The theorem is proved.