The MemoryTurnLimit Behavior
Maintained by: mikerb@mit.edu Get PDF
src: project-pavlab/bhvdocs/bhv_mem_turnlimit
1 The MemoryTurnLimit Behavior
1.1 Configuration Parameters
1.2 Calculation of the Heading History
1.3 Variables Published
1.4 The MemoryTurnLimit Objective Function
1 The MemoryTurnLimit Behavior
The objective of the Memory-Turn-Limit behavior is to avoid vehicle turns that may cross back on its own path and risk damage to the towed equipment. Its configuration is determined by the two parameters described below which combine to set a vehicle turn radius limit. However, it is not strictly described by a limited turn radius; it stores a time-stamped history of recent recorded headings and maintains a heading average, and forms its objective function on a range deviation from that average. This behavior merely expresses a preference for a particular heading. If other behaviors also have a heading preference, coordination/compromise will take place through the multi-objective optimization process. The following parameters are defined for this behavior:
1.1 Configuration Parameters [top]
Listing 1.1 - Configuration Parameters Common to All Behaviors.
activeflag: | A MOOS variable-value pair posted when the behavior is in the active state. [more]. |
condition: | Specifies a condition that must be met for the behavior to be running. [more]. |
duration: | Time in behavior will remain running before declaring completion. [more]. |
duration_idle_decay: | When true, duration clock is running even when in the idle state. [more]. |
duration_reset: | A variable-pair such as MY_RESET=true, that will trigger a duration reset. [more]. |
duration_status: | The name of a MOOS variable to which the vehicle duration status is published. [more]. |
endflag: | A MOOS variable-value pair posted when the behavior has completed. [more]. |
idleflag: | A MOOS variable-value pair posted when the behavior is in the idle state. [more]. |
inactiveflag: | A MOOS variable-value posted when the behavior is not in the active state. [more]. |
name: | The (unique) name of the behavior. [more]. |
nostarve: | Allows a behavior to assert a maximum staleness for a MOOS variable. [more]. |
perpetual: | If true allows the behavior to to run even after it has completed. [more]. |
post_mapping: | Re-direct behavior output normally to one MOOS variable to another instead. [more]. |
priority: | The priority weight of the behavior. [more]. |
pwt: | Same as priority. |
runflag: | A MOOS variable and a value posted when a behavior has met its conditions. [more]. |
spawnflag: | A MOOS variable and a value posted when a behavior is spawned. [more]. |
spawnxflag: | A MOOS variable and a value posted when a behavior is spawned. [more]. |
templating: | Turns a behavior into a template for spawning behaviors dynamically. [more]. |
updates: | A MOOS variable from which behavior parameter updates are read dynamically. [more]. |
Listing 1.2 - Configuration Parameters for the MemoryTurnLimit Behavior.
Parameter | Description |
memory_time: | The duration of time for which the heading history is maintained and heading average calculated. The default value is -1, indicating that the parameter is un-set. In this case the behavior will not produce an objective function. |
turn_range: | The range of heading valuesdeviating from the current heading average outside of which the behavior reflects sharp penalty in its objective function. The default value is -1, indicating that the parameter is un-set. In this case the behavior will not produce an objective function. |
Listing 1.3 - Example Configuration Block.
Behavior = BHV_MemoryTurnLimit { // General Behavior Parameters // --------------------------- name = mem_turn_limit // default pwt = 100 // default condition = MODE=TRANSITING // example condition = ARRAY=connected // example updates = MEM_TURN_UPDATES // example // Parameters specific to this behavior // ------------------------------------ memory_time = 60 // example (seconds) turn_range = 30 // example (degrees) }
1.2 Calculation of the Heading History [top]
The heading history is maintained locally in the behavior by storing the currently observed heading and keeping a queue of n recent headings within the memory_time threshold. The heading average calculation below handles the issue of angle wrap in a set of n headings where each heading is in the range [0,359].
where s and c are given by:
The vehicle turn radius r is not explicitly a parameter of the behavior, but is given by:
where v is the vehicle speed and u is the turn rate given by:
The same turn radius is possible with different pairs of values for turn_range and memory_time. However, larger values of turn_range allow sharper initial turns but temper the turn rate after the initial sharper turn has been achieved.
1.3 Variables Published [top]
The only variable published by this behavior is MEM_TURN_AVG which indicates the present heading average, rounded to the nearest integer.
1.4 The MemoryTurnLimit Objective Function [top]
A Rendering of the MemoryTurnLimit Objective Function
Figure 1.1: The MemoryTurnLimit objective function: The objective function produced by the MemoryTurnLimit behavior is defined over possible heading values. Depicted here is an objective function formed when the recent heading history is 225 degrees and the turn_range parameter is set to 30 degrees. The resulting objective function highly favors headings in the range of 190-240 degrees. One the right is a "birds-eye" view of the function, and on the right the function is viewed at an angle to appreciate the 3D quality of the function. Higher (red) values correspond to higher utility.
Document Maintained by: mikerb@mit.edu
Page built from LaTeX source using texwiki, developed at MIT. Errata to issues@moos-ivp.org. Get PDF