识别变量

时间:2019-05-31 10:55:26

标签: c++ ns-3

在pf-ff-mac-scheduler.cc程序中,我需要找到变量的类型以及为什么不能使用此当前变量。

 for (int i = 0; i < 15; i++)
{
  if ((RicMap[0][i]== (uint64_t) (*it).second.cell_id) && (RicMap[1][i]== (*it).first) && (RicMap[3][i]== 1))
  {
    if (timeUe[i] == Simulator::Now ().GetMilliSeconds () )
    { 

      uint64_t m_avTh = (uint64_t) (*it).second.lastAveragedThroughput; 

      RicMap[4].push_back(m_avTh);

      sliceThroughput = RicMap[4][i];

      if (sliceThroughput != 0)
      {
        counterUe = counterUe + 1 ;
      }
      timeUe[i] = timeUe[i] + MilliSeconds (1).GetMilliSeconds () ; 
      // std::cout<<" Time: "<< timer  << " Imsi: " << i+1 << " Content of Map[4]["<<i+1<<"]: "<<  Map[4][i] << "  sliceThroughput: " << sliceThroughput << " counterUe: " << counterUe << std::endl;
      std::cout<<"Data rate (PF): "<< (*it).second.lastAveragedThroughput <<"  Cell ID: "<< (*it).second.cell_id << std::endl;

用当前值更新sliceAveragedThroughputTable:sliceThroughput

Data rate (HA): 1
Data rate (PF): 1.50023e+06  Cell ID: 1
Data rate (PF): 622306  Cell ID: 3
Data rate (PF): 81511.9  Cell ID: 3
Data rate (PF): 155371  Cell ID: 3
Data rate (PF): 128698  Cell ID: 3
Data rate (PF): 36135.9  Cell ID: 3
Data rate (PF): 394100  Cell ID: 1

这就是我得到的输出。我不应该将HA设置为1,而应该将其设置为零。

请帮助我。说真的,我不知道该怎么做,很紧张。

谢谢您的进阶

0 个答案:

没有答案