20 #ifndef SATELLITE_UTILS_H
21 #define SATELLITE_UTILS_H
26 #include <ns3/mac48-address.h>
27 #include <ns3/packet.h>
58 return (T)((radian) * (180.0 / M_PI));
70 return (T)((degree) * (M_PI / 180.0));
81 return (T)(std::numeric_limits<T>::min());
92 return (T)(std::numeric_limits<T>::max());
100 template <
typename T>
111 template <
typename T>
123 template <
typename T>
126 return (T)DbToLinear<T>(dbw);
135 template <
typename T>
138 return (T)LinearToDb<T>(w);
150 template <
typename T>
153 if ((db < MinDb<T>() && (std::isinf(-db) !=
false)) || db > MaxDb<T>())
155 NS_FATAL_ERROR(
"SatUtils::DbToLinear - unsupported value: " << db);
158 return (T)std::pow(10.0, db / 10.0);
169 template <
typename T>
172 if ((linear < MinLin<T>() && linear != 0) || linear > MaxLin<T>())
174 NS_FATAL_ERROR(
"SatUtils::LinearToDb - unsupported value: " << linear);
177 return (T)(10.0 * std::log10(linear));
186 template <
typename T>
189 return (DbWToW<T>(dbm) / 1000);
198 template <
typename T>
201 return (T)(WToDbW<T>(w * 1000.0));
212 std::ostringstream oss;
213 oss << p->GetUid() <<
" ";
215 if (p->PeekPacketTag(tag))
229 static inline std::string
GetPacketInfo(
const std::vector<Ptr<Packet>> packets)
231 std::ostringstream oss;
232 for (std::vector<Ptr<Packet>>::const_iterator it = packets.begin(); it != packets.end();
531 NS_FATAL_ERROR(
"Unsupported enum SatModcod_t!");
913 NS_FATAL_ERROR(
"Unsupported enum SatModcod_t!");
1145 NS_FATAL_ERROR(
"Frame type not found");
1164 static inline double Interpolate(
double x,
double x0,
double x1,
double y0,
double y1)
1166 double dX = x1 - x0;
1167 double dY = y1 - y0;
1168 double relX = x - x0;
1169 double relY = (dY / dX) * relX;
1178 static inline double ScalarProduct(
const std::vector<std::pair<double, double>>& vector)
1180 double scalarProduct = 0.0;
1181 for (
const std::pair<double, double>& element : vector)
1183 scalarProduct += element.first * element.second;
1185 return scalarProduct;
SatBbFrameType_t
BB frame type used in DVB-S2 FWD link.
SatModcod_t
Modulation scheme and coding rate for DVB-S2.
@ SAT_MODCOD_S2X_16APSK_2_TO_3_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_9_TO_10_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_2_TO_3_NORMAL_PILOTS
@ SAT_MODCOD_S2X_256APSK_32_TO_45_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_5_TO_6_SHORT_PILOTS
@ SAT_MODCOD_S2X_8PSK_3_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_128APSK_7_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_15_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_8_TO_15_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_256APSK_11_TO_15_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_4_TO_5_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_3_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_256APSK_3_TO_4_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_3_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_4_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_32_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_13_TO_45_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_7_TO_15_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_1_TO_2_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_5_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_32_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_5_TO_6_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_7_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_8_TO_9_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_3_TO_4_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_23_TO_36_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_2_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_3_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_256APSK_11_TO_15_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_64APSK_32_TO_45_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_1_TO_2_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_5_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_5_TO_6_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_9_TO_10_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_8_TO_15_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_25_TO_36_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_32_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_3_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_5_TO_9_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_64APSK_32_TO_45_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_128APSK_3_TO_4_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_8_TO_9_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_13_TO_18_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8APSK_5_TO_9_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_4_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_32_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_32APSK_32_TO_45_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8APSK_26_TO_45_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_2_TO_3_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_128APSK_3_TO_4_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_4_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_15_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_5_TO_6_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_4_TO_5_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_3_TO_5_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_26_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_32APSK_9_TO_10_NORMAL_NOPILOTS
@ SAT_MODCOD_16APSK_3_TO_4
@ SAT_MODCOD_S2X_64APSK_11_TO_15_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_5_TO_6_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_8_TO_9_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_23_TO_36_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_4_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_3_TO_4_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_64APSK_7_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_8_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_16APSK_2_TO_3
@ SAT_MODCOD_S2X_32APSK_2_TO_3_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_4_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_2_TO_3_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_5_TO_6_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_5_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_2_TO_3_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_8_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_28_TO_45_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_23_TO_36_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_4_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_25_TO_36_NORMAL_NOPILOTS
@ SAT_MODCOD_16APSK_8_TO_9
@ SAT_MODCOD_S2X_8PSK_3_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_3_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_14_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_5_TO_6_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_5_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_5_TO_6_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_32_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_5_TO_6_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_3_TO_4_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_4_TO_15_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_5_TO_6_NORMAL_PILOTS
@ SAT_MODCOD_QPSK_9_TO_10
@ SAT_MODCOD_16APSK_5_TO_6
@ SAT_MODCOD_S2X_QPSK_11_TO_20_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_3_TO_4_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_32_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_7_TO_15_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_11_TO_20_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_4_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_256APSK_29_TO_45_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_64APSK_11_TO_15_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_8PSK_9_TO_10
@ SAT_MODCOD_S2X_16APSK_2_TO_3_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_5_TO_6_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_3_NORMAL_PILOTS
@ SAT_MODCOD_32APSK_5_TO_6
@ SAT_MODCOD_32APSK_3_TO_4
@ SAT_MODCOD_S2X_QPSK_3_TO_5_SHORT_NOPILOTS
@ SAT_MODCOD_32APSK_8_TO_9
@ SAT_MODCOD_S2X_16APSK_7_TO_15_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_256APSK_31_TO_45_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_8_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_7_TO_15_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_4_TO_5_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_28_TO_45_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_3_TO_4_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_13_TO_45_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_3_TO_5_SHORT_PILOTS
@ SAT_MODCOD_S2X_64APSK_5_TO_6_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_5_TO_6_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_2_TO_3_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_25_TO_36_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_5_TO_6_SHORT_PILOTS
@ SAT_MODCOD_S2X_32APSK_11_TO_15_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_4_TO_5_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_5_TO_6_SHORT_PILOTS
@ SAT_MODCOD_S2X_32APSK_32_TO_45_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_4_TO_5_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_4_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8APSK_5_TO_9_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_13_TO_18_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_8_TO_15_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_5_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_5_TO_6_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_4_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_256APSK_31_TO_45_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_9_SHORT_PILOTS
@ SAT_MODCOD_S2X_256APSK_32_TO_45_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_3_TO_5_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_5_TO_6_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_7_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_7_TO_15_SHORT_PILOTS
@ SAT_MODCOD_S2X_64APSK_5_TO_6_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_9_TO_10_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_13_TO_18_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_9_TO_20_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8APSK_26_TO_45_L_NORMAL_NOPILOTS
@ SAT_MODCOD_32APSK_4_TO_5
@ SAT_MODCOD_S2X_64APSK_7_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_3_TO_4_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_9_TO_20_NORMAL_PILOTS
@ SAT_MODCOD_16APSK_9_TO_10
@ SAT_MODCOD_S2X_16APSK_3_TO_4_SHORT_PILOTS
@ SAT_MODCOD_S2X_256APSK_2_TO_3_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_26_TO_45_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_2_TO_3_SHORT_PILOTS
@ SAT_MODCOD_S2X_256APSK_29_TO_45_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_256APSK_2_TO_3_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_64APSK_4_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_3_TO_4_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_15_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_5_TO_9_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_4_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_2_TO_3_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_13_TO_18_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_77_TO_90_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_4_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_9_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_9_TO_10_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_8_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_2_TO_3_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_32_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_3_SHORT_PILOTS
@ SAT_MODCOD_S2X_32APSK_7_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_32_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_3_TO_4_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_3_TO_4_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_25_TO_36_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_3_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_3_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_3_TO_4_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_7_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_8_TO_9_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_2_NORMAL_PILOTS
@ SAT_MODCOD_S2X_64APSK_4_TO_5_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_5_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_8_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_8_TO_9_NORMAL_PILOTS
@ SAT_MODCOD_16APSK_4_TO_5
@ SAT_MODCOD_S2X_8PSK_2_TO_3_NORMAL_PILOTS
@ SAT_MODCOD_S2X_8PSK_2_TO_3_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_2_TO_3_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_4_TO_15_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_2_TO_3_L_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_23_TO_36_NORMAL_PILOTS
@ SAT_MODCOD_S2X_16APSK_26_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_26_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_3_TO_5_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_8_TO_9_SHORT_PILOTS
@ SAT_MODCOD_S2X_QPSK_14_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_4_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_26_TO_45_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_2_SHORT_PILOTS
@ SAT_MODCOD_S2X_32APSK_8_TO_9_SHORT_PILOTS
@ SAT_MODCOD_S2X_8PSK_26_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_8PSK_9_TO_10_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_8PSK_9_TO_10_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_8_TO_15_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_3_TO_4_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_1_TO_2_NORMAL_NOPILOTS
@ SAT_MODCOD_16QAM_5_TO_6
@ SAT_MODCOD_S2X_QPSK_11_TO_45_SHORT_PILOTS
@ SAT_MODCOD_S2X_16APSK_8_TO_15_L_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_11_TO_15_NORMAL_PILOTS
@ SAT_MODCOD_S2X_32APSK_3_TO_4_SHORT_PILOTS
@ SAT_MODCOD_S2X_8PSK_7_TO_15_SHORT_NOPILOTS
@ SAT_MODCOD_16QAM_3_TO_4
@ SAT_MODCOD_S2X_QPSK_1_TO_4_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_128APSK_7_TO_9_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_QPSK_9_TO_10_NORMAL_PILOTS
@ SAT_MODCOD_S2X_QPSK_11_TO_45_SHORT_NOPILOTS
@ SAT_MODCOD_S2X_16APSK_77_TO_90_NORMAL_NOPILOTS
@ SAT_MODCOD_S2X_32APSK_4_TO_5_SHORT_PILOTS
@ SAT_MODCOD_S2X_256APSK_3_TO_4_NORMAL_PILOTS
This class implements a tag that carries the satellite MAC specific information, such as source and d...
Mac48Address GetSourceAddress(void) const
Get source MAC address.
Mac48Address GetDestAddress(void) const
Get destination MAC address.
SatUtils class is for general conversions used in satellite module.
static T DbWToW(T dbw)
Converts Decibel Watts to Watts.
static T WToDbm(T w)
Converts Watts to Decibel milli Watts.
static SatEnums::SatBbFrameType_t GetFrameTypeS2X(SatEnums::SatModcod_t modcod)
static double Interpolate(double x, double x0, double x1, double y0, double y1)
Simple linear interpolation.
static double ScalarProduct(const std::vector< std::pair< double, double >> &vector)
Scalar product.
static T DbToLinear(T db)
Converts decibels to linear.
static T MinDb()
Get minimum value for Decibel.
static T RadiansToDegrees(T radian)
Converts radians to degrees.
static T DbmToW(T dbm)
Converts Decibel milli Watts to Watts.
static std::string GetPacketInfo(const std::vector< Ptr< Packet >> packets)
Gets packet information in std::string for printing purposes.
static T DegreesToRadians(T degree)
Converts degrees to radians.
static T WToDbW(T w)
Converts Watts to Decibel Watts.
static T LinearToDb(T linear)
Converts linear to decibels.
virtual ~SatUtils()=0
Destructor.
static uint32_t GetModulatedBits(SatEnums::SatModcod_t modcod)
Get the modulated bits of a certain MODCOD.
static T MaxLin()
Get maximum value for linear.
static double GetCodingRate(SatEnums::SatModcod_t modcod)
Gets the coding rate of a certain MODCOD.
static T MaxDb()
Get maximum value for Decibel.
static std::string GetPacketInfo(const Ptr< const Packet > p)
Get packet information in std::string for printing purposes.
static T MinLin()
Get minimum value for linear.
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.