A Discrete-Event Network Simulator
API
three-gpp-v2v-propagation-loss-model.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2020 SIGNET Lab, Department of Information Engineering,
3  * University of Padova
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 
19 #ifndef THREE_GPP_V2V_PROPAGATION_LOSS_MODEL_H
20 #define THREE_GPP_V2V_PROPAGATION_LOSS_MODEL_H
21 
23 
24 namespace ns3
25 {
26 
34 {
35  public:
40  static TypeId GetTypeId();
41 
46 
51 
52  // Delete copy constructor and assignment operator to avoid misuse
55  delete;
56 
57  private:
67  double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override;
68 
84  double GetO2iDistance2dIn() const override;
85 
95  double GetLossNlosv(double distance2D,
96  double distance3D,
97  double hUt,
98  double hBs) const override;
99 
109  double GetLossNlos(double distance2D, double distance3D, double hUt, double hBs) const override;
110 
118  double GetAdditionalNlosvLoss(double distance3D, double hUt, double hBs) const;
119 
129  ChannelCondition::LosConditionValue cond) const override;
130 
137 
138  int64_t DoAssignStreams(int64_t stream) override;
139 
143 };
144 
152 {
153  public:
158  static TypeId GetTypeId();
159 
164 
169 
170  private:
180  double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override;
181 };
182 
183 } // namespace ns3
184 
185 #endif /* THREE_GPP_V2V_PROPAGATION_LOSS_MODEL_H */
LosConditionValue
Possible values for Line-of-Sight condition.
Base class for the 3GPP propagation models.
Implements the pathloss model defined in 3GPP TR 37.885, Table 6.2.1-1 for the Highway scenario.
double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is not obstructed.
Implements the pathloss model defined in 3GPP TR 37.885, Table 6.2.1-1 for the Urban scenario.
double GetShadowingStd(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading standard deviation.
double GetLossNlosv(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is obstructed by a vehicle.
ThreeGppV2vUrbanPropagationLossModel(const ThreeGppV2vUrbanPropagationLossModel &)=delete
double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is not obstructed.
double GetO2iDistance2dIn() const override
Returns the minimum of the two independently generated distances according to the uniform distributio...
double GetShadowingCorrelationDistance(ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading correlation distance.
double m_percType3Vehicles
percentage of Type 3 vehicles in the scenario (i.e., trucks)
Ptr< LogNormalRandomVariable > m_logNorVar
log normal random variable
double GetLossNlos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is obstructed by a building.
int64_t DoAssignStreams(int64_t stream) override
Assign a fixed random variable stream number to the random variables used by this model.
ThreeGppV2vUrbanPropagationLossModel & operator=(const ThreeGppV2vUrbanPropagationLossModel &)=delete
double GetAdditionalNlosvLoss(double distance3D, double hUt, double hBs) const
Computes the additional loss due to an obstruction caused by a vehicle.
Ptr< UniformRandomVariable > m_uniformVar
uniform random variable
a unique identifier for an interface.
Definition: type-id.h:59
Every class exported by the ns3 library is enclosed in the ns3 namespace.