Netsim: Accelerate Network R & D
Netsim: Accelerate Network R & D
NetSim
Accelerate Network R & D
5G NR
By
The publisher has taken care in the preparation of this document but makes no expressed or implied
warranty of any kind and assumes no responsibility for errors or omissions. No liability is assumed
for incidental or consequential damages in connection with or arising out of the use of the information
contained herein.
Copyright in the whole and every part of this manual belongs to TETCOS LLP and may not be used,
sold, transferred, copied or reproduced in whole or in part in any manner or in any media to any
person, without the prior written consent of TETCOS LLP. If you use this manual you do so at your
own risk and on the understanding that TETCOS LLP shall not be liable for any loss or damage of
any kind.
TETCOS LLP may have patents, patent applications, trademarks, copyrights, or other intellectual
property rights covering subject matter in this document. Except as expressly provided in any written
license agreement from TETCOS LLP, the furnishing of this document does not give you any license
to these patents, trademarks, copyrights, or other intellectual property. Unless otherwise noted, the
example companies, organizations, products, domain names, e-mail addresses, logos, people,
places, and events depicted herein are fictitious, and no association with any real company,
organization, product, domain name, email address, logo, person, place, or event is intended or
should be inferred.
Rev 13.2 (V), Jun 2021, TETCOS LLP. All rights reserved.
Contact us at
TETCOS LLP
# 214, 39th A Cross, 7th Main, 5th Block Jayanagar,
Bangalore - 560 041, Karnataka, INDIA.
Phone: +91 80 26630624
E-Mail: [email protected]
Visit: www.tetcos.com
3 Model Features........................................................................................................... 21
3.1 The 5G Frame Structure ..................................................................................... 21
3.2 Data Transmission Overview .............................................................................. 22
3.3 5G NR Stack ....................................................................................................... 23
3.4 SDAP (Specification: 37.324) .............................................................................. 24
3.4.1 5G QoS characteristics ............................................................................ 25
3.5 RLC (Based on specification 38.322) .................................................................. 25
3.6 RLC-AM (Based on specification 38.322) ........................................................... 30
3.6.1 Transmit Operations ................................................................................ 31
3.6.2 Receive Operations ................................................................................. 32
3.6.3 Actions when a RLC PDU is received from a lower layer ......................... 33
3.6.4 Reception of a STATUS report ................................................................ 33
3.7 PDCP (Based on specification 38.322) ............................................................... 33
3.8 MAC Layer .......................................................................................................... 34
3.8.1 Overview ................................................................................................. 34
3.8.2 MAC Scheduler: Introduction ................................................................... 34
3.8.3 Round Robin Scheduler........................................................................... 35
3.8.4 Proportional Fair Scheduler ..................................................................... 35
3.8.5 Max Throughput Scheduler ..................................................................... 36
3.8.6 Special cases .......................................................................................... 37
3.8.7 Log File ................................................................................................... 38
3.9 PHY Layer .......................................................................................................... 38
3.9.1 Overview of the PHY implementation ...................................................... 38
3.9.2 Digital Beamforming ................................................................................ 39
3.9.3 MIMO (Digital) Beamforming Assumptions in NetSim .............................. 41
em te Se e s
e e i es
te et
i s
se i me t
i i
ti
Net e m e
et ss
ts
et e
e t e
i es
ime se ies t t ts
st t e s
i e e it e i i
S e t
ime e e
i t
eset t
i e
Figure 1-1: NetSim’s 5G NR design window, the results dashboard and the plots window
2 Simulation GUI
5G NR comes with a palette of various devices like Wired & Wireless Nodes, L2 Switch & Access
Point, AMF (Access and Mobility Management Function), UPF (User Plane Function), SMF (Session
Management Function) & Router, gNB (Equivalent of eNB in LTE), UE (User Equipment), and
Building. Devices are connected using 3GPP defined interfaces; O-RAN defined interfaces are not
available.
The deployment options have been grouped into 2 categories. Standalone (SA) option where there
is only one independent access network (LTE or 5G NR) that is connected to either the EPC or the
5G Core and the Non-Standalone options where both LTE and 5G NR radio access technologies
are present, where one of the access networks assist the other in connecting to either an EPC or a
5GC.
Stand Alone: In 5G Stand-alone mode of operation in NetSim, the network can be created using
the 5G Core devices which includes a single AMF, SMF and UPF to which the gNB can be connected
via Layer 2 Switches. The RAN part consists of gNBs and UEs and the UEs can handle both Uplink
and Downlink data transfer to and from the Data Network (DN) via the UPF.
Non-Stand Alone: In the Non-Stand-alone mode of operation in NetSim, the users can design the
network scenario using different deployment options.
1. Option 3 where only LTE core/ EPC is present and no 5G Core devices are present. Option 3 is
categorized into:
a. Option 3: Only eNB connects to EPC and eNB and gNB connects to the XN interface.
b. Option 3a: Both eNB and gNB connects to the EPC. gNB connects to the XN interface and
eNB does not XN interface.
NetSim places the 5G core devices (AMF, SMF, UPF and Switches) / LTE EPC by default on to the
grid.
The device connectivity rules are explained below. Example screen shots are available in the section
3.15.
2.2.3.1 Option 3 / 3a
▪ UE should mandatorily be connected to the master node (MN) first. In option 3, the MN is eNB
▪ UE should mandatorily be connected to the secondary node (SN) next. In option 3, the SN is
the gNB
▪ UE cannot be connected to any other device.
▪ The data (external) network connects to the EPC. This is achieved by first connecting a router
( et’s call it R1) to the EPC.
▪ Switches, nodes, APs and other routers can now be connected to R1
2.2.3.2 Option 4 / 4a
▪ UE should mandatorily be connected to the master node (MN) first. In option 4, the MN is gNB
▪ UE should mandatorily be connected to the secondary node (SN) next. In option 4, the SN is
the eNB
▪ UE cannot be connected to any other device.
▪ The data (external) network connects to the 5G core through the UPF. This is achieved by first
connecting a router (let’s call it R1) to the UPF.
▪ Switches, nodes, APs and other routers can now be connected to R1
▪ Connectivity rules for the devices within the data network is per the Internetwork library
document.
2.2.3.3 Option 7 / 7a
▪ UE should mandatorily be connected to the master node (MN) first. In option 7, the MN is eNB
▪ UE should mandatorily be connected to the secondary node (SN) next. In option 7, the SN is
the gNB
▪ UE cannot be connected to any other device.
▪ The data (external) network connects to the 5G core through the UPF. This is achieved by first
connecting a router (let’s call it R1) to the UPF.
▪ Switches, nodes, APs and other routers can now be connected to R1.
▪ Connectivity rules for the devices within the data network is per the Internetwork library
document.
▪ NetSim allows users to design the network on a square grid. The major and minor grid lines
are displayed; major grid line values along X and Y co- i te is is ye . e i e’s X,
Y co-ordinate is determined by its location on the grid.
▪ Users can choose the grid size prior to placement of the first device. The grid size cannot be
changed after the first device has been placed on the grid.
▪ The grid length can be in the range of 10m to 1,000,000m.
▪ UPF (User Plane Function): User Plane Function has 5G_N4 interface for wired connectivity
to SMF, 5G_N3 interface for wired connectivity to gNB through L2_Switch, and 5G_N6
interface for wired connectivity to router in NG core which in turn can connect to Switches,
APs, Servers etc
gNB Properties
Interface (5G RAN) – Datalink Layer
Parameter Type Range Description
The scheduler serves equal portion
to each queue in circular order,
Scheduling Type Local Round Robin
handling all processes without
priority.
from 15 to 240 kHz. NetSim supports 𝜇 = 0, 1, 2 for FR1 and 𝜇 = 2, 3 for FR2. The setting 𝜇 = 0
corresponds to the LTE (4G) system configuration.
In the time domain (to support backwards compatibility with LTE) the frame length in 5G NR is set
to 10 ms, and each frame is composed of 10 subframes of 1 ms each. The 1 ms subframe is then
divided into one or more slots in 5G, whereas LTE had exactly two slots in a subframe. The slot
1
length depends on the numerology, 𝜇, and is equal to ms. The number of OFDM symbols per slot
2𝜇
is 14 for a configuration using normal cyclic prefix. For extended cyclic prefix, the number of OFDM
symbols per slot is 12. See section 3.9.7.2 - Numerologies, for more information.
Physical Resource Block (PRB): The PRB is the minimum unit of resource allocation in the
frequency domain, i.e., the width of a resource block, 180 kHz. It is a system-level constant. For
example, a PRB can either contain 12 subcarriers of 15 kHz each. As a formula, 𝑃𝑅𝐵𝑊𝑖𝑑𝑡ℎ =
12 × 15 × 2𝜇 kHz.
Resource Block (RB): It is the minimum unit of resource allocation, i.e., 1 PRB by 1 slot. NetSim’s
scheduler performs resource allocation every subframe (TTI, transmission time interval), however,
the granularity of resource allocation is 1 slot in time, i.e., the duration of a resource block, and 1
PRB in frequency. One sub-carrier by one symbol is defined as a resource element.
▪ In TDD operation the UL and DL transmissions are separated in the time-domain over different
frames/subframes/slots/symbols and use the same carrier frequency. In FDD operation UL
and DL transmissions are separated in the frequency domain, with different frequencies used
for UL and for DL transmission.
▪ Higher layer packets arrive at the RLC buffer for each UE and each gNB.
▪ Prior to transmission, the MAC scheduler in the gNB determines the allocation of PRBs (PHY
resources) to users. In this module the Transport block size (TBS) (explained in 3.9.13) is
computed using the channel quality index (CQI). The CQI is determined by the Adaptive
Modulation and Coding (AMC) function based on the SNR.
▪ Now, the received SNR is determined from a) large scale pathloss and shadowing calculated
e t e3 ’s st sti ti m e s, and b) the small-scale fading which leads to
beamforming gains when using MIMO2. These models provide signal attenuation as an output.
Several parameters are used in the model, including the distance between the transmitter and
the receiver. These computations are executed each associated UE-gNB pair, in DL and UL,
at the start of simulation and again at every mobility event. In calculating SNR, the noise power
is obtained from 𝑁 = 𝑘 × 𝑇 × 𝐵.
▪ Note that the SNR/CQI is not computed/fed-back using reference signals/control channels but
is computed on the data channel (PDSCH and PUSCH). Then it is assumed to be
▪ Based on this SNR the AMC determines a wideband CQI which indicates the highest rate
Modulation and coding scheme (MCS), that it can reliably decode, if the entire system
bandwidth were allocated to that user. The modulation scheme defines the number of bits, that
can be carried by a single RE. Modulation scheme supported by 5G include QPSK (2 bits), 16
QAM (4 bits), 64 QAM (6 bits), and 256 QAM (8 bits). The code rate defines the proportion of
bits transmitted that are useful. It is computed as the ratio of useful bits by total bits that are
transmitted. The modulation order 𝑄𝑚 , which denotes the number of bits per RE, and the code
rate denoted by 𝑅 are jointly encoded as modulation and coding scheme (MCS) index. These
values of 𝑄𝑚 and 𝑅 are then passed to the TBS determination function.
▪ At each gNB a frame of length 10ms is started. Each frame in turn starts 10 sub frames each
of length 1ms. Each sub frame then starts a certain number of slots based on numerology.
▪ The PHY layer in NetSim then notifies the MAC about the slot start. The MAC sub layer in turn
seeks a buffer status report from the RLC layer and invokes the MAC scheduler. It then notifies
the RLC of the transmission. The RLC then transmits the transport block to the PHY layer. The
downlink and uplink data channels (PDSCH, PUSCH) receive this transport block as its service
data unit (SDU), which is then processed and transmitted over the radio interface.
3.3 5G NR Stack
UE gNB
Figure 3-2: User Plane Protocol Stack
▪ Mapping between a QoS flow and a data radio bearer (DRB) per the new QoS framework
In NetSim the SDAP module’s SetMode function maps the Application QoS Type (which can be
set i NetSim’s to RLC mode.
BE AM Mode Non-GBR
Table 3-1: Mapping of Application QoS to RLC mode in NetSim
In the same function, the logical channel is also set to DTCH which is the dedicated traffic channel.
Next, comes the MAC_OUT function. This function determines what the current device is connected
After this is the SendToNetwork function. This function is called when a packet is at MAC-IN at the
receiever. The function creates the Network Event, sets all the Event-Details and sends the packet
to IP layer. And finally, the HandleMacIN function decides whether the packet must be sent to
another interface (if intermediate device) or sent to network layer (if end device). The header is
stripped off.
5G Quality of Service (QoS) model is based on QoS Flows. Each QoS flow has a unique identifier
called QoS Flow Identifier (QFI). There are two types of flows: Guaranteed Bit Rate (GBR) QoS
Flows and Non-GBR QoS Flows. Every QoS flow has a QoS profile that includes QoS parameters
and QoS characteristics. Applicable parameters depend on GBR or non-GBR flow type. QoS
characteristics are standardized or dynamically configured.
The current NetSim COTS build does not implement 5G QoS. All traffic flowing is categorized as
non-GBR. A framework has been provided for users to modify the underlying code to implement
QoS flow categorization in terms of:
▪ UM: RLC Header, Buffering at both Tx and Rx, Segmentation/Reassembly, No feedback (i.e.,
No ACK/NACK)
▪ AM: RLC Header, Buffering at both Tx and Rx, Segmentation/Reassembly, Feedback (i.e.,
ACK/NACK)
Each of these modes can both transmit and receive data. In TM and UM, separate entity is used for
transmission and reception, but in AM a single RLC entity perform both transmission and reception,
NetSim implements all the 7 entities for the RLC that are shown in Figure 3-5: RLC Modes of
operation and RLC Entities. Note that each of logical channels use a specific RLC mode:
▪ DTCH use RLC UM or AM. (Which mode is used for each DTCH channel, is determined by
RRC message).
The RLC entities provide the RLC service interface to the upper PDCP layer and the MAC service
interface to the lower MAC layer. The RLC entities use the PDCP service interface from the upper
PDCP layer and the MAC service interface from the lower MAC layer.
The main call at the transmit side RLC is done in the function
fn_NetSim_LTENR_RLC_HandlePDUFromUpperLayer() in the file LTENR_RLC.c
Once the MAC Layer allocates resources it calls the following function in LTENR_RLC.c
UM stands for 'Unacknowledged Mode'. 'Unacknowledged Mode' means 'it does not require any
reception response from the other party'. 'Reception response' simply mean 'ACK' or 'NACK' from
the other party. (UM mode is similar to TM mode in that it does not require any ACK/NACK from the
other party, but it is different from TM in that it has its own header)
Per the figure below the RLC transmit side (All the RLC UM functionality is available in the file
LTENR_RLC_UM.c in the project LTE_NR).
▪ Buffers the data and generates RLC Header. This is handled in NetSim by the function void
LTENR_RLC_UM_HandlePDUFromUpperLayer()
o The above two functionalities are handled in NetSim by the function UINT
LTENR_RLC_UM_SEND_PDU (NETSIM_ID d, NETSIM_ID in,NETSIM_ID r, NETSIM_ID
rin, UINT size, LTENR_LOGICALCHANNEL logicalChannel) which in turn calls the function
static NetSim_PACKET*
LTENR_RLC_UM_FRAGMENT_PACKET (NetSim_PACKET* p, UINT size, UINT sn) and
the function static int LTENR_RLC_UM_ADD_HDR(NetSim_PACKET* p
NOTE: If you compare this in LTE process, it seems that UM RLC does not perform any
'Concatenation'. According to following statement from 38.322 v0.1.0, the 'concatenation' process is
moved to MAC layer. From RAN2 NR#1: Working assumption on no RLC concatenation taken at
RAN2#96 is confirmed (i.e., concatenation of RLC PDUS is performed in MAC).
The main call at the receive side RLC is done in the function void
fn_NetSim_LTENR_RLC_HandleMACIN() in the file LTENR_RLC.c
▪ Buffers. Here the RLC waits for all the fragments to arrive.
o This is handled in NetSim by the function void LTENR_RLC_UM_RECEIVE_PDU(). If
there is no fragments then call LTENR_CallPDCPIN(); else call
LTENR_RLC_UM_RECEIVE_PDU_WITH_SN();
▪ Reorders, if required
▪ Strips the RLC header
▪ Reassembles
o The above three functionalities are handled in NetSim by the code in the region #pragma
region RLC_UM_RECEPTIONBUFFER
a. t-PollRetransmit: This timer is used by the transmitting side of an AM RLC entity in order to
retransmit a poll. Default value in NetSim is set to ms5(5 milli seconds). Range is provided in the
GUI dropdown menu.
b. t-Reassembly: This timer is used by the receiving side of an AM RLC entity and receiving UM
RLC entity in order to detect loss of RLC PDUs at lower layer. If t-Reassembly is running, t-
Reassembly shall not be started additionally, i.e., only one t-Reassembly per RLC entity is running
at a given time. Default value in NetSim is set to ms5(5 milli seconds). Range is provided in the
GUI dropdown menu.
c. t-StatusProhibit: This timer is used by the receiving side of an AM RLC entity in order to prohibit
transmission of a STATUS PDU. Default value in NetSim is set to ms5(5 milli seconds). Range is
provided in the GUI dropdown menu. The following parameters are configured per TS 38.331 [5]:
d. maxRetxThreshold: This parameter is used by the transmitting side of each AM RLC entity to
limit the number of retransmissions corresponding to an RLC SDU, including its segments.
Default value in NetSim is set to t1. Range is provided in the GUI dropdown menu.
e. pollPDU: This parameter is used by the transmitting side of each AM RLC entity to trigger a poll
for every pollPDU PDUs. Default value in NetSim is set to p4(PDUs). Range is provided in the
GUI dropdown menu.
After RLC transmitters does the segmentation/concatenation process, it adds RLC header and then
it creates two identical copies and transmit the one copy of the data out to lower layer (MAC) and
sends another copy to Retransmission buffer.
If the RLC gets Nack or does not get any response from the receiver for a certain period of time, the
RLC PDU in the retransmission buffer gets transmitted again. If the RLC get ACK, the copy of the
packet in retransmission buffer is discarded.
There are four buffers maintained in RLC-AM. There is no size defined in the standard and hence
NetSim implements an infinite buffer (see LTENR_RLC.h and LTENR_RLCBuffer.c for related
code). There are 3 buffers for transmit operations and 1 for receive operation:
The MAC sub layer then seeks a Buffer Status Report from the RLC.
The entry functions for RLC-AM is defined in the section #pragma region RLCAM_OUT. The first
function called is void LTENR_RLCAM_HandlePDUFromUpperLayer()
Here the packet is added to the Transmission Buffer. Then based on the MAC scheduler, the MAC
layer sends a notification to RLC, which in turn sends a packet by first checking the Re Transmission
Buffer followed by the Transmission-Buffer. These functions are also in the same region.
The transmitting side of an AM RLC entity shall prioritize transmission of RLC control PDUs over
AMD PDUs. The transmitting side of an AM RLC entity shall prioritize transmission of AMD PDUs
containing previously transmitted RLC SDUs or RLC SDU segments over transmission of AMD
PDUs containing not previously transmitted RLC SDUs or RLC SDU segments. The transmitting
side of an AM RLC entity shall maintain a transmitting window according to the state variable
TX_Next_Ack as follows:
The transmitting side of an AM RLC entity shall not submit to lower layer any AMD PDU whose SN
falls outside of the transmitting window.
For each RLC SDU received from the upper layer, the AM RLC entity shall:
- associate a SN with the RLC SDU equal to TX_Next and construct an AMD PDU by setting the SN
of the AMD PDU to TX_Next;
When submitting an AMD PDU that contains a segment of an RLC SDU, to lower layer, the
transmitting side of an AM.
- set the SN of the AMD PDU to the SN of the corresponding RLC SDU.
The transmitting side of an AM RLC entity can receive a positive acknowledgement (confirmation of
successful reception by its peer AM RLC entity) for an RLC SDU by the following:
When receiving a positive acknowledgement for an RLC SDU with SN = x, the transmitting side of
an AM RLC entity shall:
- send an indication to the upper layers of successful delivery of the RLC SDU;
- set TX_Next_Ack equal to the SN of the RLC SDU with the smallest SN, whose SN falls within the
range
TX_Next_Ack ≤ SN ≤ TX_Next and for which a positive acknowledgment has not been received
yet.
The receiving side of an AM RLC entity shall maintain a receiving window according to the state
variable RX_Next as follows:
When receiving an AMD PDU from lower layer, the receiving side of an AM RLC entity shall:
- either discard the received AMD PDU or place it in the reception buffer.
- update state variables, reassemble and deliver RLC SDUs to upper layer and start/stop t-
Reassembly as needed when t-Reassembly expires, the receiving side of an AM RLC entity shall:
After submitting an AMD PDU including a poll to lower layer, the transmitting side of an AM RLC
entity shall:
- set POLL_SN to the highest SN of the AMD PDU among the AMD PDUs submitted to lower layer;
- start t-PollRetransmit.
- else:
- restart t-PollRetransmit
At the Receive side the functionality is handled in the section #pragma region RLCAM_IN. The entry
function in the receive side is void LTENR_RLC_AM_RECEIVE_PDU(). The receives the AMPDU
and checks if
If both the conditions are true, the AMPDU is placed in the Reception Buffer and starts the
ReassemblyTimer. If the PDU has a PollRequest then it starts constructing the StatusPDU. The code
for this is in the section #pragma region RLCAM_STATUSPDU_SEND
Upon reception of a STATUS report from the receiving RLC AM entity the transmitting side of an AM
RLC entity shall:
- if the STATUS report comprises a positive or negative acknowledgement for the RLC SDU with
sequence number equal to POLL_SN:
- if t-PollRetransmit is running:
PDCP Entity: The PDCP entities are located in the PDCP sublayer. NetSim currently implements
one PDCP entity per UE (users can add more by modifying the code). The same PDCP entity is
associated with both the control and the user plane.
▪ LTENR_PDCP.c
▪ LTENR_PDCP.h
▪ Multiplexing/de-multiplexing of MAC SDUs into/from transport blocks for DL-SCH and UL-SCH
data transfer
▪ Buffer status reporting
▪ MAC Scheduler
Base stations (gNBs) generally deal with multiple mobile stations UEs, some of which require larger
bandwidths than others and some of which have better connections (signal quality) than others. In
ideal circumstances the base station has plenty of resources (e.g., bandwidth) and each UE gets the
resources it needs. However usually resources are limited, and the base station needs some way of
fairly allocating the resources between the UEs.
It divides the available PRBs among the active flows, i.e., those logical channels which have a non-
empty RLC queue. The MCS for each user is calculated according to the received CQIs.
The Proportional Fair (PF) scheduler works by scheduling a user when its instantaneous channel
quality is high relative to its own average channel condition over time. The PF scheme is based on
information such as a presently available data rate for each user and an average data rate over an
immediately prior predetermined interval for each user.
In comparison with the round-robin (RR) scheduler in which UEs are cyclically scheduled irrespective
of the channel condition, the PF scheduler maximizes the system throughput while maintaining long-
term fairness in the allocation of resources between users.
3.8.4.1 Implementation
Let 𝑖, 𝑗 denote generic users and let 𝑡 be the slot index. Since NetSim uses a flat fading model, the
resource block index 𝑘 is not considered. Let 𝑀𝑖 (𝑡) be the MCS seen by user 𝑖 at time (slot) 𝑡. The
channel CQI (derived from the data channel SINR) is used by the adaptive modulation and coding
(AMC) module to determine the MCS. We denote by 𝑆(𝑀, 𝐵) the TB size in bits for a given MCS, 𝑀,
and a given number of physical resource blocks (PRBs), 𝐵. The achievable rate 𝑅𝑖 (𝑡) in bit/s for
user 𝑖 in slot 𝑡 is defined as
𝑆(𝑀𝑖 (𝑡), 1)
𝑅𝑖 (𝑡) =
𝜏
where 𝜏 is the TTI, i.e., 1 slot duration. At the start of each slot 𝑡, the user index 𝑖 ∗ (𝑡) - selected by
the scheduler - t i e ie s e t t se ’s em is ssi e t time 𝑡 is determined
as
𝑅𝑗 (𝑡)
𝑖 ∗ (𝑡) = 𝑎𝑟𝑔𝑚𝑎𝑥 ( )
𝑗=1,…,𝑁 𝑇𝑗 (𝑡)
This selection is carried out by the scheduler till all PRBs in slot 𝑡 are allocated. In the above
expression, 𝑇𝑗 (𝑡) is the past throughput performance perceived by the user 𝑗, and is defined as
where 𝛼 is the time constant (in units of slots) of the exponential moving average. NetSim uses 𝛼 =
50, and 𝑇̂𝑗 (𝑡) is the actual throughput achieved by the user 𝑖 in the subframe 𝑡. If 𝐵̂𝑗 (𝑡) is the number
of PRBs allocated to user 𝑗, we finally get
3.8.4.2 Remarks
R1. The solution to the multi-carrier short term proportional fair scheduling is prohibitively
complex to obtain. In the optimal solution, in each slot, each RB’s allocation should depend
on other RB allocations. NetSim’s implementation is a long term near optimal PF scheduler.
R2. When there is no channel variation, the throughput of PF scheduler approximately equals
that of the round robin scheduler.
R3. The difference between the RR and PF schedulers can be seen when the radio channel
varies (i) the SINR sufficiently to move the MCS up or down, and (ii) in a time scale of the
order of the slot duration (i.e., order of milli seconds).
R4. Mobility cases: NetSim pathloss computations don't follow continuous math since it will mean
a very large number of calculations. These PL calculations are discrete time instants i.e.,
every time a UE moves with the UE movement update determined per the update interval
parameter in the UI or via a mobility file. Let us denote the time difference between updates
as Δ𝑇. The UE is assumed to instantaneously move to a point 𝑃𝑇 at time 𝑇 and stay there till
just before time (𝑇 + Δ𝑇). At the moment, (𝑇 + Δ𝑇), the UE instantaneously moves to
point 𝑃𝑇+Δ𝑇 . Pathloss is computed at (𝑃𝑡 , 𝑇) and then at (𝑃𝑇+Δ𝑇 , 𝑇 + Δ𝑇). Therefore, (and
again) differences between the RR and PF scheduler will be appreciable only if the update
interval is of the order of milli seconds.
R5. The PF algorithm is known to possess the following optimality property: it maximizes
∑𝑘 log(𝑇𝑘 ) i.e., it maximizes the sum of the log throughputs of all UEs.
The Max Throughput (MT) scheduler aims to maximize the overall throughput of the Base station
(gNB or eNB). It allocates each PRBs to the user that can achieve the maximum achievable rate in
the current TTI. The highest achievable rate is calculated by wideband MCS, that is derived from the
We denote 𝑆(𝑀, 𝐵) as the TB size in bits for a given MCS, 𝑀, and a given number of physical
resource blocks (PRBs), 𝐵. The achievable rate 𝑅𝑖 (𝑡) in bit/s for user 𝑖 at slot 𝑡 is defined as
𝑆(𝑀𝑖 (𝑡), 1)
𝑅𝑖 (𝑡) =
𝜏
where 𝜏 is the TTI i.e., 1 slot duration. At the start of each slot 𝑡, the user index 𝑖 ∗ (𝑡) - selected by
the scheduler - t i e ie s e t t se ’s em is ssi e t time 𝑡 is determined
as
While MT can maximize cell throughput, it cannot provide fairness to the UEs that experience poor
channel condition.
When there are several UEs having the same achievable rate, NetSim implements RR scheduling
amongst these UEs that have the same achievable rate.
C1. Carrier aggregation case: the scheduler runs on a per carrier basis.
a. PF Scheduler: 𝑇̂𝑗 (𝑡) is computed and maintained independently for each carrier.
C2. NSA mode: Traffic is split between 4G and 5G (eNB and gNB) above the MAC. The scheduler
runs independently on the eNB and gNB.
C3. Association and Handover: PF Scheduler: At time of association or handover, say 𝑡𝑎 , NetSim
sets 𝑇𝑗 (𝑡𝑎 ) = 1
C4. Application priorities and heterogenous traffic: In 5G, the types of QoS are
a. GBR, which is transmitted in RLC UM mode. In NetSim, Applications which have UGS
priority set are transmitted in UM mode.
b. Non-GBR, which is transmitted in RLC AM mode. In NetSim, Applications which do
not have UGS priority set are transmitted in AM mode.
c. Control channel traffic, which is transmitted in RLC TM mode. NetSim assume ideal
t e be i es ’t m e t ese t smissions.
C5. The MAC scheduler allocates resources on a combined (UM plus AM) RLC requirement.
Once UE wise allocation is complete, RLC would first transmit the UM mode traffic followed
by the AM mode traffic, to that UE. And so on for all UEs.
S t
ie
A te s
A i be s its e
ti e ie e s t bet ee e N its ss i te s
Figure 3-9: Radio resource allocation log file showing allocation per carrier per slot between each gNB and
its associated UEs
NetSim is a packet level simulator for simulating the performance of end-to-end applications over
various packet transport technologies. NetSim can scale to simulating networks with 100s of end-
systems, routers, switches, etc. NetSim provides estimates of the statistics of application-level
performance metrics such as throughput, delay, packet-loss, and statistics of network-level
processes such as buffer occupancy, collision probabilities, etc.
In order to achieve a scalable simulation, that can execute in reasonable time on desktop level
computers, in all networking technologies the details of the physical layer techniques have been
abstracted up to the point that bit-error probabilities can be obtained from which packet error
probabilities are obtained.
Of all the wireless access technologies implemented in NetSim, the most sophisticated is 5G NR, in
which the physical layer utilizes a variety of techniques that go well beyond even 4G LTE. These
include multiple subcarrier bandwidths in the same system, slot lengths that depend on the
subcarrier bandwidth, flexible time-division duplexing, a wide range of constellation sizes and coding
rates, multiuser MIMO-OFDM, etc. Particularly with regard to MIMO-OFDM, with the attendant
channel estimation (the errors therein), and the complexities of signal processing, NetSim has taken
the design decision to replace these by idealized, symbol level models, where the statistics of the
effective stochastic channel gains, and the statistics of the effective stochastic noise and interference
are modelled in an idealized setting. Such models then permit the calculation of the required bit error
rates, and thereby code block error rates, etc.
Ver 13.2 Page 38 of 211
Overview of the 5G NR PHY:
𝑟𝑏
Where 𝑅 is the code rate, 𝑄 is the modulation order, 𝜈 is the number of MIMO layers, 𝑛𝑠𝑐 is
the number of sub carriers per resource block, 𝑛𝑠𝑦𝑚𝑏𝑜𝑙 is the number of symbols per slot, 𝑁𝑃𝑅𝐵
is the number of PRBs and 𝑂𝐻 is the overheads specified in the standard.
▪ The available PHY resource is shared dynamically between the users, with the resource
allocation being dynamically adjusted per user demands and channel conditions. The MAC
Scheduler determines the data (how much to and from, which UE and gNB) that is to be
transmitted, from the higher layer RLC buffer, in units of Physical Resource Blocks (PRBs). It
is transmitted at a rate determined using 𝑅, code rate and 𝑄, modulation order of the UE –
gNB channel.
▪ For a transmitter (gNB or eNB) with 𝑡 antennas and a receiver with 𝑟 antennas, the 𝑟 × 𝑡
channel gain matrix (between every transmit-receive antenna pair) has complex Gaussian
elements. We assume in the standard model that the complex Gaussian elements are
statistically independent across elements, and each element is a circularly symmetric
Gaussian. We denote this matrix by 𝐻.
𝑊 = 𝐻 𝐻† 𝑟 < 𝑡,
𝑊 = 𝐻†𝐻 𝑟≥𝑡
▪ NetSim permits the user to enable or disable a stochastic fading model. Fading is modelled by
the elements of 𝐻 being time varying, with some coherence time. Such time variation results
in the eigenvalues of 𝑊 also varying. NetSim models such time variation by letting the user
define a coherence time during which the eigenvalues (fast fading gains) are kept fixed. For
each (𝑟, 𝑡) value, NetSim maintains a list of samples of eigenvalues for the corresponding
Wishart matrix. To model fading, a new set of eigenvalues is used by NetSim in successive
coherence times.
▪ Putting the above discussions together, if fast fading with eigen-beamforming is enabled in
NetSim’s GUI, then the MIMO link is modelled by several SISO channels (see below), with the
symbol level channel gain being derived from the eigenvalues of the Wishart matrix.
𝐵𝑒𝑎𝑚𝐹𝑜𝑟𝑚𝑖𝑛𝑔𝐺𝑎𝑖𝑛 (𝑑𝐵) = 10 log10(𝐸𝑖𝑔𝑒𝑛𝑉𝑎𝑙𝑢𝑒)
It must be noted that the eigenvectors are not required as they are only a part of the receive
and transmit signal processing, and NetSim only needs to work with the equivalent symbol-
by-symbol flat fading SISO channels.
▪ If fast fading is disabled, NetSim reduces the MIMO transmission to a set of parallel,
independent channels with constant gain, since the Beam forming gain does not change with
time.
▪ Note that the LOS probability parameter in NetSim is solely used to compute the large scale
pathloss per the 3GPP 38.901 standard. This parameter is not used in the channel rank (MIMO
layers) computations. The Fading and Beam Forming parameter is used to determine (i) the
number of MIMO layers and (ii) the gains in each layer, as shown in the table below.
Parameter drop down option No. of MIMO layers Beamforming Gain and Model
Unity (0 dB).
No fading MIMO unit gain Min (𝑁𝑡 , 𝑁𝑟 ) A theoretical model useful for
benchmarking.
Max (𝑁𝑡 , 𝑁𝑟 )
Assumes Matched Filter Precoding
No fading MIMO array gain Min (𝑁𝑡 , 𝑁𝑟 )
(MFP) and Maximal Ratio
Combining (MRC)
Eigen values of the Wishart Matrix.
Rayleigh with Eigen Beamforming Min (𝑁𝑡 , 𝑁𝑟 )
Assumes MFP and MRC
NetSim makes the following assumptions to simplify MIMO operations for a packet-simulator:
▪ Operation in spatial multiplexing mode only and not in transmit diversity mode.
▪ The LayerCount = Min (Nt , Nr ) where Nt is the number of transmit antennas and Nr is equal to
the number of receive antennas.
▪ e t e e is ss me t be e t t e ye t. NetSim es ’t perform
any Rank indicator (RI) computations.
▪ Each layer is reduced to a flat fading SISO channel, i.e., for layer j, 1 ≤ j ≤ LayerCount,
yj = √λj xj + wj
where, xj is the symbol transmitted, λj is the corresponding eigenvalue of the Wishart matrix
obtained as in the previous section, wj is circular symmetric complex Gaussian noise, and yj
is the complex valued baseband received symbol.
▪ Since the distance between the transmitter and receiver is much larger than the antenna
spacings, a common pathloss is assumed for every layer. The pathloss is modelled, as usual,
using distance dependent pathloss (power law), log normal shadowing, and a statistical model
for fast fading (e.g., Rayleigh fading).
▪ Then, given the transmit power in the symbol xj , the layer SNR can be obtained directly from
the flat fading SISO equivalent model displayed above.
▪ It is assumed that the transmit power is equally split between all Layers transmitted. At a high
SNR, (iterative) water-filling will lead to nearly equal power allocation across all subcarriers
and all layers [1].
▪ The transmit power (or total radiated power) is not split equally among the antennas. The per-
antenna power depends on the beamforming vector used. For example, if the (eigen)
beamforming vector is [1, 0]T in the 2 antenna case, all the power is radiated out of the first
1 1 T
antenna. If it is [ , ] , then the power is split equally among the antennas ... and so on.
√2 √2
NetSim abstracts out the actual beamforming operation and computes the received SINR
when the beamforming vectors are used.
▪ Downlink parallel transmission to multiple users is enabled by utilising multiple parallel
resource blocks. Within each resource block, all MIMO layers are transmitted to the same UE.
▪ UEs receive no interference from other gNBs, and a gNB does not receive interference from
UEs connected to any other gNB.
▪ Error free channel: This arises due to the practical fact that the adaptive MCS algorithm
chooses the modulation order and coding scheme based on the SNR, in such a way that the
data is decoded successfully at the receiver with a very high probability.
Figure 3-10: An example NetSim output showing SINR vs. time for each MIMO layer, as the UE moves away from the
gNB. The beamforming gain is recalculated every coherence time
In summary, NetSim models the effect of eigen-beamforming in MIMO systems via the eigenvalues
of the gram matrix formed using (random) channel instantiations. These eigenvalues are used to
compute layer-wise SNRs and the corresponding CQI. The CQI values are used by a scheduler to
fix the TBS parameters, and this in turn determines the throughput.
NetSim's power lies in its ability to incorporate the impact of link-level factors (such as beamforming)
on the network-level performance with high precision and computational efficiency. This, in turn,
allows the simulator to scale to 10s of gNBs and 100s of UEs, and yet return performance results in
a short time.
1. In Analog beamforming, multiple antennas are used to concentrate the radiated power towards a
particular direction (e.g., a part of a sector), thus improving the received SINR and the probability of
detecting the SSB from the gNB (at a UE.)
2. Analog beamforming and digital beamforming are different as shown in the table below
A2. Based on A1, NetSim computes an upper bound on the average Analog beam forming gain (dB)
as 10 log10 (𝑁𝑡 × 𝑁𝑟 ). Here 𝑁𝑡 is the transmit antenna count at the gNBs and 𝑁𝑟 is the receive
antenna count at the UE.
A3. The beam selection and alignment are assumed to occur instantaneously. There is no time
delay to account for beam-selection, SSB burst periodicity etc. Users requiring such time delays
can attempt modelling it using the Handover interruption time variable available in the gNB
properties. In any case, the beam selection/monitoring of the best beams from both serving and
neighbouring cells are assumed to be occurring in parallel with the other data processing taking
place at the UE.
3.9.4.2 Logging
The minimum guard band for each UE channel bandwidth and SCS is specified below.
The minimum guard bands have been calculated using the following equation:
(𝐵𝑊𝑐ℎ𝑎𝑛𝑛𝑒𝑙 × 1000(𝑘𝐻𝑧) − 𝑁𝑅𝐵 × 𝑆𝐶𝑆 × 12) − 𝑆𝐶𝑆
2
where 𝑁𝑅𝐵 are from Table 5.3.2-1. The minimum guard band of receiving BS SCS 240 kHz for each
UE channel bandwidth is specified below.
For a transmitter (gNB or eNB) with t antennas and a receiver with r antennas, the 𝑁𝑟 × 𝑁𝑡 channel
gain matrix (between every transmit-receive antenna pair) on a given subcarrier has complex
Gaussian elements. We assume in the standard model that the complex Gaussian elements are
statistically independent across elements (which is the case the antennas are spread sufficiently far
apart, e.g., of the order of a few wavelengths), and each element is a circularly symmetric Gaussian.
We denote this matrix by H.
In NetSim, Fast-Fading is modeled by the elements of the H-Matrix being time-varying, with some
coherence time. NetSim abstracts out the actual (digital) beamforming operation and computes the
received SINR when the beamforming vectors are used. The MIMO link is modelled by parallel SISO
channels, and the beamforming gain/loss would be equal to Eigenvalues of the Gram matrix of H
(which would also be time-varying). This is the case when the transmitter/receiver use Eigen
beamforming to precode/combine the signals across antennas, respectively. In turn, it assumes the
availability of channel state information at both the transmitter and receiver. In the case where
multiple layers are transmitted to different users, the interference is calculated by considering its
statistics, by assuming that the channels between the base station and the different users to be
independent of each other.
The definition of frequency ranges is per the table given below Table 3-2.
3.9.7.1 NR Band – FR 1
The FR1 bands (per 3GPP TS 38.101-1 V15.5.0 (2019-03)) implemented in NetSim are those that
run:
• TDD single band in Duplex mode, namely n34, n38, n39, n40, n41, n50, n51, n77, n78, n79,
n259, n260, n261 and n262 as shown below in Table 3-3.
• FDD Single band in Duplex mode, namely n1, n2, n3, n5, n7, n8, n12, n20, n25, n28, n66,
n70, n71 and n74 as shown below in Table 3-4.
The maximum transmission bandwidth configuration NRB for each UE channel bandwidth and
subcarrier spacing is specified below Table 3-4.
5 10 15 20 25 30 40 50 60 80 90 100
SCS
MHz MHz MHz MHz MHz MHz MHz MHz MHz MHz MHz MHz
(kHz)
NRB NRB NRB NRB NRB NRB NRB NRB NRB NRB NRB NRB
15 25 52 79 106 133 160 216 270 N/A N/A N/A N/A
30 11 24 38 51 65 78 106 133 162 217 245 273
60 N/A 11 18 24 31 38 51 65 79 107 121 135
Table 3-5: Maximum transmission bandwidth configuration NRB
The minimum guardband for each UE channel bandwidth and SCS is specified below Table 3-5.
SCS 5 10 15 20 25 30 40 50 60 80 90 100
(kHz) MHz MHz MHz MHz MHz MHz MHz MHz MHz MHz MHz MHz
15 242.5 312.5 382.5 452.5 522.5 592.5 552.5 692.5 N/A N/A N/A N/A
30 505 665 645 805 785 945 905 1045 825 925 885 845
60 N/A 1010 990 1330 1310 1290 1610 1570 1530 1450 1410 1370
Table 3-6: Minimum guardband for each UE channel bandwidth and SCS (kHz)
NOTE: The minimum guardbands have been calculated using the following equation:
(𝐵𝑊𝑐ℎ𝑎𝑛𝑛𝑒𝑙 × 1000(𝑘𝐻𝑧) − 𝑁𝑅𝐵 × 𝑆𝐶𝑆 × 12) − 𝑆𝐶𝑆
2
where 𝑁𝑅𝐵 are from Table 5.3.2-1.
3.9.7.2 NR Band – FR 2
The FR2 bands (per 3GPP TS 38.101-2 V15.5.0 (2019-03)) implemented in NetSim as shown below
Table 3-6.
The maximum transmission bandwidth configuration NRB for each UE channel bandwidth and
subcarrier spacing is specified below.
3.9.8.1 General
All UEs connected to BS (gNB) have the same channel bandwidth. This is a user settable bandwidth
available in the gNB properties. Bandwidth is a single parameter in TDD; in FDD users can set DL
bandwidth and UL bandwidth. It is currently not possible in NetSim to configure different channel
bandwidths to different UEs connected to a BS.
The above is true even in case of carrier aggregation (CA). All component carriers (CCs) are
assigned to all UEs, and the pooled OFDM resources are shared between the UEs.
3.9.9.1 Numerologies
Multiple OFDM numerologies are supported as given by Table 4.2-1 where 𝜇 and the cyclic prefix
for a bandwidth part are obtained from the higher-layer parameter subcarrierSpacing and
cyclicPrefix, respectively.
0 15 Normal
1 30 Normal
2 60 Normal, Extended
3 120 Normal
4 240 Normal
Standards Table 4.2-1: Supported transmission numerologies
Downlink and uplink transmissions are organized into frames with 𝑇𝑓 = 10ms duration, each
consisting of ten subframes of 𝑇𝑠𝑓 = 1ms duration. The number of consecutive OFDM symbols per
s b me,𝜇 s t s b me,𝜇
subframe is 𝑁symb = 𝑁symb 𝑁s t . Each frame is divided into two equally-sized half-frames
of five subframes each with half-frame 0 consisting of subframes 0 – 4 and half-frame 1 consisting
of subframes 5 – 9.
There is one set of frames in the uplink and one set of frames in the downlink on a carrier.
Uplink frame number 𝑖 for transmission from the UE shall start 𝑇𝑇𝐴 = (𝑁𝑇𝐴 + 𝑁𝑇𝐴,𝑜𝑓𝑓𝑠𝑒𝑡 )𝑇𝑐 before the
start of the corresponding downlink frame at the UE where N TA,offset is given by [5, TS 38.213].
Downlink frame i
Uplink frame i
3.9.9.3 Slots
𝜇 s b me,𝜇
For subcarrier spacing configuration 𝜇, slots are numbered 𝑛s ∈ {0, … , 𝑁s t − 1 } in increasing
𝜇 me,𝜇
order within a subframe and 𝑛s, ∈ {0, … , 𝑁s t − 1 } in increasing order within a frame. There are
slot slot
𝑁symb consecutive OFDM symbols in a slot where 𝑁symb depends on the cyclic prefix as given by
𝜇
Tables 4.3.2-1 and 4.3.2-2. The start of slot 𝑛s in a subframe is aligned in time with the start of
𝜇
slot
OFDM symbol 𝑛𝑠 𝑁symb in the same subframe.
OFDM symbols in a slot can be classified as 'downlink', 'flexible', or 'uplink'. Signaling of slot formats
is described in subclause 11.1 of [5, TS 38.213].
In a slot in a downlink frame, the UE shall assume that downlink transmissions only occur in
'downlink' or 'flexible' symbols.
In a slot in an uplink frame, the UE shall only transmit in 'uplink' or 'flexible' symbols.
A UE not capable of full-duplex communication among a group of cells is not expected to transmit in
the uplink in one cell within the group of cells earlier than 𝑁 x- x 𝑇 after the end of the last received
downlink symbol in the same or different cell within the group of cells where 𝑁 x- x is given by Table
4.3.2-3
A UE not capable of full-duplex communication among a group of cells is not expected to receive in
the downlink in one cell within the group of cells earlier than 𝑁 x- x 𝑇 after the end of the last
1. If we take 𝜇 = 0, the number of slots in a sub frame is 1. The total number of slots, therefore,
in a frame is 1 × 10 = 10. For different DL:UL ratios the slot structures are as follows
Ratio 1:1 Ratio 1:4 Ratio 4:1
Sub Frame ID Slot Type Sub Frame ID Slot Type Sub Frame ID Slot Type
1 UL 1 UL 1 UL
2 DL 2 DL 2 DL
3 UL 3 UL 3 DL
4 DL 4 UL 4 DL
5 UL 5 UL 5 DL
6 DL 6 UL 6 UL
7 UL 7 DL 7 DL
8 DL 8 UL 8 DL
9 UL 9 UL 9 DL
10 DL 10 UL 10 DL
2. For 𝜇 = 1, the number of slots in a sub frame is 2. The total number of slots, therefore, in a
frame is 2 × 10 = 20. For different DL:UL ratios the slot structures are as follows
For a DL/UL mixed configuration, the first slot in NetSim always UL and the second slot is always
DL, and subsequent slots are based on the DL:UL ratio set.
Perfect CSIT and CSIR: The channel matrix H is assumed to be known perfectly and instantaneously
at the transmitter and receiver, respectively. With perfect CSIT the transmitter can adapt its
transmission rate (MCS) relative to the instantaneous channel state (SNR).
The CQI indices and their interpretations are given in Table 5.2.2.1-2 or Table 5.2.2.1-4 for reporting
CQI based on QPSK, 16QAM and 64QAM. The CQI indices and their interpretations are given in
Table 5.2.2.1-3 for reporting CQI based on QPSK, 16QAM, 64QAM and 256QAM.
A CQI is computed for all the symbols in one TB, based on the SNR calculated on the data channels
(DL and UL). The SNR calculation is done at the start of the simulation, then every UE measurement
interval and at every instant a UE moves. In calculating SNR, the noise power is obtained from 𝑁 =
𝑘 × 𝑇 × 𝐵. Based on the SNR, the Adaptive Modulation and Coding (AMC) functionality determines
the values of Q, the modulation order, and R, the code rate, in the TBS formula. The SNR is
computed on a per UE level for UL and DL.
The modulation order and code rate is based on the table chosen by the user. In the GUI users can
se e t “t b e1” corresponding to Table 5.2.2.1-2), “t b e2” (corresponding to Table 5.2.2.1-3) or
“t b e3” (corresponding to Table 5.2.2.1-4). Block error probability is currently not implemented in
NetSim and hence is not used for deciding the table.
NetSim does not implement Sub-band Offset. The AMC determines a wideband CQI which indicates
the highest rate Modulation and coding scheme (MCS), that it can reliably decode, if the entire
system bandwidth were allocated to that user.
A combination of modulation scheme and transport block size corresponds to a CQI index if:
- the combination could be signaled for transmission on the PDSCH in the CSI reference
resource according to the Transport Block Size determination described in Subclause 5.1.3.2,
and
3.9.11 Efficiency
𝐸𝑏
𝐸𝑓𝑓𝑖𝑐𝑖𝑒𝑛𝑐𝑦 = 𝑙𝑜𝑔2 (1 + )
𝑁0
𝐸𝑏
Where 𝑁0
is the ratio of the signal to noise in linear power scale, while SNR is the ratio in
To determine the modulation order, target code rate, and transport block size(s) in the physical
downlink shared channel, the UE shall first.
- determine the modulation order (𝑄𝑚 ) and target code rate (𝑅) based on the procedure
defined in Subclause 5.1.3.1, and
and second
- the UE shall use the number of layers (𝜐), the total number of allocated PRBs before
rate matching (𝑛𝑃𝑅𝐵 ) to determine to the transport block size based on the procedure
defined in Subclause 5.1.3.2.
′ 𝐶𝑖′ X 1
2max (0,𝜇−𝜇 ) . ∑ ⌊ ⌋ 𝑥𝑖 . 𝐹𝑖 > ⌈ ⌉ . . 𝑇𝐵𝑆𝐿𝐵𝑅𝑀
𝐿𝑖 4 𝑅𝐿𝐵𝑅𝑀
𝑖∈𝑆
- S is the set of TBs belonging to PDSCH(s) that are partially or fully contained in the
consecutive-symbol duration
- 𝐶𝑖′ is the number of scheduled code blocks for as defined in [5, 38.212].
TS 38.212]
𝑗
- 𝑘0,𝑖 is the starting location of RV for the 𝑗th transmission
𝑗
- 𝐸𝑖 = min(𝐸𝑟 ) of the scheduled code blocks for the 𝑗th transmission
- 𝜇′ corresponds to the subcarrier spacing of the BWP (across all configured BWPs of a
carrier) that has the largest configured number of PRBs
- in case there is more than one BWP corresponding to the largest configured number of
PRBs, 𝜇′ follows the BWP with the largest subcarrier spacing.
If the UE skips decoding, the physical layer indicates to higher layer that the transport block is
not successfully decoded.
where
𝜇 10−3
- 𝑇𝑠 = 𝑠𝑙𝑜𝑡 where is the numerology of the PDSCH
2𝜇 ∙𝑁𝑠𝑦𝑚𝑏
𝐴
- for the 𝑗th TB, 𝑉𝑗,𝑚 = 𝐶′ ∙ ⌊𝐶 ⌋
- 𝐴 is the number of bits in the transport block as defined in Subclause 7.2.1 [5, TS 38.212]
- 𝐶 is the total number of code blocks for the transport block defined in Subclause 5.2.2
[5, TS 38.212]
- 𝐶′ is the number of scheduled code blocks for the transport block as defined in Subclause
5.4.2.1 [5, TS 38.212]
The user can select from the following MCS tables, for each gNB and associated UEs, from
the GUI:
The UE and gNB then uses this table to determine the modulation order 𝑄𝑚 and Code Rate,
𝑅. Different tables can be chosen for DL (gNB to UE) and for UL (UE to gNB). The UL table
index selection based on transform precoding selection in the GUI is given below.
Table 3-8: Uplink MCS Table index determination based on transform precoding and MCS table
selection in GUI
The procedure for TBS determination is standardized in TS 38.214 Section 5.1.3.2 (DL) and
6.1.4.2 (UL). The standard specifies the TBS determination through Step 1, Step 2, Step 3,
and Step 4, all which are implemented in NetSim.
1) The UE shall first determine the number of Res (NRE ) within the slot.
′
- A UE first determines the number of REs allocated for PDSCH within a PRB (𝑁𝑅𝐸 ) by
′ 𝑅𝐵 𝑃𝑅𝐵 𝑃𝑅𝐵 𝑃𝑅𝐵 𝑅𝐵
𝑁𝑅𝐸 = 𝑁𝑠𝑐 × 𝑁𝑠𝑦𝑚𝑏 − 𝑁𝐷𝑀𝑅𝑆 − 𝑁𝑜ℎ , where 𝑁𝑠𝑐 = 12 is the number of subcarriers in
sh
a physical resource block, Nsymb is the number of symbols of the PDSCH allocation
PRB
within the slot, NDMRS is the number of REs for DM-RS per PRB in the scheduled
PRB 𝑃𝑅𝐵
duration and Noh is the overhead configured by higher layer parameter and 𝑁𝑜ℎ is
set to 0.
- A UE determines the total number of REs allocated for PDSCH (NRE ) by 𝑁𝑅𝐸 =
′ )
min(156, 𝑁𝑅𝐸 × 𝑛𝑃𝑅𝐵 , where 𝑛𝑃𝑅𝐵 is the total number of allocated PRBs for the UE.
𝑁𝑖𝑛𝑓𝑜 −24
𝑟𝑜𝑢𝑛𝑑 ( )), where 𝑛 = ⌊log2 (𝑁𝑖𝑛𝑓𝑜 − 24)⌋ − 5 and ties in the round function are
2𝑛
else
′
if 𝑁𝑖𝑛𝑓𝑜 > 8424
′ ′
𝑁𝑖𝑛𝑓𝑜 +24 𝑁𝑖𝑛𝑓𝑜 +24
𝑇𝐵𝑆 = 8. 𝐶 ⌈ ⌉ − 24, where 𝐶 = ⌈ ⌉
8.𝐶 8424
else
′
𝑁𝑖𝑛𝑓𝑜 + 24
𝑇𝐵𝑆 = 8 ⌈ ⌉ − 24,
8
end if
end if
else if Table 5.1.3.1-2 is used and 28 ≤ 𝐼𝑀𝐶𝑆 ≤ 31.
3.9.14.1 Introduction
( )
N ( )
( ) NA +
( )
( )
A
Y S
Figure 3-12: We see the HARQ transmission process. The transmitter sends CBG1 which is errored.
Therefore, the receiver sends a NACK. CBG1 is then retransmitted (transmission attempt 2). The
receiver then soft combines the first and second transmissions, which is successful and hence
sends back an ACK
8. In HARQ-CC, every retransmission contains the same coded bits (information and coding
bits). We abstract soft combining and model it by summing (in linear scale) the SINRs of
transmitted and retransmitted CBGs. The BLER is then looked up for the combined SINR.
9. The New Data Indicator (NDI) flag is set (both in UL and DL) true for transmission of a
new TB
10. HARQ entity is terminated during handover-triggered de-association from a gNB and re-
created at the new gNB after the handover procedure is completed.
11. HARQ retransmissions have priority over new data transmissions. Within a HARQ
process, new data transmissions are not taken up when retransmission data is in the
queue.
12. HARQ processes are multiplexed in time (slots) in a round robin fashion. For example, if
we had a case with 4 HARQ processes then:
1. The HARQ ACK/NACK is sent out-of-band by the receiver immediately after receipt (𝛥𝑡 →
0+ ). It is then instantaneously and correctly received at the transmitter. The ACK/NACKs
are not logged.
1. Packets are either split or combined into transport blocks (TBs) depending on the packet
size and the TB size. It is the TB that needs to be transmitted over the air.
a. Users can set the application layer packet size in NetSim GUI > Application
properties. The packet size at the MAC is the application packet size plus transport
layer and IP layer overheads. Users can obtain the MAC layer packet size from the
packet trace.
b. The TB size is determined by the LTE and 5G NR protocol running in the MAC/PHY.
Users can obtain the TB size from the code block log file (explained subsequently in
section 3.9.13)
2. TB are then split to Code blocks (CBs). The code block size calculation and TB
segmentation is explained in section 3.9.15 below.
a. The max number of CBGs per TB can be set in the NetSim GUI (based on RRC
parameter MAX_CBG_PER_TB in the NetSim GUI)
6. If any CB is in error, the transmitter retransmits the entire CBG to which that CB is a part
of.
7. The receiver then soft combines the first transmission and all subsequent retransmissions
a. Soft combining is modelled by adding their SINRs in the linear scale. For example, if
there were 2 retransmissions, then the combined SINR would be given by
10. If all CBGs (in a TB) are successful, then at the receiver, the TB is sent up to the RLC
2. Again, consider a multi-layer scenario with CBG errors in 2 or more layers. How many
PRBs should then be allocated for retransmissions and how many for new data from
different UEs? In such cases NetSim calculates the PRBs required for retransmission as
the max of PRBs required for retransmission in each layer.
3.9.14.6 Logging
Figure 3-13: HARQ log file showing code block transmission. Here CBS_ represents the information
bits within a code block (CBS column).
1. Transmission attempts 1, 2, 3 and 4 are indexed as 0, 1, 2, 3. If the 4th attempt is errored,
the CBG is dropped.
2. et t e y s“ et” , es t s, s et . ee e,
the packet trace logs a packet in the MAC OUT of the transmitter and subsequently if
received successfully at the MAC IN of the receiver. If the packet errored, it is also marked
in the packet trace.
5. The remarks column would have messages for HARQ preparation and would be blank for
actual transmissions.
Figure 3-14: HARQ log showing HARQ working via information provided in the Remarks columns
There are ongoing discussions of abandoning of HARQ for the 1 ms end-to-end latency use
case of URLLC. This decision implies that the code rate had to be lowered such that a single
shot transmission, i.e., no retransmissions and no feedback, achieves the required BLER.
NetSim allows users to turn HARQ OFF via the GUI. Note that the code block log will continue
to be written. Users will notice that errored CBGs are not retransmitted if HARQ is turned OFF.
Since the CB/CBG is in error, that entire TB to which it belongs will be in error.
Users can inspect the packet trace and will see large numbers of packets errors if HARQ is
turned OFF and if the UE is seeing a high BLER.
1. If the transport block size is larger than 3824, a 16-bit CRC is added at the end of the
transport block or 24-bit CRC is added.
2. The transport block is divided into multiple equal size code blocks when the transport
block size exceeds a threshold.
4. For QC-LDPC base graph 2, the threshold is equal to 3840. In 5G NR, the maximum
code block size number is 8448.
5. An additional 24-bit CRC is added at the end of each code block when there is a
segmentation.
LDPC BG 1, CBS Max, (𝐾𝑐𝑏 ) = 8448, LDPC BG 2, CBS Max, (𝐾𝑐𝑏 ) = 3840
Y S
Y S N G S
N
= =
=
𝐿 = Extra CRC bits, 𝐶 = Number of Code blocks, 𝑇𝐵𝑆 = Size of Transport block,
𝐾′ = Information bits in code block. The base matrix expansion factor 𝑍𝑐 is calculated by
selecting minimum 𝑍𝑐 in all sets of lifting size tables, such that: 𝐾𝑏 × 𝑍𝑐 ≥ 𝐾. 𝐾𝑏 denotes the
number of information bit columns for the lifting size 𝑍𝑐.
NetSim GUI allows users set the BLER, via the BLER drop down option. This option has two
settings, and each setting in-turn has different options for MCS selection. Both BLER and MCS
selection are global options and will apply to all gNBs and UEs in both DL and UL in the
network scenario.
1. Zero BLER
▪ MCS is chosen from the 3GPP (spectral efficiency to MCS) table assuming ideal
Shannon rate whereby
▪ MCS is chosen from the 3G (spectral efficiency to MCS) table per the following
expression provided in TR 36.942:
As explained in the assumptions, NetSim does not model physical control channels or
reference signals. All measurements are made on the physical data channels. The downlink
received SNR is determined from large scale pathloss and shadowing calculated per the
stochastic propagation models in the 3GPPTR38.900 standard, and fast fading calculated
from the H matrix. This SNR calculation is done at the start of the simulation, and then at every
instant a UE moves. It is a single wideband measurement at the center frequency. Interference
from other gNBs is not considered in the SNR calculations.
Out of coverage in NetSim is based on the calculated spectral efficiency of the physical data
𝐸
channel. Spectral Efficiency is equal to 𝑙𝑜𝑔2 (1 + 𝑁𝑏 ). A UE is out-of-coverage when this
0
spectral efficiency falls below a threshold. This threshold is the value of the spectral efficiency
of index 1 per 3GPP 38.214 Table 5.2.2.1.-2 for CQI Table 1, or 5.2.2.1.-3 for CQI Table 2, or
5.2.2.1.-4 for CQI Table 3.
The NetSim log would report CQI as 0 whenever this condition occurs. Note that the RRC
connection is not released and NetSim does not currently model Radio Link Failures (RLF). If
t e ’s s e t e i ie y, it t e s me se i N i sses t e t es , data
transmissions . e t m bi ity, i t e ’s s e t e i ie y m i ee t N ,
crosses threshold then handover procedure is initiated.
In NetSim carrier aggregation (CA) is done in both DL and in the UL. When doing CA, the PHY
layer is separate for each component carrier (CC). Thus, each CC will have a different
pathloss, SINR and TBS. Then the resources of all component carriers (CCs) are pooled at
the MAC, and scheduling is across the pooled resources. However, in practice each UE may
be ssi e es es m ti . Si e NetSim es ’t m e e e y selective
channel fading, there is generally negligible difference in network performance between
allotting from a pool vs. allotting from one CC. The exception is when the data demand from
any UE is greater than the capacity of a CC.
The Intraband CA configuration is based on TR 38716 01-01 Rel 16 NR. The interband CA
configuration is based on 38 than716 02-00 for 2 bands DL / x bands UL, and TR 38.716 03
01 for 3 bands DL and 1 band UL. Carrier aggregation can be configured in the gNB's Physical
layer properties. Following are the various configuration options that are available:
TDD Bands
CA Configuration Table
CA Configuration CA CA Type Frequency Uplink Low Uplink High
Count Range (MHz) (MHz)
INTER_BAND_CA
CA_2DL_1UL_n39_n41 2 CA1, CA2 FR1 1880, 2496 1920, 2690
▪ BLER
NetSim currently assumes an error free channel. While received SNR is calculated
NetSim currently does not further calculate the BLER based on the received SNR
▪ HARQ
▪ Physical control channels
While calculating the TBS capacity, a fixed overhead is reduced to account for the
control channels. This overhead fraction varies for UL and DL, across FR1 and FR2,
and is provided in the standard.
▪ Detailed antenna models: NetSim currently supports only Omnidirectional antennas. As
yet there are no options to set (i) antenna patterns and (ii) the elevation and azimuth
angles to represent the antenna orientation
▪ Random access procedure
▪ Power control
▪ Uplink interference.
Where,
- Note that normal cyclic prefix is assumed, which has 14 ODFM symbols per slot or
14 × 2𝜇 symbols per millisecond.
𝐵𝑊(𝑗),𝜇
- 𝑁𝑃𝑅𝐵 is the maximum Resource Block allocation in bandwidth 𝐵𝑊 (𝑗) with
numerology 𝜇 as defined in 5.3 TS 38.101-1 [2] and 5.3 TS 38.101-2 [3], where 𝐵𝑊 (𝑗)
is the UE supported maximum bandwidth in the given band or band combination. The
number of subcarriers per physical resource block (PRB) is fixed to 12.
NOTE: Only one of the UL or SUL carriers (the one with the higher data rate) is counted for a
cell operating SUL.
The approximate maximum data rate can be computed as the maximum of the approximate
data rates computed using the above formula for each of the supported band or band
combinations.
For EUTRA in case of MR-DC, the approximate data rate for a given number of aggregated
carriers in a band or band combination is computed as follows.
𝐽
−3
𝑑𝑎𝑡𝑎 𝑟𝑎𝑡𝑒(𝑖𝑛 𝑀𝑏𝑝𝑠) = 10 ∑ 𝑇𝐵𝑆𝑗
𝑗=1
Where,
• NetSim GUI (gNB properties > Interface (5G_RAN) > Physical Layer > Channel Model)
allows users to configure both indoor and outdoor PL models. Both indoor and outdoor
options are shown in the GUI irrespective of the underlying scenario.
• Based on gNBs/UEs placement within or outside a building NetSim automatically
chooses the indoor/outdoor propagation models. The selection is as follows:
o Outdoor gNB to Outdoor UE: Outdoor PL model
o Outdoor gNB to Indoor UE: Outdoor PL till building, then penetration (O2I) loss,
and finally indoor PL within the building
o Indoor gNB to Indoor UE: Indoor PL model
o An Indoor gNB cannot be connected to an Outdoor UE in NetSim
The pathloss models are summarized in Table 7.4.1-1 and the distance definitions are
indicated in Figure 7.4.1-1 and Figure 7.4.1-2. Note that the distribution of the shadow fading
is log-normal, and its standard deviation for each scenario is given in Table 7.4.1-1.
Figure7.4.1-1: Definition of 𝒅𝟐𝑫 and 𝒅𝟑𝑫 Figure 7.4.1-2: Definition of 𝒅𝟐𝑫−𝒐𝒖𝒕 , 𝒅𝟐𝑫−𝒊𝒏 ,
for outdoor UTs and 𝒅𝟑𝑫−𝒐𝒖𝒕 , 𝒅𝟑𝑫−𝒐𝒖𝒕 for indoor UTs
Note that,
Pathloss [dB], fc is in GHz and d is in meters, see note 6 Shadow Applicability range,
LOS/NLOS
ℎ = 5𝑚
− 𝑚𝑖𝑛( 0.044ℎ1.72 , 14.77) + 0.002 𝑙𝑜𝑔10 ( ℎ)𝑑3D h = avg. building height
W = avg. street width
𝑃𝐿2 = 𝑃𝐿1 (𝑑BP ) + 40 𝑙𝑜𝑔10 ( 𝑑3D /𝑑BP ) The applicability
RMa
ranges:
𝑃𝐿RMa−NLOS = 𝑚𝑎𝑥( 𝑃𝐿RMa−LOS , 𝑃𝐿′RMa−NLOS ) 5𝑚 ≤ ℎ ≤ 50𝑚
for 10𝑚 ≤ 𝑑2D ≤ 5km 5𝑚 ≤ 𝑊 ≤ 50𝑚
𝜎SF = 8 10m ≤ ℎBS ≤ 150𝑚
NLOS
LOS
𝟑 × 𝟏𝟎𝟖 𝒎/𝒔 is the propagation velocity in free space, and 𝒉′𝑩𝑺 and 𝒉′𝑼𝑻 are the effective antenna
heights at the BS and the UT, respectively. The effective antenna heights h'BS and h'UT are
computed as follows: 𝒉′𝑩𝑺 = 𝒉𝑩𝑺 − 𝒉𝑬 , 𝒉′𝑼𝑻 = 𝒉𝑼𝑻 − 𝒉𝑬 , where 𝒉𝑩𝑺 and 𝒉𝑼𝑻 are the actual
antenna heights, and 𝒉𝑬 is the effective environment height. For UMi 𝒉𝑬 = 𝟏. 𝟎𝒎. For UMa
𝟏
𝒉𝑬 = 𝟏𝒎 with a probability equal to and chosen from a discrete uniform distribution
𝟏+𝑪(𝒅𝟐𝑫 ,𝒉𝑼𝑻 )
uniform (𝟏𝟐, 𝟏𝟓, … , (𝒉𝑼𝑻 − 𝟏. 𝟓)) otherwise. With 𝐂(𝒅𝟐𝑫 , 𝒉𝑼𝑻 ) given by
Where,
𝟎 , 𝒅2D ≤ 𝟏𝟖𝒎
𝒈(𝒅2D ) = {𝟓 𝒅2D 𝟑 −𝒅2D .
( ) 𝒆𝒙𝒑 ( ) , 𝟏𝟖𝒎 < 𝒅2D
𝟒 𝟏𝟎𝟎 𝟏𝟓𝟎
Note that 𝒉𝑬 depends on 𝒅𝟐𝑫 and 𝒉𝑼𝑻 and thus needs to be independently determined for every
link between BS sites and UTs. A BS site may be a single BS or multiple co-located BSs.
Note 2: The applicable frequency range of the PL formula in this table is 𝟎. 𝟓 < 𝒇𝒄 < 𝒇𝑯 GHz, where
𝒇𝑯 = 𝟑𝟎 GHz for RMa and 𝒇𝑯 = 𝟏𝟎𝟎 GHz for all the other scenarios. It is noted that RMa
pathloss model for > 𝟕 GHz is validated based on a single measurement campaign conducted
at 24 GHz.
Note 3: UMa NLOS pathloss is from TR36.873 with simplified format and
𝟑 × 𝟏𝟎𝟖 𝒎/𝒔 is the propagation velocity in free space, and 𝒉𝑩𝑺 and 𝒉𝑼𝑻 are the antenna
heights at the BS and the UT, respectively.
Note: The LOS probability is derived with assuming antenna heights of 3m for indoor, 10m for UMi,
and 25m for Uma
Standards Table 7.4.2-1: LOS probability
The pathloss incorporating O2I building penetration loss is modelled as in the following:
PL𝑛𝑝𝑖 is an additional loss is added to the external wall loss to account for non-perpendicular
incidence; 𝐿𝑚𝑎𝑡𝑒𝑟𝑖𝑎𝑙_𝑖 = 𝑎𝑚𝑎𝑡𝑒𝑟𝑖𝑎𝑙_𝑖 + 𝑏𝑚𝑎𝑡𝑒𝑟𝑖𝑎𝑙_𝑖 , 𝑓 is the penetration loss of material 𝑖 example
values of which can be found in Table 7.4.3-1; 𝑝𝑖 is proportion of 𝑖-th materials, where ∑𝑁
𝑖=1 𝑝𝑖 =
Table 7.4.3-2 gives 𝑃𝐿𝑡𝑤 , 𝑃𝐿𝑖𝑛 , and 𝜎𝑃 for two O2I penetration loss models. The O2I
penetration is UT-specifically generated and is added to the SF realization in the log domain.
Indoor
Path loss through external Standard
loss:
wall: deviation:
PLin in
PLtw in [dB] σP in [dB]
[dB]
−𝐿glass
Both low-loss and high-loss models are applicable to UMa and UMi-Street Canyon.
The O2I Models such as Low Loss and High Loss are associated with the type of material
used in the buildings and is used to calculate the penetration loss in case of an indoor
scenario. In case of scenario where UE's are not inside a building these parameters will not
have any impact on the results. In an indoor scenario, users will be able to notice difference in
the SNR.
Note that this implementation interfaces with MATLAB R2020(a/b). Lower versions of MATLAB
are not directly supported.
3.12.1 Configuration
Additional Loss
Associated Parameters Value
Model
Rain Rate (mm/hr) 16(default), Range 0 to 100
Tilt Angle 0(default), Range -90 to 90
RAIN
Elevation Angle 0(default), Range -90 to 90
Exceedance Rain (%) 0.01(default), Range 0.001 to 1
Ambient Temperature (Celsius) 15(default), Range -50 to 50
101300(default), Range 50000 to
GAS Dry Air Pressure (pa)
300000
Water Vapor Density (𝑔/𝑚3 ) 4(default), Range 1 to 10
Ambient Temperature (Celsius) 15(default), Range -50 to 50
FOG 3
Liquid Water Density ((𝑔/𝑚 ) 0.5(default), Range 0 to 5
Table 3-10: Parameters in the various MATLAB additional loss models
Note: Rain and Gas models support frequencies from 1 to 1000 GHz and Fog model supports
frequencies from 10 to 1000 GHz only.
When Additional Loss Model option is set to MATLAB NetSim Simulation console waits for
MATLAB Interface process to connect.
Figure 3-18: NetSim Simulation console waits for MATLAB Interface process to connect
MATLAB Interface process can be started and connected to the running instance of NetSim
simulation using one of the following methods depending on where MATLAB is installed:
▪ If MATLAB is installed in the same system where NetSim is installed. MATLAB Interface
process can be launched directly from the design window of NetSim.
o Go to Options Menu and select the Open MATLAB Interface option as shown below:
Downlink I te e e e e be i e i t e N ’s _ AN i te e e ties
under channel models section of Physical Layer as shown below.
The Wyner model is widely used to due to its simplicity and analytical tractability. In this model:
• We model DL interference from any number of interfering BSs. Let 𝐵𝑆𝑖 be the serving
BS to 𝑈𝐸𝑘 . Let 𝐵𝑆𝑗 be any other BS (𝑗 ≠ 𝑖). Then the distance between 𝑈𝐸𝑘 and 𝐵𝑆𝑖
𝐵𝑆 𝐵𝑆
is denoted as 𝐷𝑈𝐸𝑖𝑘 , while the distance between UE and 𝐵𝑆𝑗 is denoted as 𝐷𝑈𝐸𝑗𝑘 .
𝐵𝑆𝑗 𝐵𝑆
(𝐷𝑈𝐸 −𝐷𝑈𝐸𝑖 )
• A UE sees interference if 𝐾
𝐵𝑆𝑗
𝐾
is within a user defined threshold (for example,
𝐷𝑈𝐸
𝐾
𝐵𝑆
𝐷𝑈𝐸𝑖 𝐵𝑆 𝐵𝑆
20%). This ratio is also equal to 1 − 𝐵𝑆𝑗
𝑘
. When 𝐷𝑈𝐸𝐾𝑖 ≤ 𝐷𝑈𝐸𝐾𝑗 , we see that 0 ≤
𝐷𝑈𝐸
𝐾
𝐵𝑆𝑗 𝐵𝑆
(𝐷𝑈𝐸 −𝐷𝑈𝐸𝑖 ) 𝐵𝑆
𝐵𝑆 𝐵𝑆
𝐾
𝐵𝑆𝑗
𝐾
≤ 1. The ratio is 0 when 𝐷𝑈𝐸𝑖𝐾 = 𝐷𝑈𝐸𝑗𝐾 and is 1 when 𝐷𝑈𝐸𝐾𝑖 = 0. When
𝐷𝑈𝐸
𝐾
𝐵𝑆 𝐵𝑆 𝐵𝑆
𝐷𝑈𝐸𝑖𝐾 = 𝐷𝑈𝐸𝐾𝑗 the UE is equidistant from both BS i.e., at the cell edge. When 𝐷𝑈𝐸𝑖𝐾 = 0,
the UE is at the centre of the serving BS, 𝐵𝑆𝑖 .
• Users at the cell-edge will see out of cell interference; as the user moves closer to the
cell centre, it sees lesser interference.
• We call this user defined threshold as differential distance ratio threshold and denote
it by 𝐷𝐷𝑅𝑡ℎ . The DDR threshold is used to define 𝐾 thresholds, which are in turn used
to determine the out of cell interference experienced by 𝑈𝐸𝑘 , as explained below. First,
𝐵𝑆 𝐵𝑆
we bin the 𝐷𝐷𝑅𝑡ℎ , conditional on 𝐷𝑈𝐸𝑖𝐾 ≤ 𝐷𝑈𝐸𝑗𝐾 , into K steps, as follows:
𝐵𝑆 𝐵𝑆
(𝐷𝑈𝐸𝐾𝑗 − 𝐷𝑈𝐸𝑖𝐾 ) 𝐷𝐷𝑅𝑡ℎ
0≤ 𝐵𝑆 <( )×1
𝐷𝑈𝐸𝐾𝑗 𝐾
𝐵𝑆 𝐵𝑆
𝐷𝐷𝑅𝑡ℎ (𝐷𝑈𝐸𝑗𝐾 − 𝐷𝑈𝐸𝑖𝐾 ) 𝐷𝐷𝑅𝑡ℎ
( )×1 ≤ 𝐵𝑆𝑗 <( ) ×2
𝐾 𝐷𝑈𝐸𝐾 𝐾
…
𝐵𝑆 𝐵𝑆
𝐷𝐷𝑅𝑡ℎ (𝐷𝑈𝐸𝑗𝐾 − 𝐷𝑈𝐸𝑖𝐾 ) 𝐷𝐷𝑅𝑡ℎ
( ) × (𝐾 − 1) ≤ 𝐵𝑆 <( )×𝐾
𝐾 𝐷𝑈𝐸𝐾𝑗 𝐾
𝐵𝑆 𝐵𝑆
𝐷𝐷𝑅𝑡ℎ (𝐷𝑈𝐸𝐾𝑗 − 𝐷𝑈𝐸𝐾𝑖 )
( )×𝐾 ≤ 𝐵𝑆
𝐾 𝐷𝑈𝐸𝐾𝑗
Where 𝐷𝐷𝑅𝑡ℎ , is a user input varying from 0.00 to 1.00 (default is 0.1 or 10%), and K,
the number of steps, is a user input varying from 1 to 4 (default is 1). For example: if
the given value for the DDR is 0.2 and nSteps is 4, then the range of the curves will be
0.2
from 0 to 4
= 0.05, i.e 0 to 0.05, 0.05 to 0.10, 0.10 to 0.15, 0.15 to 0.2.
Figure 3-23: Interference zones are the regions within the four curves and the cell boundary of 𝒈𝑵𝑩𝒊 .
This example is for a case involving just 2 BSs with 𝑫𝑫𝑹 = 𝟎. 𝟒 and 𝑲 = 𝟒. The four curves are
𝑩𝑺𝒋 𝑩𝑺
(𝑫𝑼𝑬 −𝑫𝑼𝑬𝒊 ) 𝒌 𝟐𝒌 𝟑𝒌 𝟒𝒌
𝑲 𝑲
therefore the equations where 𝑩𝑺𝒋 is equal to = 𝟎. 𝟏, = 𝟎. 𝟐, = 𝟎. 𝟑, and = 𝟎. 𝟒. The
𝑫𝑼𝑬 𝟒 𝟒 𝟒 𝟒
𝑲
handover interference region is also shown.
𝐵𝑆𝑗 𝐵𝑆
(𝐷𝑈𝐸 −𝐷𝑈𝐸𝑖 )
• In case 𝐾
𝐵𝑆𝑗
𝐾
> 𝐷𝐷𝑅𝑡ℎ , the out of cell interference seen at the UE is set to 𝐼𝐾 .
𝐷𝑈𝐸
𝐾
The default value of 𝐼𝐾 is 0, i.e., cell centre users do not see any out of cell interference.
The default values of 𝐼𝑘 for 𝑘 = 1, 2, … , 𝐾 − 1 is 10 dB.
• In NetSim, handover is triggered when the signal strength from 𝐵𝑆𝑗 is offset (3dB by
default) higher than signal strength from 𝐵𝑆𝑖 . A handover is not triggered when 𝑈𝐸𝑘 is
equidistant from both BSs but only when it is slightly nearer to 𝐵𝑆𝑗 . Therefore, the short
𝐵𝑆 𝐵𝑆
time when 𝐷𝑈𝐸𝑖𝐾 ≥ 𝐷𝑈𝐸𝑗𝐾 is a special case requiring a different interference power. We
te m t is i te e e e s “H e i te e e e” is se te se i t.
Handover interference is denoted as 𝐼−1 and −3𝑑𝐵 ≤ 𝐼−1 ≤ 0 𝑑𝐵.
• Sample interference file format and example:
In this model NetSim computes interference from one or more interfering base-stations (BS or
gNB) at a UE, based on (i) the gNB UE locations and (ii) the pathloss between the interfering
gNB and the UE.
NetSim supports various 3GPP propagation models to calculate the pathloss between every
BS (gNB) and every UE. One of the parameters in the pathloss equations is the distance
between the BS and the UE. Some of the other user settable parameters used in the 3GPP
models are (i) Centre frequency (chosen from the band selected) (ii) Rural or Urban
environments (iii) UE-BS channel is in LOS or NLOS (iv) Shadow-fading in the UE-BS channel
(v) Indoor or outdoor UE location, etc., Complete details of the 3GPP pathloss models
supported in NetSim are given in 3.11.1.
Let 𝐵𝑆𝑖 be the serving BS to 𝑈𝐸𝑘 . Let 𝐵𝑆𝑗 be any other BS (𝑗 ≠ 𝑖). 𝑈𝐸𝑘 communicates with
𝐵𝑆𝑖 while all other BSs (𝑗 ≠ 𝑖) act as interferers. The uplink interference from the UEs in the
system is not modeled in NetSim at present. Thus, only downlink connections experience
interference.
𝐵𝑆
The distance between 𝑈𝐸𝑘 and 𝐵𝑆𝑖 is denoted as 𝐷𝑈𝐸𝑖𝑘 , while the distance between UE and
𝐵𝑆
𝐵𝑆𝑗 is denoted as 𝐷𝑈𝐸𝑗𝑘 . The power of the interfering signal from any 𝐵𝑆𝑗 at any 𝑈𝐸𝑘 depends
on (i) the transmit power of the interfering BS and (ii) pathloss between the interfering BS and
the UE. It can therefore be expressed as
𝐵𝑆 𝐵𝑆
𝐼𝑈𝐸𝑗𝑘 = 𝑃𝐵𝑆𝑗 − 𝑃𝐿𝑈𝐸𝑗𝑘
𝐵𝑆
where 𝑃𝐵𝑆𝑗 is the transmit power of 𝐵𝑆𝑗 , 𝑃𝐿𝑈𝐸𝑗𝑘 represents the 3GPP model based pathloss
𝐵𝑆
between 𝐵𝑆𝑗 and 𝑈𝐸𝑘 . This pathloss is dependent on 𝐷𝑈𝐸𝑗𝑘 and the channel between 𝐵𝑆𝑗 and
𝑈𝐸𝑘 . The interference powers (linear) from all interfering BSs (i.e., apart from the serving BS)
are added to the noise power (in linear scale) and we get the expression
SINR determines the 5G PHY rate (throughput) that the UE would get. This is because the
PHY Rate depends on the CQI/MCS which is in turn depends on SINR. Section 3.2 explains
the details.
The Wyner model is approximate but is computationally faster, while the geometric model is
precise but computationally slower due to the calculations involved.
• The received power at 𝑈𝐸𝑘 from 𝐵𝑆𝑖 , with transmit power 𝑃𝑖 is given (in the linear scale)
as
𝐵𝑆 𝑃𝑖
𝑃𝑈𝐸𝑘𝑖 = ( 𝐵𝑆𝑖 )
𝑃𝐿𝑈𝐸𝑘
𝑗
• 𝐼𝑖𝑘 or the interference in linear scale at a 𝑈𝐸𝑘 (associated with 𝐵𝑆𝑖 ) from 𝐵𝑆𝑗
• To normalize the power should we further multiply by the ratio given below
𝑠𝑙𝑜𝑡
𝑗 𝑅𝐵𝑈𝐸 𝑘
𝐼𝑖𝑘 = Σ𝑗 𝐼𝑖𝑘 × ( 𝑠𝑙𝑜𝑡 )
𝑅𝐵𝑡𝑜𝑡𝑎𝑙
• Assumptions:
A1. The above formula assumes the interference seen by 𝑈𝐸𝑘 is proportional to the
number of RBs allotted to 𝑈𝐸𝑘
A2. Fast fading is not accounted for in the interfering signal calculations since it
would require too much computational time, given that it needs to be re-
calculated every coherence time, not just between BS and its associated UEs
but between a BS and all the UEs in all cells. Hence NetSim calculates average
interfering signal power and not instantaneous interfering signal power, which
is a well-accepted assumption in multi-cell MIMO literature. Recall that NetSim
accounts for fast fading in the direct signal power calculations.
• The total noise seen will be
𝑠𝑙𝑜𝑡
𝑘 × 𝑇 × 𝑅𝐵𝑈𝐸 𝑘
𝑠𝑙𝑜𝑡
𝐵𝑆 𝑅𝐵𝑈𝐸
• The signal power 𝑃𝑈𝐸𝑘𝑖 × ( 𝑠𝑙𝑜𝑡
𝑘
)
𝑅𝐵𝑡𝑜𝑡𝑎𝑙
Therefore,
𝑠𝑙𝑜𝑡
𝐵𝑆 𝑅𝐵𝑈𝐸
𝑘
𝑃𝑈𝐸𝑘𝑖 × ( ) 𝐵𝑆
𝑠𝑙𝑜𝑡
𝑅𝐵𝑡𝑜𝑡𝑎𝑙 𝑃𝑈𝐸𝑘𝑖
𝑆𝐼𝑁𝑅 = 𝑠𝑙𝑜𝑡
= 𝑗
𝑅𝐵𝑈𝐸 𝑠𝑙𝑜𝑡
𝑠𝑙𝑜𝑡 𝑗 𝑘 𝑘 × 𝑇 × 𝑅𝐵𝑡𝑜𝑡𝑎𝑙 + Σ𝑗 𝐼𝑖𝑘
𝑘×𝑇× 𝑅𝐵𝑈𝐸 𝑘
+ Σ𝑗 𝐼𝑖𝑘 ×( 𝑠𝑙𝑜𝑡 )
𝑅𝐵𝑡𝑜𝑡𝑎𝑙
NetSim accounts for the Rx power from neighbouring cells, in a statistical sense, as explained
below. Let us consider an example of two BSs and two UEs with BS1 transmitting to UE1 and
BS2 transmitting to UE2. The BSs employ digital (Eigen) beamforming to the UE they are
transmitting to, so there is no channel-dependent beamforming between BS1 and UE2 or BS2
and UE1.
Now, since we model the fast-fading component of the channel as having i.i.d. circularly
symmetric complex Gaussian entries, the expected interference power at UE2 is simply the
transmit power by BS1 times the path loss between BS1 and UE2. This because the long-term
statistical average of the square of the magnitude inner product between the (unit-norm)
beamforming vector employed by BS1 and the channel between BS1 and UE2 is unity.
3.13.4.3 Limitations
• In the above interference formula NetSim assumes that all interfering BSs transmit data
in that slot.
• The interference calculations need to be done for each slot. Enabling interference will
slow down the simulation.
3.14 5G Core
NetSim 5G core functionality was introduced in NetSim v13. This 5G core includes entities,
which reside within the core devices (and partially within the gNB) such as Session
Management Function (SMF), Access and Mobility Management Function (AMF) and User
Plane Function (UPF) and the protocols these entities use for operation.
The NetSim 5G core model provides users the means to simulate the end-to-end IP
connectivity. It supports interconnection of multiple UEs to the Internet/Cloud via the Radio
Figure 3-24: 5G Network scenario consisting of multiple UEs and gNBs connected to 5G Core - AMF,
SMF and UP. The UPF is connects out to the Data Network/ Internet.
NetSim 5G Core model has been designed as follows:
In the 5G standalone architecture, the roles played by each of the entities are different.
3.14.1 5G Interfaces
1. 5G_N1_N2: N1-N2 is the reference point between the gNB (gNodeB) and the AMF.
2. 5G_N3: Interface between the RAN (gNB) and the (UPF).
3. 5G_N4: Interface between the Session Management Function (SMF) and the UPF
4. 5G_N6: Interface between the Data Network (DN) and the UPF.
5. 5G_N11: Interface between the SMF and AMF.
6. 5G_XN: Interface between two RAN (gNB) nodes.
The N11 interface provides control plane interaction between the SMF and the AMF using the
GTPv2-C protocol specified in [TS29274]. In NetSim, this interface is modelled with direct
interaction between the SMF and the AMF objects, without implementing the encoding of the
messages.
Of these primitives, the first two are used during the initial UE attachment for the establishment
of the N2-U bearers; the other two are used during handover to switch the N2-U bearers from
the source gNB to the target gNB as a consequence of the reception by the AMF of a PATH
SWITCH REQUEST NG-AP message.
Figure 3-26: A 5G network scenario with a Single UE connected to a gNB which is connected to the
5G Core and the UE downloads data from the Server (Wired Node)
As an example, consider a 5G network scenario with 5G Core devices (which consists of AMF,
SMF, UPF and three L2 Switches), a UE which is connected to a gNB, and in the server side,
a Wired Node which is connected to a Router which is connected to the 5G core via UPF.
1. Radio Resource Control – MIB(Master Information Block) packets are broadcast by each
gNB to all the UEs. These packets are transmitted periodically every 80 ms.
▪ The transmission of MIB packet starts from the MAC Layer. The transmission time can
be calculated from the MAC Layer Arrival Time in the packet trace.
▪ The size of each MIB packet is 8 Bytes and can be observed in the Phy Layer Payload
field in the packet trace.
2. RRC System Information Block 1 packets are broadcast by the gNBs to all the UEs. These
packets are transmitted periodically every 160ms.
▪ The transmission of SIB1 packet starts from the MAC Layer. The transmission time can
be calculated from the MAC Layer Arrival Time in the packet trace.
▪ The size of each SIB1 packet is 8 Bytes. This can be observed in the Phy Layer Payload
field in the packet trace.
3. After the first set of packets, the cell selection occurs as explained below.
Ver 13.2 Page 99 of 211
▪ The UE attaches itself initially to the gNB from which it receives the highest SNR.
▪ If SNR from multiple gNBs is equal, the UE will attach to the gNB with the lowest ID.
▪ The gNB to which the UE is connected by the user in NetSim GUI at the network design
stage, is only for visual purposes. It plays no role in determining which gNB the UE will
attach to
4. RRC System Information are broadcast by the selected gNBs to all UEs when the cell
selection is complete.
▪ The SI packet is sent only once during the simulation. It is not sent after every Handover.
▪ It occurs at 160.9ms.
▪ The transmission of SI packet starts from the MAC Layer. The transmission time can be
calculated from the MAC Layer Arrival Time in the packet trace.
▪ The size of each SI packet is 8 Bytes. The size of the packet can be calculated from the
Phy Layer Payload field in the packet trace.
5. The RRC Setup Request will be sent by the UE to the connected gNB within 2.5ms of
receipt of RRC SI packet
▪ The RRC Setup Request is sent with the random UE-Identity and an establishment
cause. This can be observed in the Headers column of the packet trace.
▪ RRC Setup Packet Size is 24 Bytes. The size of the packet can be calculated from the
Phy Layer Payload field in the packet trace.
▪ UE stops the timer (T300) when it receives the RRC Setup message.
7. The RRC Setup Complete message is used to confirm the successful completion of an
RRC connection establishment.
If the SNR from another gNB is offset greater than SNR from serving gNB, it leads to handover.
After the handover procedure is completed RRC Reconfiguration would happen between
target gNB and UE. The UE will then send the UE MEASUREMENT REPORT to this gNB.
1. The gNB will introduce the UE to the 5G Core after the initial gNB- UE attachment process.
2. The gNB will send Initial UE message and Registration request to the selected AMF (In
NetSim, there is only one AMF). The message will be transmitted when gNB receives the
first NAS message to be transmitted from the radio link after the RRC Setup Complete
3. Upon receiving the UE message and registration request, the AMF will send Create Session
Request to the SMF in-order to create a session for the UE.
4. The SMF will send the PFCP Session Request to UPF to denote that the UE is present in
the network and the data packet flow may occur to UPF and to create/ establish/ modify
PFCP session for UE.
5. Further, AMF will send the Initial Context Setup Request to the gNB to confirm the setup of
a UE context.
6. The gNB will send Initial Context Setup and Registration Complete message to the AMF
and then the UE will be associated with the core.
NSA leverages the existing LTE radio access and core network (EPC) to anchor 5G NR using
the Dual Connectivity feature. This solution provides a seamless option to deploy 5G services
with very less disruption in the network. The eNB is connected to the EPC through the LTE_S1
interface and to the gNB through the XN interface. The gNB can be connected to the EPC
through the LTE_S1 interface and other gNBs through the XN interface. Similarly, the eNBs
and gNBs will be connected to 5G Core through the N1_N2, and N3 interfaces and gNB-eNB
and gNB-gNB connections through the XN interface. The control packets like RRC MIB, RRC
SIB1, RRC SI in NSA modes will be transmitted from the master nodes to the UE. Similarly,
the UE will send the UE_MEASUREMENT_REPORT and RRC_SETUP messages to the
master nodes. The master node will be selected according to the deployment option selected.
1. Option 3 where only LTE core/ EPC is present and no 5G Core devices are present. Here,
eNB is the Master Cell and gNB is the Secondary Cell. Option 3 is categorized into:
a. Option 3: Only eNB connects to EPC and eNB and gNB connects to the XN interface.
b. Option 3a: Both eNB and gNB connects to the EPC. gNB connects to the XN interface
and eNB does not XN interface.
2. Option 4 where only 5G Core devices are present, and EPC is not available. Here, gNB is
the Master Cell and eNB is the Secondary Cell. Option 4 is categorized into:
a. Option 4: Only gNB connects to all the 5G Core interfaces. eNB connects to the XN
interface.
The standardized NSA EPC networking architecture includes Option 3, and Option 3a
Non-standalone option 3 is where radio access network is composed of eNBs as the master
node and gNBs as the secondary. The radio access network is connected to EPC (Evolved
Packet Core).
3.15.2.1 Option 3
Option 3 represents a network having both LTE and NR radio access but using only the EPC
core of LTE to route the Control signals. In this option, LTE is used as the control plane anchor
for NR, and both LTE and NR are used for user data traffic (user plane).
All uplink/downlink data flows to and from the LTE part of the LTE/NR base station, i.e., to and
from the eNB. The eNB then decides which part of the data it wants to forward to the 5G gNB
over the XN interface. The gNB never communicates with the 4G core network directly.
In the Option 3 networking mode, the XN interface traffic between eNB and gNB.
Traffic is split across 4G and 5G at eNodeB. Hence, eNB is the Master Cell.
In NetSim Option 3 of NSA mode connects the eNB to the EPC using LTE_S1 interface. The
gNBs and eNBs are inter-connected in option 3 using the XN interface via a Layer 2 Switch
and the UEs present in the network consists of two interfaces, an LTE interface and a 5G_RAN
interface.
The data flows from the eNB and the eNB decides which part of data is to be forwarded to the
gNB over the XN interface.
3.15.2.2 Option 3a
In the option 3a, both the eNB and the gNB can directly talk to the LTE core network but they
cannot directly talk with each other over the XN interface. This means that a single data bearer
cannot share the load over LTE and NR.
There is only control plane traffic in the XN interface. The dynamic switching between 5G and
4G is not supported in Option 3a. The traffic is split across 5G and 4G at the EPC.
In NetSim Option 3a of NSA mode connects the eNB and gNB to the EPC using LTE_S1
interface. Hence, the eNB and gNB can directly communicate with the EPC. Since XN interface
is not present for eNB and it is present for gNB in this deployment option, gNB and eNB cannot
communicate with each other. the UEs present in the network consists of two interfaces, an
LTE interface and a 5G_RAN interface.
The EPC or the LTE Core in Option 3/3a is replaced by the 5G Core in Option 4. The master
node is the LTE NR cell or gNB and the secondary node is LTE cell or eNB.
In Option 4 of Non-Stand-alone mode, both LTE and 5G NR radio access technologies are
deployed and controlled through only the 5G Core, i.e., AMF, SMF and UPF.
The gNB has both the NG-U and NG-C interfaces. Both eNB and gNB connects over the XN
interface. The interface between gNB and AMF is called N2 interface and the interface
between gNB and UPF is called N3 interface, So the control plane is over N2 interface and
user plane is over N3 interface.
The eNB is not connected to 5G Core, hence data traffic is split over the XN interface. The
gNB is connected to 5G Core with NG-U and NG-C.
In NetSim, the gNB is connected to the UPF via Switch_4 using the 5G_N3 interface and to
the AMF via Switch_5 using the 5G_N1_N2 interface, hence, gNB communicates directly with
the 5G Core and eNB does not communicate directly with the 5G Core. The gNBs and eNBs
are inter-connected using the XN interface via a Layer 2 Switch and the UEs present in the
network consists of two interfaces, an LTE interface and a 5G_RAN interface.
3.15.3.2 Option-4a
In Option 4a, the eNB is not connected to gNB over XN interface, but it is connected to 5G
Core over the NG-U interface.
The gNB has both NG-U and NG-C interface. Data traffic is split between 4G and 5G at the
5G Core, specifically the UPF.
The eNB has NG-U and NG-C interfaces to 5G Core and eNB connects with gNB over XN
interface. The master node is the LTE cell or eNB and the secondary node is the LTE-NR cell
or gNB in these deployment options.
3.15.4.1 Option-7
In Option 7, the gNB does not communicate to 5G Core. Data traffic flows through eNB
communicating to and from the 5G Core. Some part of the data can be transferred through
gNB over the XN interface.
In NetSim, the eNBs are connected to the UPF via Switch_4 using the 5G_N3 interface and
to the AMF via Switch_5 using the 5G_N1_N2 interface. The gNBs and eNBs are inter-
connected using the XN interface and hence direct communication between eNB and gNB is
possible. The UEs present in the network consists of two interfaces, an LTE interface and a
5G_RAN interface. The data is delivered to the UE when it comes to the 5G NR through the
LTE-RAN.
3.15.4.2 Option-7a
In Option 7a, eNB and gNB are not connected via the XN interface and instead gNB is
connected to 5G Core over NG-U. The eNB is connected to 5G Core over NG-C and NG-U.
Data traffic is split at the 5GC (UPF).
In NetSim, the gNB and eNB are connected to the UPF via Switch_4 using the 5G_N3 interface
and to the AMF via Switch_5 using the 5G_N1_N2 interface. The gNBs does not have an XN
Interface and eNBs inter-connected using the XN interface and hence direct communication
between eNB and gNB is not possible. The UEs present in the network consists of two
interfaces, an LTE interface and a 5G_RAN interface.
The user data goes directly from the 5G Core to the gNB and then to the UE.
eNB is the Master Node and gNB is the Secondary Node in Options 3, 3a.
1. The MN, eNB will broadcast the RRC_MIB packets to the UE every 40 ms and RRC_SIB1
every 80 ms.
2. After the transmission of the RRC_MIB and RRC_SIB1 packets, the eNB will send RRC_SI
packet to the UE.
3. After reception of RRC_SI packet, UE will send RRC_Setup_Request to the eNB.
4. On receiving the RRC_Setup_Request packet, the eNB will acknowledge the request by
transmitting RRC_Setup packet to the UE.
5. The UE will send back the RRC_Setup_Complete packet on the receipt of RRC_Setup
message.
6. After the RRC connection, the MN node will send DC_SEC_CELL_ADDITION_REQUEST
to the SN via the L2Switch.
7. On the receipt of this secondary cell addition request, the SN sends back the response
packet, i.e. DC_SEC_CELL_ADDITION_RESPONSE.
8. The UE will now send the UE_MEASUREMENT_REPORT every 120 ms to the MN which
contains the SNR information. The time interval at which the measurement report is to be
transmitted can be set by the user in the eNB/ gNB properties-> Interface_ LTE/ 5G_RAN
-> Datalink Layer.
Ver 13.2 Page 109 of 211
9. After the UE attachment procedure, the data packets will be transmitted from the server to
the UE based on the splitting algorithm.
10. As per the current splitting algorithm in NetSim, the first data packet will be transmitted to
the EPC and from the EPC it goes to the MN, eNB, and from the eNB it will be transmitted
to the UE.
11. The second data packet will flow to eNB from EPC and then to the gNB through the
L2Switch (via XN interface) and then to the UE.
12. Similarly, the third packet will flow through the MN, fourth through the SN and so on.
Figure 3-40: Packet flow can be analyzed using the Packet Trace
3.16.2 Option 3a
1. The MN, eNB will broadcast the RRC_MIB packets to the UE every 40 ms and RRC_SIB1
every 80 ms.
2. After the transmission of the RRC_MIB and RRC_SIB1 packets, the eNB will send RRC_SI
packet to the UE.
3. After reception of RRC_SI packet, UE will send RRC_Setup_Request to the eNB.
4. On receiving the RRC_Setup_Request packet, the eNB will acknowledge the request by
transmitting RRC_Setup packet to the UE.
5. The UE will send back the RRC_Setup_Complete packet on the receipt of RRC_Setup
message.
6. After the RRC connection, the MN node will send
DC_SEC_CELL_ADDITION_REQUEST to the SN via the EPC.
7. On the receipt of this secondary cell addition request, the SN sends back the response
packet, i.e. DC_SEC_CELL_ADDITION_RESPONSE.
8. The UE will now send the UE_MEASUREMENT_REPORT every 120 ms to the MN which
contains the SNR information. The time interval at which the measurement report is to be
transmitted can be set by the user in the eNB/ gNB properties-> Interface_ LTE/ 5G_RAN
-> Datalink Layer.
9. After the UE attachment procedure, the data packets will be transmitted from the server to
the UE based on the splitting algorithm.
10. As per the current splitting algorithm in NetSim, the first data packet will be transmitted to
the EPC and from the EPC it goes to the MN, eNB, and from the eNB it will be transmitted
to the UE.
Figure 3-42: Packet flow can be analyzed using the Packet Trace
3.16.3 Option 4
gNB is the Master Node and eNB is the Secondary Node in Options 4 and 4a.
1. The MN, gNB will broadcast the RRC_MIB packets to the UE every 80 ms and RRC_SIB1
every 160 ms.
2. After the transmission of the RRC_MIB and RRC_SIB1 packets, the gNB will send RRC_SI
packet to the UE.
3. After reception of RRC_SI packet, UE will send RRC_Setup_Request to the gNB.
4. On receiving the RRC_Setup_Request packet, the gNB will acknowledge the request by
transmitting RRC_Setup packet to the UE.
5. The UE will send back the RRC_Setup_Complete packet on the receipt of RRC_Setup
message.
6. The gNB will send INITIAL_UE_MSG_AND_REGISTRATION_REQUEST to the AMF via
L2Switch_5 through the N1_N2 interface.
7. AMF will send CREATE_SESSION_REQUEST to SMF through N11 interface.
8. SMF will send PFCP_SESSION_REQUEST to UPF through N4 interface.
9. UPF will send back the response packet to SMF, i.e, PFCP_SESSION_RESPONSE
10. SMF will send back the response packet to AMF, i.e., CREATE_SESSION_RESPONSE
11. AMF will send the INITIAL_CONTEXT_SETUP_REQUEST to the gNB via Switch_5.
12. On the receipt of Context setup request, gNB will send
INITIAL_CONTEXT_SETUP_RESPONSE_REGISTRATION_COMPLETE packet to the
AMF via switch_5 through the N1_N2 interface.
13. This marks the completion of UE registration process.
1. The MN, gNB will broadcast the RRC_MIB packets to the UE every 80 ms and RRC_SIB1
every 160 ms.
2. After the transmission of the RRC_MIB and RRC_SIB1 packets, the gNB will send RRC_SI
packet to the UE.
3. After reception of RRC_SI packet, UE will send RRC_Setup_Request to the gNB.
4. On receiving the RRC_Setup_Request packet, the gNB will acknowledge the request by
transmitting RRC_Setup packet to the UE.
1. The MN, eNB will send broadcast the RRC_MIB packets to the UE every 40 ms and
RRC_SIB1 every 80 ms.
2. After the transmission of the RRC_MIB and RRC_SIB1 packets, the eNB will send RRC_SI
packet to the UE.
3. After reception of RRC_SI packet, UE will send RRC_Setup_Request to the eNB.
4. On receiving the RRC_Setup_Request packet, the eNB will acknowledge the request by
transmitting RRC_Setup packet to the UE.
5. The UE will send back the RRC_Setup_Complete packet on the receipt of RRC_Setup
message.
6. The eNB will send INITIAL_UE_MSG_AND_REGISTRATION_REQUEST to the AMF via
L2Switch_5 through the N1_N2 interface.
7. AMF will send CREATE_SESSION_REQUEST to SMF through N11 interface.
8. SMF will send PFCP_SESSION_REQUEST to UPF through N4 interface.
9. UPF will send back the response packet to SMF, i.e, PFCP_SESSION_RESPONSE
10. SMF will send back the response packet to AMF, i.e.,
CREATE_SESSION_RESPONSE.
11. AMF will send the INITIAL_CONTEXT_SETUP_REQUEST to the eNB via Switch_5.
12. On the receipt of Context setup request, eNB will send
INITIAL_CONTEXT_SETUP_RESPONSE_REGISTRATION_COMPLETE packet to the
AMF via switch_5 through the N1_N2 interface.
13. This marks the completion of UE registration process.
14. After the UE registration, the MN node will send
DC_SEC_CELL_ADDITION_REQUEST to the SN via the Switch_6.
15. On the receipt of this secondary cell addition request, the SN sends back the response
packet, i.e., DC_SEC_CELL_ADDITION_RESPONSE.
16. The UE will now send the UE_MEASUREMENT_REPORT every 120 ms to the MN which
contains the SNR information. The time interval at which the measurement report is to be
transmitted can be set by the user in the eNB/ gNB properties-> Interface_ LTE/ 5G_RAN
-> Datalink Layer.
17. After the UE attachment procedure, the data packets will be transmitted from the server to
the UE based on the splitting algorithm.
18. As per the current splitting algorithm in NetSim, the first data packet will be transmitted to
the UPF through the N6 interface and from the UPF it goes to the MN, eNB via Switch_4
Figure 3-48: Packet flow can be analyzed using the Packet Trace
3.16.6 Option 7a
1. The MN, eNB will send broadcast the RRC_MIB packets to the UE every 40 ms and
RRC_SIB1 every 80 ms.
2. After the transmission of the RRC_MIB and RRC_SIB1 packets, the eNB will send RRC_SI
packet to the UE.
3. After reception of RRC_SI packet, UE will send RRC_Setup_Request to the eNB.
4. On receiving the RRC_Setup_Request packet, the eNB will acknowledge the request by
transmitting RRC_Setup packet to the UE.
5. The UE will send back the RRC_Setup_Complete packet on the receipt of RRC_Setup
message.
6. The eNB will send INITIAL_UE_MSG_AND_REGISTRATION_REQUEST to the AMF via
L2Switch_5 through the N1_N2 interface.
7. AMF will send CREATE_SESSION_REQUEST to SMF through N11 interface.
8. SMF will send PFCP_SESSION_REQUEST to UPF through N4 interface.
9. UPF will send back the response packet to SMF, i.e, PFCP_SESSION_RESPONSE
10. SMF will send back the response packet to AMF, i.e., CREATE_SESSION_RESPONSE.
11. AMF will send the INITIAL_CONTEXT_SETUP_REQUEST to the eNB via Switch_5.
12. On the receipt of Context setup request, eNB will send
INITIAL_CONTEXT_SETUP_RESPONSE_REGISTRATION_COMPLETE packet to the
AMF via switch_5 through the N1_N2 interface.
13. This marks the completion of UE registration process.
14. After the UE registration, the MN node will send
DC_SEC_CELL_ADDITION_REQUEST to the SN via the Switch_4.
3.17 Handover
3.17.1 Use of SNR instead of RSRP
In 5G, NetSim does not model control channels; there are no pilots/reference/synchronization
signals. The channel matrix H is assumed to be known perfectly and instantaneously at the
transmitter and receiver, respectively. Hence there is no RSRP, and all signal power related
calculations are done using the data channel itself. Therefore, the hand-over is based on the
SNR measured at the s-gNB and the t-gNB. Since the noise power would be the same at s-
gNB and t-gNB, in effect the handover is based on received signal level on the PDSCH.
The handover logic of NetSim 5G library is based on the Strongest Adjacent Cell Handover
Algorithm (Ref: Handover within 3GPP LTE: Design Principles and Performance. Konstantinos
Dimou. Ericcson Research). The algorithm enables each UE to connect to that gNB which
provides the highest SNR. Therefore, a handover occurs the moment a better gNB - adjacent
cell has offset stronger RSRP (measured as SNR in NetSim) - is detected. If there is more
than one gNB with offset higher signal strength, then the gNB with the highest signal strength
becomes the target gNB. If carrier aggregation and MIMO is enabled then the SNR is averaged
over all carriers and over all layers.
• The signal strength compared is the average of all layers across all carriers.
• NetSim assumes that admission control during handover is always successful. Hence
there are no handover failures on this count.
This HOM is part of NetSim implementation while TTT can be implemented as a custom project
in NetSim.
Users may also be interested in measuring Ping pong handovers. For this, users should log
the gNB to which the UE is attached. Users can then simulate scenarios where UE would
attach to gNB1 then to gNB2, back to gNB1, again to gNB2 ... and so on, within a short time
frame. Ping pong handovers can then be calculated per some (user-defined) criteria. Such
scenarios can be simulated by enabling shadow-fading and fading-and-beamforming (fast
fading). These phenomena would cause SINR to fluctuate over short distances and even over
time at the same location.
Custom coding is required to log the "attached gNB" for each UE. NetSim radio measurements
workspace (available in file-exchange/ GitHub) can serve as the base for this development
effort.
NetSim implements on those aspects of the 5G handover procedure that directly affects
network performance. Other aspects of the handover, for example security, are either not
implemented or abstracted since they do not affect network performance. Handovers can
occur in RRC_CONNECTED (during active Tx or Rx) or in RRC_IDLE states (no Tx or Rx).
1. Once the UE connection and association procedures are completed, the UE sends a
UE_MEASUREMENT_REPORT every UE_Measurement_Report_Interval to the
connected gNB. UE_Measurement_Report_Interval is by default set as 120ms in NetSim
and is a user configurable parameter.
2. At some time, neighbor cell RSRP (measured as SNR in NetSim) becomes offset higher
than serving cell RSRP.
3. Immediately after receiving the next UE_MEASUREMENT_REPORT, source gNB (also
sometimes called serving gNB) sends a HANDOVER REQUEST to the target (neighbor)
gNB. This packet is sent through the Xn interface via a 5G-Core Switch. All the links in the
5G Core are by default 10 Gbps.
4. The Target gNB sends back HANDOVER REQUEST ACK to serving gNB, again via the
Xn interface. If the HANDOVER REQUEST or the HANDOVER REQUEST ACK are
errored then if the target gNB signal strength continues to be offset higher than source
gNB signal strength, step 1 is repeated at the next UE_MEASUREMENT_REPORT.
5. After receiving HANDOVER REQUEST ACK the serving gNB sends the HANDOVER
COMMAND to UE.
6. Then HANDOVER COMMAND packet is send by source gNB to the UE.
7. The target gNB then sends RRC Reconfiguration msg to UE. If UE is in RRC Connected
mode than the target gNB is assigned as new source gNB for the UE.
Figure 3-52: Screen shot of NetSim packet trace file showing the control packets involved in
handover. Some columns have been hidden before the last column.
3.17.5 Handover Interruption Time
During this period the UE can neither transmit nor receive user data. Handover Interruption
time can be configured in the Datalink layer properties of the gNB as shown below
During handover buffer is transferred from s-gNB to t-gNB, and active timers such as t-poll
retransmit are stopped in the s-gNB.
The LTE NR packet trace file has in its last column the field LTENR_PACKET_INFO. This field
has information relating to PDCP header and RLC header. The packet trace file can be opened
from results dashboard.
Figure 3-54: LTE NR Packet Trace. Depending on Excel settings in some cases the entire header
may not be displayed. User can do Ctrl + A (Select All) -> Right Click -> Format Cells -> Alignment ->
Wrap Text to view the complete header.
3.18.2 PDCP and RLC Headers logged in Packet Trace
e e e ie s e e i t e N _ A _N ie NetSim’s
packet trace.
▪ D/C field termed as dCBit in NetSim. This is 0 for control PDU and 1 for Data PDU
▪ SN field termed SN in NetSim. This provides the sequence number of the PDCP PDU
1. LTENR_StartFrame
▪ Downlink and uplink transmissions are organized into frames.
▪ There is one set of frames in the uplink and one set of frames in the downlink on a carrier.
▪ This event is triggered when a frame is formed.
▪ As frame length is 10ms, the event gets triggered every 10ms.
(LTENR->LTENR_Phy.c-> LTENR_addStartFrameEvent() )
2. LTENR_Start_Subframe
▪ Each frame consists of 10 subframes.
▪ Event gets triggered every 1 ms
(LTENR->LTENR_Phy.c-> LTENR_addStartSubFrameEvent ())
3. LTENR_StartSlot
▪ Sub frames are divided into slots.
▪ Slot size depends on Numerology (µ)
1
▪ Event gets triggered every 2𝜇 ms
By default, the log is written for all gNBs and UEs in the network. To get the log written only
for specific UEs in the network, the UE_ID_LIST defined in the LTENR_RadioMeasurments.c
file can be modified suitably.
• Time in Milliseconds
• gNB/eNB Name
• UE Name
• Distance between the gNB/eNB and the UE in meters
• Association Status (True/False)
• Carrier ID
• Channel Type (PDSCH/PUSCH/SSB)
• MIMO Layer ID
• Transmitter Power in dBm
• Total Loss in dB
• Pathloss in dB
• Shadow Fading Loss in dB
• Received Power in dBm
• SNR in dB
• SINR in dB
• Interference Power in dBm
• Beamforming gain in dB
• CQI Index
• MCS Index
The log file can be accessed from the Simulations Results Window under the log file drop
down in the left pane.
• gNB ID
• Component Carrier ID
• Slot ID
• Slot
• Total PRBs
The log file can be accessed from the Simulations Results Window under the log file drop
down in the left pane.
• In case of sc e i it ms s s x t e ’s e te
to one UE, the entries for the other UEs for which allocation did not happen is not
written to the log file.
• Rank is a metric used for resource allocation.
CQI Table
MCS Table
The CQI information is according to the 38-214 Table 5.2.2.1-2, 5.2.2.1-3, 5.2.2.1-4. And in
the above example:
▪ CQI Index: 15
▪ Modulation: 256QAM
▪ Code Rate x [1024]: 948
▪ Efficiency: 7.406300
▪ MCS Index:27
▪ Modulation: 256QAM
▪ Modulation Order: 8
▪ Target code Rate x [1024]: 948.000000
▪ Spectral efficiency: 7.406300
Figure 4-1: List of scenarios for the example of 5G Log File and Packet Trace
The following network diagram illustrates, what the NetSim UI displays when you open the
example configuration file.
Figure 4-2: Network set up for studying the 5G Log File and Packet Trace
To view and study the 5GNR design/flow of the simulation, use the LTENR.log file which can
be opened post simulation from Results Window > Log Files.
For logging additional information relating to Buffer-status-notification, open the source code
and inside the LTE NR project, uncomment the lines given below in stdafx.h
stdafx.h
#define LTENR_SDAP_LOG
#define LTENR_PDCP_LOG
#define LTENR_RLC_BUFFERSTATUSREPORTING_LOG
1. The Physical Resource Block (PRB) list is formed at the beginning of the log file. This
1
corresponds to 1 slot (2𝜇 𝑚𝑠) in time-domain and 15 ∗ 12 ∗ 2𝜇 kHz in frequency domain.
▪ For each numerology and carrier, a resource grid of (max. number of resource blocks
for that numerology) * (number of sub-carriers per resource block) and (number of
symbols per sub-frame of that numerology) is defined.
▪ In this example the GUI settings (gNB 5G-RAN interface Physical Layer) are:
o 𝜇 (numerology) is set 0.
o No. of resource blocks (PRB count) = 52
o No. of sub-carriers per PRB = 12
o No. of symbols per sub-frame of numerology (0) = 1.
▪ The log file explains the PRB list for gNB (7) on interface (4):
o The lowest (F_Low_MHz) and highest frequency (F_High_MHz) for the
Uplink/Downlink operating bands are logged first along with the channel bandwidth
(MHz), PRB bandwidth(kHz) and guard bandwidth(kHz).
o The list defines the lower frequency, upper frequency, and central frequency in MHz
for each physical resource block of the PRB count.
▪ The Adaptive Modulation and Coding (AMC) information is initialized for Uplink and
Downlink:
o AMC information: Links Spectral efficiency is calculated and based on this Channel
quality indicator (CQI) (Includes the CQI index, modulation, code rate and efficiency)
and Modulation coding scheme (MCS) (Includes the MCS index, modulation,
modulation order, code rate and spectral efficiency) is read from the standard table
and setup for both Downlink and Uplink.
▪ A new frame gets started for the gNB, where the frame id=1, start time and the end time
of the frame are logged.
▪ After the frame-1 starts, the sub-frame for the same gnb is started within the frame. The
frame id=1, sub-frame id=1, start time and end time are logged
▪ Within frame-1, sub-frame-1 a slot is started. This slot’s ID (1), slot type (Uplink), start
time and end time are logged.
Figure 4-7: LTE NR Log File- Frame and Sub Frame list with start time and end time
6. The RLC sub-layer then processes the transmission status notification for downlink:
▪ Initially the RLC transmission for the control takes place, where the transmission status
for each of the control logical channels i.e., BCCH, CCCH, DCCH and PCCH is
calculated based on the mode (TM & AM) they support.
▪ While calculating the transmission status for control, the RLC sends the Physical Data
Unit (PDU) based on the mode (TM or AM).
▪ Later the RLC transmission for the data packet happens, where the transmission status
for traffic logical channel i.e., DTCH is calculated based on the AM and UM mode it
supports.
▪ DTCH channel supports Un-Ack mode (UM). t e s t eb e i t eb e is ’t
NULL:
o It will find the buffer that matches the logical channel, and it only proceeds further if
the size of the PDU is within the minimum RLC PDU size.
o If the message packet is NULL (or) message type is user data & the payload of PDU
is greater than size of PDU, it fragments the UM data buffer packet (or else) the buffer
is marked for removal.
o Then the RLC sends the PDU to the MAC layer. And then the RLC buffer gets
updated.
7. At time 1000502.4 µs packet arrives at the Service Data Adaptation Protocol (SDAP) sub
layer in the gNB:
▪ As the packet arrives at the SDAP sub-layer, the SDAP header is appended to the
Packet with header size.
▪ SDAP sets the RLC mode (here, acknowledge mode) based on QoS, and the logical
channel (DTCH) is chosen.
8. The packet is passed to the Packet Data Convergence Protocol (PDCP) sub-layer at gNB:
▪ Packet is enqueued to the transmission (Tx) buffer and discard time is started.
▪ PDCP header is added, and packet is passed to the RLC sub-layer.
9. The packet is then passed to the Radio Link Control (RLC) sub-layer at gNB and is added
to the transmission buffer.
13. The packet enters the Radio Link Control (RLC) protocol sub-layer in the MAC layer at the
UE:
▪ The PDU (Physical Data Unit) is received at the UE, specific to RLC mode:
▪ The AMPDU header of the packet is received and logged. If the sequence number of the
PDU is outside the receiving window, the PDU is discarded.
▪ It checks if the PDU is already present in the reception buffer. If present it drops the PDU
and if the PDU is not present in the reception buffer, then it is added to the reception
buffer: The sequence index (SI), sequence number (SN), and sequence order (SO) for
the corresponding mode also get updated.
▪ Checks if all the Service Data Unit (SDU) byte segments of the PDU packet have been
e ei e . t, it its t e em i i S ’s be e t smitti et. e
reassembly is done for all the SDU if all the SDU byte segments of PDU packet are
received.
▪ Checks if the reassembly timer is started or not and stops if started and vice-versa.
16. Next the STATUSPDU gets transmitted from the UE to the gNB (See Packet Trace)
▪ Based on the control data type of the packet, the case is chosen.
▪ Since it is STATUSPDU type, the STATUSPDU packet is received accordingly at the
gNB. And the RLCAM transmitted buffer is cleared, and poll retransmit timer is
stopped.
4.2.1 Rural-Macro
Properties
CA Type INTER_BAND_CA
CA Configuration CA_2DL_1UL_n39_n41
Pathloss Model 3GPPTR38.901-7.4.1
Outdoor_Scenario RURAL_MACRO
LOS_NLOS_Selection USER_DEFINED
LOS_Probabillity 1
Shadow Fading Model None
Fading _and_Beamforming NO_FADING_MIMO_UNIT_GAIN
O2I Building Penetration Model None
Table 4-1: gNB >Interface (5G_RAN) >Physical layer properties
3. CBR application source id as 10 and destination id as 8 with packet size as 1460Bytes and
te _A i _time s 20000μs Generation Rate=0.584). Transport Protocol is set to UDP.
Additionally, the “S ar T m ( )” parameter is set to 1s, while configuring the application.
4. Set UE height as 10m.
5. Set other properties to default.
6. Plots are enabled in NetSim GUI.
Go back to the scenario and change the distance between gNB and UE as 30, 50, 70, 100,
300, 500, 700, and 1000 and note down Pathloss value from the log file.
4.2.1.3 Result
120
Avg Pathloss(dB)
100
80
60
40
20
0
10 100 1000
Distance(m)
LOS NLOS
4.2.2 Urban-Macro
Properties
CA Type INTER_BAND_CA
CA Configuration CA_2DL_1UL_n39_n41
Pathloss Model 3GPPTR38.901-7.4.1
Outdoor_Scenario URBAN_MACRO
LOS_NLOS_Selection USER_DEFINED
LOS_Probabillity 1
Shadow Fading Model None
Fading _and_Beamforming NO_FADING_MIMO_UNIT_GAIN
O2I Building Penetration
None
Model
Table 4-4: gNB >Interface (5G_RAN) >Physical layer properties
3. CBR application source id as 10 and destination id as 8 with packet size as 1460Bytes and
Inter_Arrival_time s 20000μs e e ti te=0. 84 . Transport Protocol is set to UDP.
Additionally, the “S ar T m ( )” parameter is set to 1s, while configuring the application.
4. Set UE height as 10m.
5. Set other properties to default.
6. Plots are enabled in NetSim GUI.
7. The log file can enable per the information provided in Section 3.18.
Note: The minimum distance for rural macro and urban macro is 35m. Below 35m, the 2D and 3D
distance will be 10m in ltenr log file.
CA Type INTER_BAND_CA
CA Configuration CA_2DL_1UL_n39_n41
Pathloss Model 3GPPTR38.901-7.4.1
Outdoor_Scenario URBAN_MACRO
LOS_NLOS_Selection USER_DEFINED
LOS_Probabillity 0
Shadow Fading Model None
Go back to the scenario and change the distance between gNB and UE as 30, 50, 70, 100,
300, 500, 700, and 1000 and note down Pathloss value from the log file.
4.2.2.3 Result
120
Avg Pathloss (dB)
100
80
60
40
20
0
10 100 1000
Distance (m)
LOS NLOS
CA Type INTER_BAND_CA
CA Configuration CA_2DL_1UL_n39_n41
Pathloss Model 3GPPTR38.901-7.4.1
Outdoor_Scenario URBAN_MICRO
LOS_NLOS_Selection USER_DEFINED
LOS_Probabillity 1
Shadow Fading Model None
CA Type INTER_BAND_CA
CA Configuration CA_2DL_1UL_n39_n41
Pathloss Model 3GPPTR38.901-7.4.1
Outdoor_Scenario URBAN_MICRO
LOS_NLOS_Selection USER_DEFINED
LOS_Probabillity 0
Shadow Fading Model None
Go back to the scenario and change the distance between gNB and UE as 30, 50, 70, 100,
300, 500, 700, and 1000 and note down Pathloss value from the log file.
4.2.3.3 Result
120
Avg Pathloss (dB)
100
80
60
40
20
0
10 100 1000
Distance (m)
LOS NLOS
The following network diagram illustrates, what the NetSim UI displays when you open the
example configuration file.
1. Drop the building and drop gNB and UE inside the building.
2. Set distance between gNB_7 and UE_8 as 10m.
3. Go to gNB properties → Interface (5G_RAN) → PHYSICAL_LAYER.
CA Type INTER_BAND_CA
CA Configuration CA_2DL_1UL_n39_n41
Pathloss Model 3GPPTR38.901-7.4.1
Outdoor_Scenario RURAL_MACRO
LOS_NLOS_Selection USER_DEFINED
LOS_Probabillity 1
Indoor Scenario INDOOR_OFFICE
Shadow Fading Model None
Go back to the scenario and change the distance between gNB and UE as 10, 20, 30, 40, 50,
60, 70, 80, 90, and 100 and note down Pathloss value from the log file.
1. Drop the building and drop gNB and UE inside the building.
2. Set distance between gNB_7 and UE_8 as 10m.
3. Go to gNB properties → Interface (5G_RAN) → PHYSICAL_LAYER.
Properties
CA Type INTER_BAND_CA
CA Configuration CA_2DL_1UL_n39_n41
Pathloss Model 3GPPTR38.901-7.4.1
Outdoor_Scenario RURAL_MACRO
LOS_NLOS_Selection USER_DEFINED
LOS_Probabillity 0
Indoor Scenario INDOOR_OFFICE
Shadow Fading Model None
Go back to the scenario and change the distance between gNB and UE as 10, 20, 30, 40, 50,
60, 70, 80, 90, and 100 and note down pathloss values from the log file.
4.2.4.3 Result
Distance(m) LOS Pathloss (dB) NLOS pathloss (dB)
CA 0 CA 1 Avg CA 0 CA 1 Avg
10 55.27 57.97 56.62 62.54 65.90 64.22
20 60.48 63.18 61.83 74.07 77.43 75.75
30 63.52 66.23 64.875 80.81 84.17 82.49
40 65.69 68.39 67.04 85.59 88.96 87.27
50 67.36 70.06 68.71 89.31 92.67 90.99
60 68.73 71.43 70.08 92.34 95.70 94.02
70 69.89 72.59 71.24 94.90 98.27 96.58
80 70.89 73.59 72.24 97.12 100.49 98.80
90 71.78 74.48 73.13 99.08 102.45 100.76
100 72.57 75.27 73.92 100.84 104.20 102.52
Table 4-12: Results Comparison for LOS and NLOS pathloss vs. Distance
120
100
Avg Pathloss(dB)
80
60
40
20
0
10 Distance(m) 100
LOS NLOS
Properties
Physical Layer Properties
Frequency Range FR2
CA Type INTRA_BAND_NONCONTIGUOUS_CA
CA Configuration CA_n261(7O) _n261A
Numerology Channel Bandwidth (MHz) per carrier
CA1, CA2, CA3,
CA4, CA5, CA6,
CA7, CA8, CA9, 3 100
CA10, CA11,
CA12, CA13, CA14
Pathloss Model 3GPPTR38.901-7.4.1
Results
Note: Filter the CA_ID to 1 in the LTE Radio measurement log file and same values have been
considered in the tables given below. (SNR and CQI are shown for downlink Layer1).
Code Code
Pathloss SNR CQI Rate Rate Throughput
Distance(m) Modulation
(dB) (dB) Index R*[1024] R*[1024] (Mbps)
(CQI) (MCS)
100 97.34 37.46 15 64QAM 948 772 505.10
200 109.05 25.74 15 64QAM 948 772 505.10
300 115.93 18.86 15 64QAM 948 772 505.10
400 120.80 13.98 13 64QAM 772 772 448.09
500 124.59 10.20 11 64QAM 567 567 289.32
600 127.68 7.11 9 16QAM 616 616 183.52
700 130.30 4.49 8 16QAM 490 490 129.69
800 132.56 2.22 6 QPSK 602 602 79.58
900 134.6 0.22 5 QPSK 449 449 51.35
1000 136.35 -1.55 4 QPSK 308 308 36.19
Table 4-19: FR1 - Variation of pathloss, SNR, CQI, Modulation, code rates and throughput as the
distance of the UE from the gNB is increased.
Code Code
Pathloss SNR CQI Rate Rate Throughput
Distance(m) Modulation
(dB) (dB) Index R*[1024] R*[1024] (Mbps)
(CQI) (MCS)
50 109.10 21.72 15 64QAM 948 772 4095.9
1000m
Configuring the scheduling algorithm, and parameter settings in example config files
Properties
Data Link Layer Properties
Application Properties
Application 1 Application 2 Application 3
Application Type CBR CBR CBR
Source ID 12 12 12
Destination ID 8 9 10
QoS UGS UGS UGS
Transport Protocol UDP UDP UDP
Packet Size 1460Bytes 1460Bytes 1460Bytes
Inter-arrival time 10μs 10μs 10μs
Start Time 1s 1s 1s
Table 4-23: Application properties
8. Plots are enabled in NetSim GUI.
9. Run Simulation for 1.5s and note down throughput value in the results window in each
sample. Recall that each sample has a different scheduling algorithm configured.
The results with all the three UEs simultaneously downloading data is as given below.
Table 4-24: UDP download throughputs for different scheduling algorithms when all three 3 UEs
simultaneously downloading data
Next, consider a scenario with only one of the UEs seeing DL traffic e ’t i e i b it
configuration file for this, and since it is a simple exercise for a user) First, run for the UE at
1000m, then for UE at 1500m and finally for UE at 2000m. This gives the maximum achievable
throughput per node since the gNB resources (bandwidth) is not shared between 3 UEs and
is fully dedicated to just one UE. The results are below.
The PHY rate is decided per the received SNR. Therefore, a UE closer to the gNB will get a
higher date rate than a UE further away. In this example the distances from the gNB are such
that UE10_Distance > UE9_Distance > UE8_Distance.
In Round Robin PRBs are allocated equally among all three nodes. However, throughputs are
in the order UE8 > UE9 > UE10 because of their distances from the gNB. The individual
1
throughputs seen by each of the UEs is exactly 3 of the throughput as shown in Table 4-25.The
PF scheduler results will match that of the RR scheduler since the channel is not time varying.
In Max throughput scheduling the PRBs are allocated such that the system gets the maximum
download throughput. The nearest UE will get all the resources and its throughput will be 3
times the throughput of the UE which got the max throughout in RR.
A difference is the performance of the RR and PF schedulers is seen only if the channel is
time varying, of the order of the coherence time which is 10𝑚𝑠. We consider the following
case: all UEs are initially at a distance 𝑑 = 300 𝑚 from the gNB. Then the UEs move away
from the gNB at the same speed of 0.1𝑚 every 10𝑚𝑠 (or 0.01𝑠 ), which is a speed of 10𝑚/𝑠.
The simulation is run for 10s, and the UEs end up at a distance of 300 + 10 × 10 = 400𝑚 from
UE ID RR Throughput PF Throughput
UE1
UE2
UE3
Table 4-26: Comparison of PF vs. RR throughput in a case involving time varying channels
Figure 4-33: List of scenarios for the example of Max Throughput vs Bandwidth and Numerology
The following network diagram illustrates, what the NetSim UI displays when you open the
example configuration file.
For the first time set Numerology value as 1 in gNB properties and change CA1 bandwidth
value as 10, 20, 30, and 40, CA2 bandwidth value as 10, 20, 30, 40, 50, 60, 80, 90, and 100
note down throughput.
For the second time set CA1 bandwidth value as 40, CA2 bandwidth value as 50 in gNB
properties and change the Numerology value as 0, 1, and 2 and note down throughput.
Result:
Numerology = 𝟏
Bandwidth Throughput (Mbps)
CA1=10, CA2=10 120.30
CA1=20, CA2=20 259.29
CA1=30, CA2=30 405.29
CA1=40, CA2=40 550.12
CA1=40, CA2=50 643.56
CA1=40, CA2=60 744.01
CA1=40, CA2=80 934.40
CA1=40, CA2=90 1031.34
CA1=40, CA2=100 1128.28
Table 4-30: Results Comparison with constant Numerology vs. Bandwidth and throughput
Figure 4-35: List of scenarios for the example of Max Throughput vs MCS and CQI
The following network diagram illustrates, what the NetSim UI displays when you open the
example configuration file.
Figure 4-36: Network set up for studying the Max Throughput vs MCS and CQI
Settings done in example config file:
Go Back to the Scenario and set MCS Table as QAM64 and CQI Table as TABLE1 and note
down throughput.
Go Back to the Scenario and set MCS Table as QAM256 and CQI Table as TABLE2 and note
down throughput.
Result:
Properties
Physical Layer Properties
gNB Height (m) 10
Tx_Power (dBm) 40
Duplex Mode TDD
CA_Type Inter Band CA
CA Configuration CA_2DL_1UL_n39_n41
DL_UL_Ratio 1:1
CA-1
0
Numerology
5
Bandwidth (MHz)
CA-2
Numerology 0
Bandwidth (MHz) 10
Channel Model
Pathloss Model 3G99TR38.901-7.4.1
Outdoor Scenario Rural Macro
The following network diagram illustrates, what the NetSim UI displays when you open the
example configuration file.
Properties
Physical Layer Properties
gNB Height (m) 10
Tx_Power (dBm) 40
Duplex Mode TDD
CA_Type Inter Band CA
CA Configuration CA_2DL_1UL_n39_n41
DL_UL_Ratio 1:1
CA-1
0
Numerology
5
Bandwidth (MHz)
CA-2
0
Numerology
10
Bandwidth (MHz)
Channel Model
Pathloss Model 3G99TR38.901-7.4.1
Outdoor Scenario Rural Macro
LOS_NLOS_Selection User Defined
LOS Probability 1
Shadow Fading Model LOG_NORMAL
ShadowFading_Standard_Deviation 3G99TR38.901-7.4.1-1
Fading _and_Beamforming NO_FADING_MIMO_UNIT_GAIN
O2I Building Penetration Model LOW_LOSS_MODEL
Table 4-39: gNB >Interface (5G_RAN) >Physical layer properties
5. Set TX_Antenna_Count as 1 and RX_Antenna_Count as 1 in gNB properties.
6. Set TX_Antenna_Count as 1 and RX_Antenna_Count as 1 in UE properties.
7. Set the CBR application between source id 10 and destination id 8 with Packet Size 1460
B and IAT 20000 µs and Transport Protocol is set to UDP.
8. Set application Start_Time as 1 sec.
9. The log file can enable per the information provided in Section 3.18.
10. Plots are enabled in NetSim GUI.
11. Run simulation for 11 sec.
Note down the Total Propagation Loss, Pathloss, Shadow Fading Loss, O2I Penetration Loss,
Thermal Noise, and Signal to Noise Ratio (SNR)
Note: The values of Carrier_Id=0 present in the log file have been considered in the tables
given below. (SNR values shown for downlink Layer1 ad Uplink Layer1).
Outdoor Indoor
Under 4G click on 20 Nodes Sample, the following network diagram illustrates, what the
NetSim UI displays when you open the example configuration file.
Application Properties
Frame Per Sec 50
Pixel Per Frame 50000
Mu 1
Start_Time 1s
Table 4-42: Application properties
8. Plots are enabled in NetSim GUI.
9. Run simulation for 2 sec. After simulation completes go to metrics window and note down
throughput and delay value from application metrics.
4.8.2 5G
Under 5G click on 20 Nodes Sample, the following network diagram illustrates, what the
NetSim UI displays when you open the example configuration file.
1. For the above 5G scenario set the following given properties Table 4-42.
For the given settings, the 4G network has a max download capacity available of about 217
Mbps. When this capacity is ready, as the number of users increases the throughput per user
starts dropping in 4G. And the latency shoots up once this threshold is crossed. However, 5G
can provide necessary bandwidth (has a capacity of 5+ Gbps) for each user to download at
the full rate of 2.5 Mbps.
2.5
Throughput per User (Mbps)
1.5
0.5
0
20 40 60 80 100 120 140
Number of Devices
4G 5G
Figure 4-45: Throughput vs Number of Devices for 4G and 5G. The 4G per user throughput starts
falling after 80 devices.
200000
Average Delay(micro second)
150000
100000
50000
0
20 40 60 80 100 120 140
Number of Devices
4G 5G
Figure 4-46: Plot of Latency vs Number of Devices. The 5G Network average delay is insignificant i.e.,
many orders of magnitude lower, and hence not visible in the plot.
4.9 5G-Peak-Throughput
Open NetSim, Select Examples ->5G NR -> 5G Peak Throughput then click on the tile in the
middle panel to load the example as shown in below screenshot
The following network diagram illustrates, what the NetSim UI displays on clicking.
Go back to the Scenario and change channel bandwidth to 100 MHz, run simulation for 1.1
sec and note down throughput value from application metrics.
Result:
Go back to the Scenario and change channel bandwidth to 400 MHz, run simulation for 1.1
sec and note down throughput value from application metrics.
Result:
Open NetSim, Select Examples ->5G NR -> Distance vs Throughput n261 band then click
on the tile in the middle panel to load the example as shown in below Figure 4-49.
Ver 13.2 Page 188 of 211
Figure 4-49: List of scenarios for the example of Distance vs Throughput n261 band
NetSim UI displays the configuration file corresponding to this experiment as shown below in
Figure 4-50.
Figure 4-50: Network set up for studying the Distance vs Throughput n261 band
4.10.1 DL: UL Ratio 4:1
Step 1: A network scenario is designed in NetSim GUI comprising of 1 gNB, 5G-Core, and 1
UE and 1 Router and 1 Wired Node in the “5G N ” Network Library.
Step 3: The device positions are set as per the table given below.
Parameter Value
Tx_Power 40
gNB Height 10m
CA Type Single Band
CA Configuration n261
DL-UL Ratio 4:1
Numerology 3
Channel Bandwidth 100 MHz
MCS Table QAM64LOWSE
CQI Table TABLE3
Outdoor Scenario Urban Macro
Pathloss Model 3GPPTR38.901-7.4.1
LOS_NLOS_Selection User Defined
LOS Probability 1
Shadow Fading Model None
Fading _and_Beamforming NO_FADING_MIMO_UNIT_GAIN
O2I Building Penetration Model Low Loss Model
Table 4-52: gNB >Interface (5G_RAN) >Physical layer properties
Step 5: Set Tx_Antenna_Count and Rx_Antenna_Count as 2 and 2 in gNB properties >
Interface(5G_RAN) > Physical Layer.
Step 7: In the General Properties of UE 8, set Mobility Model as File Based Mobility
Step 8: Two CBR Application were generated from between the Wired_Node_10 and UE_8
with the following values.
Parameter Value
APP1_CBR_DL
Source Wired_Node_10
Destination UE_8
Start Time (s) 1
Packet Size (Bytes) 1460
IAT (µs) 11.68
Generation Rate (Mbps) 1000
Transport Protocol UDP
APP2_CBR_UL
Source UE_8
Destination Wired_Node_10
Start Time (s) 1
Ver 13.2 Page 190 of 211
Packet Size (Bytes) 1460
IAT (µs) 97.33
Generation Rate (Mbps) 120
Transport Protocol UDP
Table 4-53: Application Properties
File Based Mobility: In File Based Mobility, users can write their own custom mobility models
ei et em eme t t e m bi e se s. e te m bi ity.txt i e ’s i e i
mobility with each step equal to 4 sec with distance 100 m. The NetSim Mobility File
(mobility.txt) format is as follows:
..
..
Results:
Step 2: In the gNB properties-> Interface 5G_RAN, the DL:UL ratio was set to 3:2.
Parameter Value
APP1_CBR_DL
Source Wired_Node_10
Destination UE_8
Start Time (s) 1
Packet Size (Bytes) 1460
IAT (µs) 11.68
Generation Rate (Mbps) 1000
Transport Protocol UDP
APP2_CBR_UL
Source UE_8
Destination Wired_Node_10
Start Time (s) 1
Packet Size (Bytes) 1460
IAT (µs) 38.93
Generation Rate (Mbps) 300
Transport Protocol UDP
Table 4-54: Application Properties
Step 4: Similarly, in LOS, set the LOS Probability to 0 in gNB properties and run simulation for
1.3s.
Results:
The following network diagram illustrates, what the NetSim UI displays on clicking.
Figure 4-60: Network set up for studying the gNB cell radius for different data rates
Setting done in example config file:
App_1_CBR
Source Id 10
Destination Id 8
Packet Size 1460
IAT 1.94 µs
Start time 1s
Transport Protocol UDP
Generation Rate 6 Gbps
Table 4-56: Application properties
6. Plots are enabled in NetSim GUI.
7. Run simulation for 1.1 sec. After simulation completes go to metrics window and note down
throughput value from application metrics.
Go back to the Scenario and change distance between gNB and UE to 100m, 130m, 150m,
170m, 190m, 200m, 300m, 330m, and 350m and run simulation for 1.1 sec.
Result:
Cell Radius (m) Data Rate (Mbps). Downlink
≈1500 Mbps Downlink
100 1574.81
130 1335.72
150 1205.37
≈1000 Mbps Downlink
170 1096.75
190 955.42
200 825.07
≈500 Mbps Downlink
300 499.20
App_1_CBR
Source Id 10
Destination Id 8
Packet Size 1460
IAT 1.94 µs
Start time 1s
Transport Protocol UDP
Generation Rate 6 Gbps
Table 4-59: Application properties
Go back to the Scenario and change distance between gNB and UE to 20m, 110m, and 150m
and run simulation for 1.1 sec.
Result:
Figure 4-61: List of scenarios for the example of Impact of numerology on a RAN with phones sensors
and cameras
Figure 4-62: Network set up for studying the with 25 smartphones, 6 sensors and 3 cameras
communicating with respective cloud servers
In terms of application data traffic, the camera (video) and sensor nodes have one UDP flow
each, that goes in the UL towards a remote node on the Internet. These flows are fixed-rate
flows: we have a continuous transmission of 5 Mb/s for the video nodes, to simulate a 720p24
HD video, and the sensors transmit a payload of 500 bytes each 2.5 ms, that gives a rate of
1.6 Mb/s. For the smartphones, we use TCP as the transmission protocol. These connect to
data base servers. Each phone has to download a 25 MB file and to upload one file of 1.5 MB.
These flows start at different times: the upload starts at a random time between the 25th and
the 75th simulation seconds, while each download starts at a random time between the 1.5th
and the 95th simulation seconds.
impact of different numerologies, and how they affect the end-to-end performance. The metrics
measured and analysed are a) Throughput of TCP uploads & downloads, and b) Latency of
the UDP uploads
Numerology(μ)
Camera Sensor Smartphone
Uplink Uplink Uplink Downlink
Throughput Delay Throughput Delay Throughput Throughput
(Mbps) (μ ) (Mbps) (μ ) (Mbps) (Mbps)
4.99 1845.51 1.6 2274.02 89.80 0.00
4.99 1848.21 1.6 2272.62 89.80 0.00
4.99 1850.91 1.6 2279.64 89.80 0.00
1.6 2278.24 89.80 0.00
1.6 2276.83 89.80 0.00
1.6 2275.43 89.80 0.00
89.80 0.00
89.80 0.00
89.80 0.00
89.80 80.50
89.80 85.69
90.00 75.43
3.62 86.27
0.23 86.26
0.35 86.27
0.17 86.27
0.27 86.27
0.36 86.27
1.35 86.27
1.51 86.27
0.69 86.27
Numerology(μ)
Camera Sensor Smartphone
Uplink Uplink Uplink Downlink
Throughput Delay Throughput Delay Throughput Throughput
(Mbps) (μ ) (Mbps) (μ ) (Mbps) (Mbps)
4.99 35801.94 1.60 1523.71 154.02 0.00
4.99 35720.37 1.60 1522.31 154.02 0.00
4.99 35948.59 1.60 1529.32 154.02 0.00
1.60 1527.92 154.02 0.00
1.60 1526.52 154.02 0.00
1.60 1525.11 154.02 0.00
154.02 0.00
154.02 0.00
154.02 0.00
154.02 0.00
154.02 172.52
154.02 172.52
153.72 171.37
0.52 171.37
0.54 171.37
0.66 171.37
0.63 171.37
0.68 171.37
4.56 171.37
7.14 171.37
6.61 171.37
1.11 171.37
5.58 171.37
5.68 171.37
2.09 171.37
Table 4-69: Throughput and delay for Camera, Sensors and Smartphones, When 𝝁 =
𝟏
Numerology(μ)
Camera Sensor Smartphone
Uplink Uplink Uplink Downlink
Throughput Delay Throughput Delay Throughput Throughput
(Mbps) (μ ) (Mbps) (μ ) (Mbps) (Mbps)
5.00 78284.10 1.60 773.57 149.33 0.00
5.00 79995.75 1.60 772.17 149.33 0.00
5.00 52688.39 1.60 779.18 149.33 0.00
1.60 777.78 149.33 0.00
5
Avg. Throughput (Mbps)
0
0 1 2
Numerology (µ)
Camera Sensor
Figure 4-63: The average uplink throughput for camera and sensors remains the same as numerology
is increased. This is because the flow is UDP.
Figure 4-64: Smartphone Uplink, and Smartphone Downlink average throughput vs. Numerology (µ)
2.5
2
Avg. Delay (ms)
1.5
0.5
0
0 1 2
Numerology (µ)
Camera Sensor
Figure 4-65: Camera Uplink, and Sensor Uplink Latency vs. Numerology. The latency drops as the
numerology increases
For UDP applications the 𝜇 does not impact the throughput. However, higher 𝜇 leads to an
obviously lower delay. The variation of delay vs. 𝜇 is as follows:
Step 1: A network scenario is designed in NetSim GUI comprising of 1 gNB, 5G-Core, and 1
UE and 1 Wired Node in the “5G N ” Network Library.
Step 3: The device positions are set as per the table given below Table 4-72.
Parameter Value
Tx_Power 40
gNB Height 10m
CA Type Single Band
CA Configuration n78
DL-UL Ratio 4:1
Numerology 0
Channel Bandwidth 10 MHz
MCS Table QAM64LOWSE
CQI Table TABLE3
Propagation Model Urban Macro
Pathloss Model 3GPPTR38.901-7.4.1
LOS_NLOS_Selection User Defined
LOS Probability 0
Shadow Fading Model None
Fading and Beamforming NO_FADING_MIMO_UNIT_GAIN
O2I Building Penetration Model Low Loss Model
Table 4-73: gNB >Interface (5G_RAN) >Physical layer properties
Step 5: Set Tx_Antenna_Count and Rx_Antenna_Count as 2 and 1 in gNB properties >
Interface(5G_RAN) > Physical Layer.
Step 7: In the General Properties of UE 8, set Mobility Model as File Based Mobility
Step 8: A CBR Application was generated from Wired Node 10 i.e. Source to UE 8 i.e.
Destination with Packet Size remaining 1460Bytes and Inter Arrival Time remaining 1168µs.
Step 10: Additionally, the “S ar T m ( )” parameter is set to 1s, while configuring the
application.
File Based Mobility: In File Based Mobility, users can write their own custom mobility models
and define the movement of the mobile users. Create a mobility.txt fi e ’s i e i
mobility with each step equal to 4 sec with distance 100 m.
Results:
As the UE moves away from the gNB, the Application throughput starts reducing. The
maximum throughput of 10 Mbps is obtained until 40 sec. At 40s the UE is 1000m away from
the gNB. Then the throughput drops to 9.3 Mbps at 40 sec and at time 48 sec (when UE is
1200m away from gNB), the throughput drops to 6 Mbps and at time 52 sec (when UE is
1300m away from gNB), the throughput drops to 3.26 Mbps and subsequently keeps dropping
as till the end of the simulation as the UE continues to move further away from the gNB.
7 Reference Documents
[1] S. A. J. N. J. S. V. Andrea Goldsmith. [Online]. Available:
https://web.stanford.edu/class/archive/ee/ee359/ee359.1062/cup_mimo.pdf. [Accessed
20 11 2020].
[3] N. Patriciello, S. Lagen, L. Giupponi and B. Bojovic, "5G New Radio Numerologies and
their Impact on the End-To-End Latency," IEEE 23rd International Workshop on Computer
Aided Modeling and Design of Communication Links and Networks (CAMAD), 2018.
[4] M. Mezzavilla, M. Zhang, M. Polese, R. Ford, S. Dutta, S. Rangan and M. Zorzi, "End-to-
End Simulation of 5G mmWave Networks," IEEE Communication Surveys & Tutorials, Vol
20, No. 3, Third Quarter, 2018.
[5] 3G PPP Standards (Rel 15): 37.324, 38.300, 38.321, 38.322, 38.323, 23.501, 38.901
V15.0.0 (2018-06)