A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
nist-error-rate-model.h
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2010 The Boeing Company
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: Gary Pei <guangyu.pei@boeing.com>
19  */
20 #ifndef NIST_ERROR_RATE_MODEL_H
21 #define NIST_ERROR_RATE_MODEL_H
22 
23 #include <stdint.h>
24 #include "wifi-mode.h"
25 #include "error-rate-model.h"
26 #include "dsss-error-rate-model.h"
27 
28 namespace ns3 {
29 
39 {
40 public:
41  static TypeId GetTypeId (void);
42 
44 
45  virtual double GetChunkSuccessRate (WifiMode mode, double snr, uint32_t nbits) const;
46 
47 private:
48  double CalculatePe (double p, uint32_t bValue) const;
49  double GetBpskBer (double snr) const;
50  double GetQpskBer (double snr) const;
51  double Get16QamBer (double snr) const;
52  double Get64QamBer (double snr) const;
53  double GetFecBpskBer (double snr, double nbits,
54  uint32_t bValue) const;
55  double GetFecQpskBer (double snr, double nbits,
56  uint32_t bValue) const;
57  double GetFec16QamBer (double snr, uint32_t nbits,
58  uint32_t bValue) const;
59  double GetFec64QamBer (double snr, uint32_t nbits,
60  uint32_t bValue) const;
61 };
62 
63 
64 } // namespace ns3
65 
66 #endif /* NIST_ERROR_RATE_MODEL_H */
represent a single transmission modeA WifiMode is implemented by a single integer which is used to lo...
Definition: wifi-mode.h:88
the interface for Wifi's error models
a unique identifier for an interface.
Definition: type-id.h:44