Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

This is the respository for our IRS extension for ns-3. With ns3IRS simulation of full-stack IRS scenarios becomes possible.

NotificationsYou must be signed in to change notification settings

tkn-tub/ns3irs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

User Guide

Prerequisites

Before using the IRS module, ensure the following requirements are met:

  • Tested withns-3.43
  • This module has to be located in thecontrib/ directory
  • TheEigen3 library must be installed, and ns-3 must be built with the--enable-eigen flag.
  • A modification is required in the ns-3 source code:
// File: src/network/helper/node-container.h// Original:classNodeContainer;// Replace with:classNodeContainer :publicObject;

Using the IRS Module in Simulations

1. Creating the IRS Node

Create one or multiple IRS nodes usingNodeContainer:

NodeContainer irsNodes;irsNodes.Create(1);

2. Configuring Node Mobility

The IRS node(s) require a mobility model, which can be installed using theMobilityHelper, just like any other node in ns3.While any mobility model can theoretically be applied, it is recommended to use a static mobility model for the IRS in multi-IRS scenarios.In these scenarios moving IRS nodes can lead to inaccurate results, as the optimization strategies for the possible paths with more than one IRS assume stationary IRS.

MobilityHelper mobility;Ptr<ListPositionAllocator> positionAlloc = CreateObject<ListPositionAllocator>();positionAlloc->Add({0,0,0});mobility.SetPositionAllocator(positionAlloc);mobility.SetMobilityModel("ns3::ConstantPositionMobilityModel");mobility.Install(irsNodes);

3.1 Configuring the IRS Module: IrsLookupModel

Use theIrsLookupHelper to configure the IRS node with anIrsLookupModel, utilizing a pre-generated csv file for the lookup data:

IrsLookupHelper irsHelper;irsHelper.SetDirection({0,1,0});irsHelper.SetLookupTable("path/to/lookup_table.csv");irsHelper.Install(irsNodes);

The lookup table can be generated using thegenerateIrsLookupTable helper script in thematlab/ directory, as follows:

freq=5.15e9;% Frequency in HzNr=20;% Number of elements in rowsNc=20;% Number of elements in columnsap= [0;0;0];% AP positionue= [50;0;0];% UE positionris= [0.7;-0.7;0];% IRS positiondir= [0,1,0];% IRS direction[r_ap_ris,a_ap_ris,r_ris_ue,a_ris_ue]= calcangle(ap,ue,ris,dir);ris_table= generateIrsLookupTable( ...    round(a_ap_ris(1)), round(a_ris_ue(1)),Nr,Nc,freq, ...    abs(ue(1)- ap(1)),r_ap_ris,r_ris_ue,0,"constructive" ...);

3.2 Configuring the IRS Module: IrsSpectrumModel

Using theIrsSpectrumModel, the IRS node can be configured as follows:

Ptr<IrsSpectrumModel> irs = CreateObjectWithAttributes<IrsSpectrumModel>("Direction",VectorValue({0,1,0}),    "N",    TupleValue<UintegerValue, UintegerValue>({20,20}),    "Spacing",    TupleValue<DoubleValue, DoubleValue>({0.05,0.05}),    "Frequency",    DoubleValue(5.21e9));irs->CalcRCoeffs(los_distance,         irs_distance,Angles(in_az, in_el),         Angles(out_az, out_el),         0);irsNodes.Get(0)->AggregateObject(irs);

los_distance refers to the length of the LOS path in meters, whileirs_distance represents the distance of the path reflected over the IRS in meters.The variablesin_az andin_el represent the optimized incoming azimuth and elevation angles, respectively, in radians.Similarly,out_az andout_el correspond to the optimized outgoing azimuth and elevation angles, respectively, in radians.The last argument in theCalcRCoeffs function is set to zero, which calculates the reflection coefficients so they create constructive interference with the LOS path.

N represents the number of elements in both the row and column directions, whileSpacing denotes the distance between elements.Frequency indicates the operating frequency for which the IRS is designed.

About

This is the respository for our IRS extension for ns-3. With ns3IRS simulation of full-stack IRS scenarios becomes possible.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp