A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
src
wimax
model
snr-to-block-error-rate-record.cc
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2007,2008, 2009 INRIA, UDcast
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
* Author: Mohamed Amine Ismail <amine.ismail@sophia.inria.fr>
19
* <amine.ismail@udcast.com>
20
*/
21
22
#include "ns3/simulator.h"
23
#include "ns3/snr-to-block-error-rate-record.h"
24
#include "ns3/assert.h"
25
26
namespace
ns3
{
27
28
SNRToBlockErrorRateRecord::SNRToBlockErrorRateRecord
(
double
snrValue,
29
double
bitErrorRate,
double
blockErrorRate,
double
sigma2,
double
I1,
30
double
I2)
31
{
32
m_snrValue
= snrValue;
33
m_bitErrorRate
= bitErrorRate;
34
m_blockErrorRate
= blockErrorRate;
35
m_sigma2
= sigma2;
36
m_i1
= I1;
37
m_i2
= I2;
38
}
39
40
SNRToBlockErrorRateRecord
*
41
SNRToBlockErrorRateRecord::Copy
()
42
{
43
return
(
new
SNRToBlockErrorRateRecord
(
m_snrValue
,
m_bitErrorRate
,
44
m_blockErrorRate
,
m_sigma2
,
m_i1
,
m_i2
));
45
46
}
47
48
double
49
SNRToBlockErrorRateRecord::GetSNRValue
(
void
)
50
{
51
return
m_snrValue
;
52
}
53
54
SNRToBlockErrorRateRecord::~SNRToBlockErrorRateRecord
(
void
)
55
{
56
m_snrValue
= 0;
57
m_bitErrorRate
= 0;
58
m_blockErrorRate
= 0;
59
m_sigma2
= 0;
60
m_i1
= 0;
61
m_i2
= 0;
62
}
63
64
double
65
SNRToBlockErrorRateRecord::GetBitErrorRate
(
void
)
66
{
67
return
m_bitErrorRate
;
68
}
69
double
70
SNRToBlockErrorRateRecord::GetBlockErrorRate
(
void
)
71
{
72
return
m_blockErrorRate
;
73
}
74
double
75
SNRToBlockErrorRateRecord::GetSigma2
(
void
)
76
{
77
return
m_sigma2
;
78
}
79
double
80
SNRToBlockErrorRateRecord::GetI1
(
void
)
81
{
82
return
m_i1
;
83
}
84
double
85
SNRToBlockErrorRateRecord::GetI2
(
void
)
86
{
87
return
m_i2
;
88
}
89
90
void
91
SNRToBlockErrorRateRecord::SetSNRValue
(
double
snrValue)
92
{
93
m_snrValue
= snrValue;
94
}
95
void
96
SNRToBlockErrorRateRecord::SetBitErrorRate
(
double
bitErrorRate)
97
{
98
m_bitErrorRate
= bitErrorRate;
99
}
100
void
101
SNRToBlockErrorRateRecord::SetBlockErrorRate
(
double
blockErrorRate)
102
{
103
m_blockErrorRate
= blockErrorRate;
104
}
105
void
106
SNRToBlockErrorRateRecord::SetI1
(
double
I1)
107
{
108
m_i1
= I1;
109
}
110
void
111
SNRToBlockErrorRateRecord::SetI2
(
double
I2)
112
{
113
m_i2
= I2;
114
}
115
116
}
ns3::SNRToBlockErrorRateRecord::SNRToBlockErrorRateRecord
SNRToBlockErrorRateRecord(double snrValue, double bitErrorRate, double BlockErrorRate, double sigma2, double I1, double I2)
creates a record and sets its values
Definition:
snr-to-block-error-rate-record.cc:28
ns3::SNRToBlockErrorRateRecord::m_snrValue
double m_snrValue
SNR value.
Definition:
snr-to-block-error-rate-record.h:103
ns3::SNRToBlockErrorRateRecord::m_i2
double m_i2
The upper boundary of the confidence interval.
Definition:
snr-to-block-error-rate-record.h:108
ns3::SNRToBlockErrorRateRecord::GetI1
double GetI1(void)
Definition:
snr-to-block-error-rate-record.cc:80
ns3::SNRToBlockErrorRateRecord::GetI2
double GetI2(void)
Definition:
snr-to-block-error-rate-record.cc:85
ns3::SNRToBlockErrorRateRecord::m_i1
double m_i1
The lower boundary of the confidence interval.
Definition:
snr-to-block-error-rate-record.h:107
ns3::SNRToBlockErrorRateRecord::m_sigma2
double m_sigma2
sigma2
Definition:
snr-to-block-error-rate-record.h:106
ns3::SNRToBlockErrorRateRecord
This class represents a record (handled by SnrToBlockErrorRate manager) that keeps a mapping between ...
Definition:
snr-to-block-error-rate-record.h:34
ns3::SNRToBlockErrorRateRecord::GetBlockErrorRate
double GetBlockErrorRate(void)
Definition:
snr-to-block-error-rate-record.cc:70
ns3::SNRToBlockErrorRateRecord::GetSNRValue
double GetSNRValue(void)
Definition:
snr-to-block-error-rate-record.cc:49
ns3::SNRToBlockErrorRateRecord::SetBlockErrorRate
void SetBlockErrorRate(double)
set the BlcER value
Definition:
snr-to-block-error-rate-record.cc:101
ns3::SNRToBlockErrorRateRecord::Copy
SNRToBlockErrorRateRecord * Copy()
copy a record
Definition:
snr-to-block-error-rate-record.cc:41
ns3::SNRToBlockErrorRateRecord::SetI2
void SetI2(double)
set the upper boundary of the confidence interval
Definition:
snr-to-block-error-rate-record.cc:111
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::SNRToBlockErrorRateRecord::~SNRToBlockErrorRateRecord
~SNRToBlockErrorRateRecord(void)
Definition:
snr-to-block-error-rate-record.cc:54
ns3::SNRToBlockErrorRateRecord::GetSigma2
double GetSigma2(void)
Definition:
snr-to-block-error-rate-record.cc:75
ns3::SNRToBlockErrorRateRecord::m_bitErrorRate
double m_bitErrorRate
bit error rate
Definition:
snr-to-block-error-rate-record.h:104
ns3::SNRToBlockErrorRateRecord::SetI1
void SetI1(double)
set the lower boundary of the confidence interval
Definition:
snr-to-block-error-rate-record.cc:106
ns3::SNRToBlockErrorRateRecord::m_blockErrorRate
double m_blockErrorRate
block error rate
Definition:
snr-to-block-error-rate-record.h:105
ns3::SNRToBlockErrorRateRecord::SetSNRValue
void SetSNRValue(double)
set the snr value
Definition:
snr-to-block-error-rate-record.cc:91
ns3::SNRToBlockErrorRateRecord::GetBitErrorRate
double GetBitErrorRate(void)
Definition:
snr-to-block-error-rate-record.cc:65
ns3::SNRToBlockErrorRateRecord::SetBitErrorRate
void SetBitErrorRate(double)
set the BER value
Definition:
snr-to-block-error-rate-record.cc:96
Generated on Wed Nov 7 2018 10:02:16 for ns-3 by
1.8.14