smp::cost_evaluator_time< typeparams > Class Template Reference

The cost evaluator class based on the trajectory execution time. More...

#include <time.h>

Inheritance diagram for smp::cost_evaluator_time< typeparams >:
smp::cost_evaluator_base< typeparams >

List of all members.

Public Member Functions

int ce_update_vertex_cost (vertex_t *vertex_in)
 Update function for vertex cost modification.
int ce_update_edge_cost (edge_t *edge_in)
 Update function for edge cost modification.
double evaluate_cost_trajectory (state_t *state_initial_in, trajectory_t *trajectory_in, state_t *state_final_in=0)
 Evaluates the cost of a trajectory.

Detailed Description

template<class typeparams>
class smp::cost_evaluator_time< typeparams >

The cost evaluator class based on the trajectory execution time.

This class computes the cost of a trajectory according to the time it takes to execute that particular trajectory.


Member Function Documentation

template<class typeparams >
int smp::cost_evaluator_time< typeparams >::ce_update_edge_cost ( edge_t edge_in) [virtual]

Update function for edge cost modification.

This function is called by the planner whenever the cost associated with an edge is changed by the optimizing (incremental) planning algorithm.

Parameters:
edge_inA pointer to the edge with modified cost.
Returns:
Return 1 if success, a non-positive value to indiacate error.

Implements smp::cost_evaluator_base< typeparams >.

template<class typeparams >
int smp::cost_evaluator_time< typeparams >::ce_update_vertex_cost ( vertex_t vertex_in) [virtual]

Update function for vertex cost modification.

This function is called by the planner whenever a the cost associated with a vertex is changed by the optimizing (incremental) planning algorithm.

Parameters:
vertex_inA pointer to the vertex with modified cost.
Returns:
Return 1 if success, a non-positive value to indiacate error.

Implements smp::cost_evaluator_base< typeparams >.

template<class typeparams >
double smp::cost_evaluator_time< typeparams >::evaluate_cost_trajectory ( state_t *  state_initial_in,
trajectory_t trajectory_in,
state_t *  state_final_in = 0 
) [virtual]

Evaluates the cost of a trajectory.

This function returns the cost of a given trajectory that starts from state_initial_in and reaches state_final_in. Sometimes the final state is embedded in the trajectory itself, in which case state_final_in argument can be set to NULL.

Parameters:
state_initial_inInitial state that the trajectory starts from
trajectory_inTrajectory
state_final_inFinal state that the trajectory reaches
Returns:
Returns 1 for success, and a non-positive number to indicate error.

Implements smp::cost_evaluator_base< typeparams >.


The documentation for this class was generated from the following file: