## 4 Hybrid Beamforming and RIS Phase Shift Matrix Design
### Hybrid Beamforming and RIS Phase Shift Matrix Design Based on Tensor-Train Decomposition
\begin{split}\vec{\Lambda}_{r,q}=\widetilde{\mathfrak{F}}_{r,q}^{(2) }\Big{(}1_{R_{>(2)}}^{T}\bigotimes I_{R_{1}}R_{P,q}\bigotimes I_{R_{1}}^{T} \Big{)}\\ =\Big{[}\widetilde{\mathfrak{F}}_{km,1}(t),\cdots,\widetilde{ \mathfrak{F}}_{km,Q_{\breve{R}}}(t)\Big{]}e\mathbb{C}^{T\times Q_{\breve{R}}} \end{split}  \tag{60}\]  
\[ \begin{split}\vec{\breve{A}}_{T,r}^{H}=\widetilde{\mathfrak{F}}_{T,r }^{H(3)}\Big{(}1_{R_{>(2)}}^{T}\bigotimes I_{R_{1}}R_{T,r}\bigotimes I_{R_{1}}^{T} \Big{)}\\ =\Big{[}\widetilde{\mathfrak{F}}_{P}\big{(}\
u_{r,1}{}^{T}(t) \big{)},\cdots,\widetilde{\mathfrak{F}}_{P}\big{(}\
u_{r,Q_{\breve{R}}}{}^{T}(t) \big{)}\Big{]}\ e\mathbb{C}^{N_{T}\times Q_{\breve{R}}}\end{split}  \tag{61}\]According to the existing tensor form \(\ddot{\mathcal{M}}_{k}\) and tensor form \(\ddot{\mathcal{R}}\), the received signal \(\mathcal{Y}_{k}\) is expressed as:  
\[ \begin{array}{c}\mathcal{Y}_{k}=W_{BB,k}^{H}W_{RF,k}^{H}\cdot\ddot{\mathcal{M} }_{k}\Phi\ddot{\mathcal{R}}\cdot F_{RF}^{T}F_{BB,k}^{T}s_{k}\\ +\sum\limits_{j\
eq k}^{K}W_{BB,k}^{H}W_{RF,k}^{H}\cdot\ddot{\mathcal{M}}_{k} \Phi\ddot{\mathcal{R}}\cdot W_{BB,k}^{H}W_{RF,k}^{H}F_{RF}^{T}F_{BB,j}^{T}s_{j} +\mathcal{N}_{k}\\ =\mathcal{T};W_{BB,k}^{H}W_{RF,k}^{H}\cdot\tilde{\mathcal{A}}_{R,km},\tilde{ \mathcal{A}}_{km,q},\tilde{\mathcal{A}}_{p,km}^{H},\Phi\mathcal{T};\tilde{ \mathcal{A}}_{p,r},\tilde{\mathcal{A}}_{r,q},\tilde{\mathcal{A}}_{T,r}^{H},F_{ RF}^{T}F_{BB,k}^{T}s_{k}+\\ \sum\limits_{j\
eq k}^{K}\mathcal{T};W_{BB,k}^{H}W_{RF,k}^{H},\tilde{\mathcal{ A}}_{k,km},\tilde{\mathcal{A}}_{km,q},\tilde{\mathcal{A}}_{p,km}^{H}, \Phi\mathcal{T};\tilde{\mathcal{A}}_{p,r},\tilde{\mathcal{A}}_{r,q},\tilde{ \mathcal{A}}_{T,r}^{H},F_{RF}^{T}F_{BB,j}^{T}s_{j}+\mathcal{N}_{k}\end{array}  \tag{62}\]  
where \(\mathcal{Y}_{k}\in\mathbb{C}^{\mathbb{N}_{s}\times kN_{s,k}\times T}\) is the received signal tensor of the \(k\)th terrestrial user, and \(\mathcal{N}_{k}\in\mathbb{C}^{\mathbb{N}_{s}\times kN_{s,k}\times T}\) is the noise tensor of the \(k\)th terrestrial user. By utilizing RIS-assisted millimeter-wave massive MIMO of UAV communication, the spectral efficiency \(R_{k}\) of hybrid beamforming can be expressed as:  
\[R_{k}=\sum\limits_{k=1}^{K}\log_{2}\left|I_{kN_{k}}+\frac{p^{{}^{ \prime}}}{kN_{s}}R_{kn}^{-1}W_{BB,k}^{H}W_{RF,k}^{H}\ddot{M}_{k}\Phi\ddot{R}_ {k}F_{RF}F_{BB,k}\left(W_{BB,k}^{H}W_{RF,k}^{H}\ddot{M}_{k}\Phi\ddot{R}_{k}F_ {RF}F_{BB,k}\right)^{H}\right| \tag{63}\]  
where \(R_{kn}=\sigma_{n}^{2}W_{BB,k}^{H}W_{RF,k}^{H}W_{RF,k}W_{BB,k}\) denotes the \(k\) noise covariance matrix at the received user. \(p^{{}^{\prime}}\) denotes the transmit power. So, the maximum spectral efficiency problem can be expressed as the following equation:  
\[ \begin{array}{c}\underset{F_{RF},F_{BB,k}}{\max}W_{RF,k},W_{BB,k}\Phi R_{k} \\ s.t.\quad\left\|F_{RF}F_{BB,k}\right\|_{F}^{2}=kN_{s,k}\\ \theta_{t}\epsilon\mathcal{T},\forall t\end{array}  \tag{64}\]  
This is a non-convex NP-hard problem. It decomposes the original optimization problem into two independent optimization sub-problems, namely \(\Phi\) the optimization problem and \((F_{RF},F_{BB,k},W_{RF,k}W_{BB,k})\) of the optimization problem. Setting up the hybrid channel \(H_{kc}=\ddot{M}_{k}\Phi\ddot{R}_{k}\), next it is necessary to figure out an optimized solution of the RIS phase shift matrix \(\Phi\).