# Data-Driven Formation Control for Multi-Vehicle Systems Induced by Leader Motion
## 4 Sampled-Data Leader Motion Mechanism Design  
In this section, we exploit and extend the recent results of [19] to multi-agent systems following the description of Section 2. System (5) under (15) and first agent as the driving node becomes:  
\[\dot{\mathbf{r}}(t) =\mathbf{v}(t), \tag{21}\] \[\dot{\mathbf{v}}(t) =\text{diag}\bigg{(}\frac{1}{M_{i}}\bigg{)}\big{(}\mathbf{u}^{ \text{c}}(t)+\mathbf{e}_{1}M_{1}\bar{u}(t)\big{)},\]  
where \(\mathbf{u}^{\text{c}}(t)\) is the stacked vector of inputs, following either protocol (8) or (12). We consider that the leader keeps the input constant between two samples, and hence, \(u(t)\) is a piecewise constant function, as in (Section 3 of [27]). Define the box function as:  
\[\pi_{i}(t)=H(t-i\Delta)-H(t-(i+1)\Delta), \tag{22}\]  
where \(H(\tau)\) is the step function at time \(\tau\), so that the input injected by the leader into the network in Equation (21) is:  
\[\bar{u}(t)=\sum_{i}u_{i}\pi_{i}(t), \tag{23}\]  
where the discrete values \(u_{i}\) are set by node 1 as a function of its past evolution, as in (20). Considering the system under leader motion induced by (22), the evolution of system (21) takes the form:  
\[ \begin{split}\begin{bmatrix}\mathbf{r}(t)\\ \mathbf{v}(t)\end{bmatrix}&=e^{-\Gamma t}\begin{bmatrix}\mathbf{r}(0)\\ \mathbf{v}(0)\end{bmatrix}+\int_{0}^{t}e^{-\Gamma(t-\tau)}\begin{bmatrix} \mathbf{e}_{1}\\ \mathbf{0}\end{bmatrix}\sum_{i}u_{i}\pi_{i}(\tau)d\tau,\\ &=e^{-\Gamma t}\begin{bmatrix}\mathbf{r}(0)\\ \mathbf{v}(0)\end{bmatrix}+\sum_{i:(i+1)\Delta<t}u_{i}\int_{0}^{t}e^{-\Gamma(t -\tau)}\begin{bmatrix}\mathbf{e}_{1}\\ \mathbf{0}\end{bmatrix}\pi_{i}(\tau)d\tau,\end{split}  \tag{24}\]  
when dealing with protocol (8), or analogously using matrix \(\Gamma_{2}\) when the protocol adopted is (12). The system motion sampled at \(t=k\Delta\) allows us to compute \(r_{1_{\ell}}=r_{1}(\ell\Delta)\) as required in (19); the whole sampled system motion (24) provides:  
\[ \begin{cases}\mathbf{r}((k+1)\Delta)=\Phi_{r}(\Delta)\mathbf{r}(k\Delta)+ \Phi_{r\tau}(\Delta)\mathbf{v}(k\Delta)+\Psi_{r}(\Delta)u_{k},\\ \mathbf{v}((k+1)\Delta)=\Phi_{vr}(\Delta)\mathbf{r}(k\Delta)+\Phi_{v}(\Delta) \mathbf{v}(k\Delta)+\Psi_{v}(\Delta)u_{k},\\ \mathbf{r}(0)=\mathbf{r}_{0},\\ \mathbf{v}(0)=\mathbf{v}_{0},\end{cases}  \tag{25}\]where matrices \(\Phi_{r}(\Delta),\Phi_{r\upsilon}(\Delta),\Phi_{\upsilon r}(\Delta),\Phi_{v}( \Delta)\in\mathbb{R}^{N\times N}\), and \(\Psi_{r}(\Delta),\Psi_{v}(\Delta)\in\mathbb{R}^{N}\) are the submatrices obtained by:  
\[ \begin{bmatrix}\Phi_{r}(\Delta)&\[PERSON]_{r\upsilon}(\Delta)\\ \[PERSON]_{\upsilon r}(\Delta)&\Phi_{v}(\Delta)\end{bmatrix} =\Phi(\Delta)=e^{ \Gamma\Delta},\qquad \begin{bmatrix}\Psi_{r}(\Delta)\\ \[PERSON]_{v}(\Delta)\end{bmatrix} =\Psi(\Delta)=\int_{0}^{\Delta}\biggl{(}e^{- \Gamma_{\xi}} \begin{bmatrix}\mathbf{e}_{1}\\ \mathbf{0}\end{bmatrix} \biggr{)}d\varsigma, \tag{26}\]  
when (8) is used, or analogously, using matrix \(\Gamma_{2}\) when the protocol adopted is (12). In the following, when referring to the analog of Equation (26) when adopting (12), we use the same notation adding the index \(2\), namely \(\Phi_{r}^{(2)}(\Delta),\Phi_{r\upsilon}^{(2)}(\Delta),\Psi_{r}^{(2)}(\Delta)\). In the following, for ease of notation, we do not explicitly write the sampling time \(\Delta\). Matrices \(\Phi\), \(\Psi\) in (26) have strong relations with the eigenstructure of \(\mathcal{L}\). Indeed, it holds that:  
**Proposition 1**. : _Let \(\mathbf{p}\in\mathbb{R}^{N}\) be a vector in the left null space of \(\mathcal{L}\), namely \(\mathbf{p}^{\top}\mathcal{L}=\mathbf{0}_{N}^{\top}\). Under Assumption A1 and Assumption A2, it holds:_  
\[ \begin{array}{llll}\Phi_{r}\mathbf{1}=\mathbf{1},&\Phi_{r\upsilon}\mathbf{1 }=\Delta\mathbf{1},&\mathbf{p}^{\top}\Phi_{r}=\mathbf{p}^{\top},&\mathbf{p}^{ \top}\Phi_{r\upsilon}=\Delta\mathbf{p}^{\top},\\ \Phi_{\upsilon r}\mathbf{1}=\mathbf{0},&\Phi_{v}\mathbf{1}=\mathbf{0},&\mathbf{ p}^{\top}\Phi_{vr}=\mathbf{0},&\mathbf{p}^{\top}\Phi_{v}=\mathbf{p}^{\top}. \end{array}  \tag{27}\]  
Proof.