## 4 Numerical Simulation  
A simulation example is listed in the present section to demonstrate the results of the theoretical analysis conducted in this study. The simulation was conducted in MATLAB R2021b on a workstation equipped with an Intel Core i5-12500K CPU, 16 GB RAM, and an NVIDIA RTX 3050 GPU. **Example 1**. : _Figure 1 shows the communication topology denoting that a multi-agent system with 10 agents was divided into two groups, \(\mathcal{V}_{1}=\{1,2,3,4\}\) and \(\mathcal{V}_{2}=\{5,6,7,8,9,10\}\); let \(f(x_{i}(t))=[0.5 sin(x_{2i}(t)),0.2 cos(x_{3i}(t)),2 sin(2x_{i1}(t))]^{\text{T}} \in R^{3}\). Thus, the nonlinear dynamics of the agents are presented as follows:_  
\[ \begin{cases}\dot{x}_{i1}(t)=0.5 sin(x_{i2}(t))+u_{i1}(t)+\sigma\omega_{i1}(t),\\ \dot{x}_{i2}(t)=0.2 cos(x_{i3}(t))+u_{i2}(t)+\sigma\omega_{i2}(t),\\ \dot{x}_{i3}(t)=2 sin(2x_{i1}(t))+u_{i3}(t)+\sigma\omega_{i3}(t),\end{cases} \]  
_where \(x_{i}(t)=(x_{i1}(t),x_{2}(t),x_{3}(t))^{\text{T}}\), \(u_{i}(t)=(u_{i1}(t),u_{2}(t),u_{i3}(t))^{\text{T}}\), and \(\omega_{i}(t)=(\omega_{i1}(t),\\ \omega_{i2}(t),\omega_{i3}(t))^{\text{T}}\). The constant matrices of the system are given as_  
\[Q=\left[ \begin{array}{cccc}-0.4&0&0&0\\ 0&-1&0&0\\ 0&0&-1.4&0\\ 0&0&0&0\end{array} \right];K=\left[ \begin{array}{cccc}-0.6&0&0&0\\ 0&1&0&0\\ 0&0&1.2&0\end{array} \right];\]  
\[C=\left[ \begin{array}{cccc}1.4&0&0\\ 0&0.8&0\end{array} \right].\]The initial states of agents (\(x_{ij}(0)\), \(j=1,2,3\)) are randomly selected within the range of \([-10,10]\). The prescribed time is \(T=3\) s.  
For the case of consensus with exogenous disturbance, i.e., \(\sigma=1\), we set \(k_{1}=3.4\), \(k_{2}=0.8\), and \(h=3\). The initial states of disturbances (\(d_{ij}(0)\), \(j=1,2,3,4\)) are randomly selected within the range of \([-10,10]\). According to the design of \(C\), one has \(\lambda_{min}(CC^{\mathrm{T}})=0.64\) and \(\lambda_{max}(CC^{\mathrm{T}})=1.96\). Thus, we choose \(\alpha=2.97\). The conditions of Theorem 1 are all satisfied. Figures 2 and 3 compare the states of two groups of observers with and without prescribed-time control, respectively. Figure 2 shows that bipartite output consensus can be achieved at T = 3 s under the prescribed-time control protocol (10). Figure 3 indicates that without prescribed-time control (\(u_{i}(t)=-\alpha\sum_{j\in N_{i}}a_{ij}(\widehat{x}_{i}(t)-s_{ij}\widehat{x}_ {j}(t))-\widehat{\omega}_{i}(t)\)), bipartite output consensus is achieved at T = 8 s. Figure 4a describes the error between the output states (\(y_{i}(t)\)) and their observers (\(\hat{g}_{i}(t)\)), i.e., \(\widehat{e}_{i}(t)=\parallel\hat{g}_{i}(t)-y_{i}(t)\parallel\), \(i=1,2,\cdots,10\). Figure 4b describes the error between the disturbances (\(\omega_{i}(t)\)) and their observers \(\widehat{\omega}_{i}(t)\), i.e., \(\varepsilon_{i}(t)=\parallel\widehat{\omega}_{i}(t)-\omega_{i}(t)\parallel\), \(i=1,2,\cdots,10\). Figure 4c describes the error of bipartite output consensus as \(E(t)=\sum_{j=2}^{n}\parallel\widehat{y}_{1}(t)-s_{1j}\widehat{y}_{j}(t)\parallel\). Figure 4 indicates that two types of observers can converge to the actual output state and achieve bipartite output consensus at a prescribed time of T = 3 s. Figure 5 illustrates that the control inputs (\(u_{i}(t)\), \(i=1,2,\cdots,10\)) are relatively large in the beginning; however, \(u_{i}(t)\) can converge to 0 at T = 3 s.  
Therefore, the prescribed-time bipartite output consensus of nonlinear multi-agent systems with exogenous disturbances can be achieved under the conditions of Theorem 1. **Remark 4**. : _As shown in Figure 3, the multi-agent system without prescribed-time control needs 8 s to achieve consensus. Similarly, the multi-agent systems discussed in [38], with four followers still, need 15 s to achieve consensus. Therefore, the prescribed-time control protocols provide a better solution to ensure that the multi-agent system achieves consensus within a shorter prescribed time (T)._  
**Remark 5**.