A New Concept on Automatic Parking of an Electric Vehicle C. CAMUS P. COELHO J.C. QUADRADO Instituto Superior de Engenharia de Lisboa Rua Conselheiro Emídio Navarro PORTUGAL Abstract: - A solution to perform an automatic parking manoeuvre for an electric vehicle is presented in this paper. A mathematical dnamic model is described considering the initial and final position of the vehicle in each point of the desired trajector controlled b the vehicle s velocit and steering angle. The problem of obstacle detection is also considered to avoid collision and a discrete trajector generation is formulated based on the initial and destination position of the vehicle. Ke-Words: - Electrical vehicle, automatic parking, trajector generation 1. Introduction An intelligent vehicle should have the abilit to handle information (from sensors), plan and eecute vehicular motion control in a similar wa as done b a human driver. Parking is certainl one of the vehicular motion controls that present some challenge. To properl park a car into the space between two parked cars (parallel parking) is quite a subtle task that needs human epertise. There is several research work on automated guided vehicles with focus in different aspects. Basicall all the eisting solutions use vision [1] or ultrasonic sensors [] to detect parking slots and obstacles, followed b planning and eecution of a designed motion series. Some algorithms were suggested for the purpose of parallel automatic parking [3]. The relationship between the current position and the desired position ma have an infinit number of combinations. The purpose of this paper is to find a reasonable solution for the parallel parking problem. To solve this problem we begin to establish a vehicle s dnamic model and the corresponding inverse dnamics model, then we made a few obstacle detection considerations and we finalize with a model for trajector generation.. The Automatic Parking Problem In this paper we propose to find a solution to perform an automatic parking manoeuvre b an electric vehicle. To do so the following data is required: The position and orientation of the initial and final points and the position of obstacles around it. An algorithm to describe a discrete trajector must be found for the vehicle to be driven and an obstacle detection algorithm must be developed to avoid collision when the vehicle is driven through the defined trajector to the final parking place. 3. Dnamic Model of the Vehicle To establish the vehicle position we define a two dimension cartesian sstem (, ) and a variable for orientation. Thus the geographic position of the vehicle is defined b a combination of position and orientation P(,, ). The direction is taken counter-clockwise from the -ais, accordingl to figure 1. (orientation coordinate) (, ) (position coordinates) Fig.1 Coordinates position sstem The dnamic model simulates the vehicle s behaviour establishing each new position P(,, ) based in the previous position P( 0, 0, 0 ) and the
commands applied to the vehicle (Figure ). Those commands are velocit υ and steering angle θ. 0 Dnamic 0 Model 0 υ Fig. Dnamic model for the new vehicle s position The resulting function is described in (1). P(,, ) = f ( 0, 0, 0, υ, θ) (1) For this dnamic model it is assumed that the vehicle is a rigid bod of length l, width is ignored as well as mass an all the eisting friction forces (Figure 3). θ In cartesian components,, the equation assumes (3). = 0 + υ t + ½ a t = 0 + υ t + ½ a t (3) As the speed and acceleration have the same orientation as the vehicle the can be written in terms of coordinates, i.e. for velocit (4) and for acceleration (5). υ = υ cos υ = υ sen (4) a = a cos a = a sen (5) The resulting mechanical equations are described in (6). = 0 + υ cos t + ½ a cos t = 0 + υ sen t + ½ a sen t (6) Being the acceleration defined in (7) a = dυ/dt (7) l Considering small time intervals we have (8) a = υ / t = (υ-υ 0 )/ t (8) Fig.3 Simplified vehicle model Considering the general equation of variable straight movement of a point presented in (), where r is the new position vector; r 0 is the initial position vector; υ 0 is the initial speed vector applied to the point; a is the acceleration vector applied to the point. r = r 0 + υ 0 t + ½ a t () The vehicle in cartesian components () is presented in figure 4. 0 υ 0 Fig.4 Components of the vehicle Thus, in a discrete form, for time intervals, the model becomes in terms of position coordinates (9) = 0 +υ cos t+½ (υ-υ 0 )cos t = 0 +υ sen t+½ (υ-υ 0 )sen t (9) Regarding the orientation coordinate we have equation (10). d / dt = υ θ / l (10) In the discrete form (10) becomes (11), where l is the vehicle s length; υ is the speed applied to the car; is the orientation coordinate of the vehicle related to the referential ; θ is the steering angle that defines the direction applied to the car. = 0 + υ θ / l t (11) The dnamic model considered for the vehicle is, in its discrete form, defined b (1), where ( 0, 0, 0 ) is the previous position of the vehicle; (,, ) is the new position of the vehicle; (υ,θ) are the commands applied to the vehicle.
= 0 υ θ / l t = 0 + υ cos t + ½ (υ-υ 0 ) cos t (1) = 0 + υ sen t + ½ (υ-υ 0 ) sen t 4. Inverse Dnamic Model The mathematical model that represents the vehicle s dnamic behaviour is defined b (1). Figure 5 describes the inverse dnamic model considered. 5. Obstacle Detection Considerations Detection of obstacles is performed avoiding them to get inside a securit zone established around the vehicle. An kind of obstacle can be described b a set of small line segments defined b a set of pair coordinates. For the parallel parking action the normal situation is presented in figure 7. Desired Commands position to appl Inverse υ Dnamic Model θ 0 0 0 Current position Fig.5 Inverse dnamics model of the vehicle According to Figure 5, the inverse model can be formulated as the commands (velocit and steering angle) that should be applied to the vehicle so that it goes from an initial position P( 0, 0, 0 ) to a final one P(,, ) (13). P(υ, θ) = f (,,, 0, 0, 0 ) (13) Solving (1) in order to υ and θ, the resulting sstem s equations is (14). Fig.7 Obstacles contours Once the environment where the vehicle stands is defined b the line segments designed with outside contour points of obstacles we should take into account that this obstacles stand in a constant referential that we call obstacles referential ref Obstacles (). When the vehicle moves it performs a translation and a rotation movement and the vehicle s referential ref vehicle (uv) changes as related to obstacles referential (Figure 8). θ = ( - 0 ) l / (υ t) (14) υ = /3 [(- 0 )+(- 0 )]/[(cos+sen) t] + υ 0 /3 v The resulting position control analtical model of the vehicle can be epressed in terms of the coordinates, and and b considering the dnamic and inverse dnamics model (Figure 6). u Desired Commands Position Position to appl Obtained ref υ Inverse ref Dnamic Dnamics ref θ Model Model 0 0 0 Fig. 6 Block diagram of the vehicle s model Fig.8 Translation and rotation of ref vehicle (uv) When the vehicle stands at its initial position the two referentials coincide. When the car begins its parking manoeuvre its referential changes b translation and rotation movements. To describe the vehicle position in terms of the obstacles referential we convert the vehicle s referential into the obstacles referential b a mapping matri (15)[4].
- - cos -sen a P = sen a cos a P uv (15) 0 0 1 - - In graphical terms this situation corresponds to figure 9. v u Fig.9 Representing the car in ref Obstacles () It is also possible to convert a point at the obstacles referential into the cars referential b the transform matri (16). The equation of the line segment defined b two points is presented in (17). 0 = m (- 0 ) (17) m = ( 1-0 ) / ( 1-0 ) The non-centred equation of the ellipse is given b (18), where (f, g) is the centre and (r a, r b ) are the ellipse radius. (-f) /r a + (-g) / r b The resulting sstem is (19). = 1 (18) 0 = m (- 0 ) (19) (-f) /r a + (-g) / r b = 1 The solution of this equations sstem (19) are the points P 1 and P where the line intercepts the ellipse. If there isn t a real solution it means that the do not intercept. If the solution is real then we must verif if it belongs to the line segment (P 3 P 4 ) of the obstacle contour (Figure 11). - - -1 cos -sen a P uv = sen a cos a P (16) 0 0 1 - - Obstacle P 1 P Intersection points not to consider If the obstacles are included into the vehicle s referential it is possible to test if the enter at the vehicles securit zone. The securit zone considered has the geometric form of an ellipse (Figure 10). In figure 10 the ellipse option was taken considering the easier wa to represent the car s polnomial shape. Ellipse Circumference Line segments (1 equation) (1 equation) (4 equations) P 3 P 4 Line without intersection Fig.11 Eample of obstacle without intersection In the end is also necessar to verif in which of the four quadrants, in the vehicle s referential, the interception points are and ignore those that are outside the vehicle s direction. Fig. 10 Possible geometric forms of the securit zone With this option and using onl one equation (ellipse) is possible to assure that an obstacle that intersects the securit zone is detected. This can be done b the constant verification of the intersection of a line segment with an ellipse. 6. Trajector generation for automatic parking For the automated vehicle parking it is necessar to define a trajector that the car must perform in order to reach the desired final position. As far as the final desired position P f (,,) is established, the set of points in plan where the car should drive to reach its objective, should be calculated.
The trajector is constructed b a set of points, with the coordinates of the several positions of the vehicle, referenced to the obstacles referential. The solution to find the correct trajector for automatic parking is obtained considering that the path connecting initial and final positions of the vehicle is approimatel two circumference arcs (Figure 1). Initial position (0,0,90) Trajector Fig.1 - Trajector for automatic parking Final position ( f, f,90) For the eample in Figure 1, the initial position of the parallel parking manoeuvre is P i (0,0,90), where the two referential sstems, the vehicle s and the obstacle s, coincide. The final position desired is P f ( f, f, 90). The vehicle should end its parking manoeuvre in a parallel position. First we must determine the characteristics of the circumferences whose arcs the trajector segments belong to (Figure 13). P i (0,0,90) C 1 r 1 r C Pf i ( f, f,90) points P i and P f and the line formed with points C 1 and C (Figure 14). P i (0,0,90) C 1 P m ( m, m, m ) C P f ( f, f,90) Fig.14 Interception point between C 1 and C The circumferences equations are described in (1), where c 1,c 1, c,c are the circumference centres; r 1,r are the radius;, the circumference interception point (P m ( m, m, m ) in Figure 14). (-c 1 ) +(-c 1 ) = r 1 (-c ) +(-c ) = r In the present eample () is verified (1) r 1 = r = r c 1 = r c 1 = 0 () c,= f Solving the equations sstem (3) we find r and the coordinate c. (-r) +() = r (-c ) +(- f ) = r (3) With the circumference equations established is possible to compose the trajector. It is necessar now to calculate the trajector points that belong to these circumferences. A possible method is to calculate the angle λ, between the line that joints the vehicle s initial and final position points and the - ais (Figure 15). Fig.13 Circumferences centre and radius The centres of the circunference and radius are described in (0) C 1 (+ r 1, 0 ), C ( f - r, f ) if P f {1 st Q,4 th Q} C 1 (- r 1, 0 ), C ( f + r, f ) if P f { nd Q,3 rd Q} (0) The point where the circumferences touch is the intersection point of the straight line formed with c 1,c 1 λ c, c Fig.15 Trajector calculation
The angle in figure 15 is given b (4). tg λ = (c 1 -c )/(c 1 -c ) (4) The limit of angle variation of the parametric equations of a circumference in order to get the trajector points, can also be determined. Based in the parametric equations (5) and the angle variation according the final point s quadrants, the trajector set points can be obtained. = C + r cos δ = C + r sen δ (5) If P f belongs to the 1 st Quadrant: Pc1: 180 < δ < 180-λ with δ< 0 Pc: λ < δ < 0 with δ< 0 If P f belongs to the nd Quadrant: Pc1: 0 < δ < λ with δ > 0 Pc: 180-λ < δ < 180 with δ< 0 If P f belongs to the 3 rd Quadrant: Pc1: 0 < δ < -λ with δ < 0 Pc: 180-λ < δ < 180 with δ> 0 If P f belongs to the 4 th Quadrant: Pc1: 180 < δ < 180+λ with δ > 0 Pc: λ < δ < 0 with δ< 0 The previous points are defined in terms of the position coordinates through the solution of the referred parametric equations and in terms of the orientation coordinate through the sum (or subtraction due to vehicle direction) of 90 to the δ angle used to calculate the position coordinates. The vehicle s orientation is for each trajector point perpendicular to the curve s radius as it shows in the figure 16. 7. Conclusions In this paper, we proposed a solution to the parallel parking problem finding the discrete trajector through circumference arcs. The solution is ver simple and eas to appl when compared to other solutions. A spine parking solution could also be performed or automatic parking with several tries in smaller space. The obstacles detection algorithm computes the coordinates of a possible collision. The elliptical securit zone has simple mathematical representation and can var with the vehicle s speed. The sstem was implemented with successful results. Future work will be done including sonar based sensors that allow a direct obstacle detection and measurement. References: [1] Jin Xu, Guang Chen and Ming Xie, Vision- Guided Automatic Parking for Smart Car. Proceedings of IEEE Intelligent Vehicles Smposium, Dearborn, MI, USA, October 000. [] C. Laugier and F. Thierr, Sensor-based control architecture for a car-like vehicle. Proceedings of IEEE International Conference on Intelligent Robots and Sstems, 1998. [3] Jin Xu, Ming Xie and Jiangzhou Lu, Duple Motion Planning Strateg for Automatic Manoeuvre of Vehicle in Comple Environment. 001 IEEE Intelligent Transportation Sstems Conference Proceedings, August 001. [4] Industrial Robotics: Technolog, Programming and Aplications; M.P.Grover, M. Weiss, R.N. Odre; Mc Graw-Hill International Editions, Singapore, 1986. P i C 1 λ P f C Fig.16 - Orientation angle calculation