RDK2::SensorData::LaserData Struct Reference

#include <laserdata.h>

Inheritance diagram for RDK2::SensorData::LaserData:

Inheritance graph
[legend]
Collaboration diagram for RDK2::SensorData::LaserData:

Collaboration graph
[legend]

Detailed Description

Note:
Laser data points (beams) are expected to be equally distantiated.

Definition at line 36 of file laserdata.h.


Public Types

typedef std::vector< LaserPointLaserPoints

Public Member Functions

 LaserData ()
 Constructor.
void mm2m ()
 Converts all internal measures from mm to meters.
void setLaserRollPitchYaw (double roll=0, double pitch=0, double yaw=0)
 Sets the Roll (angle around z axis), Pitch (angle around y axis), Yaw (angle around x axis) angles of the laser range scanner sensor in the case is mounted on a Tilt Joint.
double getLaserRoll ()
 Returns the Roll angle of the laser range scanner sensor Rotation around the vertical axis (z) is called roll.
double getLaserPitch ()
 Returns the Pitch angle of the laser range scanner sensor. Rotation around the side-to-side (y) axis is called pitch.
double getLaserYaw ()
 Returns the Yaw angle of the laser range scanner sensor Rotation around the bottom to front axis (x) is called yaw.
int getNearestIndex (double theta) const
 Returns the index of the ray that is nearest to theta. Returns the index of the ray that is nearest to theta, that is, $ round(\frac{\theta - \theta_{min}}{d}) $ in which $ d = \frac{\theta_{max} - \theta_{min}}{n_{points} - 1} $.
double getRayWidth () const
 Returns the distance between two rays (supposed to be the same for each ray). Returns the distance between two rays (supposed to be the same for each ray), that is, $ \frac{\theta_{max} - \theta_{min}}{n_{points} - 1} $.
void updateThetas ()
 Update the theta value of all laser points Update the theta value of all laser points, according to $ \theta_{min} $, $ \theta_{max} $ and the number of points.
double minRange () const
 Returns minimum range (values of 0 are ignored).
int getMinAngle ()
bool raysEqualTo (const LaserData &ld)
 True if same rays.
int numValidPoints () const
 Number of points with reading != 0.
bool isInsideClearArea (RDK2::Geometry::Point2d world) const
 Returns true if the point is in the clear area swept by the laser.
RDK2::Geometry::DMatrixD getFisherForXY ()
 Returns the (unscaled) 2x2 Fisher's information matrix for (x,y).
double getFisherForTheta ()
 Returns the (unscaled) 1x1 Fisher's information matrix for theta.
RDK2::Geometry::DMatrixD getFisher ()
 Returns the (unscaled) 3x3 Fisher's information matrix for (x,y,theta).
RDK2::Geometry::DMatrixD getFisher (double sigma)
 Returns the information matrix properly scaled by sigma.
RDK2::Geometry::DMatrixD getCRB (double sigma) throw (RDK2::Geometry::DNotInvertibleMatrixException)
 Trhows if Fisher's matrix is singular (under constrained situation).
void copy (const LaserData &)
ParsergetParser () const

Data Fields

RDK2::Geometry::Point3od laserPose
 Position of laser relative to robot.
double minReading
 Minimum and maximum sensor range. Points above and below are invalid.
double maxReading
double minTheta
 Span of data. Probably minTheta=-PI/2, maxTheta=+PI/2.
double maxTheta
double roll
 Roll angle of robot position.
double pitch
 Pitch angle of robot position.
double laserPan
LaserPoints points

Static Public Attributes

static LaserParser laserParser

Data Structures

struct  LaserPoint

Member Typedef Documentation

Definition at line 90 of file laserdata.h.


Constructor & Destructor Documentation

RDK2::SensorData::LaserData::LaserData (  )  [inline]

Constructor.

Definition at line 94 of file laserdata.h.

References maxReading, maxTheta, minReading, and minTheta.


Member Function Documentation

void RDK2::SensorData::LaserData::mm2m (  ) 

Converts all internal measures from mm to meters.

Deprecated:

Definition at line 142 of file laserdata.cpp.

References RDK2::SensorData::BaseSensorData::estimatedPose, laserPose, maxReading, minReading, RDK2::Geometry::mm2m(), RDK2::SensorData::BaseSensorData::odometryPose, and points.

Here is the call graph for this function:

void RDK2::SensorData::LaserData::setLaserRollPitchYaw ( double  roll = 0,
double  pitch = 0,
double  yaw = 0 
) [inline]

Sets the Roll (angle around z axis), Pitch (angle around y axis), Yaw (angle around x axis) angles of the laser range scanner sensor in the case is mounted on a Tilt Joint.

Definition at line 111 of file laserdata.h.

References RDK2::Geometry::Point3o< Numeric >::gamma, laserPose, RDK2::Geometry::Point3o< Numeric >::phi, pitch, roll, and RDK2::Geometry::Point2o< Numeric >::theta.

double RDK2::SensorData::LaserData::getLaserRoll (  )  [inline]

Returns the Roll angle of the laser range scanner sensor Rotation around the vertical axis (z) is called roll.

Definition at line 116 of file laserdata.h.

References laserPose, and RDK2::Geometry::Point2o< Numeric >::theta.

double RDK2::SensorData::LaserData::getLaserPitch (  )  [inline]

Returns the Pitch angle of the laser range scanner sensor. Rotation around the side-to-side (y) axis is called pitch.

Definition at line 121 of file laserdata.h.

References laserPose, and RDK2::Geometry::Point3o< Numeric >::phi.

double RDK2::SensorData::LaserData::getLaserYaw (  )  [inline]

Returns the Yaw angle of the laser range scanner sensor Rotation around the bottom to front axis (x) is called yaw.

Definition at line 126 of file laserdata.h.

References RDK2::Geometry::Point3o< Numeric >::gamma, and laserPose.

int RDK2::SensorData::LaserData::getNearestIndex ( double  theta  )  const [inline]

Returns the index of the ray that is nearest to theta. Returns the index of the ray that is nearest to theta, that is, $ round(\frac{\theta - \theta_{min}}{d}) $ in which $ d = \frac{\theta_{max} - \theta_{min}}{n_{points} - 1} $.

Parameters:
theta the angle for which the index is computed.
Returns:
the index of the LaserPoint that is nearest to theta.
Warning:
the index can be outside the limits of the points vector.

Definition at line 137 of file laserdata.h.

References getRayWidth(), and minTheta.

Referenced by RDK2::SensorData::LaserDataTracker::update().

Here is the call graph for this function:

double RDK2::SensorData::LaserData::getRayWidth (  )  const [inline]

Returns the distance between two rays (supposed to be the same for each ray). Returns the distance between two rays (supposed to be the same for each ray), that is, $ \frac{\theta_{max} - \theta_{min}}{n_{points} - 1} $.

Returns:
the distance between two rays.

Definition at line 145 of file laserdata.h.

References maxTheta, minTheta, and points.

Referenced by getNearestIndex(), RDK2::SensorData::LaserDataTracker::update(), and updateThetas().

void RDK2::SensorData::LaserData::updateThetas (  ) 

Update the theta value of all laser points Update the theta value of all laser points, according to $ \theta_{min} $, $ \theta_{max} $ and the number of points.

Definition at line 52 of file laserdata.cpp.

References getRayWidth(), minTheta, and points.

Referenced by RDK2::SensorData::LaserDataTracker::update().

Here is the call graph for this function:

double RDK2::SensorData::LaserData::minRange (  )  const

Returns minimum range (values of 0 are ignored).

Definition at line 91 of file laserdata.cpp.

References RDK2::Geometry::min(), and points.

Here is the call graph for this function:

int RDK2::SensorData::LaserData::getMinAngle (  ) 

Definition at line 102 of file laserdata.cpp.

References points.

bool RDK2::SensorData::LaserData::raysEqualTo ( const LaserData ld  ) 

True if same rays.

Definition at line 65 of file laserdata.cpp.

References points.

int RDK2::SensorData::LaserData::numValidPoints (  )  const

Number of points with reading != 0.

Definition at line 58 of file laserdata.cpp.

References points.

bool RDK2::SensorData::LaserData::isInsideClearArea ( RDK2::Geometry::Point2d  world  )  const

Returns true if the point is in the clear area swept by the laser.

Definition at line 77 of file laserdata.cpp.

References RDK2::Geometry::Point2< Numeric >::abs(), RDK2::SensorData::BaseSensorData::estimatedPose, laserPose, maxTheta, minReading, minTheta, RDK2::Geometry::norm2PIX(), points, RDK2::Geometry::Point2< Numeric >::theta(), and RDK2::Geometry::Point2o< Numeric >::theta.

Here is the call graph for this function:

DMatrixD RDK2::SensorData::LaserData::getFisherForXY (  ) 

Returns the (unscaled) 2x2 Fisher's information matrix for (x,y).

These function need to know the orientation in space of the scan: for this it uses the "estimate" field; You need to multiply these matrices by $ \frac{1}{\sigma^2} $ to get the actual Fisher's matrix.

Definition at line 27 of file laserdata_fisher.cpp.

References RDK2::Geometry::DMatrix< X >::el(), RDK2::SensorData::BaseSensorData::estimatedPose, points, RDK2::Geometry::DMatrix< X >::setAll(), RDK2::Geometry::square(), and RDK2::Geometry::Point2o< Numeric >::theta.

Referenced by getFisher().

Here is the call graph for this function:

double RDK2::SensorData::LaserData::getFisherForTheta (  ) 

Returns the (unscaled) 1x1 Fisher's information matrix for theta.

Definition at line 52 of file laserdata_fisher.cpp.

References RDK2::SensorData::BaseSensorData::estimatedPose, points, RDK2::Geometry::square(), and RDK2::Geometry::Point2o< Numeric >::theta.

Referenced by getFisher().

Here is the call graph for this function:

DMatrixD RDK2::SensorData::LaserData::getFisher (  ) 

Returns the (unscaled) 3x3 Fisher's information matrix for (x,y,theta).

Definition at line 65 of file laserdata_fisher.cpp.

References RDK2::Geometry::DMatrix< X >::el(), RDK2::SensorData::BaseSensorData::estimatedPose, getFisherForTheta(), getFisherForXY(), points, RDK2::Geometry::DMatrix< X >::setAll(), and RDK2::Geometry::Point2o< Numeric >::theta.

Referenced by getCRB(), and getFisher().

Here is the call graph for this function:

RDK2::Geometry::DMatrixD RDK2::SensorData::LaserData::getFisher ( double  sigma  )  [inline]

Returns the information matrix properly scaled by sigma.

Definition at line 185 of file laserdata.h.

References getFisher().

Here is the call graph for this function:

RDK2::Geometry::DMatrixD RDK2::SensorData::LaserData::getCRB ( double  sigma  )  throw (RDK2::Geometry::DNotInvertibleMatrixException) [inline]

Trhows if Fisher's matrix is singular (under constrained situation).

Definition at line 190 of file laserdata.h.

References getFisher(), and RDK2::Geometry::DMatrix< X >::inv().

Here is the call graph for this function:

void RDK2::SensorData::LaserData::copy ( const LaserData l  ) 

Parser * RDK2::SensorData::LaserData::getParser (  )  const [virtual]

Reimplemented from RDK2::SensorData::BaseSensorData.

Definition at line 35 of file laserparser.cpp.

References laserParser.


Field Documentation

Position of laser relative to robot.

Definition at line 39 of file laserdata.h.

Referenced by copy(), getLaserPitch(), getLaserRoll(), getLaserYaw(), isInsideClearArea(), mm2m(), RDK2::SensorData::LaserParser::parse(), and setLaserRollPitchYaw().

Minimum and maximum sensor range. Points above and below are invalid.

Definition at line 42 of file laserdata.h.

Referenced by copy(), isInsideClearArea(), LaserData(), RDK2::RSensorData::RLaserData::loadFromLogLine(), mm2m(), and RDK2::SensorData::LaserParser::parse().

Roll angle of robot position.

Definition at line 48 of file laserdata.h.

Referenced by setLaserRollPitchYaw().

Pitch angle of robot position.

Definition at line 51 of file laserdata.h.

Referenced by setLaserRollPitchYaw().

Definition at line 53 of file laserdata.h.

Definition at line 205 of file laserdata.h.

Referenced by getParser().


The documentation for this struct was generated from the following files:

Generated on Tue Mar 3 15:06:49 2009 for OpenRDK by  doxygen 1.5.6