# **meeting 11/21**
**Advisor: Prof. Chih-Yu Wang \
Presenter: Shao-Heng Chen \
Date: Nov 21, 2023**
<!-- Chih-Yu Wang -->
<!-- Wei-Ho Chung -->
## **Training results**
green line: ```Nk = 4```, gray line: ```Nk = 1```


## **Channel model**
### **General Communication Systems**
- The $\mathbf{H}_1 \in \mathbb{C}^{N_s \times N_t}, \hat{\mathbf{h}}_{k, 2} \in \mathbb{C}^{1 \times N_s}$ and $\hat{\mathbf{h}}_{k, 3} \in \mathbb{C}^{1 \times N_t}$ are modeled as
$$
\begin{align*}
{\mathbf {H}}_{1} &= \sqrt{\frac{K_{1}}{K_{1} + 1}} \kappa _\mathrm{LoS} \ \textbf{a}_\mathrm{RIS}(\gamma^r, \eta^r)\textbf{a}_\mathrm{BS}(\theta^t)^H + \sqrt{\frac{1}{K_{1} + 1}} \kappa_\mathrm{NLoS} \; \overline{\mathbf {H}}_\mathrm{NLoS}, \\
\hat{\mathbf{h}}_{k, 2} &= \sqrt{\frac{K_{1}}{K_{1} + 1}} \kappa _\mathrm{LoS} \ \textbf{a}_\mathrm{UE}(\theta^r)\textbf{a}_\mathrm{RIS}(\gamma^t, \eta^t)^H + \sqrt{\frac{1}{K_{1} + 1}} \kappa_\mathrm{NLoS} \; \overline{\mathbf {h}}_\mathrm{NLoS}, \\
\hat{\mathbf{h}}_{k, 3} &= \sqrt{\frac{K_{1}}{K_{1} + 1}} \kappa _\mathrm{LoS} \ \textbf{a}_\mathrm{UE}(\theta^r)\textbf{a}_\mathrm{BS}(\theta^t)^H+ \sqrt{\frac{1}{K_{1} + 1}} \kappa_\mathrm{NLoS} \; \overline{\mathbf {h}}_\mathrm{NLoS},
\end{align*}
$$
- where $K_1$ is the Rician factor, and the former and latter terms are line-of-sight (LoS) and non-line-of-sight (NLoS) components
- with $K_1 = 10 dB$
- $\kappa_\mathrm{LoS}$ and $\kappa_\mathrm{LoS}$ are the large-scale fading constant for the LoS channel and NLoS channel, respectively
- with $\kappa_\mathrm{LoS} = \kappa_\mathrm{LoS} = 10^{-0.5} \sim 0.3162$
- $\textbf{a}_{BS}, \textbf{a}_{RIS}$ and $\textbf{a}_{UE}$ are the steering vectors at the BS, RIS, and UE, respectively
- the values of $AoD$ and $AoA$ are randomly generated between $0$ and $2\pi$
- $\theta^t$ and $\theta^r$ denote the angles of departure $(AoD)$ at the BS and angles of arrival $(AoA)$ at the UE
- $\gamma^t$ and $\gamma^r$ are the azimuth $AoD$ and $AoA$ at the RIS
- $\eta^t$ and $\eta^r$ are the elevation $AoD$ and $AoA$ at the RIS
- $\overline{\mathbf{H}}_\mathrm{NLoS}$ and $\overline{\mathbf {h}}_\mathrm{NLoS}$ are the small-scale fading modeled by complex Gaussian with zero mean and unit variance $\sim \mathcal{CN}(0, 1)$
## **Problem formulations**
### **Max-min downlink rate**
- The objective is to maximize the worst case downlink achievable data rate
$$
\begin{align*}
\max\limits_{\mathbf{\Phi}} \;\; &\min\limits_{\Delta\mathbf{h}_{k, 2}, \; \Delta\mathbf{h}_{k, 3}, \; \varphi_i', \; \beta(\varphi_i)} \;\;\;\;\; R \\
\textrm {s.t.} \;\;
& R \geq 0, \\
& R_{k} \geq R_{min}, \forall k = 1, \ldots, N_k, \\
& tr\{ \mathbf{F}\mathbf{F}^{H} \} \leq P_{t}, \\
& \| \phi_i \|_2^2 = \beta(\varphi_i) = (1 - \beta_{min}) \cdot (\frac{\sin(\varphi_i - \mu) + 1}{2})^\kappa + \beta_{min}, \; \beta_{min} \geq 0, \; \mu\geq 0, \;\; \forall i = 1, \ldots, N_s, \\
& \varphi_i = \hat{\varphi_i} + \varphi_i' \ , \; \varphi_i \in [0, 2\pi), \;\; \forall i = 1, \ldots, N_s, \\
& \hat{\varphi_i} \in \mathcal{A} = \{ e^{(j\frac{ \; 2\pi n \;}{2^{bits \;}})} \}_{n = 0}^{ 2^{bits - 1}}, \; f(\varphi_i'(\mu, \kappa)) = \frac{\;e^{\kappa \cos(\varphi_i' - \mu)}\;\;\;}{\;2\pi I_0(\kappa)\;}, \;\forall i = 1, \ldots, N_s, \\
& \| \Delta\mathbf{h}_{k, 2} \|_2 \leq \psi, \; \forall k = 1, \ldots, N_k, \\
& \| \Delta\mathbf{h}_{k, 3} \|_2 \leq \psi, \; \forall k = 1, \ldots, N_k.
\end{align*}
$$
- the variable $R_{min}$ is the **lower bound** of our objective function
- $R_k$ represents the downlink achievable rate of the $k$-th user
- The above received signal model can be further written as
$$
\begin{align*}
y_{k} = (\mathbf{h}_{k,2} \mathbf{\Phi} \mathbf{H}_{1} + \mathbf{h}_{k, 3}) \mathbf{f}_{k}x_{k} + \sum\limits_{j, \ j \neq k}^{N_k} (\mathbf{h}_{k,2} \mathbf{\Phi} \mathbf{H}_{1} + \mathbf{h}_{k, 3}) \mathbf{f}_{j}x_{j} + n_{k},
\end{align*}
$$
- without joint detection of data streams for all users, the second term is treated as cochannel interference
- $\mathbf{h}_{k, 2} \in \mathbb{C}^{1 \times N_s}$ and $\mathbf{h}_{k, 3} \in \mathbb{C}^{1 \times N_t}$ are the RIS-UE channel and BS-UE channel, respectively
- $\mathbf{H}_{1} \in \mathbb{C}^{N_s \times N_t}$ is the BS-RIS channel and $\mathbf{\Phi} \in \mathbb{C}^{N_s \times N_s}$ is the RIS matrix
- $\mathbf{f}_k \in \mathbb{C}^{N_t \times 1}$ is the $k$-th column vector of the beamforming matrix $\mathbf{F} \in \mathbb{C}^{N_t \times N_k}$
- The SINR at the $k$-th user is then given by
$$
\begin{align*}
\rho_{k} = \frac{| (\mathbf{h}_{k,2} \mathbf{\Phi H}_{1} + \mathbf{h}_{k, 3}) \mathbf{f}_{k} |^{2} }{ \sum\limits_{j, \ j \neq k}^{N_k} | (\mathbf {h}_{k,2} \mathbf{\Phi H}_{1} + \mathbf{h}_{k, 3}) \mathbf{f}_{j} |^{2} + \sigma_{n}^{2} }.
\end{align*}
$$
- The resulted downlink rate for the $k$-users is written as
$$
\begin{align*}
R_k = \log_2(1 + \rho_{k}).
\end{align*}
$$
#### **downlink rate reward**

### **Sum-Rate Maximization**
- The goal is to maximize the sum downlink rate (spectral efficiency) in the system, which is given by
$$
\begin{align*}
\sum\limits_{k = 1}^{N_k} R_{k} = \sum\limits_{k = 1}^{N_k} \log_2(1 + \rho_{k}) = \sum\limits_{k = 1}^{N_k} \log_2(1 + \frac{| (\mathbf{h}_{k,2} \mathbf{\Phi H}_{1} + \mathbf{h}_{k, 3}) \mathbf{f}_{k} |^{2} }{ \sum\limits_{j, \ j \neq k}^{N_k} | (\mathbf {h}_{k,2} \mathbf{\Phi H}_{1} + \mathbf{h}_{k, 3}) \mathbf{f}_{j} |^{2} + \sigma_{n}^{2} }).
\end{align*}
$$
- The optimization problem is expressed as:
$$
\begin{align*}
\max\limits_{\mathbf{\Phi}} \;\; & \; \sum\limits_{k = 1}^{N_k} R_{k} \\
\textrm {s.t.} \;\;
& tr\{ \mathbf{F}\mathbf{F}^{H} \} \leq P_{t}, \\
& \| \phi_i \|_2^2 = \beta(\varphi_i) = (1 - \beta_{min}) \cdot (\frac{\sin(\varphi_i - \mu) + 1}{2})^\kappa + \beta_{min}, \; \beta_{min} \geq 0, \; \mu\geq 0, \;\; \forall i = 1, \ldots, N_s, \\
& \varphi_i = \hat{\varphi_i} + \varphi_i' \ , \; \varphi_i \in [0, 2\pi), \;\; \forall i = 1, \ldots, N_s, \\
& \hat{\varphi_i} \in \mathcal{A} = \{ e^{(j\frac{ \; 2\pi n \;}{2^{bits \;}})} \}_{n = 0}^{ 2^{bits - 1}}, \; f(\varphi_i'(\mu, \kappa)) = \frac{\;e^{\kappa \cos(\varphi_i' - \mu)}\;\;\;}{\;2\pi I_0(\kappa)\;}, \;\forall i = 1, \ldots, N_s, \\
& \| \Delta\mathbf{h}_{k, 2} \|_2 \leq \psi, \; \forall k = 1, \ldots, N_k, \\
& \| \Delta\mathbf{h}_{k, 3} \|_2 \leq \psi, \; \forall k = 1, \ldots, N_k.
\end{align*}
$$
#### **Sum-Rate reward**
