radio.h File Reference

#include "geom.h"
#include "source.h"
#include "utils.h"

Go to the source code of this file.

Defines

#define SPEED_LIGHT   299792458
#define DENIED   1024
#define LARGE_LOSS   -16777216
#define CONSIDER_VEG   true
#define CONSIDER_LAND   true

Functions

double knifeEdgeLoss (double startY, double endY, double pointY, double distX, double dist1X, double dist2X, double lambda, double sight)
double calcFresnelLoss (double ground, double sight, double fresnel)
double calcLandLoss (int type, double distance, double freq)
double pathLoss (Point *p, Point *q, SourceGroup *s, double resolution, double txPower, double antenna, double freq)
double pathLossLongley (Point *p, Point *q, SourceGroup *s, double resolution, double txPower, double antenna, double freq)


Define Documentation

#define CONSIDER_LAND   true

#define CONSIDER_VEG   true

#define DENIED   1024

#define LARGE_LOSS   -16777216

#define SPEED_LIGHT   299792458


Function Documentation

double calcFresnelLoss ( double  ground,
double  sight,
double  fresnel 
)

Calculate the fresnel loss given the situation variables. This model was found in literature, but seems less reliable.

Parameters:
ground Elevation of ground at current point, in meters
sight Imaginary elevation of line-of-sight between origin and end point, in meters
fresnel Low-point elevation of first-fresnel zone at current point, in meters
Returns:
Calculated loss, in dBm

double calcLandLoss ( int  type,
double  distance,
double  freq 
)

Calculate the land-use attentuation loss assuming we pass through a specific distance of given type. This equation seems very unreliable, and has not been verified.

Parameters:
type Enumeration value of type of land-use we are passing through
distance Distance of this land-use type that our signal passes through, in meters
freq Frequency of our transmitted signal, in MHz
Returns:
Calculated loss, in dBm

double knifeEdgeLoss ( double  startY,
double  endY,
double  pointY,
double  distX,
double  dist1X,
double  dist2X,
double  lambda,
double  sight 
)

Calculate the knife-edge loss given the situation variables.

Parameters:
startY Signal origin elevation point, in meters
endY Signal end elevation point, in meters
pointY Elevation where we are currently calculating knife-edge loss, in meters
distX Distance along the path between the origin and end points, in meters
dist1X Fraction along the path between origin and end point, from origin point
dist2X Fraction along the path between origin and end point, remaining towards end point
lambda Lambda value calculated using signal frequency
sight Imaginary elevation of line-of-sight between origin and end point, in meters
Returns:
Calculated loss as provided by knife-edge diffraction model, in dBm

double pathLoss ( Point p,
Point q,
SourceGroup s,
double  resolution,
double  txPower,
double  antenna,
double  freq 
)

Calculate the loss if we follow a given path between two radio towers.

Parameters:
p Signal origin point, with towerHeight set
q Signal destination point, with towerHeight set
s SourceGroup to provide elevation and vegetaion data as required
resolution Detail used to step along the line-of-sight path, in kilometers
txPower Transmitter power, in mW
antenna Total antenna gain of both receiver and transmitter, in dB
freq Frequency that radios operate at, in MHz
Returns:
Calculated loss along given path, in dBm

double pathLossLongley ( Point p,
Point q,
SourceGroup s,
double  resolution,
double  txPower,
double  antenna,
double  freq 
)

Calculate the loss if we follow a given path between two radio towers. Uses Longley-Rice propagation model to calculate attenuation.

Parameters:
p Signal origin point, with towerHeight set
q Signal destination point, with towerHeight set
s SourceGroup to provide elevation and vegetaion data as required
resolution Detail used to step along the line-of-sight path, in kilometers
txPower Transmitter power, in mW
antenna Total antenna gain of both receiver and transmitter, in dB
freq Frequency that radios operate at, in MHz
Returns:
Calculated loss along given path, in dBm


Generated on Sat Feb 23 21:49:22 2008 for libprop by  doxygen 1.5.4