ChallengeSymbols Class Reference

#include <ChallengeSymbols.h>

Inheritance diagram for ChallengeSymbols:

Xabsl2FunctionProvider BehaviorControlInterfaces List of all members.

Public Member Functions

 ChallengeSymbols (const BehaviorControlInterfaces &interfaces)
void registerSymbols (Xabsl2Engine &engine)
void update ()
void challenge2Swap (Pose2D *p, int i, int j)
void challenge2ShortestPermutation (Pose2D *p, int n, double &minLength)
void challenge2ShortestPath ()
void challenge2OptimalRotation (Pose2D &pose)
double challenge2TargetPositionX ()
double challenge2TargetPositionY ()
double challenge2TargetPositionRotation ()

Private Attributes

Pose2D targetPositions [5]
double index
double lastIndex

Detailed Description

The Xabsl2 symbols that are defined in "challenge-symbols.xml"

Author:
Thomas Röfer

Definition at line 20 of file ChallengeSymbols.h.


Constructor & Destructor Documentation

ChallengeSymbols::ChallengeSymbols ( const BehaviorControlInterfaces interfaces  ) 

Definition at line 12 of file ChallengeSymbols.cpp.

References challenge2OptimalRotation(), InFile::exists(), getPlayer(), lastIndex, Player::red, targetPositions, Pose2D::translation, and Vector2< V >::y.


Member Function Documentation

void ChallengeSymbols::challenge2OptimalRotation ( Pose2D pose  ) 

Definition at line 79 of file ChallengeSymbols.cpp.

References pi, pi_2, Pose2D::rotation, Pose2D::translation, Vector2< V >::x, and Vector2< V >::y.

Referenced by ChallengeSymbols().

void ChallengeSymbols::challenge2ShortestPath (  ) 

Definition at line 98 of file ChallengeSymbols.cpp.

References challenge2ShortestPermutation(), index, lastIndex, BehaviorControlInterfaces::robotPose, and targetPositions.

Referenced by challenge2TargetPositionRotation(), challenge2TargetPositionX(), and challenge2TargetPositionY().

void ChallengeSymbols::challenge2ShortestPermutation ( Pose2D p,
int  n,
double &  minLength 
)

Definition at line 112 of file ChallengeSymbols.cpp.

References abs(), challenge2Swap(), and targetPositions.

Referenced by challenge2ShortestPath().

void ChallengeSymbols::challenge2Swap ( Pose2D p,
int  i,
int  j 
)

Definition at line 134 of file ChallengeSymbols.cpp.

Referenced by challenge2ShortestPermutation().

double ChallengeSymbols::challenge2TargetPositionRotation (  ) 

Returns rotation of target position with current index.

Definition at line 73 of file ChallengeSymbols.cpp.

References challenge2ShortestPath(), index, targetPositions, and toDegrees().

Referenced by registerSymbols().

double ChallengeSymbols::challenge2TargetPositionX (  ) 

Returns x coordinate of target position with current index.

Definition at line 61 of file ChallengeSymbols.cpp.

References challenge2ShortestPath(), index, int(), targetPositions, Pose2D::translation, and Vector2< V >::x.

Referenced by registerSymbols().

double ChallengeSymbols::challenge2TargetPositionY (  ) 

Returns y coordinate of target position with current index.

Definition at line 67 of file ChallengeSymbols.cpp.

References challenge2ShortestPath(), index, int(), targetPositions, Pose2D::translation, and Vector2< V >::y.

Referenced by registerSymbols().

void ChallengeSymbols::registerSymbols ( Xabsl2Engine engine  ) 

registers the symbols at an engine

Definition at line 35 of file ChallengeSymbols.cpp.

References challenge2TargetPositionRotation(), challenge2TargetPositionX(), challenge2TargetPositionY(), index, Xabsl2Symbols::registerDecimalInputFunction(), and Xabsl2Symbols::registerDecimalInputFunctionParameter().

Referenced by GT2004BehaviorControl::registerSymbolsAndBasicBehaviors().

void ChallengeSymbols::update (  ) 

updates the symbols

Definition at line 56 of file ChallengeSymbols.cpp.


Member Data Documentation

double ChallengeSymbols::index [private]

the index for targetPosition? functions

Definition at line 43 of file ChallengeSymbols.h.

Referenced by challenge2ShortestPath(), challenge2TargetPositionRotation(), challenge2TargetPositionX(), challenge2TargetPositionY(), and registerSymbols().

double ChallengeSymbols::lastIndex [private]

The index of the previous call

Definition at line 43 of file ChallengeSymbols.h.

Referenced by challenge2ShortestPath(), and ChallengeSymbols().

Pose2D ChallengeSymbols::targetPositions[5] [private]

The 5 target positions for the localization challenge

Definition at line 42 of file ChallengeSymbols.h.

Referenced by challenge2ShortestPath(), challenge2ShortestPermutation(), challenge2TargetPositionRotation(), challenge2TargetPositionX(), challenge2TargetPositionY(), and ChallengeSymbols().


The documentation for this class was generated from the following files:
Generated on Thu Dec 7 01:21:17 2006 for DT2005.panorama by  doxygen 1.4.7