nyuwireless-unipd / ns3-mmwave

ns-3 module for simulating mmWave-based cellular systems. See https://ieeexplore.ieee.org/document/8344116/ (open access) as a reference.
GNU General Public License v2.0
292 stars 190 forks source link

Question about MCS using mmwave-epc-tdma #257

Open amao2021 opened 1 year ago

amao2021 commented 1 year ago

Hi, Thank you for providing wonderful simulator. I'm doing my own project with ns3-mmwave. I want to reproduce your multi-user scheduling experiment in paper End-to-End Simulation of 5G mmWave Networks. So I started from mmWave-epc-tdma.cc. I use the file RxPacketTrace.txt to get the DL PHY Throughput. Here are some questions.

  1. After I changed the scheduler to MR or PF, the mcs values are always 0. And when I changed it to MaxWeight, error No way to create such TB size, something went wrong! appeared. I am confused and want to know the configurations of schedulers.
  2. In paper End-to-End Simulation of 5G mmWave Networks, you said UEs have similar distances from the eNB but are assigned the constant speed of 25 m/s. I really want to know the distance between UEs and eNB.

Looking forward to hearing from you.

pagmatt commented 1 year ago

Hi,

First of all, please be aware that the paper "End-to-End Simulation of 5G mmWave Networks" refers to an older version of the mmWave module. A lot of changes have been introduced since then, and this will already make very hard to reproduce results 1:1. Regarding question 1, I can take at the scheduler error. Did you modify only the mmwave-epc-tdma.cc file ? If that is the case, can you upload here or link your version ? Related to question 2, I can not find the specific distances either. They seem to be in the [20, 100] range by looking at the figures, but that is all I can say unfortunately.

BR, Matteo

amao2021 commented 1 year ago

Hi, pagmatt, Thank you very much for your advice!

  1. I was using the latest version of new-handover. I changed the scheduler, the frame structure, the number of UEs and the speed of UEs. By the way, mcs was also 0 when I changed only the scheduler. I will put the code at the end.
  2. After seeing your suggestion, I tried the bbr and master version. the bbr version failed in the build step, but the master version succeeded. And the code and frame structure of the master version seems to be closer to the paper, so I am now trying to reproduce your experimental results with it.
  3. Also for the 7 UE scenario, is their respective distance to the eNB actually a series of random numbers between [20, 100]? (as written in the code) Or they have a similar distance from enb?

Best, Mao

================================================================================================

mmwave-epc-tdma.txt

include "ns3/epc-helper.h"

include "ns3/internet-module.h"

include "ns3/mobility-module.h"

include "ns3/applications-module.h"

include "ns3/point-to-point-helper.h"

include "ns3/config-store-module.h"

include "ns3/command-line.h"

include "ns3/mmwave-helper.h"

include "ns3/mmwave-point-to-point-epc-helper.h"

include

include

include <ns3/nstime.h>

using namespace ns3; using namespace mmwave;

/**

// dlClient.SetAttribute ("DataRate", DataRateValue (dataRate)); // ulClient.SetAttribute ("DataRate", DataRateValue (dataRate));

dlClient.SetAttribute ("OnTime", StringValue (ss.str ())); ulClient.SetAttribute ("OnTime", StringValue (ss.str ())); ss.str (""); ss << "ns3::ExponentialRandomVariable[Mean=" << interPacketInterval * 1e-6 << "]"; std::cout << "OffTime == " << ss.str () << std::endl; dlClient.SetAttribute ("OffTime", StringValue (ss.str ())); ulClient.SetAttribute ("OffTime", StringValue (ss.str ()));

for (uint32_t u = 0; u < ueNodes.GetN (); ++u) { ++ulPort; ++otherPort; PacketSinkHelper dlPacketSinkHelper ("ns3::UdpSocketFactory", InetSocketAddress (Ipv4Address::GetAny (), dlPort)); PacketSinkHelper ulPacketSinkHelper ("ns3::UdpSocketFactory", InetSocketAddress (Ipv4Address::GetAny (), ulPort)); serverApps.Add (dlPacketSinkHelper.Install (ueNodes.Get (u))); serverApps.Add (ulPacketSinkHelper.Install (remoteHost));

// UdpClientHelper dlClient (ueIpIface.GetAddress (u), dlPort); // dlClient.SetAttribute ("Interval", TimeValue (MicroSeconds(interPacketInterval))); // dlClient.SetAttribute ("MaxPackets", UintegerValue(1000000)); // dlClient.SetAttribute ("PacketSize", UintegerValue(packetSize)); // // UdpClientHelper ulClient (remoteHostAddr, ulPort); // ulClient.SetAttribute ("Interval", TimeValue (MicroSeconds(interPacketInterval))); // ulClient.SetAttribute ("MaxPackets", UintegerValue(1000000)); // ulClient.SetAttribute ("PacketSize", UintegerValue(packetSize));

// UdpClientHelper client (ueIpIface.GetAddress (u), otherPort); // client.SetAttribute ("Interval", TimeValue (MicroSeconds(interPacketInterval))); // client.SetAttribute ("MaxPackets", UintegerValue(1000000)); dlClient.SetAttribute ("Remote", AddressValue (InetSocketAddress (ueIpIface.GetAddress (u), dlPort))); // ulClient.SetAttribute ("Remote", AddressValue (InetSocketAddress (remoteHostAddr, ulPort)));

  clientApps.Add (dlClient.Install (remoteHost));
  clientApps.Add (ulClient.Install (ueNodes.Get(u)));

// if (u+1 < ueNodes.GetN ()) // { // clientApps.Add (client.Install (ueNodes.Get(u+1))); // } // else // { // clientApps.Add (client.Install (ueNodes.Get(0))); // } } serverApps.Start (Seconds (0.003)); clientApps.Start (Seconds (0.003)); mmwaveHelper->EnableTraces (); // Uncomment to enable PCAP tracing //p2ph.EnablePcapAll("mmwave-epc-simple");

Simulator::Stop (Seconds (simTime)); Simulator::Run ();

/GtkConfigStore config; config.ConfigureAttributes();/

Simulator::Destroy (); return 0;

}

amao2021 commented 1 year ago

Is there something I missed when I set up the scheduler? In the newest version, after I change the scheduler, mcs is still 0. Sometimes only DL has mcs value and UL is still 0.

Looking forward to hearing from you. Mao