## 3 Proposed Analog RF Beamforming
### Source Analog Precoder  
Multi-linear singular value decomposition (SVD) can be used to derive the common RF beamformer at the source that enables transmission of data streams through any selected relay node. The tensor representation of channel matrices from source to relay nodes is given as  
\[\mathbf{H}_{t}=[\mathbf{H}_{1}\sqcup_{3}\ldots\sqcup_{3}\mathbf{H}_{K}]\in\mathbb{C}^{N_{ rel}\times N_{t}\times K}, \tag{18}\]  
where \(\mathbf{H}_{1},\;\mathbf{H}_{2},\ldots\mathbf{H}_{K}\) are the channel matrices from the source to \(K\) relay nodes. Multi-linear SVD of \(\mathbf{H}_{t}\) is expressed as  
\[\mathbf{H}_{t}=\mathbf{S}\times_{1}\mathbf{X}_{(1)}\times_{2}\mathbf{X}_{(2)}\times_{3}\mathbf{X }_{(3)}, \tag{19}\]  
where \(\mathbf{S}\in\mathbb{C}^{N_{rel}\times N_{t}\times K}\) is a core tensor, and \(\mathbf{X}_{(1)}\in\mathbb{C}^{N_{rel}\times N_{rel}},\mathbf{X}_{(2)}\in\mathbb{C}^{N _{t}\times N_{t}}\) and \(\mathbf{X}_{(3)}\in\mathbb{C}^{K\times K}\) are unitary matrices. It is worth highlighting that \(\mathbf{X}_{(2)}\in\mathbb{C}^{N_{t}\times N_{t}}\) contains orthonormal bases for the column space spanned by \(\big{[}\mathbf{H}_{1}^{T}\ldots\mathbf{H}_{K}^{T}\big{]}\in\mathbb{C}^{N_{t}\times KN_ {rel}}\). Therefore, the full-complexity beamforming matrix \(\mathbf{F}_{opt}\in\mathbb{C}^{N_{t}\times N_{t}^{RF}}\) consisting of first \(N_{t}^{RF}\) columns of \(\mathbf{X}_{(2)}\) can facilitate in designing the common analog RF precoder at the source. Hence,  
\[\mathbf{F}_{opt}=\mathbf{X}_{(2)}\big{(};1:N_{t}^{RF}\big{)}\in\mathbb{C}^{N_{t}\times N _{t}^{RF}}. \tag{20}\]  
The unconstrained beamforming matrix \(\mathbf{F}_{opt}\) in (20) is not favorable due to the absence of element-wise constant amplitude constraint. To resolve this issue, the optimization problem that minimizes the reconstruction loss between \(\mathbf{F}_{opt}\) and \(\mathbf{V}_{RF}\), where \(\mathbf{V}_{RF}\) is the common analog RF beamformer at the source with the element-wise constant modulus constraint, is formulated. In an attempt to minimize the reconstruction loss between the above-mentioned beamforming matrices, the solution of the following error minimization problem leads to the required phase-shift values for designing the source analog beamformer \(\mathbf{V}_{RF}\). Therefore,  
\[\min_{\mathbf{V}_{RF}}\left\|\mathbf{F}_{opt}-\mathbf{V}_{RF}\right\|_{F}^{2}=tr\Big{\{} \big{(}\mathbf{F}_{opt}-\mathbf{V}_{RF}\big{)}\big{(}\mathbf{F}_{opt}-\mathbf{V}_{RF}\big{)}^ {H}\Big{\}}\]  
\[s.t.\;\|\mathbf{V}_{RF}\mathbf{V}_{BB,k}\|_{F}^{2}\leq P_{s},\;|\mathbf{V}_{RF}(x,y)|=\frac {1}{\sqrt{N_{t}}},\;\forall\;x,y, \tag{21}\]  
where \(P_{s}\) is the transmitted power at the source. From the above formulation, it is possible to decompose the cost function in (21) into its components as  
\[f=\sum_{i=1}^{N_{t}^{RF}}\big{(}\mathbf{F}_{opt}(;i)-\mathbf{V}_{RF}(;i) \big{)}\big{(}\mathbf{F}_{opt}(;i)-\mathbf{V}_{RF}(;i)\big{)}^{H}\] \[=f_{1}+\ldots+f_{N_{t}^{RF}}, \tag{22}\]where \(\textbf{F}_{opt}(\cdot;i)\) and \(V_{RF}(\cdot;i)\) represent the \(i\)th column of these matrices. Therefore, the component functions in (22) can be written as  
\[ \begin{array}{c}f_{1}=\big{(}\textbf{F}_{opt}(\cdot;1)-\textbf{V}_{RF}(\cdot,1)\big{)}\big{(}\textbf{F}_{opt}(\cdot;1)-\textbf{V}_{RF}(\cdot;1)\big{)}^{H }\\ \vdots\\ f_{N_{t}^{RF}}=\big{(}\textbf{F}_{opt}(\cdot;N_{t}^{RF})-\textbf{V}_{RF}(\cdot ;N_{t}^{RF})\big{)}\big{(}\textbf{F}_{opt}(\cdot;N_{t}^{RF})-\textbf{V}_{RF}( \cdot;N_{t}^{RF})\big{)}^{H}\end{array} , \tag{23}\]  
It is obvious from (22) that phase-shift values for designing the beamforming vectors in \(\textbf{V}_{RF}\) can be obtained by minimizing each component function independently. The general representation of \(\textbf{F}_{opt}(\cdot;i)\) and \(\textbf{V}_{RF}(\cdot;i)\), for evaluating the required phase-shift values is given as  
\[\textbf{F}_{opt}(\cdot;i)= \begin{bmatrix}r_{1}e^{i\theta_{1i}}\\ r_{2}e^{i\theta_{2i}}\\ \vdots\\ r_{N_{t}^{RF}}e^{i\theta_{N_{t}}}\end{bmatrix} ,\textbf{V}_{RF}(\cdot;i)=