The present application claims priority to Korean Patent Application No. 10-2018-0151119, filed Nov. 29, 2018, the entire contents of which is incorporated herein for all purposes by this reference.
The present invention relates to an online bidirectional trajectory planning method in a state-time space, a recording medium storing a program for employing the same, and a computer program stored in a medium for employing the same. More particularly, the present invention relates to an online bidirectional trajectory planning method in a state-time space, a recording medium storing a program for employing the same, and a computer program stored in a medium for employing the same, wherein autonomous driving is available while over-run or vibration does not occur in a robot by planning a bidirectional trajectory using a forward trajectory and a backward trajectory.
Autonomous driving robots refer to robots that search for their own surroundings and detect obstacles while searching for the optimal trajectory to a destination by using wheels or legs thereof.
Trajectory planning and obstacle avoidance are major techniques in autonomous driving of moving robots. Robots have to generate a trajectory to a destination and move to the destination without colliding with the surrounding obstacles. A good trajectory means the shortest trajectory where a movement trajectory to a destination is minimum, or a safe trajectory where collisions with surrounding obstacles are minimum.
Generally, safe trajectories are more important in the application field of robot. However, the optimal trajectory may be the shortest while being the safest.
Generally, as a method of ensuring a safe trajectory, there is used a method of determining a direction where an empty space is large by using obstacle detecting sensors installed in the robot (devices measuring a distance with nearby obstacles, such as laser or ultrasonic waves, etc.) and determining a movement direction of robot by taking into account a direction to a destination. Weighting factors for a direction to an empty space and for a direction to a destination are determined experimentally. When a large weighting factor is given to an empty space, collision with surrounding obstacle may be minimized, but a long trajectory may be obtained, and in extreme cases, the robot may not get to the destination. On the contrary, when a large weighting factor is given to a destination, safety is degraded.
A fundamental driving performance of an autonomous driving robot is an intelligent navigation capability of moving along an optimal trajectory to a destination without collisions. For the intelligent navigation capability, a trajectory planning technique and a location recognition technique are required.
Herein, the trajectory planning technique may be classified into global trajectory planning and local trajectory planning.
First, global trajectory planning means searching for an optimal trajectory to a target point by using a given environmental map, and local trajectory planning means avoiding obstacles in real time under a dynamic environment.
In addition, the location recognition technique is a location determining technique where a current location of a robot that is navigating is determined on a map.
As a conventional example of the above global trajectory planning method, typically, for example, a “Dijkstra algorithm” is known which is disclosed in a note on two problems in connexion with graphs (E. W. Dijkstra, Numerische Mathematik, Volume 1, Number 1, 269-271, 1959)”.
In detail, the Dijkstra algorithm is provided as initial trajectory planning and is widely used in various fields up to now. However, a lot of calculation time is required since the algorithm performs searching in all the spaces.
In addition, as another conventional example of the above global trajectory planning method, for example, an A* algorithm is provided that is disclosed in “A Formal Basis for the Heuristic Determination of Minimum Cost Paths in Graphs_A star (PETER E. HART, VOL. ssc-4, NO 2, 1968)”.
In detail, the A* algorithm is a complement to the Dijkstra algorithm, and a searching time is faster than the Dijkstra algorithm by adding an evaluating function on the basis of depth first search and breadth first search. However, real time calculation for the same is difficult.
In order to enable real time calculation, an incremental planning method is used where a trajectory is planned by designating a waypoint through which a robot passes.
An incremental planning method enables fast calculation, but an over-run phenomenon occurs where a turning trajectory becomes large when the robot turns on the target waypoint and then turns toward the next target waypoint as a distance between waypoints is short or an angle between waypoints is small.
In Korean Patent No. 10-1079197, a method of tracking a trajectory of an autonomous driving device is disclosed.
Accordingly, the present invention has been made keeping in mind the above problems occurring in the related art, and an objective of the present invention is to provide an online bidirectional trajectory planning method in a state-time space, a recording medium storing a program for employing the same, and a computer program stored in a medium for employing the same, wherein autonomous driving is available while over-run or vibration does not occur in a robot by planning a bidirectional trajectory using a forward trajectory and a backward trajectory.
Technical tasks obtainable from the present invention are non-limited the above-mentioned technical task, and other unmentioned technical tasks can be clearly understood from the following description by those having ordinary skill in the technical field to which the present invention pertains.
In order to achieve the above object, according to one aspect of the present invention, there is provided an online bidirectional trajectory planning method in a state-time space, wherein the method is employed in a program form executed by an arithmetic processing means including a computer, the method including: planning a bidirectional trajectory on the basis of a forward trajectory calculation in a state-time space which is from a current location of a robot or a last calculation point of a forward trajectory to a current target waypoint or a last calculation point of a backward trajectory by taking into account a state value (s) and a time value, and a backward trajectory calculation in the state-time space which is from the current target waypoint or a last calculation point of the backward trajectory to the current location of the robot or the last calculation point of the forward trajectory, wherein the forward trajectory and the backward trajectory are incrementally planned, wherein a state value (sn) (n represents a time index, and is a natural number)) in the state-time space, which is used when planning the forward trajectory and the backward trajectory, includes a configuration value of a location and a bearing (heading angle), and includes any one or a plurality of pieces of information selected from a steering angle, a velocity, and an acceleration.
In addition, in the forward trajectory calculation and the backward trajectory calculation, a cost-to-go function (H) is decomposited, and a priority r (r is natural number) is assigned to each decomposited cost-to-go function (Hr), and the decomposited cost-to-go functions (Hr) are applied according a preset reference (an r* value may be set or calculated) to a near-optimal timed state function (N) which calculates a trajectory such that a value of summing the decomposited cost-to-go functions (Hr) become minimum, wherein a state value (sn+m) from a point where a state value (sn) is given to a target point is calculated where the calculation is performed for a number (m) of steps on the basis of the state value (sn) given in an n step, a state value (sto) at the target point, and the number (m) of steps to be calculated.
In addition, in the forward trajectory calculation and the backward trajectory calculation, a cost-to-go function (H) is decomposited, and a priority r (r is a natural number) is assigned to each decomposited cost-to-go function (Hr), and the decomposited cost-to-go functions (Hr) are sequentially applied according to a priority (an r* value may be set or calculated) to a near-optimal timed state function (N) which calculates a trajectory such that each value of the decomposited cost functions (H) become minimum, wherein a state value (sn+m) from a point where a state value (sn) is given to a target point is calculated where the calculation is performed for a number (m) of steps on the basis of the state value (sn) given in an n step, a state value (sto) at the target point, and the number (m) of steps to be calculated.
In addition, in the forward trajectory calculation, when a safe timed configuration region Qnsafe (m) exists which is a space within a configuration region where collisions with static obstacles and dynamic obstacles are not present, the forward trajectory is calculated on the basis of a configuration value (qn) of the robot a time index (n) and the safe timed configuration region Qnsafe (m) at the time index (n), and in the backward trajectory calculation, when the safe timed configuration region exists, the backward trajectory is calculated on the basis of the configuration value (qn) of the robot at the time index (n) and the safe timed configuration region Qnsafe (m).
In addition, the planning of the bidirectional trajectory includes: S20 of setting a robot state in a current target waypoint; S30 of calculating the backward trajectory; S50 of calculating the forward trajectory; and S60 of generating a command for controlling the robot according to the bidirectional trajectory when the S30 of calculating the backward trajectory and the S50 of calculating the forward trajectory are repeated a preset number of times.
In addition, the online bidirectional trajectory planning method in a state-time space may further include: calculating a connection trajectory connecting the forward trajectory and the backward trajectory, wherein the bidirectional trajectory is planned by incrementally planning the forward trajectory and the backward trajectory after the calculating of the connection trajectory.
In addition, the planning of the bidirectional trajectory includes: S20 of setting a robot state in a current target waypoint; S30 of calculating the backward trajectory; S40 of determining whether or not the connection trajectory exists where the current location of the robot or the last calculation point of the forward trajectory is connected to the current target waypoint or the last calculation point of the backward trajectory; S50 of calculating the forward trajectory when the connection trajectory does not exist; and S60 of generating a command for controlling the robot according to the bidirectional trajectory when the S50 of calculating the forward trajectory is repeated a preset number of times.
In addition, in the S40 of determining whether or not the connection trajectory exists, when the connection trajectory exists, a forward time index is set for the connection trajectory and the backward trajectory, whether or not an inevitable collision state is present in the connection trajectory and the backward trajectory is determined, and if not, a time parameter of the forward trajectory, a time parameter of the backward trajectory, and a time parameter of the forward trajectory passing through a subsequent waypoint are changed by calculation.
In addition, according to an embodiment of the present invention, there is provided a computer-readable recording medium storing a program for employing an online bidirectional trajectory planning method in a state-time space.
In addition, according to an embodiment of the present invention, there is provided a program stored in a computer-readable recording medium, wherein the program is for employing an online bidirectional trajectory planning method in a state-time space.
According to an online bidirectional trajectory planning method in a state-time space, a recording medium storing a program for employing the same, and a computer program stored in a medium for employing the same according to an embodiment of the present invention, over-run or vibration of the robot can be minimized and at the same time trajectory calculation in real time can be available by planning a bidirectional trajectory using a forward trajectory and a backward trajectory.
In addition, an amount of calculation required for trajectory calculation can be reduced by applying a function decomposition-based cost minimizing algorithm that decomposes a cost-to-go function so as to reduce an amount of calculation.
In addition, an amount of calculation required for trajectory calculation can be reduced by calculating a trajectory on the basis of a safe timed configuration region Qnsafe (m).
In addition, a trajectory that smoothly passes through a target waypoint can be generated by calculating a forward trajectory prior to calculating a backward trajectory when setting a waypoint, calculating the backward trajectory, calculating the forward trajectory, and generating a robot control command.
In addition, a forward trajectory and a backward trajectory can be connected while the robot does not receive an over load by using a connection trajectory connecting the forward trajectory and the backward trajectory.
In addition, a required amount of calculation for trajectory can be reduced by determining a connection trajectory between calculating a backward trajectory and calculating a forward trajectory.
In addition, when a connection trajectory exists, a forward time index is set for the connection trajectory and a backward trajectory, and thus a secure trajectory can be generated by determining whether or not collision with dynamic obstacles is present in a connection trajectory and a backward trajectory, which were not considered before when performing calculation.
The above and other objects, features and other advantages of the present invention will be more clearly understood from the following detailed description when taken in conjunction with the accompanying drawings, in which:
The present invention can be modified in various manners and have various forms. Therefore, specific embodiments will be described in detail with reference to the accompanying drawings. However, the present invention is not limited to the specific embodiments, but may include all modifications, equivalents and substitutions within the scope of the present invention.
It will be understood that when an element is referred to as being “connected” or “coupled” to another element, it can be directly connected or coupled to the other element or intervening elements may be present.
In contrast, when an element is referred to as being “directly connected” or “directly coupled” to another element, there are no intervening elements present.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used herein, the singular forms “a”, “an”, and “the” are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms “comprises”, “comprising”, “includes”, and/or “including” when used herein, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. It will be further understood that terms used herein should be interpreted as having a meaning that is consistent with their meaning in the context of this specification and the relevant art and will not be interpreted in an idealized or overly formal sense unless expressly so defined herein.
Herein, with reference to the accompanying drawings, embodiments of the present invention will be described in detail. Prior to the description, it should be understood that the terms used in the specification and the appended claims should not be construed as limited to general and dictionary meanings, but interpreted based on the meanings and concepts corresponding to technical aspects of the present disclosure on the basis of the principle that the inventor is allowed to define terms appropriately for the best explanation. In addition, technical terms and scientific terms used in the present specification have the general meaning understood by those skilled in the art to which the present invention pertains unless otherwise defined, and a description for the known function and configuration obscuring the present invention will be omitted in the following description and the accompanying drawings. The drawings to be provided below are provided by way of example so that the idea of the present invention can be sufficiently delivered to a person skilled in the art to which the present invention pertains. Therefore, the present invention is not limited to the drawings provided below but may be modified in many different forms. In addition, like reference numerals designate like elements throughout the specification. In the drawings, same reference numerals denote same components throughout the disclosure.
Prior to the description, terms used in the present specification (and claims) will be briefly described.
A “state-time space” refers to a set of state values taking into account of time.
A “state value” refers to a configuration value including a location and a bearing (heading angle), and includes any one or a plurality of pieces of information selected from a steering angle, a velocity (linear velocity, angular velocity), and an acceleration. For example, the same may be (x coordinate, y coordinate, bearing, velocity, acceleration), etc.
A “timed configuration region” means a set of configuration values taking into account time.
A “configuration value” refers to a value including a location, and a bearing (heading angle). For example, the same may be (x coordinate, y coordinate, bearing), etc.
A “waypoint” refers to a designated location trough which a robot passes when calculating a driving trajectory.
For the description, various parameters and terms are designated and described. The variables and terms are as below.
A state value of a current location of the robot is represented as “sk”.
A state value at a step f calculated in a forward trajectory from a current location of the robot is represented as “sf”.
A state value of the robot when the robot arrives at a current target waypoint is represented as “gw” A state value calculated for a step b in a backward trajectory from the current target waypoint is represented as “s−b”.
A time index representing to which step corresponds the calculation is represented as “n”.
A time interval given for calculating one step is represented as “T”.
A time at a time index n is represented as “t” (t=nT).
A state value of the robot is represented as “s” (lowercase s).
A state space that is a set of state values of the robot is represented as “S” (capital letter S).
A timed state value that is a state value at a time step n is represented as sn (lowercase s).
A state-time space is represented as “Sn” (snϵSn).
A configuration value of the robot is represented as “q” (lowercase q).
A configuration region that is a set of configuration values of the robot is represented as “Q” (capital letter Q).
A timed configuration value that is a configuration value at a time step n is represented as qn(lowercase q).
A timed configuration region is represented as “Qn” (qnϵQn).
A configuration region where collision with static obstacles exists is represented as Qenv.
A free static configuration region where collision with static obstacles does not exist is represented as Qfree (Qfree=Q−Qenv).
A configuration region where collision with dynamic obstacle exists at a time index n is represented as Qnobs.
A free dynamic configuration region where collision with static obstacles and dynamic obstacles is not present is represented as Qnfree (Qnfree=Qfree−Qnobs).
A state where collision is inevitable is referred to as an “inevitable state”.
Fundamental parameters and terms are summarized, but not all of the parameters and terms necessary for the description are listed. Parameters and terms that are used in addition to the parameters and terms defined above will be described later.
Hereinafter, in the description, description will be made assuming that the robot moves from a current state point corresponding to a state value sk to a target point (current target waypoint) corresponding to a state value gw.
In an online bidirectional trajectory planning method in a state-time space according to an embodiment of the present invention, for an online bidirectional trajectory planning method in a state-time space, wherein the method is employed in a program form executed by an arithmetic processing means including a computer, a bidirectional trajectory is planned where a forward trajectory and a backward trajectory are incrementally planed (calculated). Herein, a state value sn (n represents time index, and is a natural number)) in a state-time space which is used for a planning forward trajectory and a backward trajectory includes a configuration value of a location and a bearing (heading angle), and includes any one or a plurality of pieces of information selected from a steering angle, a velocity (linear velocity, angular velocity), and acceleration.
In forward trajectory calculation, a forward trajectory in a state-time space is calculated from a current location of a robot or a last calculation point of a forward trajectory to a current target waypoint or a last calculation point of a backward trajectory by taking into account a state value s and a time value.
Herein, the time value is a value through which a future time from the current time is confirmed. For the same, a time index n may be used, but various methods may be used when an actual progress time can be confirmed such as multiplying a calculation period that calculates one step with a time index n (calculation period*time index n), etc.
In the forward trajectory calculation, a forward trajectory in a state-time space is calculated from an initial current location of the robot to a current target waypoint. Subsequently, when a forward trajectory and a backward trajectory are calculated, a forward trajectory in a state-time space may be calculated from a last calculation point of the forward trajectory toward a last calculation point of the backward trajectory.
In backward trajectory calculation, a backward trajectory in a state-time space is calculated from a current target waypoint or a last calculation point of a backward trajectory toward a current location of the robot or a last calculation point of a forward trajectory.
In the backward trajectory calculation, a backward trajectory in a state-time space may be calculated from an initial current target waypoint to a current location of the robot. Subsequently, when a forward trajectory and a backward trajectory are calculated, a forward trajectory in a state-time space may be calculated from a last calculation point of the backward trajectory to a last calculation point of the forward trajectory.
In other words, the forward trajectory calculation and the backward trajectory calculation are planned to head the opposite last calculation point.
Planning a backward trajectory allows the robot to pass more smoothly when the robot passes the target waypoint, and to reduce an over-run phenomenon where a turning trajectory becomes large when the robot turns on the target waypoint and then turns toward the next target waypoint as a distance between waypoints is short or an angle between waypoints is small.
In an online bidirectional trajectory planning method in state-time space according to an embodiment of the present invention, in the forward trajectory calculation and the backward trajectory calculation, a cost-to-go function H is decomposited, and a priority r (r is a natural number) is assigned to the decomposited cost-to-go function Hr.
The decomposited cost-to-go function is applied to a near-optimal timed state function N according to a preset reference which calculates a trajectory where a value of summing the decomposited cost-to-go function Hr becomes minimum (a r* value may be set or calculated).
Herein, a state value sn+m in a step where the number m of steps to be calculated is progressed from the given point of the state value sn toward the target point sto is calculated on the basis of a given state value sn in an n (n is natural number) step, a state value sto at a target point, and a number m of steps to be calculated.
Herein, a weighting factor is assigned to each decomposited cost function Hr, and a near-optimal timed state function N may be applied so as to calculate a trajectory so that the sum of values obtained by respectively multiplying the weight and decomposited cost functions Hr becomes minimum.
Alternatively, in an online bidirectional trajectory planning method in a state-time space according to an embodiment of the present invention, in the forward trajectory calculation and the backward trajectory calculation, a cost-to-go function H is decomposited, and a priority r (r is natural number) is assigned to the decomposited cost-to-go function Hr.
The decomposited cost-to-go functions Hr are sequentially applied to a near-optimal timed state function N according to the priority (an r* value may be set or calculated) which calculates a trajectory where each value of the decomposited cost functions Hr becomes minimum.
Herein, a state value sn+m in a step where the number m of steps to be calculated is progressed from the given point of the state value sn toward the target point sto is calculated on the basis of a state value sn given in an n step, a state value sto at a target point and a number m of steps to be calculated.
When planning the state value sn+m including the given state value sn, a cost-to-go from the state value sn+m to a point corresponding to the state value sto is calculated to be minimum.
In other words, the forward trajectory calculation and the backward trajectory calculation may be defined as below.
Herein, sn+m is a state value at a time n+m, H is a cost-to-go function, s is a given state value, sto is a state value at a target point, and m is a number of steps to be calculated.
When a cost-to-go function H is used, long time is required for calculation, and thus applying in real time to trajectory calculation is difficult.
An input value un for the robot may be obtained as below.
Herein, Hinput is a given cost cost-to-go function about input for the least effort.
The available input is always present since planning is performed for sn+m within a safe region that is bounded by the available input space of the available robot.
When the cost-to-go function for minimizing the cost-to-go is too complex to calculate a trajectory in real time, a function decomposition-based optimization method may be used.
A function decomposition-based optimization method decomposes a function into simple parts, and minimizes a dominant part first. It is assumed that H is configured with R parts as below.
Herein Hrs are arranged in order of dominance. In other words, Hr with smaller r is more dominant. When minimizing is performed sequentially one by one from H1 to HR, an available safe region becomes smaller. The decomposited cost-to-go function Hr is minimized by increasing the r value until a single state value is induced.
A safe-timed state space Ŝnr(m) that minimizes r parts from H1 to Hr may be defined as below.
A safe-timed state space Ŝno(m) calculated by using a cost-to-go function that is not decomposited is identical to a safe-timed state space Snsafe(m).
An r value from which one state value is induced is referred to as r*, and minimizing is performed for the decomposited cost-to-go function until r* is obtained. Herein, a usable safe-timed state space is reduced to a single state as below.
{sn+m}=Ŝnr*(m)
Herein,
r*=min{rϵ{1,2, . . . ,R}∥Ŝnr(m)|=1}
Even though the timed state value obtained from function decomposition-based minimization does not minimize H, the result is close to minimum as dominant parts are minimized.
In addition, real time execution is available, and calculation is efficient.
Accordingly, when a near-optimal timed state function N is applied, forward trajectory calculation and backward trajectory calculation may be performed as below.
s
n+m
=N(sn,sto,m)
Herein, sn+m is a state value in an n+m step, N is a near-optimal timed state value calculation function, sn is a given state value in an n step, and sto is a state value at a target point, and m is a number of steps to be calculated.
In case of an omnidirectional movable robot, for example, the near-optimal timed state function N may be calculated by using the equation below.
Herein, H1 is a velocity independent cost-to-go function, H2 is a moving direction part cost-to-go function, and H3 is a velocity magnitude part cost-to-go function.
In order to induce the robot to move toward the target fast and pass through waypoints effectively, a cost-to-go function H(sfrom, sto) is configured with three parts, and D is a predefined threshold distance.
Each location in a reachable region is matched 1:1 with an admissible velocity space, and thus each timed state is determined on the basis of the velocity-independent cost-to-go function H1.
The moving direction part cost-to-go function H2 and the velocity magnitude part cost-to-go function H3 are used for setting a state of a current target waypoint.
On the basis of H1, each timed configuration is determined to be the closest one to the target.
H2 and H3 are designed for setting a state of the current target waypoint.
A velocity at the current target waypoint is determined by taking account into a robot location, a location of a target waypoint, and a location of a subsequent waypoint.
A direction is determined as an average direction of two vectors which are from a robot location to a location of a target waypoint, and from a location of a waypoint to a location of a subsequent waypoint.
In addition, a magnitude of a velocity at a target waypoint is determined according to an interior angle of a trajectory at the target waypoint.
When the angle is large, the velocity becomes fast, or vice versa.
When an Euclidean distance between a robot location and a location of a target waypoint or between a location of the target waypoint and a location of a subsequent waypoint is smaller than D, a magnitude of a velocity of the current target waypoint is set proportional to the distance in order to not oscillate near the waypoint.
In case of a robot moving through wheels, for example, the near-optimal timed state function N may be calculated by using the equation below.
Herein, H1 is a velocity-independent cost-to-go function, H2 is a moving direction pat cost-to-go function, and H3 is a velocity magnitude part cost-to-go function.
As the example of the omnidirectional movable robot, each timed state is determined on the basis of the velocity-independent cost-to-go function H1.
In order to take into account both of a location close to a target location and a direction to the target location, H1 is configured with two parts with a predefined weighting factor α.
The moving direction pat cost-to-go function H2 and the velocity magnitude part cost-to-go function H3 are used for setting a linear and angular velocity of a current target waypoint similar to the case of the omnidirectional movable robot.
In an online bidirectional trajectory planning method in a state-time space according to an embodiment of the present invention, for forward trajectory calculation, when a safe timed configuration region Qnsafe (m) exists which is a space within a configuration region where collisions with static obstacles and dynamic obstacles are not present, a forward trajectory is calculated on the basis of a configuration value qn of the robot at a time index n and a safe timed configuration region Qnsafe (m) at a time index n.
In the backward trajectory calculation, when the safe timed configuration region exists, a backward trajectory is calculated on the basis of a configuration value qn of the robot at a time index n and the safe timed configuration region Qnsafe (m).
When a set of configuration values where collision with static environmental obstacles such as wall exists is referred to as Qenv and as “environmental obstacle configuration region” (Qenv⊂Q), difference of sets obtained by subtracting the environmental obstacle configuration region Qenv from the configuration region Q may be referred to as a “free static configuration region” Qfree.
The robot may predict a trajectory of each dynamic obstacle such as people and other robots on the basis of a tracking algorithm using sensor data.
Accordingly, when a set of configuration values predicted to collide with any dynamic obstacles such as people at a time index n is referred to as Qnobs and as a dynamic obstacle space “(Qnobs⊂Q), difference of sets obtained by subtracting the dynamic obstacle space Qnobs from the free static configuration region Qfree may be referred to as a “free dynamic configuration region” Qnfree.
In other words, the free dynamic configuration region Qnfree at a time index n may be a safe region where the robot does not collide with obstacles including dynamic obstacles and static obstacles at a time index n.
A motion of a robot system with an input value un(unϵU) in an input space U at a time index n may be defined as below.
s
n+1
=f(sn,un)
Herein, f is a motion model function of a robot.
A state space S of the robot and an input space U of the robot are bounded, and thus robot motion is constrained which is referred to a motion constraint.
Environment detectors (sensors) detect and track obstacles on the basis of a sensory system using sensors, such as vision sensors or laser range finders (LRF), etc., and classify the same into static obstacles (environmental obstacles) and dynamic obstacles (non-environmental obstacles) to obtain Qenv and Qnobs.
Global trajectory planner (global path planner) planning a trajectory by assigning a waypoint plans a sequence of waypoints and a target inside a free static configuration region Qfree.
At every time instant t=kT, k=0, 1, . . . , an algorithm plans a trajectory by using a reference input k.
By the above input, the robot passes through waypoints sequentially and arrive the target without any collision by using both of Qenv and Qnobs.
When a timed state value sn is given, a reachable state-time region at a time index n+m may be defined. Herein, a reachable timed configuration region may be also defined.
In order to plan a trajectory in real time, it is preferable to reduce an amount of calculation by approximating the reachable state-time region or timed configuration region.
It may be difficult to perform real time calculation when the reachable state-time region or timed configuration region is calculated accurately and used.
In order to simplify the reachable region, the robot may be controlled for m time steps by using a uniform robot input value.
A reachable state-time region that is reachable by the uniform robot input value may be defined as below.
S
n(m)={sn+mϵS|∀unϵU,sn+m=g(sn,un,m)}
Herein, g is an approximated motion model function of a robot.
Herein, a reachable timed configuration region that is reachable by the uniform input value of the robot may be defined as below.
Sn (m) and Qn (m) do not cover the whole actual reachable region, but calculation load is very small rather than calculating the whole actual reachable region, and thus the same are useful for trajectory planning.
When a state value sn is given, a safe-timed state space Snsafe (m) at a time index n+m may be defined as below.
S
n
safe(m)=Sn(m)∩Sn+mfree,(n>0,m>0)
In addition, when a state value sn is given, a safe timed configuration region Qnsafe (m) at a time n+m may be defined as below.
Q
n
safe(m)=Qn(m)∩Qn+mfree,(n>0,m>0)
Qnsafe (m) is planned within Snsafe (m), but using Qnsafe (m) may be enough by checking predicted collision and by check whether or not an available safe region exists.
When calculating the safe timed configuration region Qnsafe (m) of a backward trajectory at a current target waypoint, Qn+mfree is replaced with Qfree.
This is because, an actual time of Qn+mfree is not given, and thus data of dynamic obstacles is not obtained.
As shown in
In S20 of setting a waypoint, a robot state at a current target waypoint is set.
The current target waypoint is a waypoint where a forward trajectory is heading to pass through.
The S20 of setting a waypoint is setting a robot state when the robot passes the current target waypoint. It is preferable to set the robot state when the robot passes the current target waypoint by taking into account of a robot location, a location of a target waypoint, and a location of a subsequent waypoint.
Accordingly, in the S20 of setting a waypoint is setting a waypoint where the forward trajectory passes through the current target waypoint, a state value gw of the current target waypoint is set as an equation below so as to minimize a cost-to-go.
Herein, gw represents a state value of a current target waypoint, {tilde over (g)}w+1 represents a state value of a subsequent target waypoint while setting gw, Gw represents a state range of the current target waypoint, Gw+1 represents a state range of the subsequent target waypoint, H(a, b) represents a cost-to-go function from a to b, Sf represents a current location of a robot, grepresents the current target waypoint, and {tilde over (g)} represents a subsequent waypoint of the current target waypoint.
In S30 of calculating a backward trajectory, a backward trajectory is calculated.
The S30 of calculating a backward trajectory plans a trajectory from the current target waypoint to a current location of the robot. Herein, when the forward trajectory is calculated, a backward trajectory to a last calculation point of the forward trajectory may be calculated.
A parameter B of the first conditional statement shown in
The S50 of calculating of a forward trajectory calculates a forward trajectory.
In the S50 of calculating a forward trajectory, a trajectory is planned to a target waypoint from the current location of the robot. Herein, when the backward trajectory is calculated, a forward trajectory may be calculated to a last calculation point of the backward trajectory.
A parameter F of the second conditional statement shown in
The S30 of calculating a backward trajectory and the S50 of calculating a forward trajectory may be performed in reverse order. It is preferable to perform the S30 of calculating a backward trajectory first so as to generate a trajectory to smoothly pass through a target waypoint.
The S30 of calculating a backward trajectory and the S50 of calculating a forward trajectory may be alternately repeated. Various methods of repeating one of the S30 of calculating a backward trajectory and the S50 of calculating a forward trajectory may be repeated a preset of times first, and then repeating the other one may be used to repeat the S30 of calculating a backward trajectory and the S50 of calculating a forward trajectory.
As a result, the S30 of calculating a backward trajectory and the S50 of calculating a forward trajectory are completed when the backward trajectory and the forward trajectory are connected from a current location to a current target waypoint so as to complete bidirectional trajectory planning.
The S60 of generating a robot control command generates a command for controlling the robot according to the bidirectional trajectory when the S30 of calculating a backward trajectory and the S50 of calculating a forward trajectory are repeated a preset number of times.
Most of the robot control commands are generated according to the forward trajectory.
This is because a real time bidirectional trajectory is planned when calculation for a new bidirectional trajectory has to be completed before the robot completes moving one time step.
An input value for the robot generated in the S60 of generating a robot control command may be calculated as below.
Herein, uk is an input value for a robot at a time k, uϵŪk(1) is an input value for the robot which is included in an input space of the robot at a k-th step where one step may be run, Hinput is a minimum cost-to-go function for an input value of the robot, Sk is a state value of the robot at a time k, and sk+1 is a state value of the robot at a time k+1.
In an online bidirectional trajectory planning method in a state-time space according to an embodiment of the present invention, a connection trajectory is calculated so as to connect the forward trajectory and the backward trajectory, and planning is performed for a bidirectional trajectory that incrementally plans a forward trajectory and a backward trajectory.
When a bidirectional trajectory is continuously planned, a forward trajectory and a backward trajectory may meet, but a velocity may vary.
Accordingly, in order to overcome a velocity difference between the forward trajectory and the backward trajectory, it is preferable to connect the forward trajectory and the backward trajectory by using the connection trajectory.
In other words, it is preferable to calculate a connection trajectory, in which a first side of the connection trajectory connected to the forward trajectory, is calculated to have a velocity identical to a velocity of a last calculation point of the forward trajectory, and a second side of the connection trajectory connected to the backward trajectory is calculated to have a velocity identical to a velocity of a last calculation point of the backward trajectory.
Herein, in order to simplify calculation, calculation of a connection trajectory which is a section between a last calculated state value sf of the forward trajectory and a last calculated state value s−b of the backward trajectory may be performed by using the same input value for the robot as the equation below.
Herein, f(a, b, c) is a motion model function of a robot which calculates a state value of the robot moving from a point corresponding to a state value by a time step c according to an input value for the robot.
When a maximum time interval used when calculating a connection trajectory is C, the same becomes (c1+ . . . +cN)≤C.
As shown in
In S20 of setting a waypoint, a robot state at a current target waypoint is set. The current target waypoint is a waypoint where a forward trajectory is heading to pass through.
The S20 of setting a waypoint is setting a robot state when the robot passes the current target waypoint. It is preferable to set the robot state when the robot passes the current target waypoint by taking into account of a robot location, a location of a target waypoint, and a location of a subsequent waypoint.
Accordingly, in the S20 of setting a waypoint is setting a waypoint where the forward trajectory passes through the current target waypoint, a state value gw of the current target waypoint is set as the equation below so as to minimize the cost-to-go.
Herein, gw represents a state value of a current target waypoint, {tilde over (g)}w+1 represents a state value of a subsequent target waypoint while setting gw, Gw represents a state range of the current target waypoint, Gw+1 represents a state range of the subsequent target waypoint, H(a, b) represents a cost-to-go function from a to b, Sf represents a current location of a robot, g represents the current target waypoint, and {tilde over (g)} represents a subsequent waypoint of the current target waypoint.
In S30 of calculating a backward trajectory, a backward trajectory is calculated.
The calculating of the backward trajectory, S30, plans a trajectory from the current target waypoint to a current location of the robot. Herein, when the forward trajectory is calculated, a backward trajectory to a last calculation point of the forward trajectory may be calculated.
The S30 of calculating a backward trajectory may calculate a backward trajectory step by step, or may calculate on a per predetermined step basis.
In the S40 of determining a connection trajectory, whether or not a connection trajectory where a current location of the robot or a last calculation point of a forward trajectory is connected to a current target waypoint or a last calculation point of a backward trajectory exists is determined.
The S40 of determining a connection trajectory may be performed whenever one step of the backward trajectory is calculated, or whenever a predetermined number of steps of the backward trajectory is calculated.
Herein, when a connection trajectory is not present in the S40 of determining a connection trajectory, from the S30 of calculating a backward trajectory to the S40 of determining a connection trajectory may be repeated a preset number of times, and when a connection trajectory is determined in the S40 of determining a connection trajectory, returning to the S20 of setting a waypoint is performed.
In other words, whenever a backward trajectory is calculated for one step, whether or not a connection trajectory exists is determined, and if not, a backward trajectory is calculated for a preset number of times.
Planning a backward trajectory prior to a forward trajectory allows the robot to pass more smoothly when passing the target waypoint, and reduces an over-run phenomenon where a turning trajectory becomes large when the robot turns on the target waypoint and then turns toward the next target waypoint as a distance between waypoints is short or an angle between waypoints is small.
In addition, calculating a backward trajectory for a preset number of times first also allows the robot to pass more smoothly when passing the target waypoint.
Herein, when the S30 of calculating a backward trajectory to the S40 of determining a connection trajectory are repeated a preset number of times, moving to the subsequent step is performed even though a connection trajectory is not present.
In the S50 of calculating a forward trajectory, a forward trajectory is calculated when a connection trajectory is determined to be not present in the S40 of determining a connection trajectory.
In the S50 of calculating a forward trajectory, a trajectory is planned to a current target waypoint from the current location of the robot. Herein, when the backward trajectory is calculated, a forward trajectory may be calculated to a last calculation point of the backward trajectory.
The S50 of calculating a forward trajectory may calculate a forward trajectory step by step, or may calculate on a per predetermined step basis.
The S60 of generating a robot control command generates a command for controlling the robot according to the bidirectional trajectory when the S50 of calculating a forward trajectory are repeated a preset number of times.
Most of the robot control commands are generated according to the forward trajectory.
This is because a real time bidirectional trajectory is planned when calculation for a new bidirectional trajectory has to be completed before the robot completes moving one time step.
An input value for the robot generated in the S60 of generating a robot control command may be calculated as below.
Herein, uk is an input value for a robot at a time k, uΣŪk(1) is an input value for the robot which is included in an input space of the robot at a k-th step where one step may be run, Hinput is a minimum cost-to-go function for an input value of the robot, Sk is a state value of the robot at a time k, and sk+1 is a state value of the robot at a time k+1.
In an online bidirectional trajectory planning method in a state-time space according to an embodiment of the present invention, when a connection trajectory is determined to be present in the S40 of determining a connection trajectory, a forward time index is set for a connection trajectory and a backward trajectory, whether or not an inevitable collision state is present in the connection trajectory and the backward trajectory is determined, and then if not, a time parameter of a forward trajectory, a time parameter of a backward trajectory, and a time parameter of a forward trajectory passing through a subsequent waypoint are changed by calculation.
A forward time index applied to a forward trajectory may provide an absolute time (a time based on the robot). Accordingly, collision with dynamic obstacles may be predicted.
However, a backward time index applied to a backward trajectory and a time index applied to a connection trajectory do not provide an absolute time, and thus collision with dynamic obstacles may not be predicted.
Accordingly, when a forward trajectory, a connection trajectory, and a backward trajectory are connected, in order to determine whether or not collision with dynamic obstacles is present, a time index used in the connection trajectory and the backward trajectory has to be changed to a forward time index applied to the forward trajectory. Accordingly, an absolute time may be provided for the connection trajectory and the backward trajectory, and whether or not predicted collision is present in the backward trajectory and the connection trajectory may be determined.
When predicted collision is not present in the backward trajectory and the connection trajectory, a bidirectional trajectory is completed from the current location of the robot to the current target waypoint.
As above, an online bidirectional trajectory planning method in a state-time space according to an embodiment of the present invention has been described. However, a computer-readable recording medium on which a program for employing an online bidirectional trajectory planning method in a state-time space, and a program stored on a computer-readable recording medium for employing an online bidirectional trajectory planning method in a state-time space may be also feasible.
In other words, an online bidirectional trajectory planning method in a state-time space described above may be employed in the form of program instructions executable through diverse computing means and may be recorded in computer readable media. In other words, the method may be employed in the form of a program command that can be executed through various computer means, and can be recorded on a computer-readable recording medium. The computer readable media may include independently or associatively program instructions, data files, data structures, and so on. Program instructions recorded in the media may be specially designed and configured for embodiments, or may be generally known by those skilled in the computer software art. Computer readable recording media may include magnetic media such as hard disks and floppy disks, optical media such as CD-ROMs and DVDs, magneto-optical media such as floptical disks, and hardware units, such as ROM, RAM, flash memory, and so on, which are intentionally formed to store and perform program instructions. Program instructions may include high-class language codes executable by computers using interpreters, as well as machine language codes likely made by compilers. The hardware units may be configured to function as one or more software modules for performing operations according to embodiments of the present disclosure, and vice versa.
It will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined by the appended claims.
Number | Date | Country | Kind |
---|---|---|---|
10-2018-0151119 | Nov 2018 | KR | national |