A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
Loading...
Searching...
No Matches
uan-prop-model-ideal.cc
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2009 University of Washington
3
*
4
* SPDX-License-Identifier: GPL-2.0-only
5
*
6
* Author: Leonard Tracy <lentracy@gmail.com>
7
*/
8
9
#include "
uan-prop-model-ideal.h
"
10
11
#include "
uan-tx-mode.h
"
12
13
#include "ns3/mobility-model.h"
14
15
namespace
ns3
16
{
17
18
NS_OBJECT_ENSURE_REGISTERED
(UanPropModelIdeal);
19
20
UanPropModelIdeal::UanPropModelIdeal
()
21
{
22
}
23
24
UanPropModelIdeal::~UanPropModelIdeal
()
25
{
26
}
27
28
TypeId
29
UanPropModelIdeal::GetTypeId
()
30
{
31
static
TypeId
tid =
TypeId
(
"ns3::UanPropModelIdeal"
)
32
.
SetParent
<
UanPropModel
>()
33
.SetGroupName(
"Uan"
)
34
.AddConstructor<
UanPropModelIdeal
>();
35
return
tid;
36
}
37
38
double
39
UanPropModelIdeal::GetPathLossDb
(
Ptr<MobilityModel>
a,
Ptr<MobilityModel>
b,
UanTxMode
mode)
40
{
41
return
0;
42
}
43
44
UanPdp
45
UanPropModelIdeal::GetPdp
(
Ptr<MobilityModel>
a,
Ptr<MobilityModel>
b,
UanTxMode
mode)
46
{
47
return
UanPdp::CreateImpulsePdp
();
48
}
49
50
Time
51
UanPropModelIdeal::GetDelay
(
Ptr<MobilityModel>
a,
Ptr<MobilityModel>
b,
UanTxMode
mode)
52
{
53
return
Seconds
(a->GetDistanceFrom(b) / 1500.0);
54
}
55
56
}
// namespace ns3
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition
mpi-test-fixtures.h:37
ns3::Time
Simulation virtual time values and global simulation resolution.
Definition
nstime.h:94
ns3::TypeId
a unique identifier for an interface.
Definition
type-id.h:48
ns3::TypeId::SetParent
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Definition
type-id.cc:1001
ns3::UanPdp
The power delay profile returned by propagation models.
Definition
uan-prop-model.h:79
ns3::UanPdp::CreateImpulsePdp
static UanPdp CreateImpulsePdp()
Get a unit impulse PDP at time 0.
Definition
uan-prop-model.cc:348
ns3::UanPropModel
Base class for implemented underwater propagation models.
Definition
uan-prop-model.h:272
ns3::UanPropModelIdeal
Ideal propagation model (no pathloss, impulse PDP).
Definition
uan-prop-model-ideal.h:26
ns3::UanPropModelIdeal::GetDelay
Time GetDelay(Ptr< MobilityModel > a, Ptr< MobilityModel > b, UanTxMode mode) override
Finds propagation delay between nodes a and b.
Definition
uan-prop-model-ideal.cc:51
ns3::UanPropModelIdeal::UanPropModelIdeal
UanPropModelIdeal()
Default constructor.
Definition
uan-prop-model-ideal.cc:20
ns3::UanPropModelIdeal::GetPdp
UanPdp GetPdp(Ptr< MobilityModel > a, Ptr< MobilityModel > b, UanTxMode mode) override
Get the PDP for the path between two nodes.
Definition
uan-prop-model-ideal.cc:45
ns3::UanPropModelIdeal::~UanPropModelIdeal
~UanPropModelIdeal() override
Destructor.
Definition
uan-prop-model-ideal.cc:24
ns3::UanPropModelIdeal::GetTypeId
static TypeId GetTypeId()
Register this type.
Definition
uan-prop-model-ideal.cc:29
ns3::UanPropModelIdeal::GetPathLossDb
double GetPathLossDb(Ptr< MobilityModel > a, Ptr< MobilityModel > b, UanTxMode mode) override
Computes pathloss between nodes a and b.
Definition
uan-prop-model-ideal.cc:39
ns3::UanTxMode
Abstraction of packet modulation information.
Definition
uan-tx-mode.h:32
NS_OBJECT_ENSURE_REGISTERED
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Definition
object-base.h:35
ns3::Seconds
Time Seconds(double value)
Construct a Time in the indicated unit.
Definition
nstime.h:1308
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
uan-prop-model-ideal.h
uan-tx-mode.h
src
uan
model
uan-prop-model-ideal.cc
Generated on Sat Nov 2 2024 19:37:32 for ns-3 by
1.11.0