• Non ci sono risultati.

Feasibility problems, that could arise when real-time scaling systems are used, can be explained with the aid of Fig. 2.4, that shows some hypothetical scenarios in which feasibility is lost with certainty. In all the considered cases, ˙uis supposed to be posi-tive, but a similar analysis can be performed to account for problems that could arise when ˙u< 0.

Firstly, consider Case a, in which ˙u reaches R+. Owing to the continuity of ¨u, the velocity cannot be immediately reduced, so that the constraint is certainly vio-lated. Short-time constraints violations do not alter the system performances – motors slightly violate the maximum speed for brief periods – but the situation can become critical if, as shown in Fig. 2.4, ¨u has reached its lower bound S: ˙u decrements slowly, constraints are violated for long periods, and the system stability is endan-gered. A similar situation occurs in Case b, but, in this second case, the constraint violation is caused by the saturation on...

u .

2.4. Feasibility problems 57

t

t

t

a b

c R+

R -S+

S -U+

U -u.

u..

...u

Figure 2.4: Possible constraints violations.

An even worst situation occurs in Case c:...

u reaches U+, so that the acceleration limit cannot be fulfilled. Unfortunately, the acceleration constraint is correlated with the maximum admissible motor torques: In case of violations motors saturate, thus the controller performances worsen or, in the worst cases, stability is lost.

Critical situations are evidently caused by the proximity to zero of the accelera-tion and of the jerk bounds, thus the obvious soluaccelera-tion is based on a proper relaxaaccelera-tion of such bounds. In order to understand how it can be done, in the following is briefly resumed the equations that are used for the constraints evaluation.

Equations (2.33)–(2.35) confirm that, for any point along the path, the equivalent constraints are influenced by the status of motion of the system, i.e., by ˙uand ¨u. Thus, by acting on ˙uand ¨u, it is possible to modify the longitudinal bounds.

In particular, considering first ¨uand Case a of Fig. 2.4, in the following is ana-lyzed the relation between the bounds defined in Table 2.1 and the feasibility prob-lems. As previously reported, problems are caused by values of S, and, in turn, of

βi and µ

i, that are too close to zero. Terms µ

i approach zero if terms fi0 assume large values or if products fi002dominate over ¨q

i (or over ¨qi). In the first case noth-ing can be done, since terms fi0 only depend on the path shape. In the second case, an appropriate reduction of ˙ucan produce an enlargement of the bounds. A similar consideration holds for terms β

i: No action can be taken if their approach to zero is caused by ˆa3i or by ˆa1i. Conversely, bearing also in mind (2.24), if problems derive from the amplitude of ˆa2i( ˙u), positive effects can, again, be obtained by reducing ˙u.

In both cases, the reduction of ˙ucan also be justified through physical reasons. Terms βi are directly correlated to (2.1), while terms µ

i descend from (2.4): By decreasing

˙

u, motor torques and accelerations are certainly reduced, so that constraint violations are less probable.

Similar conclusions can be drawn for Cases b and c: The modules of S+, S, U+, and Ugenerally increase if ˙uis decreased, e.g., by properly downscaling R+, when

˙

u> 0, or R, when ˙u< 0. It is worth to mention that productivity reasons suggest to avoid global reductions of R+(or of R) that, conversely, should be limited to the sole critical points. In the following §2.4.1 and §2.4.2 are reported strategies that properly scale down R+or Rin order to limit feasibility problems that could afflict the TSS.

2.4.1 Local scaling of R+ and R

Several techniques have been tested in order to properly scale R+ and R. The best performances in terms of promptness and reliability have been achieved by means of Algorithm 1. It is executed at the same sample rate of the main control loop and it is based on a simple threshold approach. Three different thresholds, namely S, U , and Ue, have been chosen respectively on S, U+, and U. If one of such thresholds is violated, i.e., if one of the three bounds approaches zero, R+ is posed equal to zero, so that, necessarily, ˙udecreases. This causes an enlargement of the acceleration and of the jerk bounds, so that the original limit R+is restored in a short time: As shown in §2.5, sufficiently large bounds on the acceleration and the jerk can be achieved by adopting an upper velocity constraint that properly choppers between 0 and R+.

Thresholds S, U , and eU must be properly chosen. In order to achieve the best performances, the actual shapes of R+, R, S+, and Sshould be known in advance.

2.4. Feasibility problems 59

Algorithm 1 Downscale R+ and R when the acceleration and jerk limits are not sufficient to guarantee the fulfillment of the velocity bounds.

1: Evaluate R+

2: if ( ˙u> 0) andh

(|S| < S) or (U+< U ) or (|U| <U)e i then

3: R+= 0

4: end if

5: Evaluate R

6: if ( ˙u< 0) andh

(S+< S) or (|U| < U) or (U+< eU)i then

7: R= 0

8: end if

For example, in Case a of Fig. 2.4, the knowledge of the slope of R+could be used to properly scale bound S. Unfortunately, longitudinal bounds depend on the system status and, consequently, they are only roughly known, being influenced by many external factors. For this reason, S, U , and eU are chosen with a heuristic rule. In general, sufficiently good performances are verified by adopting an initial value of S that is one order of magnitude larger than the average longitudinal velocity, while U and eU should be two orders of magnitude larger. Tunings can be later refined on the actual plant.

It is worth to remark that the technique here proposed solves many of the issues generated by an improper choice of the longitudinal time-law, but, since bounds S+, S, U+, and U are also influenced by terms that do not directly depend on ˙u, fea-sibility cannot be guaranteed with certainty: The system can still enter into regions from which the feasibility cannot be maintained. The convergence toward unfeasible regions is pointed out by a sudden shrinkage of the feasible intervals: U+ and U approach each other (and/or the same happens to S+ and S), so that it is no more possible to respect the given constraints. If this happens, the user must choose a dif-ferent time-law or, alternatively, he must globally scale down R+ and R. In case of cyclic time-laws, a completely automatic approach, like the one that is proposed in the next section, can be adopted.

2.4.2 Global scaling of R+ and R

If the local approach, presented in §2.4.1, is not able to solve all feasibility issues, remaining problems can be handled by further scaling the equivalent velocity bounds according to the following equations

Re+= ψ R+, Re= ψ R,

where ψ ∈ [0.1, 1]. Scaling factor ψ applies to the whole trajectory, so it cannot be chosen too small in order to guarantee a proper tracking of ud(t).

Algorithm 2 Evaluation of the error signal used by the global bound-scaling system.

Mindicates the number of samples occurring in a period T , while ejis the error signal at time t = jT .

1: e˜= ∞; e = ∞

2: for i = 1 to M do

3: if ˙ui> 0 then

4: ei= min{Ui+−U, Ui

−Ue}

5: else

6: ei= min{

Ui

−U,Ui+−Ue}

7: end if

8: if ei< ˜ethen

9: e˜= ei 10: end if

11: ei= min{Si+− S, Si

− S}

12: if ei< e then

13: e= ei 14: end if

15: end for

16: ej= [sign(e) & sign( ˜e)] |e ˜e|

The selection of ψ can be automated in case of cyclic trajectories by adopting a strategy that maximizes its value compatibly with the assigned constraints: If the local

Documenti correlati