A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
lte-ffr-distributed-algorithm.cc
Go to the documentation of this file.
1/*
2 * Copyright (c) 2014 Piotr Gawlowicz
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation;
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program; if not, write to the Free Software
15 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16 *
17 * Author: Piotr Gawlowicz <gawlowicz.p@gmail.com>
18 *
19 */
20
22
23#include <ns3/log.h>
24
25namespace ns3
26{
27
28NS_LOG_COMPONENT_DEFINE("LteFfrDistributedAlgorithm");
29
30NS_OBJECT_ENSURE_REGISTERED(LteFfrDistributedAlgorithm);
31
33 : m_ffrSapUser(nullptr),
34 m_ffrRrcSapUser(nullptr)
35{
36 NS_LOG_FUNCTION(this);
39}
40
42{
43 NS_LOG_FUNCTION(this);
44}
45
46void
48{
49 NS_LOG_FUNCTION(this);
50 delete m_ffrSapProvider;
52}
53
56{
57 static TypeId tid =
58 TypeId("ns3::LteFfrDistributedAlgorithm")
60 .SetGroupName("Lte")
61 .AddConstructor<LteFfrDistributedAlgorithm>()
62 .AddAttribute(
63 "CalculationInterval",
64 "Time interval between calculation of Edge sub-band, Default value 1 second",
68 .AddAttribute(
69 "RsrqThreshold",
70 "If the RSRQ of is worse than this threshold, UE should be served in Edge sub-band",
71 UintegerValue(20),
73 MakeUintegerChecker<uint8_t>())
74 .AddAttribute(
75 "RsrpDifferenceThreshold",
76 "If the difference between the power of the signal received by UE from "
77 "the serving cell and the power of the signal received from the adjacent cell is "
78 "less "
79 "than a RsrpDifferenceThreshold value, the cell weight is incremented",
80 UintegerValue(20),
82 MakeUintegerChecker<uint8_t>())
83 .AddAttribute("CenterPowerOffset",
84 "PdschConfigDedicated::Pa value for Center Sub-band, default value dB0",
87 MakeUintegerChecker<uint8_t>())
88 .AddAttribute("EdgePowerOffset",
89 "PdschConfigDedicated::Pa value for Edge Sub-band, default value dB0",
92 MakeUintegerChecker<uint8_t>())
93 .AddAttribute("EdgeRbNum",
94 "Number of RB that can be used in edge Sub-band",
97 MakeUintegerChecker<uint8_t>())
98 .AddAttribute("CenterAreaTpc",
99 "TPC value which will be set in DL-DCI for UEs in center area"
100 "Absolute mode is used, default value 1 is mapped to -1 according to"
101 "TS36.213 Table 5.1.1.1-2",
102 UintegerValue(1),
104 MakeUintegerChecker<uint8_t>())
105 .AddAttribute("EdgeAreaTpc",
106 "TPC value which will be set in DL-DCI for UEs in edge area"
107 "Absolute mode is used, default value 1 is mapped to -1 according to"
108 "TS36.213 Table 5.1.1.1-2",
109 UintegerValue(1),
111 MakeUintegerChecker<uint8_t>())
112
113 ;
114 return tid;
115}
116
117void
119{
120 NS_LOG_FUNCTION(this << s);
121 m_ffrSapUser = s;
122}
123
126{
127 NS_LOG_FUNCTION(this);
128 return m_ffrSapProvider;
129}
130
131void
133{
134 NS_LOG_FUNCTION(this << s);
135 m_ffrRrcSapUser = s;
136}
137
140{
141 NS_LOG_FUNCTION(this);
142 return m_ffrRrcSapProvider;
143}
144
145void
147{
148 NS_LOG_FUNCTION(this);
150
151 if (m_frCellTypeId != 0)
152 {
155 }
156
157 NS_LOG_LOGIC(this << " requesting Event A1 and A4 measurements"
158 << " (threshold = 0"
159 << ")");
160 LteRrcSap::ReportConfigEutra reportConfig;
163 reportConfig.threshold1.range = 0;
167
168 LteRrcSap::ReportConfigEutra reportConfigA4;
171 reportConfigA4.threshold1.range = 0; // intentionally very low threshold
175
176 int rbgSize = GetRbgSize(m_dlBandwidth);
177 m_dlEdgeRbgMap.resize(m_dlBandwidth / rbgSize, false);
178 m_ulEdgeRbgMap.resize(m_ulBandwidth, false);
180}
181
182void
184{
185 NS_LOG_FUNCTION(this);
186 if (m_frCellTypeId != 0)
187 {
190 }
193 m_needReconfiguration = false;
194}
195
196void
198{
199 NS_LOG_FUNCTION(this);
200}
201
202void
203LteFfrDistributedAlgorithm::SetUplinkConfiguration(uint16_t cellId, uint8_t bandwidth)
204{
205 NS_LOG_FUNCTION(this);
206}
207
208void
210{
211 NS_LOG_FUNCTION(this);
212 m_dlRbgMap.clear();
213 int rbgSize = GetRbgSize(m_dlBandwidth);
214 m_dlRbgMap.resize(m_dlBandwidth / rbgSize, false);
215}
216
217void
219{
220 NS_LOG_FUNCTION(this);
221 m_ulRbgMap.clear();
222 m_ulRbgMap.resize(m_ulBandwidth, false);
223}
224
225std::vector<bool>
227{
228 NS_LOG_FUNCTION(this);
229
231 {
232 Reconfigure();
233 }
234
235 if (m_dlRbgMap.empty())
236 {
238 }
239
240 return m_dlRbgMap;
241}
242
243bool
245{
246 NS_LOG_FUNCTION(this);
247
248 bool edgeRbg = m_dlEdgeRbgMap[rbgId];
249
250 std::map<uint16_t, uint8_t>::iterator it = m_ues.find(rnti);
251 if (it == m_ues.end())
252 {
253 m_ues.insert(std::pair<uint16_t, uint8_t>(rnti, AreaUnset));
254 return !edgeRbg;
255 }
256
257 bool edgeUe = false;
258 if (it->second == EdgeArea)
259 {
260 edgeUe = true;
261 }
262
263 return (edgeRbg && edgeUe) || (!edgeRbg && !edgeUe);
264}
265
266std::vector<bool>
268{
269 NS_LOG_FUNCTION(this);
270
271 if (m_ulRbgMap.empty())
272 {
274 }
275
276 return m_ulRbgMap;
277}
278
279bool
281{
282 NS_LOG_FUNCTION(this);
283
285 {
286 return true;
287 }
288
289 bool edgeRbg = m_ulEdgeRbgMap[rbId];
290
291 std::map<uint16_t, uint8_t>::iterator it = m_ues.find(rnti);
292 if (it == m_ues.end())
293 {
294 m_ues.insert(std::pair<uint16_t, uint8_t>(rnti, AreaUnset));
295 return !edgeRbg;
296 }
297
298 bool edgeUe = false;
299 if (it->second == EdgeArea)
300 {
301 edgeUe = true;
302 }
303
304 return (edgeRbg && edgeUe) || (!edgeRbg && !edgeUe);
305}
306
307void
310{
311 NS_LOG_FUNCTION(this);
312 NS_LOG_WARN("Method should not be called, because it is empty");
313}
314
315void
318{
319 NS_LOG_FUNCTION(this);
320 NS_LOG_WARN("Method should not be called, because it is empty");
321}
322
323void
324LteFfrDistributedAlgorithm::DoReportUlCqiInfo(std::map<uint16_t, std::vector<double>> ulCqiMap)
325{
326 NS_LOG_FUNCTION(this);
327 NS_LOG_WARN("Method should not be called, because it is empty");
328}
329
330uint8_t
332{
333 NS_LOG_FUNCTION(this);
334
336 {
337 return 1; // 1 is mapped to 0 for Accumulated mode, and to -1 in Absolute mode TS36.213
338 // Table 5.1.1.1-2
339 }
340
341 // TS36.213 Table 5.1.1.1-2
342 // TPC | Accumulated Mode | Absolute Mode
343 //------------------------------------------------
344 // 0 | -1 | -4
345 // 1 | 0 | -1
346 // 2 | 1 | 1
347 // 3 | 3 | 4
348 //------------------------------------------------
349 // here Absolute mode is used
350
351 std::map<uint16_t, uint8_t>::iterator it = m_ues.find(rnti);
352 if (it == m_ues.end())
353 {
354 return 1;
355 }
356
357 if (it->second == EdgeArea)
358 {
359 return m_edgeAreaTpc;
360 }
361 else
362 {
363 return m_centerAreaTpc;
364 }
365
366 return 1;
367}
368
369uint16_t
371{
372 NS_LOG_FUNCTION(this);
373
374 uint8_t minContinuousUlBandwidth = m_ulBandwidth;
375
377 {
378 return minContinuousUlBandwidth;
379 }
380
381 minContinuousUlBandwidth = ((m_edgeRbNum > 0) && (m_edgeRbNum < minContinuousUlBandwidth))
383 : minContinuousUlBandwidth;
384
385 return minContinuousUlBandwidth;
386}
387
388void
390{
391 NS_LOG_FUNCTION(this << rnti << (uint16_t)measResults.measId);
392 NS_LOG_INFO("CellId: " << m_cellId << " RNTI :" << rnti
393 << " MeasId: " << (uint16_t)measResults.measId
394 << " RSRP: " << (uint16_t)measResults.measResultPCell.rsrpResult
395 << " RSRQ: " << (uint16_t)measResults.measResultPCell.rsrqResult);
396
397 if (measResults.measId == m_rsrqMeasId)
398 {
399 // check if it is center or edge UE
400 std::map<uint16_t, uint8_t>::iterator it = m_ues.find(rnti);
401 if (it == m_ues.end())
402 {
403 m_ues.insert(std::pair<uint16_t, uint8_t>(rnti, AreaUnset));
404 }
405
406 it = m_ues.find(rnti);
408 {
409 if (it->second != CenterArea)
410 {
411 NS_LOG_INFO("UE RNTI: " << rnti << " will be served in Center sub-band");
412 it->second = CenterArea;
413
414 LteRrcSap::PdschConfigDedicated pdschConfigDedicated;
415 pdschConfigDedicated.pa = m_centerPowerOffset;
416 m_ffrRrcSapUser->SetPdschConfigDedicated(rnti, pdschConfigDedicated);
417 }
418 }
419 else
420 {
421 if (it->second != EdgeArea)
422 {
423 NS_LOG_INFO("UE RNTI: " << rnti << " will be served in Edge sub-band");
424 it->second = EdgeArea;
425
426 LteRrcSap::PdschConfigDedicated pdschConfigDedicated;
427 pdschConfigDedicated.pa = m_edgePowerOffset;
428 m_ffrRrcSapUser->SetPdschConfigDedicated(rnti, pdschConfigDedicated);
429 }
430 }
431 }
432 else if (measResults.measId == m_rsrpMeasId)
433 {
434 std::map<uint16_t, uint8_t>::iterator it = m_ues.find(rnti);
435 if (it == m_ues.end())
436 {
437 m_ues.insert(std::pair<uint16_t, uint8_t>(rnti, AreaUnset));
438 }
439
441 m_cellId,
442 measResults.measResultPCell.rsrpResult,
443 measResults.measResultPCell.rsrqResult);
444
445 if (measResults.haveMeasResultNeighCells && !measResults.measResultListEutra.empty())
446 {
447 for (std::list<LteRrcSap::MeasResultEutra>::iterator it =
448 measResults.measResultListEutra.begin();
449 it != measResults.measResultListEutra.end();
450 ++it)
451 {
452 NS_ASSERT_MSG(it->haveRsrpResult == true,
453 "RSRP measurement is missing from cellId " << it->physCellId);
454 NS_ASSERT_MSG(it->haveRsrqResult == true,
455 "RSRQ measurement is missing from cellId " << it->physCellId);
456 UpdateNeighbourMeasurements(rnti, it->physCellId, it->rsrpResult, it->rsrqResult);
457
458 bool found = false;
459 for (std::vector<uint16_t>::iterator ncIt = m_neighborCell.begin();
460 ncIt != m_neighborCell.end();
461 ncIt++)
462 {
463 if ((*ncIt) == it->physCellId)
464 {
465 found = true;
466 }
467 }
468 if (!found)
469 {
470 m_neighborCell.push_back(it->physCellId);
471 }
472 }
473 }
474 else
475 {
477 this << " Event A4 received without measurement results from neighbouring cells");
478 }
479 }
480 else
481 {
482 NS_LOG_WARN("Ignoring measId " << (uint16_t)measResults.measId);
483 }
484}
485
486void
488{
489 NS_LOG_FUNCTION(this);
492
493 int rbgSize = GetRbgSize(m_dlBandwidth);
494 uint16_t rbgNum = m_dlBandwidth / rbgSize;
495
496 m_cellWeightMap.clear();
497 m_dlEdgeRbgMap.clear();
498 m_dlEdgeRbgMap.resize(m_dlBandwidth / rbgSize, false);
499 m_ulEdgeRbgMap.clear();
500 m_ulEdgeRbgMap.resize(m_ulBandwidth, false);
501
502 MeasurementTable_t::iterator it1;
503 MeasurementRow_t::iterator it2;
504 Ptr<UeMeasure> servingCellMeasures;
505 Ptr<UeMeasure> neighbourCellMeasures;
506
507 uint32_t edgeUeNum = 0;
508 std::map<uint16_t, uint8_t>::iterator areaIt;
509 for (areaIt = m_ues.begin(); areaIt != m_ues.end(); areaIt++)
510 {
511 if (areaIt->second == EdgeArea)
512 {
513 edgeUeNum++;
514 }
515 }
516
517 if (edgeUeNum != 0)
518 {
519 for (it1 = m_ueMeasures.begin(); it1 != m_ueMeasures.end(); it1++)
520 {
521 std::map<uint16_t, uint8_t>::iterator areaIt = m_ues.find(it1->first);
522 if (areaIt->second != EdgeArea)
523 {
524 continue;
525 }
526
527 servingCellMeasures = nullptr;
528 neighbourCellMeasures = nullptr;
529
530 it2 = it1->second.find(m_cellId);
531 if (it2 != it1->second.end())
532 {
533 servingCellMeasures = it2->second;
534 }
535 else
536 {
537 continue;
538 }
539
540 for (it2 = it1->second.begin(); it2 != it1->second.end(); it2++)
541 {
542 if (it2->first != m_cellId)
543 {
544 neighbourCellMeasures = it2->second;
545 }
546 else
547 {
548 continue;
549 }
550
551 if (servingCellMeasures && neighbourCellMeasures)
552 {
553 int16_t rsrpDifference =
554 servingCellMeasures->m_rsrp - neighbourCellMeasures->m_rsrp;
555 NS_LOG_INFO("CellId: " << m_cellId << " UE RNTI: " << it1->first
556 << " NeighborCellId: " << neighbourCellMeasures->m_cellId
557 << " RSRP Serving: " << (int)servingCellMeasures->m_rsrp
558 << " RSRP Neighbor: "
559 << (int)neighbourCellMeasures->m_rsrp
560 << " RSRP Difference: " << (int)rsrpDifference);
561
562 if (rsrpDifference < m_rsrpDifferenceThreshold)
563 {
564 m_cellWeightMap[neighbourCellMeasures->m_cellId]++;
565 }
566 }
567 }
568 }
569
570 std::map<uint16_t, uint64_t> metricA;
571 for (uint16_t i = 0; i < rbgNum; i++)
572 {
573 metricA[i] = 0;
574 }
575
576 std::map<uint16_t, uint32_t>::iterator cellIt;
577 for (cellIt = m_cellWeightMap.begin(); cellIt != m_cellWeightMap.end(); cellIt++)
578 {
579 NS_LOG_INFO("CellId: " << m_cellId << " NeighborCellId: " << cellIt->first
580 << " Weight: " << cellIt->second);
581
582 std::map<uint16_t, std::vector<bool>>::iterator rntpIt = m_rntp.find(cellIt->first);
583 if (rntpIt == m_rntp.end())
584 {
585 continue;
586 }
587
588 for (uint16_t i = 0; i < rbgNum; i++)
589 {
590 if (rntpIt->second[i])
591 {
592 metricA[i] += cellIt->second;
593 }
594 }
595 }
596
597 std::vector<uint16_t> sortedRbgByMetric;
598 std::multimap<uint64_t, uint16_t> sortedMetricA;
599 for (std::map<uint16_t, uint64_t>::const_iterator it = metricA.begin(); it != metricA.end();
600 ++it)
601 {
602 sortedMetricA.insert(std::pair<uint64_t, uint16_t>(it->second, it->first));
603 }
604
605 for (std::multimap<uint64_t, uint16_t>::const_iterator it = sortedMetricA.begin();
606 it != sortedMetricA.end();
607 ++it)
608 {
609 sortedRbgByMetric.push_back(it->second);
610 }
611
612 for (int i = 0; i < m_edgeRbNum / rbgSize; i++)
613 {
614 m_dlEdgeRbgMap[sortedRbgByMetric[i]] = true;
615 }
616
617 for (int i = 0; i < m_edgeRbNum / rbgSize; i++)
618 {
619 uint32_t rbgIndex = sortedRbgByMetric[i];
620 for (int k = 0; k < rbgSize; k++)
621 {
622 uint32_t rbIndex = rbgSize * rbgIndex + k;
623 m_ulEdgeRbgMap[rbIndex] = true;
624 }
625 }
626 }
627
628 for (std::vector<uint16_t>::iterator ncIt = m_neighborCell.begin();
629 ncIt != m_neighborCell.end();
630 ncIt++)
631 {
632 SendLoadInformation((*ncIt));
633 }
634}
635
636void
638{
639 NS_LOG_FUNCTION(this);
640
641 NS_LOG_INFO("SendLoadInformation to CellId : " << targetCellId);
642
643 std::vector<EpcX2Sap::UlInterferenceOverloadIndicationItem>
644 m_currentUlInterferenceOverloadIndicationList;
645 std::vector<EpcX2Sap::UlHighInterferenceInformationItem>
646 m_currentUlHighInterferenceInformationList;
647 EpcX2Sap::RelativeNarrowbandTxBand m_currentRelativeNarrowbandTxBand;
648
649 m_currentRelativeNarrowbandTxBand.rntpPerPrbList = m_dlEdgeRbgMap;
650
653 cii.ulInterferenceOverloadIndicationList = m_currentUlInterferenceOverloadIndicationList;
654 cii.ulHighInterferenceInformationList = m_currentUlHighInterferenceInformationList;
655 cii.relativeNarrowbandTxBand = m_currentRelativeNarrowbandTxBand;
656
658 params.targetCellId = targetCellId;
659 params.cellInformationList.push_back(cii);
660
662}
663
664void
666{
667 NS_LOG_FUNCTION(this);
668 NS_LOG_INFO("CellId: " << m_cellId << " Recv X2 message: LOAD INFORMATION from CellId:"
669 << params.cellInformationList[0].sourceCellId);
670
671 if (params.cellInformationList[0].sourceCellId > m_cellId)
672 {
673 return;
674 }
675
676 uint16_t neighborCellId = params.cellInformationList[0].sourceCellId;
677 std::map<uint16_t, std::vector<bool>>::iterator it = m_rntp.find(neighborCellId);
678 if (it != m_rntp.end())
679 {
680 it->second = params.cellInformationList[0].relativeNarrowbandTxBand.rntpPerPrbList;
681 }
682 else
683 {
684 m_rntp.insert(std::pair<uint16_t, std::vector<bool>>(
685 neighborCellId,
686 params.cellInformationList[0].relativeNarrowbandTxBand.rntpPerPrbList));
687 }
688}
689
690void
692 uint16_t cellId,
693 uint8_t rsrp,
694 uint8_t rsrq)
695{
696 NS_LOG_FUNCTION(this << rnti << cellId << (uint16_t)rsrq);
697
698 MeasurementTable_t::iterator it1;
699 it1 = m_ueMeasures.find(rnti);
700
701 if (it1 == m_ueMeasures.end())
702 {
703 // insert a new UE entry
705 std::pair<MeasurementTable_t::iterator, bool> ret;
706 ret = m_ueMeasures.insert(std::pair<uint16_t, MeasurementRow_t>(rnti, row));
707 NS_ASSERT(ret.second);
708 it1 = ret.first;
709 }
710
711 NS_ASSERT(it1 != m_ueMeasures.end());
712 std::map<uint16_t, Ptr<UeMeasure>>::iterator it2;
713 it2 = it1->second.find(cellId);
714
715 if (it2 != it1->second.end())
716 {
717 it2->second->m_cellId = cellId;
718 it2->second->m_rsrp = rsrp;
719 it2->second->m_rsrq = rsrq;
720 }
721 else
722 {
723 // insert a new cell entry
724 Ptr<UeMeasure> cellMeasures = Create<UeMeasure>();
725 cellMeasures->m_cellId = cellId;
726 cellMeasures->m_rsrp = rsrp;
727 cellMeasures->m_rsrq = rsrq;
728 it1->second[cellId] = cellMeasures;
729 }
730
731} // end of UpdateNeighbourMeasurements
732
733} // end of namespace ns3
The abstract base class of a Frequency Reuse algorithm.
uint16_t m_cellId
cell ID
bool m_needReconfiguration
If true FR algorithm will be reconfigured.
uint8_t m_frCellTypeId
FFR cell type ID for automatic configuration.
int GetRbgSize(int dlbandwidth)
Get RBG size for DL Bandwidth according to table 7.1.6.1-1 of 36.213.
bool m_enabledInUplink
If true FR algorithm will also work in Uplink.
uint8_t m_dlBandwidth
downlink bandwidth in RBs
uint8_t m_ulBandwidth
uplink bandwidth in RBs
Distributed Fractional Frequency Reuse algorithm implementation.
std::map< uint16_t, Ptr< UeMeasure > > MeasurementRow_t
Cell Id is used as the key for the following map.
void DoReportUeMeas(uint16_t rnti, LteRrcSap::MeasResults measResults) override
Implementation of LteFfrRrcSapProvider::ReportUeMeas.
uint8_t DoGetTpc(uint16_t rnti) override
DoGetTpc for UE.
LteFfrSapProvider * m_ffrSapProvider
FFR SAP Provider.
LteFfrRrcSapProvider * m_ffrRrcSapProvider
FFR RRC SAP Provider.
std::map< uint16_t, uint8_t > m_ues
UEs map.
void UpdateNeighbourMeasurements(uint16_t rnti, uint16_t cellId, uint8_t rsrp, uint8_t rsrq)
Initialize up link RGB maps function.
uint8_t m_rsrpDifferenceThreshold
RSRP difference threshold.
void DoDispose() override
Destructor implementation.
LteFfrRrcSapUser * m_ffrRrcSapUser
FFR RRC SAP User.
std::map< uint16_t, uint32_t > m_cellWeightMap
cell weight map
friend class MemberLteFfrSapProvider< LteFfrDistributedAlgorithm >
let the forwarder class access the protected and private members
bool DoIsDlRbgAvailableForUe(int i, uint16_t rnti) override
Implementation of LteFfrSapProvider::IsDlRbgAvailableForUe.
void SetUplinkConfiguration(uint16_t cellId, uint8_t bandwidth)
Set up link configuration function.
void DoInitialize() override
Initialize() implementation.
void DoReportDlCqiInfo(const FfMacSchedSapProvider::SchedDlCqiInfoReqParameters &params) override
DoReportDlCqiInfo.
uint16_t DoGetMinContinuousUlBandwidth() override
DoGetMinContinuousUlBandwidth in number of RB.
void SetLteFfrSapUser(LteFfrSapUser *s) override
Set the "user" part of the LteFfrSap interface that this frequency reuse algorithm instance will inte...
void DoRecvLoadInformation(EpcX2Sap::LoadInformationParams params) override
DoRecvLoadInformation.
MeasurementTable_t m_ueMeasures
UE measures.
std::vector< bool > DoGetAvailableDlRbg() override
Implementation of LteFfrSapProvider::GetAvailableDlRbg.
std::map< uint16_t, std::vector< bool > > m_rntp
RNTP.
void SetDownlinkConfiguration(uint16_t cellId, uint8_t bandwidth)
Set down link configuration function.
std::vector< uint16_t > m_neighborCell
neighbor cell
friend class MemberLteFfrRrcSapProvider< LteFfrDistributedAlgorithm >
let the forwarder class access the protected and private members
std::vector< bool > m_ulRbgMap
UL RBG map.
std::vector< bool > m_ulEdgeRbgMap
UL edge RBG map.
uint8_t m_edgeSubBandRsrqThreshold
edge sub band RSRQ threshold
std::vector< bool > DoGetAvailableUlRbg() override
Implementation of LteFfrSapProvider::GetAvailableUlRbg.
bool DoIsUlRbgAvailableForUe(int i, uint16_t rnti) override
Implementation of LteFfrSapProvider::IsUlRbgAvailableForUe.
static TypeId GetTypeId()
Get the type ID.
LteFfrSapProvider * GetLteFfrSapProvider() override
Export the "provider" part of the LteFfrSap interface.
LteFfrRrcSapProvider * GetLteFfrRrcSapProvider() override
Export the "provider" part of the LteFfrRrcSap interface.
std::vector< bool > m_dlRbgMap
DL RBG map.
void SetLteFfrRrcSapUser(LteFfrRrcSapUser *s) override
Set the "user" part of the LteFfrRrcSap interface that this frequency reuse algorithm instance will i...
void Reconfigure() override
Automatic FR reconfiguration.
uint8_t m_centerPowerOffset
center power offset
void InitializeUplinkRbgMaps()
Initialize up link RGB maps function.
std::vector< bool > m_dlEdgeRbgMap
DL edge RBG map.
void DoReportUlCqiInfo(const FfMacSchedSapProvider::SchedUlCqiInfoReqParameters &params) override
DoReportUlCqiInfo.
void SendLoadInformation(uint16_t targetCellId)
Send load information function.
void InitializeDownlinkRbgMaps()
Initialize down link RGB maps function.
Service Access Point (SAP) offered by the Frequency Reuse algorithm instance to the eNodeB RRC instan...
Service Access Point (SAP) offered by the eNodeB RRC instance to the Frequency Reuse algorithm instan...
virtual void SetPdschConfigDedicated(uint16_t rnti, LteRrcSap::PdschConfigDedicated pdschConfigDedicated)=0
Instruct the eNodeB RRC entity to perform RrcConnectionReconfiguration to inform UE about new PdschCo...
virtual uint8_t AddUeMeasReportConfigForFfr(LteRrcSap::ReportConfigEutra reportConfig)=0
Request a certain reporting configuration to be fulfilled by the UEs attached to the eNodeB entity.
virtual void SendLoadInformation(EpcX2Sap::LoadInformationParams params)=0
SendLoadInformation.
Service Access Point (SAP) offered by the Frequency Reuse algorithm instance to the MAC Scheduler ins...
Definition: lte-ffr-sap.h:40
Service Access Point (SAP) offered by the eNodeB RRC instance to the Frequency Reuse algorithm instan...
Definition: lte-ffr-sap.h:140
virtual void DoInitialize()
Initialize() implementation.
Definition: object.cc:360
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:78
static EventId Schedule(const Time &delay, FUNC f, Ts &&... args)
Schedule an event to expire after delay.
Definition: simulator.h:568
static EventId ScheduleNow(FUNC f, Ts &&... args)
Schedule an event to expire Now.
Definition: simulator.h:606
AttributeValue implementation for Time.
Definition: nstime.h:1423
a unique identifier for an interface.
Definition: type-id.h:59
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Definition: type-id.cc:936
Hold an unsigned integer type.
Definition: uinteger.h:45
#define NS_ASSERT(condition)
At runtime, in debugging builds, if this condition is not true, the program prints the source file,...
Definition: assert.h:66
#define NS_ASSERT_MSG(condition, message)
At runtime, in debugging builds, if this condition is not true, the program prints the message to out...
Definition: assert.h:86
Ptr< const AttributeChecker > MakeTimeChecker()
Helper to make an unbounded Time checker.
Definition: nstime.h:1444
Ptr< const AttributeAccessor > MakeTimeAccessor(T1 a1)
Definition: nstime.h:1424
Ptr< const AttributeAccessor > MakeUintegerAccessor(T1 a1)
Definition: uinteger.h:46
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Definition: log.h:202
#define NS_LOG_LOGIC(msg)
Use NS_LOG to output a message of level LOG_LOGIC.
Definition: log.h:282
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
#define NS_LOG_WARN(msg)
Use NS_LOG to output a message of level LOG_WARN.
Definition: log.h:261
#define NS_LOG_INFO(msg)
Use NS_LOG to output a message of level LOG_INFO.
Definition: log.h:275
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Definition: object-base.h:46
Time Seconds(double value)
Construct a Time in the indicated unit.
Definition: nstime.h:1336
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Cell Information Item as it is used in the LOAD INFORMATION message.
Definition: epc-x2-sap.h:158
uint16_t sourceCellId
source cell ID
Definition: epc-x2-sap.h:159
std::vector< UlHighInterferenceInformationItem > ulHighInterferenceInformationList
UL high interference information list.
Definition: epc-x2-sap.h:163
RelativeNarrowbandTxBand relativeNarrowbandTxBand
relative narrow transmit band
Definition: epc-x2-sap.h:164
std::vector< UlInterferenceOverloadIndicationItem > ulInterferenceOverloadIndicationList
UL interference overload indication list.
Definition: epc-x2-sap.h:161
Parameters of the LOAD INFORMATION message.
Definition: epc-x2-sap.h:306
Relative Narrowband Tx Power (RNTP) as it is used in the LOAD INFORMATION message.
Definition: epc-x2-sap.h:144
std::vector< bool > rntpPerPrbList
RNTP per prb list.
Definition: epc-x2-sap.h:145
Parameters of the SCHED_DL_CQI_INFO_REQ primitive.
Parameters of the SCHED_UL_CQI_INFO_REQ primitive.
uint8_t rsrqResult
the RSRQ result
Definition: lte-rrc-sap.h:675
uint8_t rsrpResult
the RSRP result
Definition: lte-rrc-sap.h:674
MeasResults structure.
Definition: lte-rrc-sap.h:717
uint8_t measId
measure ID
Definition: lte-rrc-sap.h:718
bool haveMeasResultNeighCells
have measure result neighbor cells
Definition: lte-rrc-sap.h:720
std::list< MeasResultEutra > measResultListEutra
measure result list eutra
Definition: lte-rrc-sap.h:721
MeasResultPCell measResultPCell
measurement result primary cell
Definition: lte-rrc-sap.h:719
PdschConfigDedicated structure.
Definition: lte-rrc-sap.h:163
Specifies criteria for triggering of an E-UTRA measurement reporting event.
Definition: lte-rrc-sap.h:373
enum ns3::LteRrcSap::ReportConfigEutra::@62 eventId
Event enumeration.
@ RSRP
Reference Signal Received Power.
Definition: lte-rrc-sap.h:425
@ RSRQ
Reference Signal Received Quality.
Definition: lte-rrc-sap.h:426
@ EVENT_A4
Event A4: Neighbour becomes better than absolute threshold.
Definition: lte-rrc-sap.h:387
@ EVENT_A1
Event A1: Serving becomes better than absolute threshold.
Definition: lte-rrc-sap.h:384
enum ns3::LteRrcSap::ReportConfigEutra::@65 reportInterval
Report interval enumeration.
enum ns3::LteRrcSap::ReportConfigEutra::@63 triggerQuantity
Trigger type enumeration.
ThresholdEutra threshold1
Threshold for event A1, A2, A4, and A5.
Definition: lte-rrc-sap.h:393
@ THRESHOLD_RSRP
RSRP is used for the threshold.
Definition: lte-rrc-sap.h:364
@ THRESHOLD_RSRQ
RSRQ is used for the threshold.
Definition: lte-rrc-sap.h:365
enum ns3::LteRrcSap::ThresholdEutra::@60 choice
Threshold enumeration.
uint8_t range
Value range used in RSRP/RSRQ threshold.
Definition: lte-rrc-sap.h:368