A Discrete-Event Network Simulator
API
ns3::WifiSpectrumValueHelper Class Reference

This class defines all functions to create a spectrum model for Wi-Fi based on a a spectral model aligned with an OFDM subcarrier spacing of 312.5 KHz (model also reused for DSSS modulations) More...

#include "wifi-spectrum-value-helper.h"

Public Member Functions

virtual ~WifiSpectrumValueHelper ()
 Destructor. More...
 

Static Public Member Functions

static Ptr< SpectrumValueCreateDsssTxPowerSpectralDensity (uint32_t centerFrequency, double txPowerW)
 Create a transmit power spectral density corresponding to DSSS. More...
 
static Ptr< SpectrumValueCreateHtOfdmTxPowerSpectralDensity (uint32_t centerFrequency, uint32_t channelWidth, double txPowerW)
 Create a transmit power spectral density corresponding to OFDM High Throughput (HT) (802.11n/ac). More...
 
static Ptr< SpectrumValueCreateNoisePowerSpectralDensity (uint32_t centerFrequency, uint32_t channelWidth, double noiseFigure)
 
static Ptr< SpectrumValueCreateNoisePowerSpectralDensity (double noiseFigure, Ptr< SpectrumModel > spectrumModel)
 
static Ptr< SpectrumValueCreateOfdmTxPowerSpectralDensity (uint32_t centerFrequency, uint32_t channelWidth, double txPowerW)
 Create a transmit power spectral density corresponding to OFDM (802.11a/g). More...
 
static Ptr< SpectrumValueCreateRfFilter (uint32_t centerFrequency, uint32_t channelWidth)
 
static Ptr< SpectrumModelGetSpectrumModel (uint32_t centerFrequency, uint32_t channelWidth)
 Return a SpectrumModel instance corresponding to the center frequency and channel width. More...
 

Detailed Description

This class defines all functions to create a spectrum model for Wi-Fi based on a a spectral model aligned with an OFDM subcarrier spacing of 312.5 KHz (model also reused for DSSS modulations)

Definition at line 36 of file wifi-spectrum-value-helper.h.

Constructor & Destructor Documentation

ns3::WifiSpectrumValueHelper::~WifiSpectrumValueHelper ( )
virtual

Destructor.

Definition at line 363 of file wifi-spectrum-value-helper.cc.

Member Function Documentation

Ptr< SpectrumValue > ns3::WifiSpectrumValueHelper::CreateDsssTxPowerSpectralDensity ( uint32_t  centerFrequency,
double  txPowerW 
)
static

Create a transmit power spectral density corresponding to DSSS.

The center frequency typically corresponds to 802.11b channel center frequencies but is not restricted to those frequencies.

Parameters
centerFrequencycenter frequency (MHz)
txPowerWtransmit power (W) to allocate

Definition at line 286 of file wifi-spectrum-value-helper.cc.

References ns3::SpectrumValue::ConstBandsBegin(), ns3::SpectrumModel::GetNumBands(), GetSpectrumModel(), ns3::SpectrumValue::GetSpectrumModel(), NS_ASSERT, NS_LOG_FUNCTION, and ns3::SpectrumValue::ValuesBegin().

Referenced by ns3::SpectrumWifiPhy::GetTxPowerSpectralDensity().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Ptr< SpectrumValue > ns3::WifiSpectrumValueHelper::CreateHtOfdmTxPowerSpectralDensity ( uint32_t  centerFrequency,
uint32_t  channelWidth,
double  txPowerW 
)
static

Create a transmit power spectral density corresponding to OFDM High Throughput (HT) (802.11n/ac).

Channel width may vary between 20, 40, 80, and 160 MHz.

Parameters
centerFrequencycenter frequency (MHz)
channelWidthchannel width (MHz)
txPowerWtransmit power (W) to allocate

Definition at line 109 of file wifi-spectrum-value-helper.cc.

References ns3::SpectrumValue::ConstBandsBegin(), ns3::SpectrumModel::GetNumBands(), GetSpectrumModel(), ns3::SpectrumValue::GetSpectrumModel(), ns3::Integral(), NS_ASSERT_MSG, NS_FATAL_ERROR, NS_LOG_DEBUG, NS_LOG_FUNCTION, and ns3::SpectrumValue::ValuesBegin().

Referenced by ns3::SpectrumWifiPhy::GetTxPowerSpectralDensity().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Ptr< SpectrumValue > ns3::WifiSpectrumValueHelper::CreateNoisePowerSpectralDensity ( uint32_t  centerFrequency,
uint32_t  channelWidth,
double  noiseFigure 
)
static
Parameters
centerFrequencycenter frequency (MHz)
channelWidthchannel width (MHz)
noiseFigurethe noise figure in dB w.r.t. a reference temperature of 290K
Returns
a pointer to a newly allocated SpectrumValue representing the noise Power Spectral Density in W/Hz for each Band

Definition at line 308 of file wifi-spectrum-value-helper.cc.

References GetSpectrumModel().

+ Here is the call graph for this function:

Ptr< SpectrumValue > ns3::WifiSpectrumValueHelper::CreateNoisePowerSpectralDensity ( double  noiseFigure,
Ptr< SpectrumModel spectrumModel 
)
static
Parameters
centerFrequencycenter frequency (MHz)
channelWidthchannel width (MHz)
Returns
a pointer to a newly allocated SpectrumValue representing the noise Power Spectral Density in W/Hz corresponding to thermal noise, for each Band

Definition at line 315 of file wifi-spectrum-value-helper.cc.

References ns3::Integral(), NS_LOG_DEBUG, and NS_LOG_FUNCTION.

+ Here is the call graph for this function:

Ptr< SpectrumValue > ns3::WifiSpectrumValueHelper::CreateOfdmTxPowerSpectralDensity ( uint32_t  centerFrequency,
uint32_t  channelWidth,
double  txPowerW 
)
static

Create a transmit power spectral density corresponding to OFDM (802.11a/g).

Channel width may vary between 20, 10, and 5 MHz.

Parameters
centerFrequencycenter frequency (MHz)
channelWidthchannel width (MHz)
txPowerWtransmit power (W) to allocate

Definition at line 202 of file wifi-spectrum-value-helper.cc.

References ns3::SpectrumValue::ConstBandsBegin(), ns3::SpectrumModel::GetNumBands(), GetSpectrumModel(), ns3::SpectrumValue::GetSpectrumModel(), ns3::Integral(), NS_ASSERT_MSG, NS_FATAL_ERROR, NS_LOG_DEBUG, NS_LOG_FUNCTION, and ns3::SpectrumValue::ValuesBegin().

Referenced by ns3::SpectrumWifiPhy::GetTxPowerSpectralDensity().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Ptr< SpectrumValue > ns3::WifiSpectrumValueHelper::CreateRfFilter ( uint32_t  centerFrequency,
uint32_t  channelWidth 
)
static
Parameters
centerFrequencycenter frequency (MHz)
channelWidthchannel width (MHz)
Returns
a pointer to a SpectrumValue representing the RF filter applied to an received power spectral density

Definition at line 333 of file wifi-spectrum-value-helper.cc.

References ns3::SpectrumValue::ConstBandsBegin(), ns3::SpectrumModel::GetNumBands(), GetSpectrumModel(), ns3::SpectrumValue::GetSpectrumModel(), NS_ASSERT_MSG, NS_LOG_DEBUG, NS_LOG_FUNCTION, and ns3::SpectrumValue::ValuesBegin().

Referenced by ns3::SpectrumWifiPhy::StartRx().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Ptr< SpectrumModel > ns3::WifiSpectrumValueHelper::GetSpectrumModel ( uint32_t  centerFrequency,
uint32_t  channelWidth 
)
static

Return a SpectrumModel instance corresponding to the center frequency and channel width.

The model includes +/- 10 MHz of guard bands (i.e. the model will span (channelWidth + 20) MHz of bandwidth).

Parameters
centerFrequencycenter frequency (MHz)
channelWidthchannel width (MHz)
Returns
the static SpectrumModel instance corresponding to the given carrier frequency and channel width configuration.

Definition at line 57 of file wifi-spectrum-value-helper.cc.

References f(), ns3::BandInfo::fc, ns3::BandInfo::fh, ns3::BandInfo::fl, ns3::SpectrumModel::GetUid(), NS_ASSERT, NS_ASSERT_MSG, NS_LOG_DEBUG, NS_LOG_FUNCTION, and NS_LOG_LOGIC.

Referenced by CreateDsssTxPowerSpectralDensity(), CreateHtOfdmTxPowerSpectralDensity(), CreateNoisePowerSpectralDensity(), CreateOfdmTxPowerSpectralDensity(), CreateRfFilter(), ns3::SpectrumWifiPhy::DoChannelSwitch(), ns3::SpectrumWifiPhy::DoFrequencySwitch(), and ns3::SpectrumWifiPhy::GetRxSpectrumModel().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:


The documentation for this class was generated from the following files: