simulation to proofs in c2e2
play

SIMULATION TO PROOFS IN C2E2 Parasara Sridhar Duggirala 1 A simple - PowerPoint PPT Presentation

SIMULATION TO PROOFS IN C2E2 Parasara Sridhar Duggirala 1 A simple (often the only) strategy Given start and target S Compute finite cover of initial set Simulate from the center 0 of each cover Bloat


  1. SIMULATION TO PROOFS IN C2E2 Parasara Sridhar Duggirala 1

  2. A simple (often the only) strategy π‘ˆ β€’ Given start and target S β€’ Compute finite cover of initial set β€’ Simulate from the center 𝑦 0 of each cover β€’ Bloat simulation so that bloated tube contains all trajectories from the cover 𝑦 0 β€’ Union = over-approximation of reach set β€’ Check intersection/containment with π‘ˆ β€’ Refine [Girard et al 2006], [Donze et al 2008],... β€’ How much to bloat? (obviously incomplete) β€’ How to handle mode switches? 2

  3. Discrepancy (Spirit of Loop Invariants) . Definition. 𝛾: ℝ 2π‘œ Γ— ℝ β‰₯0 β†’ ℝ β‰₯0 defines a discrepancy of the system if for any two states 𝑦 1 and 𝑦 2 ∈ π‘Œ , For any t, 1. |𝜊 𝑦 1 , 𝑒 βˆ’ 𝜊 𝑦 2 , 𝑒 | ≀ 𝛾 𝑦 1 , 𝑦 2 , 𝑒 and 2. 𝛾 β†’ 0 as 𝑦 1 β†’ 𝑦 2 𝑦 ≔ 0 invariant 𝑦 ≀ 10 until 𝑦 β‰₯ 10 do βˆ’πœŠ 𝑦 1 , 𝑒 𝑦 ≔ 𝑦 + 1 βˆ’π‘Š 𝜊 𝑦 1 , 𝑒 , 𝜊 𝑦 2 , 𝑒 βˆ’π›Ύ 𝑦 1 , 𝑦 2 , 𝑒 od 3

  4. Computing Discrepancy . If L is a Lipschitz constant for f(x,t) then |𝜊 𝑦 1 , 𝑒 βˆ’ 𝜊 𝑦 2 , 𝑒 | ≀ 𝑓 𝑀𝑒 𝑦 1 βˆ’ 𝑦 2 . 𝑦 = 𝐡𝑦 Lyapunov function 𝑦 π‘ˆ 𝑁𝑦 that proves exponenial If stability, then |𝜊 𝑦 1 , 𝑒 βˆ’ 𝜊 𝑦 2 , 𝑒 | ≀ 𝐿𝑓 𝛿𝑒 𝑦 1 βˆ’ 𝑦 2 where 𝐿 = πΊπ‘£π‘œπ‘‘(𝑁) Similar observation by [Deng et al 2013] What about Nonlinear Systems? 4

  5. Computing Discrepancy . If M is a contraction metric, that is, a positive definite matrix such that βˆƒπ‘ 𝑁 > 0 : 𝐾 π‘ˆ 𝑁 + 𝑁 𝐾 + 𝑐 𝑁 𝑁 β‰Ό 0, where J is the 2 ≀ Jacobian for f, then βˆƒπ‘™, πœ€ > 0 such that 𝜊 𝑦, 𝑒 βˆ’ 𝜊 𝑦 β€² , 𝑒 𝑙 𝑦 βˆ’ 𝑦 β€² 2 𝑓 βˆ’πœ€π‘’ [Lohmiller & Slotine β€˜98]. New algorithm: computes local discrepancy by estimating maximum eigenvalue of the Jacobian matrix over a neighborhood [Fan & Mitra 2014]. Inferring Contraction Metric from simulations [Balkan et al 2014] What next? 5

  6. Simulations+Annotation οƒ  Reachtubes π’•π’‹π’π’—π’Žπ’ƒπ’–π’‹π’‘π’(π’š 𝟏 , π’Š, 𝝑, 𝑼) of gives a sequence S 0 , … , 𝑇 𝑙 : 𝑒𝑗𝑏 𝑇 𝑗 ≀ πœ— & at any time 𝑒 ∈ [π‘—β„Ž, 𝑗 + 1 β„Ž] , solution 𝜊 𝑦 0 , 𝑒 ∈ 𝑇 𝑗 . π’”π’‡π’ƒπ’…π’Šπ’–π’—π’„π’‡ 𝑻, 𝝑, 𝑼 of 𝑦 = 𝑔 𝑦 is a sequence 𝑆 0 , … , 𝑆 𝑙 such that 𝑒𝑗𝑏(𝑆 𝑗 ) ≀ πœ— and from any 𝑦 0 ∈ 𝑇, for each time 𝑒 ∈ [π‘—β„Ž, (𝑗 + 1)β„Ž] , 𝜊 𝑦 0 , 𝑒 ∈ 𝑆 𝑗 . 𝑇 0 , … , 𝑇 𝑙 , πœ— 1 ← π‘€π‘π‘šπ‘‡π‘—π‘›(𝑦 0 , π‘ˆ, 𝑔) For each 𝑗 ∈ [𝑙] πœ— 2 ← sup 𝛾 𝑦 1 , 𝑦 2 , 𝑒 π‘’βˆˆπ‘ˆ 𝑗 ,𝑦,𝑦 β€² ∈𝐢 πœ€ (𝑦 0 ) 𝑆 𝑗 ← 𝐢 πœ— 2 𝑇 𝑗 6

  7. How to get completeness for hybrid systems? Track & propagate 𝑛𝑏𝑧 and 𝑛𝑣𝑑𝑒 fragments of reachtube 𝑛𝑣𝑑𝑒 𝑆 βŠ† 𝑄 𝒖𝒃𝒉𝑺𝒇𝒉𝒋𝒑𝒐 𝑺, 𝑸 = 𝑛𝑏𝑧 𝑆 ∩ 𝑄 β‰  βˆ… π‘œπ‘π‘’ 𝑆 ∩ 𝑄 = βˆ… π’‹π’π’˜π’ƒπ’”π’‹π’ƒπ’π’–π‘Έπ’”π’‡π’ˆπ’‹π’š(𝝎, 𝑻) = βŒ©π‘† 0 , 𝑒𝑏𝑕 0 , … , 𝑆 𝑛 , 𝑒𝑏𝑕 𝑛 βŒͺ , such that either β€² 𝑑 before it are must 𝑒𝑏𝑕 𝑗 = 𝑛𝑣𝑑𝑒 if all the 𝑆 π‘˜ β€² 𝑑 before it are at least may 𝑒𝑏𝑕 𝑗 = 𝑛𝑏𝑧 if all the 𝑆 π‘˜ and at least one of them is not must 7

  8. Hybrid Reachtubes: Guards & Resets π’π’‡π’šπ’–π‘Ίπ’‡π’‰π’‹π’‘π’π’•(𝝌) returns a set of tagged regions N. ∈ 𝑂 iff βˆƒ 𝑏, 𝑆 𝑗 such that 𝑆 β€² = 𝑆𝑓𝑑𝑓𝑒 𝑏 𝑆 𝑗 and: 𝑆′, 𝑒𝑏𝑕′ 𝑆 𝑗 βŠ† 𝐻𝑣𝑏𝑠𝑒 𝑏 , 𝑒𝑏𝑕 𝑗 = 𝑒𝑏𝑕 β€² = 𝑛𝑣𝑑𝑒 𝑆 𝑗 ∩ 𝐻𝑣𝑏𝑠𝑒 𝑏 β‰  βˆ…, 𝑆 𝑗 βˆ‰ 𝐻𝑣𝑏𝑠𝑒 𝑏 , 𝑒𝑏𝑕 𝑗 = 𝑛𝑣𝑑𝑒, 𝑒𝑏𝑕 β€² = 𝑛𝑏𝑧 𝑆 𝑗 ∩ 𝐻𝑣𝑏𝑠𝑒 𝑏 β‰  βˆ…, 𝑒𝑏𝑕 𝑗 = 𝑒𝑏𝑕′ = 𝑛𝑏𝑧 8

  9. Sound & Relatively Complete. Theorem. (Soundness). If Algorithm returns safe or unsafe, then 𝐡 is safe or unsafe. Definition Given HA 𝐡 = βŒ©π‘Š, 𝑀𝑝𝑑, 𝐡, 𝐸, π‘ˆ βŒͺ , an 𝝑 -perturbation of A is a new HA 𝐡′ that is identical except, Θ β€² = 𝐢 πœ— (Θ) , βˆ€ β„“ ∈ 𝑀𝑝𝑑, π½π‘œπ‘€ β€² = 𝐢 πœ— (π½π‘œπ‘€) (b) a ∈ A, 𝐻𝑣𝑏𝑠𝑒 𝑏 = 𝐢 πœ— (𝐻𝑣𝑏𝑠𝑒 𝑏 ) . A is robustly safe iff βˆƒπœ— > 0 , such that A’ is safe for 𝑉 πœ— upto time bound T, and transition bound N. Robustly unsafe iff βˆƒ πœ— < 0 such that 𝐡′ is safe for 𝑉 πœ— . Theorem. (Relative Completeness) Algorithm always terminates whenever the A is either robustly safe or robustly unsafe. 9

  10. C2E2 10

  11. Part II TWO APPLICATIONS Duggirala ∘ Wang ∘ Mitra ∘ Munoz ∘ Viswanathan (FM 2014) Huang ∘ Fan ∘ Meracre ∘ Mitra ∘ Kiwatkowska (CAV 2014) 11

  12. SAPA-ALAS Parallel Landing Protocol Ownship and Intruder approaching parallel runways with small separation ALAS (at ownship) protocol is supposed to raise an 𝑇𝐼 alarm if within T time units the Intruder can violate π‘¦π‘‘π‘“π‘ž safe separation based on 3 different projections 𝑇𝐺 Verify Alert β‰Ό 𝑐 Unsafe for different runway and aircraft 𝑇𝐢 π‘§π‘‘π‘“π‘ž scenarios Scenario 1. With xsep [.11,.12] Nm ysep [.1,.21] Nm, 𝜚 = 30 𝑝 𝜚 𝑛𝑏𝑦 = 45 o vy o = 136 Nmph, vy i = 155 Nmph Duggirala, Wang, Mitra, Munoz, Viswanathan FM 2014 12

  13. SAPA-ALAS Parallel Landing Protocol π΅π‘šπ‘“π‘ π‘’ 𝑗 = 𝑦 βˆƒ 𝑒 ∈ 0, π‘ˆ , π‘žπ‘ π‘π‘˜ 𝑗 𝑦, 𝑒 ∈ π‘‰π‘œπ‘‘π‘π‘”π‘“} , where π‘žπ‘ π‘π‘˜ 𝑗 defined as solution of ODE 𝑦 = 𝑕 𝑗 (𝑦, 𝑒) 𝑇𝐼 π‘¦π‘‘π‘“π‘ž Use simulations and annotations of 𝑕 𝑗 to compute 𝑇𝐺 𝑛𝑣𝑑𝑒 intervals when 𝑦 ∈ π΅π‘šπ‘“π‘ π‘’ 𝑗 𝑇𝐢 π‘§π‘‘π‘“π‘ž π΅π‘šπ‘“π‘ π‘’ β‰Ί 𝑐 𝑄 2 is satisfied by Reachtube πœ” if βˆ€ 𝐽 2 ∈ 𝑁𝑣𝑑𝑒 𝑄 2 βˆͺ 𝑁𝑏𝑧 𝑄 2 there exists 𝐽 1 ∈ 𝑁𝑣𝑑𝑒 π΅π‘šπ‘“π‘ π‘’ such that 𝐽 1 < 𝐽 2 βˆ’ 𝑐 π΅π‘šπ‘“π‘ π‘’ β‰Ί 𝑐 𝑄 2 is violated by Reachtube πœ” if βˆƒ 𝐽 2 ∈ 𝑁𝑣𝑑𝑒 𝑄 2 for all 𝐽 1 ∈ 𝑁𝑣𝑑𝑒 π΅π‘šπ‘“π‘ π‘’ βˆͺ 𝑁𝑏𝑧 π΅π‘šπ‘“π‘ π‘’ such that 𝐽 1 > 𝐽 2 βˆ’ 𝑐 Duggirala, Wang, Mitra, Munoz, Viswanathan FM 2013 13

  14. Real-time Alerting Protocol . Alert β‰Ό 4 Alert β‰Ό ? Running time Scenario Unsafe (mins:sec) Unsafe 6 False 3:27 2.16 7 True 1:13 – 8 True 2:21 – 6.1 False 7:18 1.54 7.1 True 2:34 – 8.1 True 4:55 – Sound & robustly completeness 9 False 2:18 1.8 10 False 3:04 2.4 C2E2 verifies interesting scenarios in 9.1 False 4:30 1.8 reasonable time; shows that false 10.1 False 6:11 2.4 alarms are possible; found scenarios where alarm may be missed 14

  15. Exploiting Modularity Module 1 Module 1 ? Module 2 Module 3 Module 2 Module 3 Module 5 Module 4 π‘Ÿ 𝑏 𝑦 1 = 𝑔 𝑏 (𝑦 1 , 𝑦 2 , 𝑦 3 ) Γ— 𝑀 𝑂 𝑦 2 = 𝑔 𝑐 (𝑦 2 , 𝑦 1 , 𝑦 3 ) 𝑦 3 = 𝑔 𝑑 (𝑦 3 , 𝑦 1 , 𝑦 2 ) π‘Ÿ 𝑑 π‘Ÿ 𝑐 15

  16. Input-to-State (IS) Discrepancy 𝑣(𝑒) 𝜊(𝑦, 𝑣, 𝑒) 𝑣 𝑦 𝑦 = 𝑔(𝑦, 𝑣) 𝑣′(𝑒) 𝜊(𝑦 β€² , 𝑣 β€² , 𝑒) 𝑦′ time time 𝑒 Definition. IS discrepancy is defined by 𝛾 and 𝛿 such that for any initial states 𝑦, 𝑦 β€² and any inputs 𝑣, 𝑣 β€² , 𝑒 𝛿 |𝑣 𝑑 βˆ’ 𝑣 β€² 𝑑 | 𝑒𝑑 |𝜊(𝑦, 𝑣, 𝑒) βˆ’ 𝜊 𝑦 β€² , 𝑣 β€² , 𝑒 | ≀ 𝛾(𝑦, 𝑦 β€² , 𝑒) + 0 𝛾 β†’ 0 as 𝑦 β†’ 𝑦′ , and 𝛿 β†’ 0 as 𝑣 β†’ 𝑣 β€² 16

  17. Reduced System 𝑁(πœ€ 1 , πœ€ 2 , π‘Š 1 , π‘Š 2 ) . 𝑦 = 𝑔 𝑁 𝑦 𝑦 = βŒ©π‘› 1 , 𝑛 2 , π‘‘π‘šπ‘™βŒͺ 𝑛 1 𝛾 1 πœ€ 1 , π‘‘π‘šπ‘™ + 𝛿 1 𝑛 2 𝑛 2 = 𝑔 𝑁 𝑦 = 𝛾 2 πœ€ 2 , π‘‘π‘šπ‘™ + 𝛿 2 𝑛 1 π‘‘π‘šπ‘™ 1 17

  18. Bloating with Reduced Model 𝑛 1 = 𝛾 1 πœ€, 𝑒 𝑦 1 = 𝑔 1 (𝑦 1 , 𝑣 1 ) +𝛿 1 (𝑛 2 , 𝑛 3 ) 𝑛 2 = 𝛾 2 πœ€, 𝑒 𝑛 3 = 𝛾 3 πœ€, 𝑒 +𝛿 2 (𝑛 1 , 𝑛 3 ) 𝑦 3 = 𝑔 3 (𝑦 3 , 𝑣 3 ) +𝛿 3 (𝑛 1 , 𝑛 2 ) 𝑦 2 = 𝑔 2 (𝑦 2 , 𝑣 2 ) 𝜊(𝑒) 𝑛(𝑒) πœ€ 𝑦 𝑛(𝑒) time time The bloated tube contains all trajectories start from the πœ€ -ball of 𝑦 . The over-approximation can be computed arbitrarily precise. 18

  19. Reduced 𝑁 gives effective Discrepancy of 𝐡 . Theorem. For any πœ€ = βŒ©πœ€ 1 , πœ€ 2 βŒͺ , π‘Š = βŒ©π‘Š 1 , π‘Š 2 βŒͺ and π‘ˆ π‘Š π‘†π‘“π‘π‘‘β„Ž 𝐡 𝐢 πœ€ 𝑦 , π‘ˆ βŠ† π‘’β‰€π‘ˆ 𝐢 𝜈 𝑒 (𝜊 𝑦, 𝑒 ) Theorem. For any Ο΅ > 0 there exists Ξ΄ = 〈δ 1 , Ξ΄ 2 βŒͺ such that π‘Š π‘’β‰€π‘ˆ 𝐢 𝜈 𝑒 (𝜊 𝑦, 𝑒 ) βŠ† 𝐢 πœ— (π‘†π‘“π‘π‘‘β„Ž 𝐡 (𝐢 πœ€ 𝑦 , π‘ˆ) Here 𝜈 𝑒 is the solution of 𝑁(πœ€ 1 , πœ€ 2 , π‘Š 1 , π‘Š 2 ) . Huang & Mitra, HSCC 2013 19

  20. Pacemaker + Cardiac Network . Action potential remains in specific range No alternation of action potentials Nodes Thresh Sims Run time (s) Property 3 2 16 104.8 TRUE 3 1.65 16 103.8 TRUE 5 2 3 208 TRUE 5 1.65 5 281.6 TRUE 5 1.5 NA 63.4 FALSE 8 2 3 240.1 TRUE 20 8 1.65 73 2376.5 TRUE

Recommend


More recommend