A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
src
lte
model
lte-amc.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2010 TELEMATICS LAB, DEE - Politecnico di Bari
4
*
5
* This program is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License version 2 as
7
* published by the Free Software Foundation;
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17
*
18
* Original Author: Giuseppe Piro <g.piro@poliba.it>
19
* Modified by: Nicola Baldo <nbaldo@cttc.es>
20
* Modified by: Marco Miozzo <mmiozzo@cttc.es>
21
*/
22
23
#ifndef AMCMODULE_H
24
#define AMCMODULE_H
25
26
#include <vector>
27
#include <ns3/ptr.h>
28
#include <ns3/object.h>
29
30
namespace
ns3
{
31
32
class
SpectrumValue;
33
40
class
LteAmc
:
public
Object
41
{
42
43
public
:
48
static
TypeId
GetTypeId
(
void
);
49
50
LteAmc
();
51
virtual
~LteAmc
();
52
54
enum
AmcModel
55
{
63
PiroEW2010
,
67
MiErrorModel
68
};
69
76
int
GetMcsFromCqi
(
int
cqi);
77
84
int
GetDlTbSizeFromMcs
(
int
mcs,
int
nprb);
85
92
int
GetUlTbSizeFromMcs
(
int
mcs,
int
nprb);
93
100
double
GetSpectralEfficiencyFromCqi
(
int
cqi);
101
108
std::vector<int>
CreateCqiFeedbacks
(
const
SpectrumValue
& sinr,
109
uint8_t rbgSize = 0);
110
118
int
GetCqiFromSpectralEfficiency
(
double
s);
119
120
private
:
121
127
double
m_ber
;
128
134
AmcModel
m_amcModel
;
135
136
};
// end of `class LteAmc`
137
138
139
}
140
141
#endif
/* AMCMODULE_H */
ns3::LteAmc::GetMcsFromCqi
int GetMcsFromCqi(int cqi)
Get the Modulation and Coding Scheme for a CQI value.
Definition:
lte-amc.cc:280
ns3::LteAmc::AmcModel
AmcModel
Types of AMC model.
Definition:
lte-amc.h:54
ns3::LteAmc::GetUlTbSizeFromMcs
int GetUlTbSizeFromMcs(int mcs, int nprb)
Get the Transport Block Size for a selected MCS and number of PRB (table 8.6.1-1 of 36...
Definition:
lte-amc.cc:307
ns3::LteAmc::GetCqiFromSpectralEfficiency
int GetCqiFromSpectralEfficiency(double s)
Get a proper CQI for the spectral efficiency value.
Definition:
lte-amc.cc:265
ns3::LteAmc::~LteAmc
virtual ~LteAmc()
Definition:
lte-amc.cc:238
ns3::LteAmc::m_amcModel
AmcModel m_amcModel
The AmcModel attribute.
Definition:
lte-amc.h:134
ns3::LteAmc::m_ber
double m_ber
The Ber attribute.
Definition:
lte-amc.h:127
ns3::LteAmc::LteAmc
LteAmc()
Definition:
lte-amc.cc:233
ns3::LteAmc
Implements the Adaptive Modulation And Coding Scheme.
Definition:
lte-amc.h:40
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::LteAmc::GetDlTbSizeFromMcs
int GetDlTbSizeFromMcs(int mcs, int nprb)
Get the Transport Block Size for a selected MCS and number of PRB (table 7.1.7.2.1-1 of 36...
Definition:
lte-amc.cc:295
ns3::LteAmc::GetSpectralEfficiencyFromCqi
double GetSpectralEfficiencyFromCqi(int cqi)
Get the spectral efficiency value associated to the received CQI.
Definition:
lte-amc.cc:320
ns3::LteAmc::GetTypeId
static TypeId GetTypeId(void)
Get the type ID.
Definition:
lte-amc.cc:243
ns3::Object
A base class which provides memory management and object aggregation.
Definition:
object.h:87
ns3::LteAmc::PiroEW2010
Definition:
lte-amc.h:63
ns3::SpectrumValue
Set of values corresponding to a given SpectrumModel.
Definition:
spectrum-value.h:58
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:58
ns3::LteAmc::CreateCqiFeedbacks
std::vector< int > CreateCqiFeedbacks(const SpectrumValue &sinr, uint8_t rbgSize=0)
Create a message with CQI feedback.
Definition:
lte-amc.cc:330
ns3::LteAmc::MiErrorModel
An AMC model based on 10% of BER according to LteMiErrorModel.
Definition:
lte-amc.h:67
Generated on Wed Nov 7 2018 10:02:00 for ns-3 by
1.8.14