QRIS: A QuaDRiGa-Based Simulation Platform for Reconfigurable Intelligent Surfaces

Reconfigurable Intelligent Surfaces (RISs) are a promising way to improve the performance of wireless networks. However, despite the high interest in the research community, no flexible enough simulation platform allows for studying the performance of wireless communication systems with RIS in complex scenarios. To address this issue, the paper presents an open-source channel simulation platform to study RIS in wireless communication systems. The developed open-source platform extends the QuaDRiGa channel model, which is widely used for the performance evaluation of 5G and Wi-Fi networks with multiple antennas. The paper shows how to use the platform — called QRIS — to evaluate RIS in various frequency conditions, such as indoor/outdoor scenarios and multiple-RIS deployments.


I. INTRODUCTION
Reconfigurable Intelligent Surface (RIS) technology is a promising way to improve the performance of wireless communication systems. RIS is a two-dimensional surface that can be built using artificial electromagnetic metamaterials. RIS consists of periodic arrangements of specially designed sub-wavelength structural elements called Unit Cells (UCs). By tuning each UC, RIS achieves unique electromagnetic properties, such as negative refraction, perfect signal absorption, or anomalous reflection and scattering. So, it is possible to control the process of reflected wave formation. Therefore, RIS can expand the coverage area, increase the channel capacity and mitigate interference in wireless communication systems.
Although multiple testbeds have been developed [1], [2], [3], [4], [5], [6], there is a lack of simulation tools that can be used to evaluate the performance of various RIS-related solutions in various scenarios, as we show in detail in Section II.
The associate editor coordinating the review of this manuscript and approving it for publication was Sotirios Goudos .
In this paper, we address this problem and present QRIS, an open-source RIS simulation platform that eliminates the drawbacks of existing platforms. QRIS is based on the QUAsi Deterministic Radio channel Generator (QuaDRiGa) [7], which already supports many well-approved channel models for various wireless technologies and indoor/outdoor scenarios. Its essential features consider such physical effects as shadowing and accurate modeling of spatial consistency, which is important for scenarios with MIMO. This paper describes QRIS and provides several examples of how it can be used to study networks with multiple RISs and endpoint devices. Specifically, we use the developed RIS model to evaluate its effectiveness in multiple scenarios such as indoor Wi-Fi networks and 5G network systems with various RIS architectures and RIS configuration algorithms. An interested reader can request the platform code through the link https://wireless.iitp.ru/ris-quadriga.
QRIS is a flexible and accurate platform that can be used to evaluate the performance of wireless systems with RISs in various scenarios with any number of RIS, transmitters (Tx), and receivers (Rx). Compared with the existing platforms, which are analyzed in Section II and summarized in Table 1, QRIS has the following advantages.
• QRIS allows using various UC radiation patterns, including realistic ones, obtained from real measurements or comprehensive simulation using CST Microwave Studio [8].
• QRIS includes UCs models that take into account polarization, radiation pattern, Radar-Cross Sections (RCS), and phase shift variations depending on the angle of incidence.
• QRIS is suitable for the evaluation of scenarios with multiple RIS, including multi-hop transmissions.
• QRIS has an accurate channel model based on QuaDRiGa. Consequently, QRIS can be used for a wide frequency range, various RIS positions, and multiple antennas on Tx and Rx for MIMO evaluation.
• QRIS is ready to integrate with system-level simulation platforms such as ns-3 [9] to study cooperation of RIS and widely used technologies such as 5G and Wi-Fi 7, and also those which are under development. The rest of the paper is organized as follows. Section II reviews existing simulation tools, and Section III describes the QuaDRiGa channel generator. Section IV presents a RIS system model and discusses its peculiarities. In Section V, we describe the RIS model and its implementation in the QRIS simulation platform, while Section VI presents our numerical results. Section VII concludes the paper.

II. RELATED WORKS
Numerous simulation tools are already designed to study the performance of RIS in different scenarios. However, most of the tools are devoted to the study of certain effects arising in particular networks with RIS. For example, in paper [10], the authors use the simulation for precoder development in mmWave communication systems with RIS. They explicitly assume that the signal goes from the Tx to the Rx only via RIS, so there is no direct subchannel between the Tx and the Rx, which limits the range of application scenarios.
The paper [11] uses a RIS model that assumes isotropic scattering to explore issues of channel hardening effect in channels with RIS in the SISO system. The authors posited the assumption of uniform distribution of scatterers in front of the RIS, which deviates from the non-ideal conditions observed in real-world scenarios. Furthermore, due to the deterministic nature of the RIS position, employing random matrix modeling for the channels leads to an inadequately calibrated tool.
The paper [12] describes the model of the whole communication system that includes a RIS but assumes free-space propagation. Although the developed models are used to find such a RIS placement that maximizes the signal-tonoise ratio (SNR) on the receiver in particular scenarios, the results cannot be generalized because of the aforementioned assumptions and the limitations of the models.
The authors in [13] propose a free-space path loss model for wireless communications with RIS, based on a detailed study of the RIS's physical properties and electromagnetic nature. The authors use an anechoic chamber to perform experiments and show that the power reflected from a RIS follows a scaling law that depends on many parameters, including the size of the RIS, the mutual distances between the Tx/Rx and the RIS (i.e., near-field vs. far-field conditions). Simulation results validate that the proposed channel model matches well with the experimental measurement. However, in this paper, a single-antenna system is considered. In addition, the influence of the direct channel from Tx to Rx is not considered.
Some of the existing works consider RIS modeling based on physical propagation and Large-scale path loss models using the RCS concept. Paper [16] introduced a path loss model for RIS communications, which utilized RCS as a basis. The received power was linked to the distances between the Tx and Rx to the RIS, the angles within the Tx-RIS-Rx triangle, and the effective area and reflection coefficient of each UC. Furthermore, channel measurements were performed in various scenarios to validate the proposed model under both near-field and far-field conditions.
In [14] authors introduced a path loss model for RIS communications using the physical optics technique. They also explained the presence of multiple UCs on the surface, which individually function as diffuse scatterers but can collaboratively beamform the signal in a specific direction with a defined beamwidth.
Research [15] presented a unification of the contrasting characteristics of a RIS acting as a scatterer and a mirror using the free-space Green function. The outcomes demonstrated that the perception of the RIS can vary based on its dimensions and distance, appearing as a zero, one, or twodimensional entity. Moreover, the radiated power exhibited a dependency on the distance, with a power relation of the fourth, third, or second power, respectively.
Authors of [17] put forward a path loss model that shares similarities with the model presented in [13]. The proposed model aligns with the concept of RCS. In this approach, the maximum RCS of the UC can be estimated by multiplying the gain of the UC with its corresponding area. The simulation demonstrated the effectiveness of the suggested model in capturing the behavior of the reflection coefficient. The model in this paper was designed to account for both normal and oblique incidences, as well as for both TE and TM polarizations.
The most detailed RIS simulation platform is the opensource SimRIS channel model described in paper [18], [19]. SimRIS is a mmWave channel model with a RIS in the presence of scatterers. SimRIS generates with given probabilities LOS and NLOS channels between Tx, Rx, and RIS. This model includes many physical characteristics. Moreover, SimRIS uses an accurate RIS model [21] to simulate realistic gains and response matrices of UCs. However, the SimRIS toolbox supports only a predefined set of RIS locations with vertical orientation. Apart from that, SimRIS is not applicable for modeling scenarios with multiple devices and does not support low frequencies (up to 6 GHz), RISs that have many UCs, or a close location of the Rx or Tx antennas to the RIS. Moreover, the authors consider the relatively simple radiation pattern of the UC. In further works, these authors emphasize that RIS improves overall communication performance if it is deployed near Tx or Rx [20].
RIS models from the cited papers are well suited for specific tasks but are not flexible enough for RIS research in various scenarios with different device placements and used channel frequencies (see Table 1). Thus, it is important to develop a model in a wide frequency range with the possibility of arbitrary RIS placement, its orientation, propagation, and environmental conditions based on well-approved channel models following the requirements of 3GPP. This problem is addressed in this paper, where we design a new QRIS model.

III. QuaDRiGa DESCRIPTION
QuaDRiGa is a 3D stochastic channel model that takes into account how the channel changes with time. It has been developed at Fraunhofer HHI to model MIMO radio channels for various wireless networks such as indoor, outdoor, and satellite in the frequency range of 0.45-100 GHz [22]. The propagation of the signal through the wireless medium is modeled using the interaction of the electromagnetic wave with scatterers.
Each scatterer splits the wave into multiple scattered subrays with different amplitudes and phases [23]. The other parameters of the sub-rays such as delay, angles of departure, and arrival are approximately the same for all sub-rays reflected from the same scatterer, so sub-rays are combined into a cluster. The cluster parameters are determined stochastically, based on statistical distributions extracted from the real channel measurements. While the phase and amplitude of each sub-ray are calculated in the model, taking into account the actual path length.
Apart from the basic channel model, QuaDRiGa contains much auxiliary functionality, antenna models, path-loss models, and built-in tables of parameters for various scenarios [7]. For example, it implements the 3GPP 38.901 model used for the performance evaluation of cellular systems. The accuracy of the model is supported by several measurements campaigns, e.g., 3GPP [22]. Consequently, it is used to evaluate various proposals to 3GPP specifications. Thanks to accurate modeling of spatial consistency, QuaDRiGa can be used in studies related to massive MIMO and multi-cell transmission systems [24]. Also, multiple solutions are proposed to reduce the computational complexity of channel models [25].
All these features make QuaDRiGa attractive to model communication systems with RIS, and we choose QuaDRiGa as the basis for our platform.

IV. QRIS MODEL
We model the wireless channel in the presence of RIS as follows. The emitted signal from Tx arrives at Rx as a superposition of multiple signals passed through the channel with RIS and clusters, see Fig. 1. The wireless channel between Tx and Rx consists of several subchannels, a direct subchannel (Tx, Rx), a subchannel between Tx and RIS (Tx, RIS), and a subchannel between RIS and Rx (RIS, Rx). Each subchannel has multiple clusters. With a given state of each cluster, QuaDRiGa generates the channel impulse response for a pair of Rx and Tx. Through the impulse response, it is possible to get a complex channel gain for a certain central frequency. For devices with multiple antennas, the channel gain coefficient becomes a matrix of coefficients.
Consider the scattering process of the signal on RIS with M UCs. The noise-free signal y received at the Rx in a system with multiple Rx antennas N r ≥ 1 and multiple Tx antennas N t ≥ 1 is expressed in vector form as follows: is the vector of Tx signal, y ∈ C N r ×1 is the Rx signal vector, x i denotes an M -ary phase shift keying/quadrature amplitude modulation (PSK/QAM) symbol transmitted through i-th transmit antenna, H ∈ C N r ×N t is the channel matrix between Tx and Rx, including the direct channel H ∈ C N r ×N t and the RIS-aided channel R T . R ∈ C N r ×M is the channel coefficient matrix between RIS and Rx, and T ∈ C M ×N t is the channel coefficients matrix between Tx and RIS. The matrix H corresponds to the direct connection channel between Tx and Rx.
is a diagonal RIS reflection matrix, where each element, called reflection coefficient, determines signal gains α 1 . . . α M and phase shifts β 1 . . . β M on the corresponding UCs. For a MIMO channel without RIS, the throughput is determined solely by the channel matrix H. A MIMO channel with RIS described by equation (1) depends on the RIS response matrix because it affects channel matrix H.
To maximize the received power of the user, all elements of the RIS shall set their reflection amplitude to one (i.e., α i = 1, ∀i = 1, . . . , M ) for maximum signal reflection.

V. QRIS DESIGN
The original purpose of the QuaDRiGa simulation platform is to study MIMO systems. Consequently, the off-the-box version of QuaDRiGa cannot simulate scenarios involving RIS.
To incorporate RIS-assisted communication into the simulations, we approach the problem by treating each subchannel in (1) as a conventional MIMO channel and employ QuaDRiGa to acquire the respective channel matrix. A RIS can be presented as a combination of receiving and transmitting antenna arrays: for the subchannel (Tx, RIS), the RIS acts as a receiver, and for the subchannel (RIS, Rx), it acts as a transmitter. As QuaDRiGa restricts the creation of an object that is a receiver and a transmitter, at the same time, two copies of the RIS antenna array are placed at the same point in space [26].
By default, we model RIS as an array of UCs, located in a square grid with the step equal to the half-wavelength d = λ 2 [27] forming a planar antenna array, where λ is the incident radiation wavelength. To define the RIS, we set the number M of UCs, the type of UC used in RIS, the position of the center of the RIS, and the direction of the RIS, which is defined by rotation angles of the RIS relative to the coordinate axes as shown in Fig. 3. Tx and Rx locations are also configurable.

A. RADIATION PATTERNS OF VARIOUS UCs
In QRIS, various RISs may have different UCs but all UCs of the same RIS have the same radiation pattern. We have implemented various radiation patterns in QRIS, see Fig. 2. In all the cases, we consider that a UC is an electrically small low-gain element above a conducting ground layer [21].
The first type of UC denoted as COS-UC has a widely used amplitude radiation pattern √ γ cos q [28], where γ = 2(2q + 1) is a normalization factor that analytically ensures that the effective aperture of the UC in the direction of the transmitter is equal to λ 2 2 [21]. After normalization the power radiation pattern G e of a UC is as follows: where θ is the elevation angle of incidence for the sub-ray from the cluster on the UC or the elevation angle of reflecting from the UC. Note that this definition of θ differs from the original QuaDRiGa definition. Consequently, in this paper, the antenna pattern uses function sin() instead of cos().
In COS-UC, 2(2q + 1) = π or q ≈ 0.285 according to [21] because G e π 2 = π. To implement COS-UC, we use the parametric antenna template of QuaDRiGa with the following amplitude radiation pattern: where ϕ denotes the azimuth angle of incidence or reflection, A, B, C, D are the coefficients, which are obtained by equating G e (θ) = E 2 (θ, ϕ) (3) and (4) A three-dimensional graph of the considered radiation pattern is shown in Fig. 2-a. Since a significant part of the experimental RIS studies [29], [30], [31], [32] considers UCs with patch-antennas, the second type of implemented UCs corresponds to them. QuaDRiGa presents a patch-antenna model (Q-UC), the radiation pattern of which is shown in Fig. 2-b. Note that the existing QuaDRiGa patch-antenna model did not imply normalization in terms of the effective aperture of the UC, unlike COS-UC. To fix it, we multiply its radiation pattern by the normalization factor.
To take into account the influence of polarization in the simulation, we copy the corresponding COS-UC or Q-UC radiation pattern to the same point in space rotating them by 90 • and assigning them to interact with a different polarization. However, both COS-UC and Q-UC models do not take into account that the radiation pattern changes when the RIS is reconfigured and the angle of incidence is changed.   To consider this effect, we introduce the third UC model, which corresponds to a patch antenna controlled by a PIN diode. Such a UC is widely used in many RIS prototypes [29], [30], [31], [32].
We model this UC in the CST Microwave Studio [33], so, the third UC model is referred to as CST-UC. Fig. 4 illustrates the structure of the modeled UC. The top layer consists of a square copper patch with thin 35 µm and a PIN diode (SMPA1320-079LF). The middle layer is a dielectric Taconic TLX-8 whose dielectric constant ϵ is 2.55 and loss tangent is 0.0017. The bottom layer is full metal for grounding. The anode of the PIN diode is connected to the edge of the patch and the cathode is connected to the ground via the dielectric. Other dimensions of UC are a = 26 mm, p x = 3.55 mm, h = 1.6 mm.
QuaDRiGa operates with power radiation patterns G e , which are applicable for active antennas. However, CST-UC is a passive element that cannot be described solely by the power radiation pattern. To solve this issue, we use the Radar Cross-Section (RCS) approach, which takes into account the scattering field from CST-UC. To calculate CST-UC bistatic RCS in CST, we radiate a plane wave with linear polarization and with a fixed angle of incidence on a single CST-UC in open space. The RCS depends on the shape, sizes, and material of CST-UC, as well as the polarization and the incident angle of impinging plane wave. To obtain G e of CST-UC for each angle of incidence θ i , ϕ i via its RCS σ , we use expression from work [26]: where θ, ϕ are angles of directions on Rx or each cluster in subchannel (RIS, Rx). Note that such an approach does not take into account the mutual coupling effect. However, in Section V-C, we show that this assumption is acceptable for the considered UC as it gives small errors. Using the described approach, it is possible to model the radiation pattern of any UC in the CST and integrate this pattern into QRIS. The PIN diode of the CST-UC has two states: OFF and ON, which modify its radiation patterns as shown in Fig. 2-c to 2-j for two polarizations. These patterns are non-identical due to the different equivalent schemes of the OFF and ON states, shown in Fig. 5. In the ON state, the equivalent circuit of the PIN diode is a serial connection of a resistor (R = 2 ) and an inductor (L = 0.6 nH), see Fig. 5-a. In the OFF state, the equivalent circuit of the PIN diode is a serial connection of a capacitor (C = 0.3 pF) and an inductor (L = 0.6 nH), see Fig. 5 We consider the UC radiation patterns in vertical and horizontal polarization. The radiation patterns of CST-UC have much in common with the COS-UC and Q-UC patterns in the case of normally impinging wave, see Fig. 2-a and 2-d. However, in contrast to COS-UC and Q-UC, the CST-UC pattern strongly depends on the angle of incidence. More precisely, the direction of the main lobe of the patterns changes as shown in Fig.2-e to 2-j when we change the impingement angles from normal incidence with ϕ i = 90 • , θ i = 90 • to ϕ i = 10 • , θ i = 90 • . QRIS takes into account this difference in the radiation patterns.
To obtain phase shifts of CST-UC in the CST, we consider boundary conditions with similar UCs nearby one. Fig. 6 shows the frequency response of CST-UC operating in the 5.3 GHz band, obtained with simulation in the CST for the normal incidence case. The parameters of the CST-UC are chosen in such a way that the phase shift difference between the two states equals π for 5.3 GHz for the horizontal polarization and normal incidence. At the same time, the phase shift difference is close to zero for the vertical polarization. When the angle of incidence changes, the phase shift difference remains close to zero for the vertical polarization. For horizontal polarization, the phase shift difference changes, which is shown in Fig. 7, because the impedances of CST-UC in the ON and OFF states depend on the angle of incidence [34]. The increase in the angle of incidence causes the deviation of phase shift difference from π between the ON and OFF states.

B. RIS CONFIGURATION
Consider the diagonal matrix from (1), which describes the incident signal amplification and the phase shift of each UC. Being passive, RIS adjusts mainly the phase shift because changing the amplitude requires much power. By tuning the phase shifts of UCs, the RIS induces some phase between reflected signals and makes them interfere either constructively to increase the desired signal strength at the receiver or destructively to mitigate the cochannel interference. Let us describe how to configure the aforementioned UCs.

1) COS-UC AND Q-UC CONFIGURATION
If we consider a COS-UC or Q-UC with radiation patterns independent of the phase shift, a particular configuration of the RIS is determined by because the channel matrices during one experiment are fixed. Consequently, can be chosen to maximize the throughput with given channel matrices. Although QRIS supports customization of the algorithm used for RIS configuration, by default, we assume the perfect knowledge of channel matrices at all devices involved in communications via RISs. Such information can be measured with the techniques from [35] and then distributed to the other devices.
Given the channel matrices used in (1), we use the non-convex MIMO channel capacity maximization algorithm from the paper [36] to obtain the matrix and power distribution matrix on Tx that maximize the ergodic achievable rate for the MIMO system: where I N r is the identity matrix of size N r , ≤ P t is the transmitted signal covariance power matrix, P N is the channel noise power. E[·] denotes the statistical expectation, H is the matrix of the MIMO channel with the RIS from (1).
The algorithm implements the Alternative Optimization technique and maximizes the ergodic achievable rate under the following constraints. First, the total Tx power is limited. Second, the modulus of the complex reflection coefficients shall equal one: α i = 1, i = 1 . . . M . The algorithm iteratively VOLUME 11, 2023 optimizes one UC's phase shift β i , i = 1 . . . M , and the Tx covariance matrix Q at each time, while the other variables are fixed. Each outer iteration consists of two steps. In the first step, given the current Tx covariance matrix Q and N − 1 UCs phase shifts β i , i ̸ = j other than the considered one β j , the optimal value of β j can be obtained. In the second step, given all UCs phases β i , i = 1 . . . M , the optimal solution of the Tx covariance matrix is calculated via the water-filling technique [37].
The algorithm stops when the required accuracy is achieved or the maximum number of outer iterations is reached. In contrast to [36], at the second step we consider only quantized values of β j of RIS elements because on real devices the phase can take values only from some discrete set, e.g., β i ∈ {0, π}, i = 1 . . . M [38], [39].

2) CST-UC CONFIGURATION
If the RIS consists of more realistic UCs, the radiation patterns of which depend on the UC state, the aforementioned Optimal algorithm cannot be used because channel matrices change when the state of each UC changes. For example, the CST-UC has different radiation patterns for the OFF/ON states shown in Fig. 2-c to 2-j. Therefore, to configure a RIS consisting of CST-UCs, we need another algorithm, e.g., the one base on the idea from [40], which is referred to as ON-OFF and works as follows.
To find the most effective RIS configuration, we measure the receive power obtained for multiple RIS configurations with random states of UCs. For each UC, we divide all the measurements into two groups: when the UC's state is OFF or ON. Then, we select the state of the considered UC based on the group, where the average Rx power is higher.

C. VALIDATION
The validation consists of three steps. First, we compare QRIS with the SimRIS platform to validate the proposed approach for modeling RIS itself with COS-UC. Second, we validate the CST-UC model using full-wave simulation in CST with small RISs. Third, for large RISs, we use a hybrid approach with full RIS RCS calculated in CST and analytical expressions for free-space propagation.

1) QRIS VS. SimRIS
We have validated QRIS by comparing its results with the results obtained with SimRIS under the same conditions. Note that since QRIS is more flexible than SimRIS, some experiments can not be done in SimRIS.
To provide validation experiments, we consider synthetic scenarios when polarization, clusters, and the shadowing effect for QRIS and SimRIS models are disabled. Such an experiment allows testing only the RIS model implemented in QuaDRiGa and COS-UC (because only this type of UC is supported by SimRIS), excluding the complex features of channel models.
We consider the 3GPP 38.901 Indoor and 3GPP 38.901 UMi channel models with the corresponding  geometric arrangements of single-antenna Tx, RIS, and single-antenna Rx for different numbers of RIS elements and different frequencies. We compare the Signal-to-Noise ratios (SNR) obtained in QRIS and SimRIS if RIS contains COS-UCs. We vary the location of RIS along the x axis, while the coordinates of Tx and Rx are fixed. Subchannels (Tx, RIS) and (RIS, Rx) are LOS, and subchannel (Tx, Rx) is NLOS. In all validation experiments, the transmit power is P t = 5 dBm, and the noise power is P N = −120 dBm. We use the optimal RIS configuration algorithm from paper [36] in both QRIS and SimRIS platforms. Figs. 8 and 9 demonstrate that QRIS accurately estimates the performance of the RIS-assisted networks and SNR in QRIS coincides with SNR estimated using SimRIS.
In more complex scenarios, QRIS inherits QuaDRiGa features such as shadow fading and stochastic arrangement of clusters that are validated by QuaDRiGa developers [41]. 90676 VOLUME 11, 2023 Authorized licensed use limited to the terms of the applicable license agreement with IEEE. Restrictions apply.
The developed platform is flexible and can use complex radiation patterns for each UC, including experimental ones.

2) QRIS VS. CST FULL-WAVE SIMULATION
To validate CST-UC behavior, we made a comparison of two free-space scenarios using QRIS with CST-UC and full-wave simulation in CST. For that, we model Tx and Rx with a half-wave dipole antenna in CST and import their radiation patterns into QRIS so that the transmitter and receiver behavior is the same in both approaches. The Dipole antenna has a total length of 26 mm, the gap between arms is 0.5 mm, and the diameter of the arm is 0.2 mm. There is no possibility of completely excluding subchannel (Tx, Rx) in CST, so it significantly interferes with the analysis of subchannels in which RIS participates. We consider a scenario with the following coordinates: Tx (0, 0, 2) m, Rx (d TR , 0, 2) m, RIS ( d TR 2 , d TR 2 , 2) m, where distance between Tx and Rx d TR ∈ {0.5, 1, 1.5, 5, 10} m, so azimuth angle of incidence ϕ i = 45 • and azimuth angle of reflection ϕ r = 135 • . We vary the number of RIS UCs to determine the discrepancy between to approaches as the number of UCs increased. Also, we consider the states of RIS in which all UCs are in the OFF state (Full OFF) or the ON (Full ON) state. In addition, we calculate Rx power without RIS impact using the Friis equation for free-space propagation where λ is wavelength, P Tx is transmitting power, G Tx and G Rx are power radiation patterns of Tx and Rx respectively, ϕ d , θ d are angles of departure of signal from the Tx, ϕ a , θ a are angles of arrival of signal at the Rx, see Fig. 3.
For the validation, we take P Tx = 1 W power emission in QRIS and CST. Fig. 10 shows the Rx power as a function of d TR . For any number of RIS UCs and any distance, the difference between the Rx received power both in the OFF state and in the ON state, compared to the power obtained with (7), is negligible. This is because the size of the RIS in these experiments is extremely small and in any state, RIS does not make a significant contribution to the power, since there is a free-space line-of-sight subchannel between Tx and Rx. However, this experiment shows that the values of received power obtained from the QRIS, CST simulation, and the Friis equation can be compared. Unfortunately, increasing the number of UCs in full-wave simulation dramatically raises computational time and memory. To validate QRIS performance in scenarios, where the impact of RIS to Rx power is significant, we apply a hybrid approach based on the Friis equation, described below.

3) QRIS VS. ERRE RCS
The disadvantage of the previous approach to validation is the impossibility of eliminating the influence of subchannel (Tx, Rx), as well as the extremely limited number of UCs in CST experiments. To increase the size of the RIS as well as to take into account the features of the RCS modeling in the CST and remove the influence of the subchannel (Tx, Rx) on the system, we propose a hybrid approach to validation using an Extended Radar Range Equation (ERRE) [42] where σ RIS is the RCS of the whole RIS, d TI and d IR are the distances from Tx to RIS and from RIS to Rx respectively. For validation, we consider a free-space scenario where Tx has coordinates (0, 0, 2) m, Rx is located at (7k, 0, 2) m, and the RIS is in the point (5k, 5k, 2) m, k ∈ 1, 2. So, in both coordinate sets ϕ i = 45 • , ϕ r ≈ 22 • . In these experiments, the direct subchannel (Tx, Rx) is blocked. It is not considered in the analysis because it does not interfere with channels associated with the RIS. In these scenarios, we study how the divergence between ERRE and QRIS depends on d TR . We consider two cases: (i) the RIS is configured with the ON-OFF algorithm, and (ii) it is in the Full OFF state. To obtain the RCS of the entire RIS configured with the ON-OFF algorithm in CST, we first obtain optimal configuration information from QRIS and then create the RIS with the appropriate configuration in CST. Fig. 11 shows the Rx power as a function of the number of UCs M . The minimum of P Rx near M = 40 for the Full OFF state is caused by the behavior of the RCS of the entire RIS. Specifically, by varying M , we change RCS σ RIS , and according to (8) P Rx is proportional to RCS σ RIS . The RCS depends on the direction and the strength of side lobes, which non-monotonically depend on the size of the RIS.
For a large RIS, the degree of discrepancy between QRIS and ERRE does not exceed 1 dB when the RIS is configured with the ON-OFF algorithm and 1.7 dB when the RIS is in the Full OFF state. Note that in practice, the Full OFF state is rarely optimal, which means that the discrepancy is below 1.7 dB. In addition, the discrepancy between ERRE and QRIS weakly depends on the distance.
The discrepancy between QRIS and ERRE is explained by the assumptions used in the QRIS: the method of recalculating the RCS into radiation pattern [26] and neglecting mutual coupling between UCs. A higher discrepancy in the Full OFF state is explained by the increased mutual coupling of the UCs in the OFF state due to the operation of UCs at the resonant frequency in this state [43]. A limitation of our platform is the usage of identical UCs, however, in practice, the same UCs are used on RIS prototypes [44], [45], [46]. Additionally, the mutual coupling effect introduces a distinction between the isolated and grid-embedded UC patterns. Moreover, the pattern of the center UC differs from that of the RIS-edge UC also due to the mutual coupling. However, when UCs are located at a distance close to a half-wave, the effect of mutual coupling is significantly reduced [47]. Thus, in this work, we assume that all UCs exhibit an identical pattern and can be modeled free of surrounding ones. Our further step is to include mutual coupling effects into our platform, using approaches from papers [16], [17], [48].

VI. NUMERICAL RESULTS
Let us compare the performance of QRIS with various radiation patterns and configuration algorithms in the SISO scenario taking into account polarization, changes in the radiation patterns, and phase shifts difference with a change of the incidence angle. In all experiments, we consider a noise power spectral density of −173 dBm/Hz with a 9 dB noise figure, and a system bandwidth of 80 MHz, which yields P N = −85 dBm.
In the first experiment, we compare the behavior of different UCs radiation patterns in the same scenario. We consider the UMi scenario for those experiments with LOS subchannels (Tx, RIS) and (RIS, Rx), while the subchannel (Tx, Rx) is NLOS. The coordinates of the Tx, Rx, and RIS are (0, 0, 2) m, (100, 0, 2) m, (0, 10, 2) m. Operating frequency is 5.3 GHz and Tx power is P Tx = 30 dBm. We vary the number of RIS elements M and measure SNR at Rx. Let the RIS supports 1-bit quantization. For the COS-UC and Q-UC, we use zero phase shift in the OFF state for both polarization and 180 • phase shift in the ON state for both polarization. For more realistic CST-UC, the phase shifts are calculated using the CST which takes into account the state of the UC and polarization of the impinging wave. To configure the RIS, we use the Optimal and ON-OFF algorithms described in Section V-B.

LISTING 1. Sample of QRIS scenario.
As an example of using the QRIS platform, we provide a part of a code in Listing 1, where we create and configure Tx, Rx, and RIS with CST-UCs, etc. First, we create a linear polarized half-wave-dipole antenna for the Tx entity. Second, we create an Rx entity similar to the first step. Variable s is QRIS parameters class responsible for simulation options and constants for other classes. Third, we create the RIS entity and UCs for ON-OFF states and two polarizations. Fourth, we obtain the network layout l of a simulation. Then, we calculate channel matrices for our scenario. Finally, the RIS reflection matrix is optimized according to the channel matrices calculated at the previous stage. The other experiments are constructed similarly. Fig. 12 demonstrates the results of the described experiment. In this experiment, the RIS equipped with Q-UCs achieves much lower performance than estimated for COS-UC or CST-UC because the amplitude diagram is weaker for Q-UC.
We also evaluate the performance of the ON-OFF algorithm described in Section V-B2. The training set for the ON-OFF algorithm contains 500 random channel samples. The ON-OFF algorithm achieves almost the same performance as the Optimal one for COS-UC and Q-UC. However, the implementation of the Optimal algorithm is much more complex in practice [35].
In the second experiment, we vary the RIS position x RIS and measure SNR for COS-UC, Q-UC, and CST-UC. We use the ON-OFF algorithm to configure the RIS. We consider P Tx = 30 dBm, the noise power P  one half-wave-dipole antenna each. Fig. 13 demonstrates the results. SNR reaches its maximum values for all types of UCs when RIS is close to the Tx and Rx positions. This result coincides with the achieved in the previous papers [19], [49] and can be explained by the fact that since simplified Path Loss is proportional to the product of the squares of the distances from Tx to RIS and from RIS to Rx d 2 TI d 2 IR , the receiver SNR improves when the RIS is closer to the transmitter or the receiver. For a RIS equipped with COS-UCs or Q-UCs, the maximum value of SNR value is approximately the same on the left and right peaks with x RIS = 0 m and x RIS = 100 m respectively. However, for a RIS with the CST-UC, the maximum SNR is achieved when x RIS = 0 m. To explain this effect in detail, let us focus on how CST-UC's RCS and phase shifts depend on the incidence angle. The area of high performance of CST-UC in Fig. 13 corresponds to phase shift differences close to 180 • for the horizontal polarization, i.e., the incidence angle ϕ i ∈ (30 • , 150 • ), see Fig. 7. The phase shift difference for the vertical polarization of the modeled CST-UC is resilient to the changes in the incident angle. For the right peak in Fig. 13, the angle of incidence is about 6 • , which corresponds to a phase shift between ON and OFF states of about 97 • for horizontal polarization which significantly reduces the efficiency of the RIS [34]. In addition, as the RIS moves away from the Tx, the effective area of the UC decreases, which in turn reduces the amount of energy that the RIS can effectively re-radiate to the Rx [50].
Let us demonstrate how to use QRIS to estimate the throughput of different RIS-assisted MIMO systems in various scenarios and propagation conditions. For example, we evaluate MIMO 64 × 4 5G scenario band and a two-RIS Wi-Fi scenario. In both scenarios, we consider the NLOS case, where the RIS significantly improves the system throughput. To obtain statistically meaningful results, we average the throughput over 500 channel realizations. We use the ON-OFF algorithm and evaluate the performance of RIS equipped with COS-UC, Q-UC, and CST-UC. As a baseline, we consider the same communication system but without the RIS. In this case, the most efficient power distribution at Tx is obtained with the water-filling algorithm.   An important feature of the QRIS is the support of scenarios with multiple RISs configured for both multi-hop and single-hop communications. For example, let us consider a communication system with two RISs where the second RIS (labeled as RIS2) is deployed near the Rx in addition to the first RIS (labeled as RIS1) deployed near the Tx. Respectively, besides R and T for the preexisting subchannels (RIS1, Rx) and (Tx, RIS1), we letR andT denote the subchannels (RIS2, Rx) and (Tx, RIS2) due to the newly added RIS. Furthermore, there exists the inter-RIS subchannel between RIS1 and RIS2, which is denoted by U [51]. Thus, the effective subchannel between Tx and Rx is the  superimposition of the double-reflection link, the two singlereflection links, and the direct link, which is given by The second experiment corresponds to an indoor Wi-Fi network, where multiple RISs can provide a connection between two devices even if the direct link is fully blocked, see Fig. 15. Let the networking devices and two identical RISs be located according to the coordinates (in meters) shown in Fig. 15. The endpoint devices have four omni antennas and use the central frequency of 5.3 GHz. We use only the Optimal algorithm for tuning COS-UC and Q-UC in this scenario because the ON-OFF algorithm does not apply to the configuration of multiple RISs.
Both RISs have the same number of UCs. The propagation condition of subchannels (Tx, RIS1), (RIS1, RIS2), and (RIS2, Rx) is LOS, while all other subchannels are unavailable because of obstacles. Compared with the first experiment, we see that the throughput of such a system depends on the number of UCs much more strongly, and enlarging the RIS size from 64 to 900 UCs may increase the throughput dozens of times in the area of low transmit power.
The given system-level simulation results show that the designed model is flexible enough to evaluate the performance of RIS-assisted systems in a wide range of scenarios.

VII. CONCLUSION
In this paper, we present a QRIS simulation platform that can be used to evaluate the performance of RIS-assisted wireless communication systems. QRIS supports various radiation patterns for RIS UCs and various geometric locations with different numbers of UCs, operating frequencies, and scenario configurations. A distinctive feature of QRIS is the ability to consider the simultaneous usage of several RISs and their interaction. Using QRIS we evaluate the performance of RIS-assisted wireless systems with various unit cells, including those modeled in the CST Microwave Studio. Our next steps are related to the following directions.
First, we plan to integrate QRIS with a widely used network simulator ns-3 to enable system-level analyses of various wireless networks, e.g., 5G/6G and Wi-Fi 7.
Second, we are going to integrate the mutual coupling effect into our platform and explore techniques for its reduction.
Third, we are going to develop and implement a low-complexity RIS configuration algorithm for multi-RIS environments.
ILYA BURTAKOV received the B.S. degree (Hons.) in applied mathematics and physics from the Moscow Institute of Physics and Technology, in 2022, where he is currently pursuing the degree with the School of Radio Engineering and Computer Technology. He is a Junior Researcher with the Wireless Networks Laboratory, Institute for Information Transmission Problems of the Russian Academy of Sciences, and the Telecommunication Systems Laboratory, HSE University. His current research interests include analysis and performance evaluation of wireless local areas and cellular networks. VOLUME 11, 2023 ALEKSEY KUREEV received the B.S. and M.S. degrees (Hons.) in applied mathematics and physics from the Moscow Institute of Physics and Technology, in 2015 and 2017, respectively, and the Ph.D. degree in telecommunications, under the supervision of Evgeny Khorov. Currently, he is a Senior Researcher with the Wireless Network Laboratory, Institute for Information Transmission Problems, Russian Academy of Sciences, and the Telecommunication Systems Laboratory, Higher School of Economics University. He is the author of more than 20 research articles and patents. He has supervised students and lectures on the fundamentals of telecommunications and SDR prototyping. His current research interests include testbeds, software-defined radios, massive machine-tomachine communication, and ultra-dense networks.
ANDREY TYARIN received the B.S. and M.S. degrees (Hons.) in applied mathematics and physics from the Moscow Institute of Physics and Technology, in 2019 and 2021, respectively, where he is currently pursuing the Ph.D. degree with the School of Radio Engineering and Computer Technology. He is a Junior Researcher with the Wireless Networks Laboratory, Institute for Information Transmission Problems of the Russian Academy of Sciences, and the Telecommunication Systems Laboratory, HSE University. His current research interests include prototyping, semiconductor devices, and the modeling of electromagnetic field propagation.
EVGENY KHOROV (Senior Member, IEEE) received the Ph.D. and D.Sc. degrees, in 2012 and 2022, respectively. He leads the Wireless Networks Laboratory, Institute for Information Transmission Problems, Russian Academy of Sciences, and the Telecommunication Systems Laboratory, NRU HSE. He is also an Associate Professor with MIPT and MSU. He has authored more than 180 articles. He has led dozens of academic and industrial projects. His current research interests include 5G/6G systems, next-generation Wi-Fi, the Wireless Internet of Things, and QoS-aware optimization. Being a Voting Member of IEEE 802.11, he contributed to the Wi-Fi 6 Standard. He received several best paper awards. Also, he was awarded national and international prizes in science and technology. He gives tutorials and participates in panels at large IEEE events. He chaired the TPC of various IEEE and IETF conferences and workshops. In 2020, he was awarded as the Editor of the Year of Ad Hoc Networks.