satellite-channel-estimation-error.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2014 Magister Solutions Ltd
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: Jani Puttonen <jani.puttonen@magister.fi>
19  */
20 
21 #ifndef SATELLITE_CHANNEL_ESTIMATION_ERROR_H_
22 #define SATELLITE_CHANNEL_ESTIMATION_ERROR_H_
23 
24 #include <ns3/object.h>
25 #include <ns3/random-variable-stream.h>
26 
27 namespace ns3
28 {
29 
39 class SatChannelEstimationError : public Object
40 {
41  public:
46 
52  SatChannelEstimationError(std::string filePathName);
53 
58 
62  static TypeId GetTypeId(void);
63 
67  virtual void DoDispose();
68 
74  double AddError(double sinrInDb) const;
75 
76  private:
81  void ReadFile(std::string filePathName);
82 
87 
92  Ptr<NormalRandomVariable> m_normalRandomVariable;
93 
97  std::vector<double> m_sinrsDb;
98 
102  std::vector<double> m_mueCesDb;
103 
107  std::vector<double> m_stdCesDb;
108 };
109 
110 } // namespace ns3
111 
112 #endif /* SATELLITE_CHANNEL_ESTIMATION_ERROR_H_ */
SatChannelEstimatorError reads from file and stores the channel estimation error mean and standard de...
std::vector< double > m_sinrsDb
SINR values.
uint32_t m_lastSampleIndex
Last sample index of the containers.
Ptr< NormalRandomVariable > m_normalRandomVariable
Normal random variable used to calculate the channel estimation error.
virtual ~SatChannelEstimationError()
Destructor for SatChannelEstimationError.
std::vector< double > m_stdCesDb
Standard deviation values.
double AddError(double sinrInDb) const
Add channel estimation error to SINR.
virtual void DoDispose()
Dispose of this class instance.
std::vector< double > m_mueCesDb
Mean values.
void ReadFile(std::string filePathName)
Read the distribution mean and STD values from file.
static TypeId GetTypeId(void)
inherited from Object
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.