A Discrete-Event Network Simulator
API
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
26namespace ns3 {
27
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
42{
45
46}
47
48double
50{
51 return m_snrValue;
52}
53
55{
56 m_snrValue = 0;
59 m_sigma2 = 0;
60 m_i1 = 0;
61 m_i2 = 0;
62}
63
64double
66{
67 return m_bitErrorRate;
68}
69double
71{
72 return m_blockErrorRate;
73}
74double
76{
77 return m_sigma2;
78}
79double
81{
82 return m_i1;
83}
84double
86{
87 return m_i2;
88}
89
90void
92{
93 m_snrValue = snrValue;
94}
95void
97{
98 m_bitErrorRate = bitErrorRate;
99}
100void
102{
103 m_blockErrorRate = blockErrorRate;
104}
105void
107{
108 m_i1 = i1;
109}
110void
112{
113 m_i2 = i2;
114}
115
116}
This class represents a record (handled by SnrToBlockErrorRate manager) that keeps a mapping between ...
double m_i1
The lower boundary of the confidence interval.
void SetSNRValue(double snrValue)
set the snr value
void SetBitErrorRate(double bitErrorRate)
set the BER value
void SetI2(double i2)
set the upper boundary of the confidence interval
double m_i2
The upper boundary of the confidence interval.
void SetI1(double i1)
set the lower boundary of the confidence interval
SNRToBlockErrorRateRecord * Copy()
copy a record
SNRToBlockErrorRateRecord(double snrValue, double bitErrorRate, double BlockErrorRate, double sigma2, double I1, double I2)
creates a record and sets its values
void SetBlockErrorRate(double blockErrorRate)
set the BlcER value
Every class exported by the ns3 library is enclosed in the ns3 namespace.