# XOR Binary Gravitational Search Algorithm with Repository: Industry 4.0 Applications
## 4 Theoretical Analysis of the Proposed XOR Binary Gravitational Algorithm with Repository
### Full Statistical Analysis of the Proposed Method
: _In the case when \(x(t)=x_{rb}\), \(\forall\text{t}>0\) the velocity vector \(v(t)\) will never be larger than \(p_{i}^{t}v(0)\), where \(v(0)\) is the initial value of the velocity._  
_In the case when \(x(t)=x_{rb}\), from (17), it follows that_  
\[P\left(v\left(t\right)\right)=0.5+0.5\text{tan}h\left(0.5v\left(t\right)\right) \tag{20}\]3Considering (18), the following equation is obtained for \(v(t)\)_  
\[P\left(v\left(t\right)\right)=0.5+0.5\text{tan}h\left(0.5v\left(t\right)\right) \tag{20}\]4  
_Hence, \(p_{i}^{t}v(0)\) is an upper bound for \(v(t)\)._  
From Lemma 5, it is concluded that in the case when \(x(t)=x_{rb}\), the acceleration term is non-positive acting in the direction of decreasing the probability of change. However, the impact of \(p_{i}^{t}v(0)\) depends on the sign of \(v(0)\). In the case when \(x(t)\
eq x_{rb}\), \(\forall t>0\) the velocity vector \(v(t)\) will never be smaller than \(p_{i}^{t}v(0)\). In the case when \(x(t)\
eq x_{rb}\), from (17), it follows that  
\[P\left(v\left(t\right)\right)=0.5+0.5\text{tan}h\left(0.5v\left(t\right)\right) \tag{20}\]5  
Considering (18), the following equation is obtained for \(v(t)\)  
\[P\left(v\left(t\right)\right)=0.5+0.5\text{tan}h\left(0.5v\left(t\right)\right) \tag{20}\]6  
Hence, \(p_{i}^{t}v(0)\) is a lower bound for \(v(t)\). From Lemma 6, it is concluded that in the case when \(x(t)\
eq x_{b}\), the acceleration term is non-negative acting in favor of making probability of change in the corresponding bit higher. However, the impact of \(p_{i}^{t}v(0)\) depends on the sign of \(v(0)\). In XOR BGSA, considering sufficiently large number for maximum number of iterations, following properties hold. 1. If \(x(t)=x_{rb}\), \(\exists\)T s.t. \(\forall t>\) T, the probability of change becomes smaller than 0.5: \[P\left(v\left(t\right)\right)=0.5+0.5\text{tan}h\left(0.5v\left(t\right)\right) \tag{20}\]7
2. If \(x(t)\
eq x_{rb}\), \(\exists\)T s.t. \(\forall t>\) T, the probability of change becomes larger than 0.5: \[P\left(v\left(t\right)\right)=0.5+0.5\text{tan}h\left(0.5v\left(t\right)\right) \tag{20}\]8  
In the case when \(p_{i}=1\), from Theorem 1 it follows that when \(x=x_{rb}\), as mentioned earlier in Remark 1, the velocity value grows in negative direction which results in:  
\[P\left(v\left(t\right)\right)=0.5+0.5\text{tan}h\left(0.5v\left(t\right)\right) \tag{20}\]9  
Moreover, in the case when \(p_{i}=1\), from Theorem 1 it follows that when \(x(t)\
eq x_{rb}\), as mentioned earlier in Remark 2, the velocity value grows larger which results in:  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]0  
Hence in the case of \(p_{i}=1\), Theorem 2 holds. When \(0<p_{i}<1\), two cases are considered. The case when \(v(0)=0\) and \(v(0)\
eq 0\). If \(v_{0}=0\), in the case of \(x=x_{rb}\), the velocity term according to (18) is obtained as follows:  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]1  
Hence:  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]2  
In the case of \(x(t)\
eq x_{rb}\), the velocity term according to (13) is obtained as follows:  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]3  
Hence:  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]4  
If \(v(0)\
eq 0\), in the case of \(x(t)=x_{rb}\), considering the fact that  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]5  
If \(v(0)<0\), from (49), it can be seen that \(v\left(t\right)\) is the result of addition of two negative terms resulting in a negative value for \(v\left(t\right)\). However, if \(v(0)>0\), considering the fact \(E\left[r(t)\right]=0.5\), we have:  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]6  
Hence, the time T after which we have \(E[v\left(t\right)]<0\), is obtained from  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]7  
and  
\[a\left(t\right)=-r(t)G(t)M_{rb}D\leq 0 \tag{21}\]8  
Hence, after a sufficiently large value of iterations specified by T, \(v\left(t\right)\) becomes negative and stays negative onwards.