INET Framework for OMNeT++/OMNEST
inet::physicallayer::PathLossFunction Class Reference

This mathematical function provides the path loss over space and frequency. More...

#include <PowerFunctions.h>

Inheritance diagram for inet::physicallayer::PathLossFunction:
inet::math::FunctionBase< double, Domain< mps, m, Hz > > inet::math::IFunction< double, Domain< mps, m, Hz > >

Public Member Functions

 PathLossFunction (const IPathLoss *pathLoss)
 
virtual double getValue (const Point< mps, m, Hz > &p) const override
 
virtual void printStructure (std::ostream &os, int level=0) const override
 Prints the internal data structure of this function in a human readable form to the provided stream. More...
 
- Public Member Functions inherited from inet::math::FunctionBase< double, Domain< mps, m, Hz > >
virtual void partition (const typename Domain< mps, m, Hz > ::I &i, const std::function< void(const typename Domain< mps, m, Hz > ::I &, const IFunction< double, Domain< mps, m, Hz > > *)> callback) const override
 Subdivides the provided domain and calls back f with the subdomains and the corresponding potentially simpler domain limited functions. More...
 
virtual Interval< double > getRange () const override
 Returns the valid range of the function as an interval. More...
 
virtual Interval< double > getRange (const typename Domain< mps, m, Hz > ::I &i) const override
 Returns the valid range of the function as an interval for the given domain. More...
 
virtual Domain< mps, m, Hz > ::I getDomain () const override
 Returns the valid domain of the function as an interval. More...
 
virtual bool isFinite () const override
 Returns true if the function value is finite in the whole domain. More...
 
virtual bool isFinite (const typename Domain< mps, m, Hz > ::I &i) const override
 Returns true if the function value is finite in the given domain. More...
 
virtual bool isNonZero () const override
 Returns true if the function value is non-zero in the whole domain. More...
 
virtual bool isNonZero (const typename Domain< mps, m, Hz > ::I &i) const override
 Returns true if the function value is non-zero in the given domain. More...
 
virtual double getMin () const override
 Returns the minimum value for the whole domain. More...
 
virtual double getMin (const typename Domain< mps, m, Hz > ::I &i) const override
 Returns the minimum value for the given domain. More...
 
virtual double getMax () const override
 Returns the maximum value for the whole domain. More...
 
virtual double getMax (const typename Domain< mps, m, Hz > ::I &i) const override
 Returns the maximum value for the given domain. More...
 
virtual double getMean () const override
 Returns the mean value for the whole domain. More...
 
virtual double getMean (const typename Domain< mps, m, Hz > ::I &i) const override
 Returns the mean value for the given domain. More...
 
virtual double getIntegral () const override
 Returns the integral value for the whole domain. More...
 
virtual double getIntegral (const typename Domain< mps, m, Hz > ::I &i) const override
 Returns the integral value for the given domain. More...
 
virtual const Ptr< const IFunction< double, Domain< mps, m, Hz > > > add (const Ptr< const IFunction< double, Domain< mps, m, Hz > >> &o) const override
 Adds the provided function to this function. More...
 
virtual const Ptr< const IFunction< double, Domain< mps, m, Hz > > > subtract (const Ptr< const IFunction< double, Domain< mps, m, Hz > >> &o) const override
 Substracts the provided function from this function. More...
 
virtual const Ptr< const IFunction< double, Domain< mps, m, Hz > > > multiply (const Ptr< const IFunction< double, Domain< mps, m, Hz > >> &o) const override
 Multiplies the provided function with this function. More...
 
virtual const Ptr< const IFunction< double, Domain< mps, m, Hz > > > divide (const Ptr< const IFunction< double, Domain< mps, m, Hz > >> &o) const override
 Divides this function with the provided function. More...
 
virtual std::ostream & printOn (std::ostream &os) const override
 
virtual void print (std::ostream &os, int level=0) const override
 Prints this function in human readable form to the provided stream for the whole domain. More...
 
virtual void print (std::ostream &os, const typename Domain< mps, m, Hz > ::I &i, int level=0) const override
 Prints this function in a human readable form to the provided stream for the given domain. More...
 
virtual void printPartitioning (std::ostream &os, const typename Domain< mps, m, Hz > ::I &i, int level) const override
 Prints the partitioning of this function in a human readable form to the provided stream for the given domain. More...
 
virtual void printPartition (std::ostream &os, const typename Domain< mps, m, Hz > ::I &i, int level=0) const override
 Prints a single partition of this function in a human readable form to the provided stream for the given domain. More...
 
- Public Member Functions inherited from inet::math::IFunction< double, Domain< mps, m, Hz > >
virtual ~IFunction ()
 
virtual double getValue (const typename Domain< mps, m, Hz > ::P &p) const=0
 Returns the value of the function at the given point. More...
 

Protected Attributes

const IPathLosspathLoss
 

Detailed Description

This mathematical function provides the path loss over space and frequency.

Constructor & Destructor Documentation

◆ PathLossFunction()

inet::physicallayer::PathLossFunction::PathLossFunction ( const IPathLoss pathLoss)
inline
380 : pathLoss(pathLoss) {}

Member Function Documentation

◆ getValue()

virtual double inet::physicallayer::PathLossFunction::getValue ( const Point< mps, m, Hz > &  p) const
inlineoverridevirtual
382  {
383  mps propagationSpeed = std::get<0>(p);
384  Hz frequency = std::get<2>(p);
385  m distance = std::get<1>(p);
386  return pathLoss->computePathLoss(propagationSpeed, frequency, distance);
387  }

◆ printStructure()

virtual void inet::physicallayer::PathLossFunction::printStructure ( std::ostream &  os,
int  level = 0 
) const
inlineoverridevirtual

Prints the internal data structure of this function in a human readable form to the provided stream.

Reimplemented from inet::math::FunctionBase< double, Domain< mps, m, Hz > >.

389 { os << "(" << *pathLoss << ")"; }

Member Data Documentation

◆ pathLoss

const IPathLoss* inet::physicallayer::PathLossFunction::pathLoss
protected

The documentation for this class was generated from the following file:
inet::units::units::mps
compose< m, pow< s, -1 > > mps
Definition: Units.h:1151
inet::physicallayer::PathLossFunction::pathLoss
const IPathLoss * pathLoss
Definition: PowerFunctions.h:377
inet::physicallayer::IPathLoss::computePathLoss
virtual double computePathLoss(const ITransmission *transmission, const IArrival *arrival) const =0
Returns the loss factor for the provided transmission and arrival.
inet::units::values::m
value< double, units::m > m
Definition: Units.h:1233
inet::units::value
Definition: Units.h:81