Method and apparatus for low-complexity trajectory planning
Patent Information
- Authority / Receiving Office
- EP · EP
- Patent Type
- Applications
- Current Assignee / Owner
- SONY GROUP CORP
- Filing Date
- 2024-06-19
- Publication Date
- 2026-05-13
AI Technical Summary
Current optimization-based trajectory planning for actuators becomes complex and difficult to implement in real-time, especially for systems with multiple axes, due to the need for enforcing strict bounds on backward differences, which can lead to increased computation times and potential system halts, and is further complicated by changes in sampling rates.
A method and apparatus that use a continuous spline of degree n within a planning time frame to compute a piecewise constant function based on initial values and discrete trajectory constraints, allowing for reduced complexity and independence from sampling rate changes, ensuring the trajectory remains within specified limits during backward difference calculations.
This approach reduces computational complexity and maintains real-time trajectory planning capabilities, ensuring safe and accurate actuator control regardless of sampling rate changes, thereby enabling dynamic interaction with the environment without system halts.
Smart Images

Figure EP2024067052_16012025_PF_FP_ABST
Abstract
Description
[0001] Method and Apparatus for Low-Complexity Trajectory Planning
[0002] Field
[0003] The present disclosure is related to a method and an apparatus for planning a trajectory of an actuator.
[0004] Background
[0005] As technical systems increasingly interact with their environment, it is of foremost importance to enable them to react quickly to dynamically changing conditions or goals. This calls for trajectory planning algorithms that can be applied in real-time. One candidate to achieve this is optimization-based planning, which solves an optimization problem to derive a new trajectory. Optimization-based planning has the advantage of allowing one to specify the solution characteristics transparently by means of equality and inequality constraints and to specify the goal by means of an appropriate objective function.
[0006] For many technical systems, a subset of the constraints that must be strictly met are formulated as constraints on a physical parameter, such as a position and its time derivatives, such as a velocity, acceleration, jerk, and / or generally any time derivative up to order n. Since nowadays most control systems are zero-order-hold sampled with a sampling time interval length T, these time derivatives are approximated by so-called backward differences, with bk^ = wherein b^ = ukand ukis the physical parameter at time t = k - T, recursively defining the backward difference of order j at time step k.
[0007] A control algorithm receiving, for example, a desired sequence of positions to be tracked, usually first verifies backward differences of orders up to n at all time steps k and only processes them if these backward differences - as valid approximations of the time derivatives of the physical parameter, such as the velocity, acceleration, jerk, etc. - satisfy hard lower and upper bounds on them. In a case where only one of these bounds is violated, the control system cannot guarantee safe operation anymore and may bring the system to a halt. This implies that the current goal cannot be achieved and that potentially tedious procedures must be undertaken to bring the technical system into a safe state from which it may resume its action.
[0008] The state of the art is to solve this problem by enforcing lower and upper bounds on each backward difference in the optimization problem. This leads to a large number of decision variables and equality constraints defining backward differences and makes real-time planning of trajectories for longer trajectory lengths difficult to impossible. This may especially be the case if a robot has multiple axes that must be coordinated in a central manner, which would prevent the technical system to meaningfully interact with its environment.
[0009] Another problem to consider is that the hardware and software of the technical system may be subject to change from the manufacturer, such as by increasing the sampling rate to increase control performance. Even if a complex problem can be solved at the original sampling time interval length in real-time, there is a potential that a decreased sampling time interval length would lead to longer computation times or create difficulties in real-time trajectory planning. In the best case scenario, the computation time increases linearly with the increased sampling rate.
[0010] Thus, there is a demand for technical systems that apply optimization-based trajectory planning with a decreased complexity for enabling continued interaction with a surrounding environment.
[0011] Summary
[0012] This demand is addressed by a method and an apparatus in accordance with the independent claims. Possibly advantageous embodiments are addressed by the dependent claims.
[0013] According to a first aspect, the present disclosure proposes a method for planning a trajectory for at least one actuator. The trajectory is based on a continuous spline of degree n within a planning time frame comprising a plurality of time intervals. The method includes providing a plurality of initial values including an initial value for a physical parameter of the actuator and a respective initial value for a first to an ( / / - I -th derivative of the physical parameter with respect to time at the beginning of the planning time frame. The method further includes providing a trajectory objective for the planning time frame. Furthermore, the method includes providing a plurality of discrete trajectory constraints at a respective start and / or end of the time intervals that are related to the physical parameter and its first to / / -th derivative with respect to time.
[0014] The method further includes computing a piecewise constant function. Each piece represents a constant value for the / / -th derivative of the physical parameter within the respective time interval. The piecewise constant function is computed based on the trajectory objective, the plurality of discrete trajectory constraints, and the plurality of initial values. The method further includes computing a continuous trajectory function in the form of a continuous spline of degree n for the planning time frame by integration calculations of the piecewise constant function. Furthermore, the method includes sampling the continuous trajectory function to obtain samples in accordance with a sampling time interval length and controlling the actuator based on the samples of the continuous trajectory function.
[0015] According to a second aspect, the present disclosure proposes a program having a program code for performing the method described above, when the program is executed on a processor or a programmable hardware.
[0016] According to a third aspect, the present disclosure proposes a non-transitory machine-readable medium having stored thereon a program having a program code for performing the method described above, when the program is executed on a processor or a programmable hardware.
[0017] According to a fourth aspect, the present disclosure proposes an apparatus for planning a trajectory for at least one actuator. The trajectory is based on a continuous spline of degree n within a planning time frame comprising a plurality of time intervals. The apparatus comprises interface circuitry configured to receive a plurality of initial values including an initial value for a physical parameter of the actuator and a respective initial value for a first to an ( / / - I -th derivative of the physical parameter with respect to time at the beginning of the planning time frame. The interface circuitry is further configured to receive a trajectory objective for the planning time frame. Furthermore, the interface circuitry is configured to receive a plurality of discrete trajectory constraints at a respective start and / or end of the time intervals that are related to the physical parameter and its first to / / -th derivative with respect to time. The apparatus comprises processing circuitry configured to compute a piecewise constant function. Each piece represents a constant value for the / / -th derivative of the physical parameter within the respective time interval. The processing circuitry is configured to compute the piecewise constant function based on the trajectory objective, the plurality of discrete trajectory constraints, and the plurality of initial values. The processing circuitry is further configured to compute a continuous trajectory function in the form of a continuous spline of degree n for the planning time frame by integration calculations of the piecewise constant function. Furthermore, the processing circuitry is configured to sample the continuous trajectory function to obtain samples in accordance with a sampling time interval length. The apparatus further comprises an actuator and is configured to control the actuator based on the samples of the continuous trajectory function.
[0018] Brief description of the Figures
[0019] Some examples of apparatuses and / or methods will be described in the following by way of example only, and with reference to the accompanying figures, in which
[0020] Fig. 1 schematically illustrates an exemplary apparatus for planning a trajectory for at least one actuator;
[0021] Fig. 2 shows an exemplary continuous trajectory function being obtained by integration calculations of an exemplary piecewise constant function;
[0022] Fig. 3 shows an exemplary sampling of the continuous trajectory function to obtain an exemplary discrete trajectory function;
[0023] Fig. 4A shows an exemplary range for the physical parameter to be enforced at specified control points for backward difference calculations;
[0024] Fig. 4B shows an exemplary formula for evaluation of a first derivative approximation of the physical parameter to be enforced at specified control points for backward difference calculations; Fig. 4C shows an exemplary formula for evaluation of a second derivative approximation of the physical parameter to be enforced at specified control points for backward difference calculations;
[0025] Fig. 4D shows an exemplary formula for evaluation of a third derivative approximation of the physical parameter to be enforced at specified control points for backward difference calculations;
[0026] Fig. 5 depicts a comparison between a number of variables and equalities to be considered in computation using a sampling time interval length vs. a number of variables and equalities to be considered in computation using a spline time interval length;
[0027] Fig. 6A shows exemplary requirements of a planned trajectory for backward difference calculations to be performed by a control system;
[0028] Fig. 6B shows exemplary imposed limits for respective orders of an exemplary spline u(f) of degree n that correspond to the backward difference calculation requirements;
[0029] Fig. 7 A depicts exemplary discrete trajectory constraints for the mathematical spline of order n;
[0030] Fig. 7B depicts further exemplary discrete trajectory constraints in the form of ranges for each order of the mathematical spline of order / ?, including shrinkage values up to the (n-2 )-th order;
[0031] Fig. 7C depicts exemplary initial conditions for the physical parameter and first to (n- l)-th derivatives of the physical parameter;
[0032] Fig. 8 shows a chart depicting an exemplary graph for the physical parameter and each of its time derivatives, with the highest order derivative n corresponding to a piecewise constant function; Fig. 9A depicts exemplary discrete trajectory constraints for a cubic spline;
[0033] Fig. 9B depicts exemplary initial conditions for the zeroth, first, and second orders of the cubic spline;
[0034] Fig. 9C depicts further exemplary discrete trajectory constraints in the form of ranges for the cubic spline, including shrinkage values for the zeroth and first orders;
[0035] Fig. 9D depicts exemplary shrinkage values for the ranges of the zeroth and first orders that may be applied for a particular case of a cubic spline;
[0036] Fig. 10 schematically illustrates an exemplary controller for controlling one or more actuators;
[0037] Fig. 11 shows an exemplary robot configured to move based on the planned trajectory;
[0038] Fig. 12 shows an exemplary drone configured to move based on the planned traj ectory; and
[0039] Fig. 13 illustrates a flow chart of an exemplary method for planning a trajectory for at least one actuator.
[0040] Detailed Description
[0041] Some examples are now described in more detail with reference to the enclosed figures. However, other possible examples are not limited to the features of these embodiments described in detail. Other examples may include modifications of the features as well as equivalents and alternatives to the features. Furthermore, the terminology used herein to describe certain examples should not be restrictive of further possible examples.
[0042] Throughout the description of the figures same or similar reference numerals refer to same or similar elements and / or features, which may be identical or implemented in a modified form while providing the same or a similar function. The thickness of lines, layers and / or areas in the figures may also be exaggerated for clarification. When two elements A and B are combined using an 'or', this is to be understood as disclosing all possible combinations, i.e. only A, only B as well as A and B, unless expressly defined otherwise in the individual case. As an alternative wording for the same combinations, "at least one of A and B" or "A and / or B" may be used. This applies equivalently to combinations of more than two elements.
[0043] If a singular form, such as “a”, “an” and “the” is used and the use of only a single element is not defined as mandatory either explicitly or implicitly, further examples may also use several elements to implement the same function. If a function is described below as implemented using multiple elements, further examples may implement the same function using a single element or a single processing entity. It is further understood that the terms "include", "including", "comprise" and / or "comprising", when used, describe the presence of the specified features, integers, steps, operations, processes, elements, components and / or a group thereof, but do not exclude the presence or addition of one or more other features, integers, steps, operations, processes, elements, components and / or a group thereof.
[0044] Generally for technical systems of a robot or drone, there are different ways that a controller may provide control signals. In a first possibility, no safety or accuracy requirements are needed and the controller may allow for any sequence of values to be followed without requiring tracking performance. In a second possibility, a user may impose custom constraints at every time step on backward differences up to order n. If these constraints are violated at runtime, the user may also choose a response mechanism. However, in a third possibility, a user may be using a control system provided by a manufacturer with settings that cannot be changed according to safety or accuracy requirements. For example, trajectory constraints including upper and lower bounds for respective variables may be required for traj ectory planning and execution. Trajectories are usually checked by a control system by performing backward difference calculations prior to execution. If the trajectory at any point in time within a planning time frame does not satisfy the constraints, the entire system may be brought to a halt. However, if the control system is provided with a trajectory for which these constraints are enforced by design (or construction), the control system will be able to fully execute it. It is thus desirable to compute a trajectory that is guaranteed to remain within boundaries according to safety and accuracy requirements, such as those of a manufacturer that cannot be changed. Furthermore, such systems are becoming more complex, and may become too complex for efficient trajectory planning. In a particular example, we assume that a trajectory needs to be planned for 1 second with a sequence of desired positions. Many state-of-the-art systems apply trajectory constraints with a lower and upper limit for 4 variables, including a position, velocity, acceleration, and jerk, giving 8 inequality constraints. The sampling time interval length of the manufacturer, which will be referred to as Z, determines the total number of variables across the planning time frame 7 is often set between 1 to 10 milliseconds (ms). Choosing a sampling time interval length of 1 ms for the planned 1 second leads to 1000 samples, and thus 1000 points, each associated with four variables and 8 inequality constraints. Further constraints may be required to ensure a specific goal is met, such as obstacle avoidance, etc. While the problem may be solved by state-of-the-art optimization solver technology in about 10 ms, modern robots now have around six to nine independent joints to be controlled in an orchestrated fashion. For nine joints, over 70,000 inequality constraints must be considered, along with over 25,000 equalities. In a best case scenario, this would take 90 ms, with the solution time growing approximately linearly for such problems. This is too long for enabling dynamic interaction with a surrounding environment for a robot or drone. Trajectory planning with reduced complexity may improve interaction dynamics.
[0045] Additionally, users of such technical systems often have no control over a pre-specified sampling time interval length Z, corresponding to a pre-specified sampling rate. Most control system manufacturers apply the highest feasible sampling rate to minimize lag. Such systems may also be prompted to perform software updates, which may cause the pre-specified sampling rate to become even higher and may lead to more frequent occurrences of overly complex trajectory planning. Thus, it would be optimal if the complexity of trajectory planning can be made independent of the sampling rate. Generally, trajectory planning with reduced complexity that does not increase in complexity with an increased sampling rate is desirable.
[0046] The following, with reference to Figs. 1 to 9, provides a scheme for computation to overcome the previously described difficulties. Figs. 10 to 12 provide examples of how such computations may be applied. In one aspect, embodiments of the present disclosure enable a scheme using predefined trajectory limits to compute a trajectory that, after sampling, is guaranteed to remain within those limits during backward difference calculations. In another aspect, embodiments of the present disclosure enable a scheme with fewer variables considered in computation, allowing reduced calculation times. Furthermore, the complexity and calculation times are also independent of the sampling time interval.
[0047] Fig- 1 shows an exemplary apparatus 100 for planning a trajectory for at least one actuator 150. The trajectory is based on a continuous spline of degree n. The apparatus 100 is configured to receive input including a plurality of initial values 110, a plurality of discrete trajectory constraints 112, and a trajectory objective 114. Based on the input, the apparatus 100 is configured to compute a piecewise constant function 120 over a planning time window of an n- th time derivative of a physical parameter. Based thereon, the apparatus 100 is configured to compute a continuous trajectory function 122 depicting the physical parameter over the planning time window. Finally, the apparatus 100 is configured to sample the continuous trajectory function 122 to obtain samples 130. The samples 130 may be used to obtain a discrete trajectory function, which may be used as a control signal by an external control system for controlling an actuator 150 a robot or drone. The samples 130, and the discrete trajectory function may be formed in accordance with a sampling time interval length Z, which may be pre-specified by a manufacturer of the control system. The aforementioned features of the apparatus 100 may enable certain advantages for providing the control signal for the external control system, such as a reduced complexity (i.e. time of computation), maintaining the reduced complexity if the manufacturer’s pre-specified sampling rate is increased, and a guarantee of meeting pre-specified trajectory limits of the manufacturer.
[0048] In general, the spline is a mathematical function that is constructed by joining points called knots or control points. The spline may be specified as having a degree / / , wherein n is an integer greater than zero. For example, the spline may be a spline of degree 1 (linear spline), degree 2 (quadratic spline), degree 3 (cubic spline), degree 4 (quartic spline), etc. Generally in the case of a linear spline, the control points are joined by a series of straight lines (i.e. is continuous) but it is not continuously differentiable, while a quadratic spline is continuously differentiable in its first derivative and a cubic spline is continuously differentiable in its first and second derivatives, etc.
[0049] Using mathematical splines may offer several advantages in optimization of trajectories. Splines are easily manipulable mathematical functions and are thus commonly used in various fields applying numerical analysis. More specifically, a spline may have many adjustable parameters that may be manipulated while maintaining a degree of continuity and smoothness required for planning trajectories. Splines may be flexibly configured within highly specified constraints that may be refined for each use case. The most commonly used spline in optimization planning is the cubic spline. For some cases, a quartic spline or a spline of a higher degree may be more suitable to provide higher order continuity and increased flexibility within constraints, while a quadratic spline may be more suitable if greater simplicity and efficiency is desired.
[0050] The apparatus 100 is configured to select a planning time frame and to compute the continuous spline of degree n within the chosen planning time frame. The planning time frame may be the same for each trajectory computation or may be modifiable for each iteration. In general, the planning time frame may be any duration or time period for which the trajectory or any sequence of actions for following the trajectory is planned. For example, the actuator 150 may be configured to control a motion of a robot or drone (shown in Figs. 11 and 12). The apparatus 100 may be configured to select a planning time frame that is appropriate for the robot or drone and according to its current environment. In a clear environment with few obstacles, the apparatus 100 may select a comparatively longer planning time period, while more challenging environments may lead to selecting a comparatively shorter planning time period.
[0051] The planning time frame of the trajectory may also be organized by comprising a plurality of spline time intervals, which may provide a basis for control points of the continuous spline. The spline time intervals may be structured to enable an adequately precise planned trajectory when requirements at are fulfilled at the interval edges (i.e. control points of the continuous spline). For this, the apparatus 100 may receive input with requirements for a physical parameter at each control point, as well as one or more of its derivatives with respect to time. Such requirements may lead to a trajectory that is feasible and safe for the actuator 150 to follow, as well as meeting other necessary requirements or goals. The spline time intervals may correspond to a pre-determined (i.e. determined before computation) spline time interval length, which will be referred to as T.
[0052] The spline time interval length T may also be modifiable and adapted toward each use case. For example, the apparatus 100 may be configured to determine a spline time interval length T based on the complexity of the trajectory requirements. Each planning time frame may comprise N1intervals, wherein each spline time interval corresponds to an amount of time T within the planning time frame. As such, each planning time frame may be for an amount of time of TN1between two time instances of a time t = 0 and a time t = T-N1. Given a significantly greater number of requirements of greater complexity, the spline time interval length r may be shortened to allow finer trajectory planning. A planning time frame may have a pre-determined number of spline time intervals, which may be based on a pre-determined amount of memory to be used for computation. Thus, a longer pre-determined spline time interval length T may correspond to a longer planning time frame as desired, while a shorter T may correspond to a shorter planning time frame. For planning the trajectory within the planning time frame, the apparatus 100 comprises interface circuitry 102 configured to receive trajectory requirements as input information.
[0053] For example, the interface circuitry 102 is configured to receive a plurality of initial values 110. The initial values 110 include an initial value for the physical parameter of the actuator 150. For example, the physical parameter may be a kinematic parameter, such as a position, p, of the actuator 150, which may describe an absolute location or a location with reference to another object and may be measured by any units for a distance or displacement (e.g., meters). Further examples of the physical parameter include a velocity, v, corresponding to a rate of change of a position (e.g. meters per second), an acceleration, a, corresponding to a rate of change of a velocity (e.g. meters per second squared), a jerk, j, corresponding to a rate of change of an acceleration (e.g. meters per second cubed), or the physical parameter may correspond to even higher order derivatives of a position with respect to time (e.g. snap, crackle, lock, pop, whip, thrust, etc.).
[0054] The physical parameter may also be a force (i.e. multiplying an acceleration by a mass) or a derivative thereof with respect to time. Similarly, the physical parameter may also be rotational versions of the previously listed kinematic parameters, such as a rotational position (e.g. angle), a rotational velocity, and a rotational acceleration, or any time derivative thereof. Furthermore, the physical parameter may be an angular momentum or torque (i.e. multiplying a rotational velocity or acceleration, respectively, by a moment of inertia), or a time derivative thereof. Further examples of the physical parameter include a voltage, a current, and an electric current density, or any time derivative of such examples. Generally, any physical parameter that can have its time derivative computed may be used, wherein the physical parameter may optionally be specified by multiplying a variable changing over time by a constant value corresponding to another physical parameter. The initial values 110 further include a respective initial value for a first to an ( / / - lj -th derivative of the physical parameter with respect to time. For example, for a cubic spline, the initial values 110 may include an initial value for its first time derivative, and an initial value for its second time derivative. If the physical parameter is a position of the actuator 150, the initial values 110 may include an initial velocity and an initial acceleration, whereas if the physical parameter is a velocity of the actuator 150, the initial values 110 may include an initial acceleration and an initial jerk, etc.
[0055] The interface circuitry 102 is further configured to receive a plurality of discrete trajectory constraints 112. The discrete trajectory constraints 112 may be applied at the edges (i.e. front and / or back edges) of the spline time intervals, thus providing conditions at control points that are discretely located and that the spline must satisfy. The discrete trajectory constraints 112 may include restricting values of the physical parameter, or zeroth order, at points in time corresponding to the edges of the spline time intervals, which may correspond to a multiple of T. The discrete trajectory constraints 112 may further include restricting values of the first time derivative, or first order, and possibly higher order time derivatives, up to the specified / / -th order, at the respective multiples of r. Each of the discrete trajectory constraints 112 may have a respective acceptable range for values for the physical parameter and one or more of its derivatives, so that the trajectory need not pass precisely equal to a specific value, but within an acceptable range of it. The discrete trajectory constraints 112 may further include equalities (i.e. equality relationships) that may specify how a value for the physical parameter and / or one or more of its time derivatives at an edge of a spline time interval may relate to such values at another edge (e.g., a preceding or following edge).
[0056] The interface circuitry 102 is further configured to receive a trajectory objective 114. The trajectory objective 114 may refer to a desired outcome or goal and may guide the generation and optimization of the trajectory. The trajectory objective 114 may thus influence the computed trajectory in its final destination and / or path before its final destination. For example, a trajectory objective 114 may include collision avoidance regarding detected objects, which may be specified for the actuator 150 or an object coupled to the actuator 150 to remain clear of foreign objects by a minimum distance. The trajectory objective 114 may further include goals for a desired level of smoothness, time or energy efficiency, and / or reduced cost. Such goals may also influence the trajectory in opposing directions, where the most time or energy efficient trajectory may not be adequately smooth, while the smoothest trajectory may require unreasonable amounts of time and energy. Multiple goals may be prioritized as necessary. In order to incorporate various requirements for the trajectory, the trajectory objective 114 may be encoded in various forms. For example, the trajectory objectivel l4 may be encoded in terms of an objective function to be maximized or minimized. Alternatively or additionally, the trajectory objective 114 may be encoded using additional trajectory constraints.
[0057] The initial values 110, the discrete trajectory constraints 112, and the trajectory objective 114 may be provided to the interface circuitry 102 to enable computation of the trajectory. The interface circuitry 102 may be any device or means for communicating or exchanging data. The interface circuitry 102 may be communicatively coupled to a memory, which may be configured to store portions of the input information, such as the trajectory objective 114 or the discrete trajectory constraints 112. The interface circuitry 102 may also be configured to receive input information from one or more sensors configured to generate sensor data, which may be used for providing or updating the initial conditions 110 and / or the traj ectory obj ective 114, and may be used for modifying the spline time interval length T. For this, the sensor data may be fused and processed to a readable form for the interface circuitry 102. The interface circuitry 102 may also be configured to receive input information based on previously computed trajectories. For example, if a trajectory for the physical parameter was computed and executed, then the final value of the physical parameter in the trajectory may be received as input for an initial value of the physical parameter for a new trajectory to be computed. The same may apply for one or more time derivatives of the physical parameter, as appropriate. Given the input information received by the interface circuitry 102, the apparatus 100 may perform processing and computations for planning the trajectory for at least one actuator 150.
[0058] For this, the apparatus 100 comprises processing circuitry 104 coupled to the interface circuitry 102. The processing circuitry 104 may be a single dedicated processor, a single shared processor, or a plurality of individual processors, some of which or all of which may be shared. Alternatively, the processing circuitry 104 may be a digital signal processor (DSP) hardware, an application specific integrated circuit (ASIC), a neuromorphic processor or a field programmable gate array (FPGA). The processing circuitry 104 may optionally be coupled to, e.g., read only memory (ROM) for storing software, random access memory (RAM) and / or non-volatile memory. Optionally, the apparatus 100 may comprise further circuitry. The processing circuitry 104 is configured to compute a piecewise constant function 120 by means of an optimization algorithm based on the initial values 110, the discrete trajectory constraints 112, and the trajectory objective 114. More specifically, the discrete trajectory constraints 112 may comprise one or more equations to be enforced at the interval edges of the spline time intervals. While the initial values 110 may provide definite values to be inserted into the equations, certain degrees of freedom may still be present. These degrees of freedom may be confined by respective ranges (also defined by the discrete trajectory constraints 112) for the physical parameters and its time derivatives to be enforced at the interval edges. Within the remaining degrees of freedom, values for the physical parameter and its time derivatives may be computed in accordance with the trajectory objective 114.
[0059] The piecewise constant function 120 represents a constant value for the / / -th derivative of the physical parameter within a respective spline time interval T. Thus, the piecewise constant function 120 may also be expressed as a set or series of values, with each value remaining constant for its spline time interval T. In other words, the computation of the piecewise constant function 120 may also be considered as selecting (i.e. computing) values for the / / -th derivative of the physical parameter that best match the trajectory objective 114 within the limitations of the discrete trajectory constraints 112 and the initial values 110.
[0060] Once computed, the piecewise constant function 120 provides values representing the / / -th derivative of the physical parameter within each spline time interval and it comprises the required mathematical information from which a trajectory for the physical parameter may be derived. The piecewise constant function 120 includes the information corresponding to the respective spline state at an edge of each spline time interval. A spline state may comprise a value for the physical parameter and its first to (zz-l)-th time derivative. From the piecewise constant function 120, the continuous trajectory function 122 may be computed in a way that maintains the information of each spline for the respective spline time interval edges.
[0061] From the piecewise constant function 120, the processing circuitry 104 is further configured to compute a continuous trajectory function 122 using integration calculations, which include n rounds of integration, leading to a continuous spline of degree n. As such, the continuous trajectory function 122 depicts the physical parameter over time within the planning time frame instead of its / / -th order time derivative, yet still includes the information corresponding to the respective spline state at an edge of each spline time interval. In other words, the integration calculations enable a different depiction of the same spline states. The continuous trajectory function 122 may form the mathematical basis for the actual trajectory of the actuator 150 within the planning time frame. Further details regarding the integration calculations will be described with reference to Fig. 2.
[0062] To enable digital technologies to perform processing and computations, discrete signals shall be provided. Thus, the processing circuitry 104 is configured to sample the continuous trajectory function 122 to obtain samples 130, which may be used to provide discrete control signals in the form of the discrete trajectory function. Furthermore, the processing circuitry 104 is configured to send the discrete trajectory function 132 to an external control system for controlling the actuator 150 based thereon. The samples 130 correspond to a selected sampling time interval length Z, which may be pre-specified according to an external control system of a robot or drone and may be set by a manufacturer. Further details related to the sampling of the continuous trajectory function 122 will be described in greater depth with reference to Fig. 3.
[0063] Fig. 2 depicts an exemplary continuous trajectory function 122 being obtained by integration calculations of an exemplary piecewise constant function 120. The piecewise constant function 120 is depicted with an x-axis representing time (t) and a y-axis representing values for the / / -th derivative of the physical parameter with respect to time, in)(t). The piecewise constant function 120 is also depicted with a plurality of spline time intervals represented by the spaces between the vertical lines.
[0064] As previously described, each spline time interval may comprise a pre-determined time interval length, T, which may also be modified for further planning time frames, depending on a use case. Each vertical line may correspond to a multiple of T. For example, in Fig. 2, the first vertical line 124-0 corresponds to a zeroth multiple and a time instance of t = 0-T, marking the beginning of the planning time frame. The second vertical line 124-1 corresponds to a time instance of a first multiple of T after zero, t = 1 -T, and the third vertical line 124-2 corresponds to a time instance of a second multiple of T after zero, t = 2-T. This depiction continues with vertical lines 124-(Z-1), 124-(Z), 124-( / +l), and 124-( / +2) for unspecified multiples [ / -I], [Z], [Z+l], and [Z+2] of the spline time interval length T, respectively. The zeroth spline time interval may have a time interval length of T with its back edge (i.e. beginning of the interval at the lowest value of time) at t = 0 and its front edge (i.e. end of the interval at the highest value of time) at a time t = T. The following first spline time interval may have a time interval length of r with edges at t = T and t = 2T. Continuing further, the l- th time interval may have a time interval length of r with its back edge at (Z)T and its front edge at t = (Z+1)-T, etc. As depicted, each spline time interval in the piecewise constant function 120 corresponds to a constant value for the / / -th derivative of the physical parameter with respect to time.
[0065] The vertical lines, as edges of the time intervals, may specify the times in the planning time frame for which a spline state may be defined. In other words, the edges of the spline time intervals may act as the previously discussed control points of the spline. A spline state at a specified time may be defined by the value for the physical parameter and the respective values for its first to (n- l)-th derivatives at the spline time interval edges. While the piecewise constant function 120 only visually depicts the / / -th derivative of the physical parameter, it may comprise information for all orders n. For the case of Fig. 2 corresponding to a cubic spline and the physical parameter being a position of the actuator 150, only the jerk of the actuator 150 is depicted in the piecewise constant function 120, while the piecewise constant function 120 comprises the spline states including information for the acceleration, velocity, and position of the actuator 150.
[0066] The vertical lines in Fig. 2 have been labeled, such that the piecewise constant function 120 and the continuous trajectory function 122 comprise the same spline time intervals, all having the pre-determined spline time interval length T. While a value for the / / -th derivative may suddenly change between consecutive spline time intervals in the piecewise constant function 120, values for the physical parameter are continuous and smooth if at least two orders below, as depicted in the continuous trajectory function 122 (to be discussed in greater depth in Fig. 7). More specifically, the spline states are determined to be piecewise continuous (i.e. piece- wise linear) for the order / / -I and continuously differentiable for each of the orders n-2 to zero (also depicted in greater detail in Fig. 7).
[0067] As previously stated, the continuous trajectory function 122 is computed from the piecewise constant function 120 by integration calculations, also using the plurality of initial values 110. The plurality of initial values 110 includes an initial value for the physical parameter (0) and a respective initial value for a first to an ( / / - I -th derivative of the physical parameter with respect to time at the beginning of the planning time frame. Thus, for the case of a cubic spline, the initial values 110 include an initial value for the first derivative of the physical parameter, w(1)(0), and an initial value for the second derivative of the physical parameter, w(2)(0). For computing the continuous trajectory function 122, integration calculations may be performed. The final round of integration may be performed within limits of integration of time 0 and time t. The integration may apply the following formula:
[0068] The function w(t) may be computed on a piecewise basis for each time interval since the value of u (t), is constant within each time interval. The innermost integration formula, corresponding to the / / -th derivative function is written with a specification of degree n for time, as , simply to specify that each integration formula applies a different time variable, which changes to the next lower degree ( / / - I ) based on the limits of integration (i.e. for the innermost calculation, etc.). The integration calculation ends with a final round of integration performed between limits of integration 0 and t.
[0069] For the continuing example of a cubic spline and the physical parameter being a position of the actuator 150, the first, second, and third derivatives of the physical parameter may correspond to a velocity, v, an acceleration, a, and a jerk, j, of the actuator 150. The initial values 110 may include an initial position w(0) = / ?(0), an initial velocity w(1)(0) = v(0), and an initial acceleration w(2)(0) = a(0). In this case, computing the continuous trajectory function 122 by integration calculations may be performed for each interval of the piecewise constant function 120 by applying the following formula:
[0070] The function p(f) may represent the continuous trajectory function 122, which in this example, depicts a position with respect to time. The function p(f) comprises information for each cubic spline state and corresponds to the / / -time integration of the piecewise constant function 120. Once the continuous trajectory function 122 is calculated, it may be sampled, which may be according to a pre-specified sampling rate set by a manufacturer for an external control system of a robot or drone.
[0071] Fig- 3 shows an exemplary sampling of the continuous trajectory function 122. An external control system of a robot or drone, configured to perform processing using discrete signals, needs to be provided with a discrete signal, as opposed to a signal that is continuous through time. For this, the processing circuitry 104 is configured to sample the continuous trajectory function 122 to obtain a discrete trajectory function 132 that may be provided to the control system. This is depicted in Fig. 3 with a sampling time interval length of T. The sampling may correspond to selecting a value of the continuous trajectory function 122 at multiples of the sampling time interval length T. This is depicted by the respective graphs for the continuous trajectory function 122, represented by ? / ( / ) and by the discrete trajectory function 132, represented by p\t\. While depicted as another piecewise constant function, the sampling may also be represented as a sequence of numbers of a certain order, which may be provided as input to the external control system.
[0072] Similar to the spline time interval length T, the sampling time interval length T corresponds to a multiple of time within the planned trajectory. Each sampling time interval in both the continuous trajectory function 122 and the discrete trajectory function 132 is depicted by a vertical line that corresponds to the sampling time interval length T. For example, in Fig. 3, the first vertical line 134-0 corresponds to a zeroth multiple and a time instance of t = 0- , marking the beginning of the planning time frame. The second vertical line 134-1 corresponds to a time instance of a first multiple of T after zero, t = 1- , and the third vertical line 134-2 corresponds to a time instance of the second multiple of T after zero, t = 2-T. This depiction also depicts vertical lines 124-(A 1 ), 124-(A), 124-( + 1 ), and 124-(^+2) for unspecified multiples \k- 1 ], \k\, [AH- 1 ], and [k+2] of the sampling time interval length , respectively. The zeroth sampling time interval may have a time interval length of T with its back edge (i.e. lowest value of time) at t = 0 and its front edge (i.e. highest value of time) at a time t = T. The following first spline time interval may have a time interval length of T with edges at t = T and t = 2T. Continuing further, the &-th time interval may have a time interval length of T with its back edge at (ky T and its front edge at t = (A+l) -T etc. Since the same exemplary continuous trajectory function 122 from Fig. 2 is depicted in Fig. 3, it is discernable that the sampling time interval length T is shorter than the spline time interval length T. As previously described, the sampling time interval length may correspond to settings of an external control system that were set by a manufacturer, which are often not able to be changed by a user. A manufacturer may have chosen the sampling time interval length T according to the features of the actuator 150 or features of a connected object. For example, the actuator 150 may be a motor and certain motors may be more suited for using a relatively longer sampling time interval length. Low-speed motors, such as larger DC motors or slower stepper motors, or motors being used in non-critical applications, may not require a high sampling rate. Other motors may be specified with a higher sampling rate, and thus a shorter sampling time interval length. Such motors may include a high-speed motor, such as a brushless DC motor often used in drones, or motors with rapid dynamic responses, such as servo motors or specific versions of stepper motors. Generally, a manufacturer may choose the lowest feasible sampling rate to decrease lag and increase control performance.
[0073] The apparatus 100 may be configured to select the spline time interval length T based on a desired time for computation given a pre-specified sampling time interval length T that cannot be modified by the user. Multiple factors may affect this determination, such as a desired degree of smoothness or number of trajectory constraints to consider. It is possible to provide a reference for the degree of complexity, and thus a required time for computation, based on the ratio between the spline time interval length T and the sampling time interval length T, which will be referred to as m. Mathematically, the relationship between the three variables may be expressed as T = m-T.
[0074] The spline time interval length T may be chosen specifically to be larger than the sampling time interval length, T, and equivalent to a value m-T, wherein m is a real number greater than one and is not specified with an upper limit. For example, a typical range for m may be real numbers between 1 and 15, but such ranges may vary according to a specific application. The value for m (and correspondingly, a value for T for a fixed sampling rate and fixed sampling time interval length T) may be chosen to be large enough to lower complexity of computation, while also being small enough to adequately specify limitations during computation. Such limitations must be provided so that the discrete trajectory function 132, when tested with backward difference calculations by an external control system, will have its requirements fulfilled for the physical parameter and all backward differences up to order n. More specifically, a value of m equal to 1 (i.e. T = T), would provide many control points at multiples of T for the spline to specify the trajectory as desired, but more control points would also increase the complexity. Conversely, if m is too large (and correspondingly, T is too large for a fixed sampling rate), it eventually becomes infeasible to generate a trajectory, given inadequate specifications from control points. Thus, the largest possible value for m may be selected for minimizing trajectory restrictions and computation time, while still providing sufficient specifications to generate a trajectory that meets the trajectory objective(s) 114.
[0075] As previously stated, advantages of the present disclosure may include providing trajectory planning with decreased complexity and that the complexity is independent of a sampling rate that may be determined or fixed by a manufacturer. In a particular example, a sampling time interval length may first be specified by a manufacturer to be 8 milliseconds. For this value, the spline time interval length may be set to 25 milliseconds for a desired computation time, wherein the value for m is approximately m=3. However, the sampling rate may be updated by the manufacturer to further decrease lag or for other control enhancements.
[0076] If the sampling time interval length were to be changed by a software update of the manufacturer, for example, to 1 millisecond, then the value for m would become m=25. For a sampling time interval of 1 millisecond, the number of samples within the planned time frame is much greater compared to using a sampling time interval of 8 milliseconds, which would linearly increase the number of variables and constraints, and thus linearly increase the complexity of computation time directly proportional to m. In the case of such an update by a manufacturer to a higher sampling frequency, the above-mentioned features of the apparatus 100 provide a means for maintaining the same degree of complexity in calculations, and thus keep the same time for computation.
[0077] If the sampling time interval length T according to the manufacturer gets smaller based on an increase in sampling rate, then the selection of values of the spline after the integration calculations may be adjusted to correspond to values that are spaced in time according to the new sampling time interval (i.e. according to the new sampling rate). In this sense, the optimization problem does not need to be performed differently until the final step of sampling the continuous trajectory function 122. Based on this, the value for m will become implicitly modified from a first version of m according to the previous sampling rate, m = T I T ia, to a second version of m according to the new sampling rate, m = T / Tnev / . This feature specifically demonstrates how the trajectory planning to be used by an external control system for a robot or drone, as described above, is configured to maintain its complexity of computations for optimization independent of any changes in the sampling rate.
[0078] Any change in the sampling time interval length T will lead to changes in backward difference calculations performed by an external control system, as will be shown in greater detail with reference to Figs. 4A, 4B, 4C, and 4D.
[0079] Figs. 4A, 4B, 4C, and 4D respectively present backward difference formulas that may be applied in backward difference calculations, depicted up to an order three (i.e. cubic spline). As can be seen, a recursive formula is used, which may be further expanded to orders higher than three, as needed. While Fig. 4A directly provides range limits for the physical parameter w, to be enforced at the various k-intervals depicted in Fig. 3, Figs. 4B to 4D provide formulas using the sampling time interval length T for calculating approximations of the first, second, and third order time derivatives of the physical parameter w, respectively. The backward difference calculations may be applied at the interval edges, each corresponding to a &-th multiple of the sampling time interval length Z, according to the sampling rate. The backward difference calculations may be done for a total number of N sampling time intervals, wherein the amount of time t = N-Z corresponds to the planning time frame.
[0080] As an illustrative example, the procedure for calculation of backward differences will be explained in depth for the case of a cubic spline. The calculations may start at a back edge of the zeroth sampling time interval corresponding to the time t = 0. In this case, the value of the physical parameter may be checked, whether it falls within the range between the upper and lower range limits of Fig. 4 A. Then, an approximation for a first derivative may be calculated using the formula from Fig. 4B. Generally, a difference can be taken between two values of the physical parameter (ukand uk-) taken at the front edge (i.e. highest time value) of the respective sampling time interval and at the back edge (i.e. lowest time value) of the respective sampling time interval, and the difference may be divided by Z. When calculating this for the zeroth interval edge of the planning time frame (i.e. the index [Z| corresponds to a time instance / =0), then previous values, such as values from a history of a previous iteration of calculations, may be used for the index of \k- 1 ]. The calculated value for the first time derivative approximation may then be checked, whether it falls within the range between the lower and upper limits of Fig. 4B. Then a second time derivative approximation may be calculated using the formula of Fig. 4C, (with indices \k\, [Ar-1], and [k-2]) and then checked, whether it falls within the upper and lower range limits of Fig. 4C. Furthermore, a third time derivative approximation may be calculated using the formula of Fig. 4D (with indices \k\, [Ar-1], [k-2], and [Ar-3]) and then checked, whether it falls within the upper and lower limits of Fig. 4D. Also for the second and third time derivative approximations, values from a history of a previous iteration of calculations may be used, as necessary. The calculations may continue to the front edge of the next sampling time interval, corresponding to the time t = 1 -Z, then t = 2 -Z, etc., with values taken from a history of a previous iteration of calculations, as necessary.
[0081] In the case of a general spline of order / / , the time derivative approximations may continue until an / / -th time derivative approximation has been calculated and checked against its respective limits. Thus, each round of calculations corresponding to a particular instance of time includes (ft+1) range checks, including a range check for the physical parameter u and a range check for each of the values of the first to / / -th time derivative approximations.
[0082] Each round calculations and checks (i.e. each round of backward difference calculations), including a range check for u and the calculations and range checks for the first to / / -th time derivative approximations of / / , may occur and be applied immediately in real-time by an external control system for controlling the actuator 150. After a round of calculations and checks, the external control system may immediately determine whether the discrete trajectory function 132 may be followed or not, and immediately execute or halt, accordingly. Thus, in general, at every time instant tk= k-T, a new ukmay be sent to the external control system and checked against its range, and each of the time derivative approximations (corresponding to bkto bkin Fig. 6A) may be calculated and checked against their respective ranges, and the results corresponding to the time instant may be immediately applied (i.e. continuing or stopping) for controlling the actuator 150, in real-time. If at any point during such backward difference calculations, a value does not fall within its acceptable range, the calculations may stop and the discrete trajectory function 132 (i.e. the sequence of numbers represented by the discrete trajectory function 132 or the samples 130) being used for the calculation of the approximations may be labeled to be invalid. For the continuing example where the physical parameter is a position of the actuator 150 in a cubic spline, Fig. 4A may specify a range for all values of position. The position may be specified at respective interval edges corresponding to a Ath multiple of Z, as depicted in Fig. 3, and checked if it falls within its acceptable range. Furthermore, the formulas of Figs 4B, 4C, and 4D may approximate a velocity, acceleration, and jerk of the actuator 150, respectively. As such, if any value corresponding to the position or the approximated velocity, acceleration, or jerk does not fall within the respective acceptable range, the discrete trajectory function 132 may be labeled to be invalid. If controlling of the robot or drone by the control system is being performed simultaneously during the backward difference calculations, both the controlling operations of the control system and the calculations may stop.
[0083] Fig. 5 provides a comparison between the number of variables and equalities considered in backward difference calculations, corresponding to the sampling time interval length Z, vs. the number of variables and equalities used in trajectory planning using the continuous spline, corresponding to the spline time interval length T. AS previously discussed, N is specified to be the number of sampling time intervals within the planning time frame, wherein the planning time frame is equivalent to a time / =N-Z. Each of the N sampling time intervals has n+1 variables to consider, including the physical parameter (i.e. zeroth order) and backward differences corresponding to approximations for its first to / / -th time-derivatives (i.e. first to n- th orders). Furthermore, each variable has respective lower and upper bounds to consider (as depicted in Figs. 4A to 4D), which contributes to the problem’s complexity as more variables are considered. The backward differences also have N-n backward-difference-defining equalities, corresponding to the formulas that approximate the first to / / -th time derivatives of the physical parameter.
[0084] On the other hand, the computations using the continuous spline are based on the spline time interval length T. The number of frames within the planning time frame is N1and the planning time is thus equivalent to a time t=Ai-T. By their mathematical relationships, N1can also be specified as N1= N / m, or m can be re-expressed as the ratio m = N / Nz. Since the spline time interval is greater than the sampling time interval by a factor of m, the number of frames in the spline N1is less than the number of frames used for sampling N, also by a factor m. Since the computational methods using the mathematical spline enforce constraints for a number of N1intervals and respective interval edges instead of a number A, there is a reduction in computational complexity (i.e. N^n+V) variables vs N(n+ ) variables) by a factor of m. Similarly, the number of state-defining equalities N^n is reduced by a factor of m, compared to the number of backward-difference defining equalities, N-n.
[0085] A further key aspect of the present disclosure for maintaining dynamic interaction of a robot or drone with its surrounding environment is that the apparatus 100 may be configured to compute the discrete trajectory function 132 to remain within pre-specified limits in such backward difference calculations. This feature will be presented in greater depth with reference to Figs. 6A to 9D.
[0086] Fig. 6A presents limitations that must be held for backward difference calculations, as presented in greater detail in Figs. 4A to 4D, applied at intervals of , as depicted in Fig. 3. The physical parameter u is directly provided with a range of values between an upper and lower bound. The lower bound is denoted with an under-bar, while the upper bound is denoted with an over-bar. The lower bound and upper bound may be symmetric for vector physical parameters, such as kinematic parameters, including position, velocity, acceleration, jerk, etc. As such, the range for the physical parameter u may be, for example, between a negative value specified for a position lower bound and a positive value equal in magnitude and specified for a position upper bound. This range may be enforced at each of the edges of the sampling time intervals within the planning time frame, as depicted in Fig. 3.
[0087] Similarly, bounds are depicted for the backward difference calculations for approximating the first to / / -th time derivative of the physical parameter, which are found using values corresponding to the various intervals as described in Figs. 4B to 4D. The ranges for the first to n- th derivatives are also enforced in backward difference calculations at each of the edges of the sampling time intervals within the planning time frame. In order to maintain these bounds for all backward difference calculations, the ranges of the physical parameter and its time derivative approximations up to order n may be adopted for computation of the continuous spline and may be enforced for all times within the planning time frame.
[0088] Fig 6B depicts a set of desired limits for a spline u(f) of the physical parameter u and its first to / / -th derivatives with respect to time, which can be used for obtaining the desired results in backward difference calculations that fall within the ranges shown in Fig. 6A. The constraints in Fig. 6A are checked by the external control system, and thus need to be satisfied by a planned trajectory, provided by the apparatus 100 in the form of the continuous trajectory function 122 and the discrete trajectory function 132 sampled therefrom. The planned trajectory is expressed by the continuous trajectory function 122 as a spline of order / / , ? / ( / ). Specifically, z / for this spline, the constraints presented in Fig. 6B hold, then it can be sampled with any sampling frequency 1 / Z and the constraints in Fig. 6A will be guaranteed to hold.
[0089] However, the constraints as depicted in Fig. 6B are impossible to enforce, since it is presented as a continuous spectrum with infinitely many control points (i.e. no discrete series of control points are provided). Thus, the conditions in Fig. 6B must be reformulated with sufficient specification that also leaves enough flexibility for computation to be feasible. This re-formulation is based on limiting the zeroth to n-th order derivatives of the spline at specified control points, provided at multiples of the pre-determined spline time interval length T.
[0090] The optimization algorithm may enforce the desired limits to compute the piecewise constant function 120, which may then be used to compute the continuous trajectory function 122, which can be sampled (at any sampling rate) to obtain a discrete trajectory function 132.
[0091] This may be done if the discrete trajectory constraints 112 are further specified. In particular, the ranges that are known from the backward difference calculations may first be limited by boundaries as a basis and then further confined in a specific way. The specific confinement prevents a violation of the limits on the backward differences, independent of the sampling time interval T. This will be explained in greater detail with reference to Figs. 7A to 9D.
[0092] Fig. 7A shows exemplary discrete trajectory constraint equations 112A, which are depicted in matrix-vector form. The discrete trajectory constraints equations 112A may be enforced at the edges of the spline time intervals, each comprising the spline time interval length, T. It is specifically depicted that the functional values z / (Z), z / (1)(Z), and z / (2)(Z) up to z / (n_1)(t) at a multiple [7+1] of T are determined based on the respective functional values at a multiple [7] (as depicted in Fig. 2). For example, from the bottom row of the matrix and vectors, we may obtain a constraint equation specifying that with higher rows providing further constraint equations (i.e. equalities). It may also be seen that the vector next to the matrix comprising a variable for each order at state I is defined by the initial conditions for the first iteration when 7=0. The variable up may be chosen by the optimization algorithm for each value of I from 7=0 to 7= VZ-1, specifically within all presented constraints and trajectory objectives 114, to obtain the piecewise constant function 120 (i.e. the set of values representing the time derivative of order ri).
[0093] Fig. 7B shows discrete trajectory constraint ranges 112B. The ranges 112B are given for the physical parameter u in the top line and successively for each of the first derivative up to the / / -th derivative of the physical parameter. The only difference provided here from the ranges shown in Fig. 6Bis the presence of shrinkage values (shown with a triangle symbol A). Respective shrinkage values are provided to change the ranges of an order, ranging from the zeroth to ( / / -2)-th orders. A specified amount for each shrinkage value (which may be calculated according to the order of the spline) may be provided for each order between the zeroth and ( / / -2)-th orders. This way, the values of the physical parameter and its first to (zz)-th derivative may remain within required limits of backward difference calculations at all times within the planning time frame. More specifically, when applying the discrete trajectory constraint equations 112A, the ranges 112B may ensure that the final calculated values for the physical parameter and its first to / / -th derivatives remain within a respective range, so that the backward difference calculations, as presented in Figs. 4A to 4D may also remain within the required pre-specified ranges, as outlined in Fig. 6A.
[0094] The shrinkage values may depend on a chosen value for / / / , as discussed in Fig. 3. If m is large and the spline time interval r is correspondingly large, with fewer control points per unit of time within the planning time frame, the shrinkage values may increase in quantity to provide greater limitations in the respective discrete trajectory constraint ranges. However, at some point, m could grow too large, and the shrinkage values may increase so much, that the greater limitations in ranges may eventually leave the range of the interval between the upper and lower boundaries empty. In such a case, a trajectory planning becomes infeasible. As such, m is limited by how much the shrinkage values further reduce the discrete trajectory constraint ranges 112B.
[0095] Fig. 7C shows initial conditions 110, which may be used to begin the calculations applying the discrete trajectory constraint equations 112A. Given the trajectory constraint equations 112A that are initialized with the initial conditions 110 and limited by the ranges 112B with shrinkage values applied up to the ( / / -2)-th order, the piecewise constant function 120 may be computed. Furthermore, the continuous trajectory function 122 and the discrete trajectory function 132 may be computed based thereon, and the final calculated values for backward differences of the discrete trajectory function 132 may remain within the pre-specified ranges for each order.
[0096] Fig- 8 shows a chart providing a visual example for graphically depicted values for each order of the mathematical spline. As previously described, the highest order n is shown to be a piecewise constant function, with each value remaining constant for an interval r corresponding to the spline time interval length. Furthermore, lower orders (AZ- 1 ) to zero are also depicted. The order ( / / -I ), being the order directly below a piecewise constant function, is a piecewise linear function. Given the linear connections between control points I and 7+1, all plotted points between the control points are within bounds if the control points are within bounds.
[0097] This is not necessarily the case for orders (zz-2) to down to zero, which are curved, and have plotted points that are not visibly fixed. Also, since they are curved, a curve may allow a plotted point between I and 7+1 to be outside of the required range. For this, all derivatives of orders between (zz-2) down to zero are specified at the control points to be within further reduced limits for the entire planning time frame, the reduction from the original limits being defined in terms of shrinkage values. By enforcing this, all backward difference calculations may also remain in the originally required ranges after sampling the spline with a sampling rate of 1 / 7 , with T being arbitrary, without specifying any further reduction of limits (i.e. the bounds in Fig. 6A and Figs. 4A to 4D need not be adjusted).
[0098] Fig. 9A shows exemplary discrete trajectory constraint equations 112A, which are depicted in matrix-vector form. The discrete trajectory constraint equations 112A are specific for a cubic spline, with relationships between the physical parameter and its first to third derivatives. It is specifically depicted that the functional values w(Z), w(1)(Z),and w(2)(t) at a multiple [7+1] of T are determined based on the respective functional values at a multiple [7],
[0099] In the case that the physical parameter is a position of the actuator 150, the equations 112A provide constraints relating a position, a velocity, an acceleration, and a jerk of the actuator 150. The first row of the matrix-vector relationship expresses that the value of position at [7+1] is based on a value for position, a value for velocity, a value for acceleration, and a value for jerk at [ / ]. Corresponding equations can be written for w(1)[ / +i], the velocity at multiple [7+1], which depends on the velocity, acceleration, and jerk at multiple [7], and for w(2)[ / +i], the acceleration at multiple [7+1], which depends on the acceleration and jerk at multiple [ / ]. The equations demonstrate that a value for a variable (i.e. w, w(1), w(2)) at a respective multiple [ / + 1 ] is determined by its value at the previous multiple [Z] and the values of any derivatives of the variable.
[0100] Fig. 9B shows exemplary initial values 110 for a cubic spline. For example, the initial values 110 may be for the case of the physical parameter being a position of the actuator 150, with an initial position w(0) =p(fi), an initial velocity w(1)(0) = v(0), and an initial acceleration w(2)(0) = a(0). In the case that the physical parameter is a velocity, the initial values 110 may include an initial velocity w(0) = v(0), an initial acceleration, w(1)(0) = a(0), and an initial jerk, w(2)(0) = a(0). Finally, in the case of the physical parameter being an acceleration of the actuator 150, the initial values 110 may include an initial acceleration, w(0) = a(0), an initial jerk, w(1)(0) = / (0), and an initial snap, w(2)(0) = 5(0). Higher order physical parameters may also be used, with corresponding initial conditions.
[0101] Fig. 9C shows discrete trajectory constraint ranges 112B for a cubic spline, specifying a magnitude of lower and upper bounds of the physical parameter and its first to third derivatives with respect to time. In the case of the cubic spline and the physical parameter being a position, shrinkage values may be used for the position and velocity (shown as A with no overhead dot for the position shrinkage values and shown as A with an overhead dot for the velocity shrinkage values). The ranges 112B may be compared to the general ranges presented in Fig. 6B. Such ranges were provided as a basis that needed to be further confined. With further confinement, the backward difference calculations for the physical parameter and its time derivatives up to order n may remain within the respective required limits. More specifically, the lower and upper bounds of the position and velocity can be adjusted by the shrinkage values 116. However, if confined too much, then the problem to be solved by the trajectory planning algorithm may become infeasible, wherein a solution may not exist a priori. The apparatus 100 may be configured to compute optimal values for the shrinkage values 116 before computing the piecewise constant function 120 in a way to permit a maximum amount of flexibility while also maintaining the respective boundaries for the backward difference calculations.
[0102] Fig. 9D provides a specific example for shrinkage values 116 (A) to be applied to orders zero and one in the case of a cubic spline, such that any backward difference calculations performed on the discrete trajectory function 132 is guaranteed to remain within the originally defined limits for all orders n. The shrinkage values 116 may provide a further confined range of the two lowest orders of the cubic spline corresponding to the physical parameter and its first derivative. In the case that the physical parameter is a position, the zeroth and first orders may be a position and velocity. Such shrinkage values 116 may be mathematically derived. In this particular case, the depicted formulas apply to a case of symmetric bounds for speed, acceleration, and jerk constraints, as specified in Fig. 9C.
[0103] Given appropriate shrinkage values 116, the discrete trajectory function 132 may ensure that, when provided to a control system of a robot or drone, that any backward difference calculations will meet pre-specified requirements while also permitting a maximum amount of flexibility in calculation. This can be useful to allow the robot or drone to maintain a dynamic interaction with its environment, since the system is never brought to a halt. At the same time, computation time is reduced. Thus, a great advantage of an embodiment is demonstrated. The precision of the shrinkage values, which can be exploited based on the specific configurations of the apparatus 100, may provide a guarantee of meeting backward difference requirements while also keeping complexity of computation low. Such advantages can be used by many different robots or drones, which may be structured in many different ways. Possible embodiments of such control systems and robots and drones will be described in greater detail with reference to Figs. 10 to 12.
[0104] Fig. 10 schematically illustrates an exemplary controller 1000, which is part of an external control system. The controller 1000 may be communicatively connectable to the apparatus 100 and may be configured for controlling one or more actuators 150. The controller 1000 is depicted as being coupled to two actuators 150-1; 150-2. The first actuator 150-1 is coupled to a joint 152, such as a joint of a robot. The second actuator 150-2 is coupled to a propeller 154, such as a propeller of a drone. The controller 1000 may be configured to receive the discrete trajectory function 132, provided from the apparatus 100, and to control the movement of the joint 152 or propeller 154 by means of the respective actuator 150 based thereon.
[0105] In an example of a basic configuration, the controlling may be by means of a feedback loop (depicted in Fig. 10). The controller 1000 may be configured to receive a signal for a desired position and a signal for a measured position, considered as an actual position. This is depicted as the controller 1000 receiving input, which may generally correspond to a translational or rotational position (or another variable, as needed) of the joint 152 or the propeller 154. The input may include a desired position, corresponding to the discrete trajectory function 132 (depicted from above), and a measured position (depicted from the feedback loop), which may be provided from previous calculation iterations of the trajectory or, for beginning a set of calculation iterations, may also be generated by one or more sensors (as explained for Figs. 11 and 12). The controller 1000 may be configured to compute a control error corresponding to a difference between the desired position and the actual position and to compute and apply to the actuator 150 an appropriate control signal so as to compensate for the control error.
[0106] For example, the actuator 150 may be an electric motor. In this case, the discrete trajectory function 132 may be a motor signal. The discrete trajectory function 132 may be a discrete function that was derived from a continuous spline for which the physical parameter is a position. In this case, the discrete trajectory function 132 may be a motor position signal to be provided to the controller 1000. The motor position signal may correspond to a two-dimensional or three-dimensional position. In the case that the physical parameter of the continuous spline is a velocity, the motor signal may be a motor velocity signal (i.e. motor speed signal), which may be proportional to a motor voltage signal. Furthermore, in the case of the physical parameter being an acceleration, the motor signal may be a motor acceleration signal, which may be proportional to a motor current signal.
[0107] The physical parameter may also apply to angular versions of previously mentioned examples of the physical parameter. While not depicted, the motor position signal may also correspond to an angle of the actuator 150, with the position corresponding to a rotation angle between 0 and 360°. The motor position signal may correspond to a rotational state of a motor between 0 and 360°, while the motor voltage signal may correspond to a rotational velocity of the motor, and the motor current signal may correspond to a rotational acceleration of the motor.
[0108] The actuator 150 for controlling a robot or drone may also take forms beyond a motor. Such examples include a pneumatic cylinder or hydraulic actuator, using pressurized air or fluid to generate force and motion. The actuator 150 may use voltage in various forms to generate a motion and / or force, including piezoelectric, electrostatic, electromagnetic, and electrohydrodynamic actuators, among others. In general, the actuator 150 may be configured to control a robot or drone based on the discrete trajectory function 132. In some embodiments, this may include a motor configured to control a robot or drone or a part of a robot or drone based on a motor signal.
[0109] Fig. 11 shows an exemplary robot 1100 configured to move in the planned trajectory. The exemplary robot comprises multiple versions of the actuator 150 of Fig. 1. As previously described, the actuator 150 may be a motor, and the motor may be used to control the depicted robot 1100. The apparatus 100 and / or controller 1000 may be integrated into the robot 1100 or communicatively coupled to the robot 1100 so that it receives control signals corresponding to the discrete trajectory function 132. The control signals may be in the form of the previously described motor position, motor speed and / or motor acceleration signals.
[0110] The actuator 150 may be used for controlling the robot 1100 or a part of the robot 1100 along one or more translational axes. Actuators may be coupled to joints 152-1 and 152-2, which may correspond to a horizontal translational axis and a vertical translational axis, respectively. For example, joint 152-1 may include one or more wheels below the bottom surface of the robot 1100 or a belt enabling forward and / or backward motion, while the joint 152-2 may be a plurality of structures with a telescopic mechanism. In general, the robot 1100 may be configured to receive control signals based on the discrete trajectory function 132 and move the joints 152-1 and 152-2 along one or more translational axis in two- or three-dimensional space.
[0111] The robot 1100 further comprises joints 150-3 and 150-4, which may be controlled by a corresponding actuator for a movement along a rotational axis. As previously described, the physical parameter may also apply to angular versions of previously mentioned examples of the physical parameter. As such, the robot 1100 may be configured to obtain control signals based on the discrete trajectory function 132 for controlling of the joints 150-3 and 150-4 along a respective rotational axis.
[0112] The robot 1100 may also comprise one or more sensors 156-1; 156-2 for generating sensor data by one or more sensors of its surrounding environment. The robot 1100 may be configured to provide the sensor data to the interface circuitry 102. The processing circuitry 104 may be configured to use the sensor data to update parameters at the start of a round of successive iterations of trajectory planning, which may include updating the initial values 110, the discrete trajectory constraints 112, the trajectory objective 114, and / or the spline time interval length T. Once updated by the sensor data at the beginning, such parameters, particularly the initial conditions, may then be updated for a next iteration of trajectory planning (i.e. computation iteration for a successive planning time frame) based on the final corresponding values of a previously computed trajectory. The processing circuitry 104 may be configured to then perform further iterations of computing the continuous trajectory function 122 and / or the discrete trajectory function 132 based on the updated parameters.
[0113] More specifically, the sensor data may be used to track the position, velocity, and / or acceleration, and possibly values for further physical parameters. For example, the robot may comprise a sensor 156-1; 156-2 comprising an inertial measurement unit (IMU), which may be configured to generate sensor data that may be used to compute a position, velocity, and / or acceleration of the robot. Other forms of tracking the position, velocity, and / or acceleration or other physical parameters of the robot may include using a global navigation satellite system (GNSS), Doppler radar sensors, optical encoders or optical flow sensors, laser-based range finders, ultrasonic sensors, and vision-based systems, among others.
[0114] Fig. 12 shows an exemplary drone 1200 configured to move in the planned trajectory. The drone 1200 may configured with analogous functionality compared to the robot 1100. For example, the actuator 150 may be used for controlling a drone or a part of a drone along a rotational and translational axis. Given the different structural and functional differences between a robot and a drone, the discrete trajectory function 132 may be applied differently by the controller 1000 for the same types of motion.
[0115] In the particular case of the drone 1200, the trajectory may be planned for a plurality of actuators. Fig. 12 depicts a drone with four propellers 154-1; 154-2; 154-3; 154-4, which may be connected to respective motors acting as actuators. Each of the actuators may be used to control the drone 1200 along a rotational axis, such as with a signal for a rotational position or rotational velocity, etc. Each propeller is connected to a middle base 158, which may comprise one or more sensors.
[0116] The actuators may also receive signals in a way that, collectively, they are able to provide control of the drone 1200 along a translational axis. In such a case, the discrete trajectory function 132 may be further processed by the processing circuitry 104 so that the controller 1000 may provide individualized motor signals to each of the motors. When executed, the individualized motor signals may enable the drone to move along a translational axis.
[0117] For example, for a drone to increase velocity in a specific translational axis, two of the four propellers may be given a signal for a higher rotational velocity and the other two may be given a signal for a lower rotational velocity. The drone can accelerate or maintain velocity in such a manner. Rotation of the entire drone may also be achieved with a pair of diagonally positioned propellers being given a signal for a higher rotational velocity. In such a case, the processing circuitry 104 may read the discrete trajectory function 132 and generate customized motor signals for each propeller, such that a specified motion of the drone is achieved as desired.
[0118] As previously explained, for a round of successive iterations, the input information (particularly the initial values 110) may be provided based on final computed values of the physical parameter u and of its first to (n-1 )-th order time derivatives in the continuous trajectory function 122 at the end of the planning time frame. Beyond this, sensor data may be used. For example, similar to the robot 1100, the drone 1200 may also be equipped with one or more sensors for generating sensor data of a surrounding environment of the drone. Likewise, the sensor data may be used to update the initial values 110 at the beginning of an operation (i.e. at the start of a round of successive iterations of trajectory planning). Furthermore, the discrete trajectory constraints 112 may be updated by determining a new spline time interval length T based on the sensor data. For example, the planning time frame may change while keeping the number of time frames N1constant, while r may be adjusted accordingly, thus providing changes to coefficients in the discrete trajectory constraint equalities 112A. Further computations for trajectory planning may then be performed accordingly and may be done specifically for adjusting to changes in the surrounding environment of the drone.
[0119] The trajectories of the robot 1100 or drone 1200, given adequate adjustments to the input information, such as by using specific shrinkage values 116 for the discrete trajectory constraint ranges 112B, may guarantee having any computed backward differences of the discrete trajectory function 132 within pre-specified limits of multiple physical parameters, while also maintaining a high degree of flexibility in computation. The robot 1100 may be an autonomous robot and the drone may be an autonomous drone 1200. Predefined limits for the autonomous robot 1100 or drone 1200 may be checked by an external control system, such as the depicted controller 1000 of Fig. 10, by performing backward difference calculations. Avoiding a violation of the predefined limits for such backward differences, such as by computing and applying specific shrinkage values 116, may enable the autonomous versions of the robot 1100 and drone 1200 to maintain a dynamic interaction with its environment, since a halt of the entire system caused by such a violation may be ensured to not occur and with only a minimal change in constraint ranges 112B.
[0120] At the same time, the apparatus 100 may also enable the computation time to be shortened and more predictable, as measured by the factor / / / , and may allow predictable circumstances in trajectory planning for many planned time frames. This may generally increase the overall flexibility of the autonomous robot or drone, such that it may still dynamically interact with its surrounding environment, even under challenging circumstances (i.e. complex trajectory objectives). This may also increase the abilities of dynamic interaction for more complicated robots or drones, such as those with many joints that must move in a cohesive manner. Such benefits may also be maintained, even if a control system controlling the robot or drone is adjusted to have an even higher sampling rate that may not be changed by a user, since the computation is completely independent of the sampling time interval T. As such, the apparatus 100 may be used for a robot or drone to maintain dynamic interaction with its environment despite a wide variety of changes. A method for enabling such features is presented with reference to Fig. 13.
[0121] Fig. 13 illustrates a flow chart of an exemplary method 1300 for planning a trajectory for at least one actuator. The method includes providing a plurality of initial values 1310 including an initial value for a physical parameter of the actuator and a respective initial value for a first to an (n- 1 )-th derivative of the physical parameter with respect to time at the beginning of a planning time frame. The method further includes providing a trajectory objective 1320 for the planning time frame. The method further includes providing a plurality of discrete trajectory constraints 1330 at a start and / or end of respective time intervals, the trajectory constraints being related to the physical parameter and its first to / / -th derivative with respect to time. Furthermore, the method includes computing a piecewise constant function 1340, each piece representing a constant value for the / / -th derivative of the physical parameter within the respective time interval, wherein the piecewise constant function is computed based on the trajectory objective, the plurality of discrete trajectory constraints, and the plurality of initial values. The method also includes computing a continuous trajectory function 1350 in the form of a continuous spline of degree / / for the planning time frame by integration calculations of the piecewise constant function. Furthermore, the method includes sampling 1360 the continuous trajectory function to obtain samples in accordance with a sampling time interval length. The method also includes controlling 1370 the actuator based on the samples of the continuous trajectory function.
[0122] The following examples pertain to further embodiments:
[0123] (1) A method for planning a trajectory for at least one actuator, the trajectory being based on a continuous spline of degree n within a planning time frame comprising a plurality of time intervals, the method comprising: providing a plurality of initial values including an initial value for a physical parameter of the actuator and a respective initial value for a first to an ( / / - I -th derivative of the physical parameter with respect to time at the beginning of the planning time frame; providing a trajectory objective for the planning time frame; providing a plurality of discrete trajectory constraints at a respective start and / or end of the time intervals, the trajectory constraints being related to the physical parameter and its first to / / -th derivative with respect to time; computing a piecewise constant function, each piece representing a constant value for the / / -th derivative of the physical parameter within the respective time interval, wherein the piecewise constant function is computed based on the trajectory objective, the plurality of discrete trajectory constraints, and the plurality of initial values; computing a continuous trajectory function in the form of a continuous spline of degree n for the planning time frame by integration calculations of the piecewise constant function; sampling the continuous trajectory function to obtain samples in accordance with a sampling time interval length; and controlling the actuator based on the samples of the continuous trajectory function.
[0124] (2) The method of (1), wherein each time interval of the plurality of time intervals comprises a pre-determined spline time interval length T. (3) The method of (2), wherein the continuous trajectory function corresponds to a mathematical spline comprising a plurality of spline states defined at respective multiples of the pre-determined spline time interval length, wherein a spline state at a time corresponding to a respective multiple is defined by the value for the physical parameter and the respective values for its first to (n-1 )-th derivatives, and wherein the spline state at a second time corresponding to a multiple [ / + 1] of the pre-determined spline time interval length is computed based on the spline state at a first time corresponding to the previous multiple [7] and based on the value for the / / -th derivative between the first and second time.
[0125] (4) The method of (1) to (3), wherein the plurality of initial values include an initial value for the physical parameter w(0) and an initial value for the first derivative of the physical parameter, w(1)(0), and optionally a respective initial value for one or more higher order derivatives of the physical parameter, and wherein computing the continuous trajectory function by integration calculations is performed for each interval of the piecewise constant function at least in part by applying the following formula:
[0126] (5) The method of (1) to (4), wherein the physical parameter is a translational or rotational position, / ?, a velocity, v, or an acceleration, a, of the actuator, or directly proportional thereto.
[0127] (6) The method of (1) to (5), wherein the trajectory is based on a continuous spline of the third degree, wherein the physical parameter corresponds to a position, / ?, of the actuator and the first, second, and third derivatives of the physical parameter correspond to a velocity, v, an acceleration, a, and a jerk, j, of the actuator, respectively, and wherein the plurality of initial values include an initial value for the position, p(0), for the velocity, v(0), and for the acceleration, a(0), and wherein computing the continuous trajectory function by integration calculations is performed for each interval of the piecewise constant function at least in part by applying the following formula:
[0128] (7) The method of (1) to (6), wherein the trajectory objective is encoded in terms of an objective function to be maximized or minimized and / or additional trajectory constraints. (8) The method of (2), wherein the pre-determined spline time interval length, T, is larger than the sampling time interval length, Z, and equivalent to a value = m-T, wherein m is a real number greater than one, and wherein the value for m is chosen based on a desired computation time.
[0129] (9) The method of (1) to (8), wherein the samples are used to obtain a discrete trajectory function corresponding to the physical parameter, wherein the discrete trajectory function is formed with the physical parameter confined within predefined limits, and wherein values obtained by backward difference calculations approximating the first to / / -th derivatives based on the sampling time interval length T are confined within respective predefined limits.
[0130] (10) The method of (9), wherein each value of the discrete trajectory function is constant within a time period equivalent to the sampling time interval length.
[0131] (11) The method of (9) or (10), wherein the plurality of discrete trajectory constraints comprises one or more discrete trajectory constraint equations to be enforced at multiples of the pre-determined spline time interval length T and respective ranges corresponding to a respective range of acceptable values for the physical parameter and its first to / / -th derivatives of the physical parameter at the multiples of the pre-determined spline time interval length T, wherein the respective ranges are enforced during computation of the piecewise constant function.
[0132] (12) The method of (11), wherein the respective ranges corresponding to the physical parameter and the first to ( / / -2)-th parameters each comprise shrinkage values A for further confining the respective range of acceptable values during computation of the piecewise constant function, wherein the shrinkage values A are determined based on the degree of the spline, and wherein the shrinkage values A are determined for confining the physical parameter within predefined values and implicitly confining all values obtained by backward difference calculations approximating the first to / / -th derivatives based on the sampling time interval length T within respective predefined limits.
[0133] (13) The method of (12), wherein the predefined limits are determined at least in part for safety-critical applications. (14) The method of (9) to (13), wherein the actuator is a motor and the discrete trajectory function is a motor signal corresponding to at least one of a motor position signal, a motor speed signal, or a motor torque signal, and wherein the motor is configured to control a robot or drone or a part of a robot or drone based on the motor signal.
[0134] (15) The method of (1) to (14), wherein the actuator is used for controlling a robot or drone or a part of a robot or drone along one or more rotational and / or translational axes.
[0135] (16) The method of claim (15), further comprising generating sensor data by one or more sensors of a surrounding environment of the robot or drone and updating the discrete trajectory constraints, the trajectory objective, the initial conditions and / or the pre-determined spline time interval length r based on the sensor data for further iterations of computing the continuous trajectory function and / or the discrete trajectory function.
[0136] (17) A program having a program code for performing the method according to any of the previous claims when the program is executed on a processor or a programmable hardware.
[0137] (18) A non-transitory machine-readable medium having stored thereon a program having a program code for performing the method according to any of the previous claims when the program is executed on a processor or a programmable hardware.
[0138] (19) An apparatus for planning a trajectory for at least one actuator, the trajectory based on a continuous spline of degree n within a planning time frame comprising a plurality of time intervals, the apparatus comprising interface circuitry configured to: receive a plurality of initial values including an initial value for a physical parameter of the actuator and a respective initial value for a first to an (n-1 J -th derivative of the physical parameter with respect to time at the beginning of the planning time frame; receive a trajectory objective for the planning time frame; and receive a plurality of discrete trajectory constraints at a respective start and / or end of the time intervals, the trajectory constraints being related to the physical parameter of the actuator and its first to ( / / )-th derivative with respect to time; and further comprising processing circuitry configured to: compute a piecewise constant function, each piece representing a constant value for the / / -th derivative of the physical parameter within the respective time interval, wherein the piecewise constant function is computed based on the trajectory objective, the plurality of discrete trajectory constraints, and the plurality of initial values; compute a continuous trajectory function in the form of a continuous spline of degree n for the planning time frame by integration calculations of the piecewise constant function; sample the continuous trajectory function in accordance with a sampling time interval length; and control the actuator based on the samples of the continuous trajectory function.
[0139] The aspects and features described in relation to a particular one of the previous examples may also be combined with one or more of the further examples to replace an identical or similar feature of that further example or to additionally introduce the features into the further example.
[0140] Examples may further be or relate to a (computer) program including a program code to execute one or more of the above methods when the program is executed on a computer, processor or other programmable hardware component. Thus, steps, operations or processes of different ones of the methods described above may also be executed by programmed computers, processors or other programmable hardware components. Examples may also cover program storage devices, such as digital data storage media, which are machine-, processor- or computer-readable and encode and / or contain machine-executable, processor-executable or computer-executable programs and instructions. Program storage devices may include or be digital storage devices, magnetic storage media such as magnetic disks and magnetic tapes, hard disk drives, or optically readable digital data storage media, for example. Other examples may also include local computer devices (e.g. personal computer, laptop, tablet computer or mobile phone) with one or more processors and one or more storage devices or may be a distributed computer system (e.g. a cloud computing system with one or more processors and one or more storage devices distributed at various locations, for example, at a local client and / or one or more remote server farms and / or data centers). The computer system may comprise any circuit or combination of circuits. In one embodiment, the computer system may include one or more processors which can be of any type. As used herein, processor may mean any type of computational circuit, such as but not limited to a microprocessor, a microcontroller, a complex instruction set computing (CISC) microprocessor, a reduced instruction set computing (RISC) microprocessor, a very long instruction word (VLIW) microprocessor, a graphics processor, a digital signal processor (DSP), multiple core processor, a field programmable gate array (FPGA), for example, of a microscope or a microscope component (e.g. camera) or any other type of processor or processing circuit. Other types of circuits that may be included in the computer system may be a custom circuit, an application-specific integrated circuit (ASIC), or the like, such as, for example, one or more circuits (such as a communication circuit) for use in wireless devices like mobile telephones, tablet computers, laptop computers, two-way radios, and similar electronic systems. The computer system may include one or more storage devices, which may include one or more memory elements suitable to the particular application, such as a main memory in the form of random access memory (RAM), one or more hard drives, and / or one or more drives that handle removable media such as compact disks (CD), flash memory cards, digital video disk (DVD), and the like. The computer system may also include a display device, one or more speakers, and a keyboard and / or controller, which can include a mouse, trackball, touch screen, voice-recognition device, or any other device that permits a system user to input information into and receive information from the computer system.
[0141] Some or all of the method steps may be executed by (or using) a hardware apparatus, like for example, a processor, a microprocessor, a programmable computer or an electronic circuit. In some embodiments, some one or more of the most important method steps may be executed by such an apparatus.
[0142] Depending on certain implementation requirements, embodiments can be implemented in hardware or in software. The implementation can be performed using a non-transitory storage medium such as a digital storage medium, for example a floppy disc, a DVD, a Blu-Ray, a CD, a ROM, a PROM, and EPROM, an EEPROM or a FLASH memory, having electronically readable control signals stored thereon, which cooperate (or are capable of cooperating) with a programmable computer system such that the respective method is performed. Therefore, the digital storage medium may be computer readable.
[0143] Some embodiments comprise a data carrier having electronically readable control signals, which are capable of cooperating with a programmable computer system, such that one of the methods described herein is performed.
[0144] Generally, embodiments can be implemented as a computer program product with a program code, the program code being operative for performing one of the methods when the computer program product runs on a computer. The program code may, for example, be stored on a machine readable carrier. Other embodiments comprise the computer program for performing one of the methods described herein, stored on a machine readable carrier.
[0145] In other words, an embodiment of the present disclosure is, therefore, a computer program having a program code for performing one of the methods described herein, when the computer program runs on a computer.
[0146] A further embodiment of the present disclosure is, therefore, a storage medium (or a data carrier, or a computer-readable medium) comprising, stored thereon, the computer program for performing one of the methods described herein when it is performed by a processor. The data carrier, the digital storage medium or the recorded medium are typically tangible and / or non-transitionary. A further embodiment of the present disclosure is an apparatus as described herein comprising a processor and the storage medium.
[0147] A further embodiment of the present disclosure is, therefore, a data stream or a sequence of signals representing the computer program for performing one of the methods described herein. The data stream or the sequence of signals may, for example, be configured to be transferred via a data communication connection, for example, via the internet.
[0148] A further embodiment of the present disclosure comprises a processing means, for example, a computer or a programmable logic device, configured to, or adapted to, perform one of the methods described herein.
[0149] A further embodiment of the present disclosure comprises a computer having installed thereon the computer program for performing one of the methods described herein.
[0150] A further embodiment according to the present disclosure comprises an apparatus or a system configured to transfer (for example, electronically or optically) a computer program for performing one of the methods described herein to a receiver. The receiver may, for example, be a computer, a mobile device, a memory device or the like. The apparatus or system may, for example, comprise a file server for transferring the computer program to the receiver. In some embodiments, a programmable logic device (for example, a field programmable gate array) may be used to perform some or all of the functionalities of the methods described herein. In some embodiments, a field programmable gate array may cooperate with a microprocessor in order to perform one of the methods described herein. Generally, the methods are preferably performed by any hardware apparatus.
[0151] It is further understood that the disclosure of several steps, processes, operations or functions disclosed in the description or claims shall not be construed to imply that these operations are necessarily dependent on the order described, unless explicitly stated in the individual case or necessary for technical reasons. Therefore, the previous description does not limit the execution of several steps or functions to a certain order. Furthermore, in further examples, a single step, function, process or operation may include and / or be broken up into several sub-steps, - functions, -processes or -operations.
[0152] If some aspects have been described in relation to a device or system, these aspects should also be understood as a description of the corresponding method. For example, a block, device or functional aspect of the device or system may correspond to a feature, such as a method step, of the corresponding method. Accordingly, aspects described in relation to a method shall also be understood as a description of a corresponding block, a corresponding element, a property or a functional feature of a corresponding device or a corresponding system.
[0153] The following claims are hereby incorporated in the detailed description, wherein each claim may stand on its own as a separate example. It should also be noted that although in the claims a dependent claim refers to a particular combination with one or more other claims, other examples may also include a combination of the dependent claim with the subject matter of any other dependent or independent claim. Such combinations are hereby explicitly proposed, unless it is stated in the individual case that a particular combination is not intended. Furthermore, features of a claim should also be included for any other independent claim, even if that claim is not directly defined as dependent on that other independent claim.
Claims
Claims1. A method for planning a trajectory for at least one actuator, the trajectory being based on a continuous spline of degree n within a planning time frame comprising a plurality of time intervals, the method comprising: providing a plurality of initial values including an initial value for a physical parameter of the actuator and a respective initial value for a first to an (n-1 J -th derivative of the physical parameter with respect to time at the beginning of the planning time frame; providing a trajectory objective for the planning time frame; providing a plurality of discrete trajectory constraints at a respective start and / or end of the time intervals, the trajectory constraints being related to the physical parameter and its first to / / -th derivative with respect to time; computing a piecewise constant function, each piece representing a constant value for the / / -th derivative of the physical parameter within the respective time interval, wherein the piecewise constant function is computed based on the trajectory objective, the plurality of discrete trajectory constraints, and the plurality of initial values; computing a continuous trajectory function in the form of a continuous spline of degree n for the planning time frame by integration calculations of the piecewise constant function; sampling the continuous trajectory function to obtain samples in accordance with a sampling time interval length Z; and controlling the actuator based on the samples of the continuous trajectory function.
2. The method of claim 1, wherein each time interval of the plurality of time intervals in the planning time frame comprises a pre-determined spline time interval length T.
3. The method of claim 2, wherein the continuous trajectory function corresponds to a mathematical spline comprising a plurality of spline states defined at respective multiples of the pre-determined spline time interval length T, whereina spline state at a time corresponding to a respective multiple is defined by the value for the physical parameter and the respective values for its first to (n-1 )-th derivatives, and wherein the spline state at a second time corresponding to a multiple [ / + 1] of the pre-determined spline time interval length T is computed based on the spline state at a first time corresponding to the previous multiple [7] and based on the value for the / / -th derivative between the first and second time.
4. The method of claim 1, wherein the plurality of initial values include an initial value for the physical parameter w(0) and an initial value for the first derivative of the physical parameter, w(1)(0), and optionally a respective initial value for one or more higher order derivatives of the physical parameter, and wherein computing the continuous trajectory function by integration calculations is performed for each interval of the piecewise constant function at least in part by applying the following formula:
5. The method of claim 1, wherein the physical parameter is a translational or rotational position, / ?, a velocity, v, or an acceleration, a, of the actuator or directly proportional thereto.
6. The method of claim 1, wherein the trajectory is based on a continuous spline of the third degree, wherein the physical parameter corresponds to a position, / ?, of the actuator and the first, second, and third derivatives of the physical parameter correspond to a velocity, v, an acceleration, a, and a jerk, j, of the actuator, respectively, and wherein the plurality of initial values include an initial value for the position, p(0), for the velocity, v(0), and for the acceleration, a(0), and wherein computing the continuous trajectory function by integration calculations is performed for each interval of the piecewise constant function at least in part by applying the following formula:
7. The method of claim 1, wherein the trajectory objective is encoded in terms of an objective function to be maximized or minimized and / or additional trajectory constraints.
8. The method of claim 2, wherein the pre-determined spline time interval length, T, is larger than the sampling time interval length, , and equivalent to a value = m- T. wherein m is a real number greater than one, and wherein the value for m is chosen based on a desired computation time.
9. The method of claim 1, wherein the samples are used to obtain a discrete trajectory function corresponding to the physical parameter, wherein the discrete trajectory function is formed with the physical parameter confined within predefined limits, and wherein values obtained by backward difference calculations approximating the first to / / -th derivatives based on the sampling time interval length T are confined within respective predefined limits.
10. The method of claim 9, wherein each value of the discrete trajectory function is constant within a time period equivalent to the sampling time interval length T.
11. The method of claim 9, wherein the plurality of discrete trajectory constraints comprises one or more discrete trajectory constraint equations to be enforced at multiples of the pre-determined spline time interval length T and respective ranges corresponding to a respective range of acceptable values for the physical parameter and its first to / / -th derivatives of the physical parameter at the multiples of the pre-determined spline time interval length T, wherein the respective ranges are enforced during computation of the piecewise constant function.
12. The method of claim 11, wherein the respective ranges corresponding to the physical parameter and the first to (z / -2)-th parameters each comprise shrinkage values A for further confining the respective range of acceptable values during computation of the piecewise constant function, wherein the shrinkage values A are determined based on the degree of the spline, and wherein the shrinkage values A are determined for confining the physical parameter within predefined values and implicitly confining all values obtained by backward differencecalculations approximating the first to / / -th derivatives based on the sampling time interval length T within respective predefined limits.
13. The method of claim 12, wherein the predefined limits are determined at least in part for safety -critical applications.
14. The method of claim 9, wherein the actuator is a motor and the discrete trajectory function is a motor signal corresponding to at least one of a motor position signal, a motor speed signal, or a motor torque signal, and wherein the motor is configured to control a robot or drone or a part of a robot or drone based on the motor signal.
15. The method of claim 1, wherein the actuator is used for controlling a robot or drone or a part of a robot or drone along one or more rotational and / or translational axes.
16. The method of claim 15, further comprisingGenerating sensor data by one or more sensors of a surrounding environment of the robot or drone and updating the discrete trajectory constraints, the trajectory objective, the initial conditions and / or the pre-determined spline time interval length r based on the sensor data for further iterations of computing the continuous trajectory function and / or the discrete trajectory function.
17. A program having a program code for performing the method according to any of the previous claims when the program is executed on a processor or a programmable hardware.
18. A non-transitory machine-readable medium having stored thereon a program having a program code for performing the method according to any of the previous claims when the program is executed on a processor or a programmable hardware.
19. An apparatus for planning a trajectory for at least one actuator, the trajectory based on a continuous spline of degree n within a planning time frame comprising a plurality of time intervals, the apparatus comprising interface circuitry configured to: receive a plurality of initial values including an initial value for a physical parameter of the actuator and a respective initial value for a first to an (n-1 J -th derivative of the physical parameter with respect to time at the beginning of the planning time frame; receive a trajectory objective for the planning time frame; andreceive a plurality of discrete trajectory constraints at a respective start and / or end of the time intervals, the trajectory constraints being related to the physical parameter of the actuator and its first to ( / / )-th derivative with respect to time; and further comprising processing circuitry configured to: compute a piecewise constant function, each piece representing a constant value for the / / -th derivative of the physical parameter within the respective time interval, wherein the piecewise constant function is computed based on the trajectory objective, the plurality of discrete trajectory constraints, and the plurality of initial values; compute a continuous trajectory function in the form of a continuous spline of degree n for the planning time frame by integration calculations of the piecewise constant function; sample the continuous trajectory function in accordance with a sampling time interval length; and control the actuator based on the samples of the continuous trajectory function.