cis 4930 6930 principles of cyber physical systems
play

CIS 4930/6930: Principles of Cyber-Physical Systems Chapter 4: - PowerPoint PPT Presentation

CIS 4930/6930: Principles of Cyber-Physical Systems Chapter 4: Hybrid Systems Hao Zheng Department of Computer Science and Engineering University of South Florida H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 1 / 19 Hybrid Automata


  1. CIS 4930/6930: Principles of Cyber-Physical Systems Chapter 4: Hybrid Systems Hao Zheng Department of Computer Science and Engineering University of South Florida H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 1 / 19

  2. Hybrid Automata H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 2 / 19

  3. Timed Automaton Model of a Thermostat h H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 3 / 19

  4. Possible Execution of the Timed Thermostat Model τ ( t ) ... t (a) 20 t 1 t 1 + T h h ( t ) 1 ... t (b) 0 s ( t ) T c ... t (c) 0 H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 4 / 19

  5. Higher Order Dynamics: Bouncing Ball t t 1 t 2 t t 1 t 2 H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 5 / 19

  6. Higher Order Dynamics: Bouncing Ball t t 1 t 2 t t 1 t 2 y ( 0 ) = h 0 y ( t ) ˙ = − gt t y ( τ ) d τ = h 0 − 1 2 gt 2 ˙ y ( t ) = y ( 0 )+ � 0 H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 5 / 19

  7. Higher Order Dynamics: Bouncing Ball t t 1 t 2 t t 1 t 2 y ( 0 ) = h 0 y ( t ) ˙ = − gt t y ( τ ) d τ = h 0 − 1 2 gt 2 ˙ y ( t ) = y ( 0 )+ � 0 y ( t 1 ) = 0 , h 0 − 1 2 gt 2 � 1 = 0 , thus t 1 = 2 h 0 / g H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 5 / 19

  8. Higher Order Dynamics: Bouncing Ball t t 1 t 2 t t 1 t 2 At t 1 , y ( t ) 1 = 0. The bump transition takes place with new speed − a ˙ y ( t 1 ) . H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 6 / 19

  9. Higher Order Dynamics: Bouncing Ball t t 1 t 2 t t 1 t 2 At t 1 , y ( t ) 1 = 0. The bump transition takes place with new speed − a ˙ y ( t 1 ) . y ( t ) = − a ˙ ˙ y ( t 1 ) − gt ( t > t 1 ) H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 6 / 19

  10. Sticky Masses Example y 1 (t) y 2 (t) Displacement of Masses 3.0 y 1 (t) y 2 (t) 2.5 2.0 1.5 1.0 0.5 0.0 0 5 10 15 20 25 30 35 40 45 50 time H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 7 / 19

  11. Sticky Masses Example System Dynamics • Let p 1 and p 2 be neutral places of the two springs. • The forces due to the springs are zero. • Suppose the spring force is proportional to the displacement. • When apart , forces due to the springs: = k 1 ( p 1 − y 1 ( t )) F 1 = k 2 ( p 2 − y 2 ( t )) F 2 • Under Newton’s 2nd Law (i.e., F = ma ): ¨ y 1 ( t ) = k 1 ( p 1 − y 1 ( t )) / m 1 ¨ y 2 ( t ) = k 2 ( p 2 − y 2 ( t )) / m 2 H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 8 / 19

  12. Sticky Masses Example System Dynamics • When stuck together , pulled in opposite directions by two springs: = F 1 + F 2 F = m 1 + m 2 m y ( t ) = y 1 ( t ) = y 2 ( t ) y ( t ) = k 1 p 1 + k 2 p 2 − ( k 1 + k 2 ) y ( t ) ¨ m 1 + m 2 H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 9 / 19

  13. Sticky Masses Example System Dynamics • Guard on the apart to together transition is: y 1 ( t ) = y 2 ( t ) . • Initial velocity of combined mass, ˙ y ( t ) , set by conservation of momentum: ˙ y 1 ( t ) m 1 + ˙ ˙ y ( t )( m 1 + m 2 ) = y 2 ( t ) m 2 y 1 ( t ) m 1 + ˙ ˙ y 2 ( t ) m 2 ˙ y ( t ) = ( m 1 + m 2 ) • Guard on the together to apart transition is: F 2 − F 1 = ( k 1 − k 2 ) y ( t )+ k 2 p 2 − k 1 p 1 > s where s represents the stickiness of the two masses. • This transition occurs when the right-pulling force, k 2 ( p 2 − y ( t )) , exceeds the left-pulling force, k 1 ( p 1 − y ( t )) , by the stickiness s . H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 10 / 19

  14. Hybrid System Model for Sticky Masses H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 11 / 19

  15. Control Systems • A control system includes: • The plant - the physical process that is to be controlled. • The environment. • The sensors. • The controller. • The controller has two levels: • Supervisory control determines the mode transition structure. • Low-level control determines the time-based inputs to the plant. • Supervisory controller determines the strategy while the low-level controller implements the strategy. • Hybrid systems are ideal for modeling control systems. H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 12 / 19

  16. Automated Guided Vehicle (AGV) Example AGV global track coordinate frame H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 13 / 19

  17. AGV Dynamics • The speed is u ( t ) is restricted to: 0 ≤ u ( t ) ≤ 10 mph • The angular speed is ω ( t ) is restricted to: − π ≤ ω ( t ) ≤ π radians/second • Position is ( x ( t ) , y ( t )) ∈ R 2 and angle is θ ( t ) ∈ ( − π , π ] . • The motion of the AGV is defined by the differential equations: x ( t ) ˙ = u ( t ) cos θ ( t ) ˙ y ( t ) = u ( t ) sin θ ( t ) ˙ θ ( t ) = ω ( t ) H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 14 / 19

  18. Determining the Error in Position track photodiode ATV H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 15 / 19

  19. Hybrid System Model for the AGV Example H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 16 / 19

  20. A Trajectory for the AGV Example track right straight left straight initial position H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 17 / 19

  21. AGV Example Summary • Plant is the differential equations governing the AGV motion. • Environment is the closed track. • Sensor is e ( t ) which gives the AGV position relative to the track. • Supervisory controller are the four modes and guards to switch b/w them. • Low-level controller is the specification of inputs to the plant u and ω . H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 18 / 19

  22. Concluding Remarks • Hybrid systems are a bridge between state-based and time-based models which allow for the description of real-world systems. • Discrete transitions are used to change the mode of operation. • These transitions are taken when guards are satisfied that include both inputs and predicates on continuous variables. • The change in mode may result in a change in continuous behavior. • Analysis of hybrid systems is complicated by the fact that both state-based and time-based analysis is required. H. Zheng (CSE USF) CIS 4930/6930: Principles of CPS 19 / 19

Recommend


More recommend