a new constraint based framework for qualitative reasoning
play

A New Constraint-based Framework for Qualitative Reasoning - PowerPoint PPT Presentation

A New Constraint-based Framework for Qualitative Reasoning Krzysztof Apt CWI & University of Amsterdam (Joint work with Sebastian Brand) Constraint-based Qualitative Reasoning p.1/26


  1. A New Constraint-based Framework for Qualitative Reasoning Krzysztof Apt CWI & University of Amsterdam (Joint work with Sebastian Brand) Constraint-based Qualitative Reasoning – p.1/26

  2. � � � � � � � � � � Outline Qualitative (spatial) reasoning (QR) Constraint programming (CP) Mapping QR problems to CP Evolving qualitative scenarios Case study Constraint-based Qualitative Reasoning – p.2/26

  3. Qualitative Reasoning Constraint-based Qualitative Reasoning – p.3/26

  4. Qualitative Spatial Reasoning Example Two houses are connected by a road. The first house is surrounded by its garden or is adjacent to its boundary while the second house is surrounded by its garden. What can we conclude about the relation between the second garden and the road? garden 1 house 1 road house 2 garden 2 Constraint-based Qualitative Reasoning – p.4/26

  5. 8 Spatial Relations B B B A A A disjoint(A,B) equal(A,B) meet(A,B) A A A B B B covers(A,B) contains(A,B) coveredby(B,A) overlap(A,B) inside(B,A) Constraint-based Qualitative Reasoning – p.5/26

  6. The composition table for RCC8 disjoint meet equal inside coveredby contains covers overlap disjoint RCC8 disjoint disjoint disjoint disjoint disjoint disjoint disjoint meet meet meet meet inside inside inside inside coveredby coveredby coveredby coveredby overlap overlap overlap overlap meet disjoint disjoint meet inside meet disjoint disjoint disjoint meet meet coveredby inside meet meet contains equal overlap inside covers coveredby coveredby overlap covers overlap overlap equal disjoint meet equal inside coveredby contains covers overlap inside disjoint disjoint inside inside inside RCC8 disjoint disjoint meet meet inside inside coveredby coveredby overlap overlap coveredby disjoint disjoint coveredby inside inside disjoint disjoint disjoint meet coveredby meet meet meet contains equal overlap covers coveredby coveredby overlap covers overlap overlap contains disjoint contains contains equal contains contains contains contains meet covers inside covers covers contains overlap coveredby overlap overlap covers contains overlap covers overlap covers disjoint meet covers inside equal contains contains contains meet contains coveredby coveredby covers covers contains covers overlap covers overlap covers overlap overlap overlap overlap disjoint disjoint overlap inside inside disjoint disjoint RCC8 meet meet coveredby coveredby meet meet contains contains overlap overlap contains contains covers covers covers covers overlap overlap overlap overlap Constraint-based Qualitative Reasoning – p.6/26

  7. � � � � � � Reasoning using RCC8 In total 193 entries. They summarize all possibilities. For example: contains(A,B) , covers(B,C) implies contains(A,C) . Using this table we can conclude that covers(garden2,road) or overlap(garden2,road) . Constraint-based Qualitative Reasoning – p.7/26

  8. � � � � � � � � � � � � Examples of Qualitative Reasoning Spatial relations (RCC8) (Egenhofer ’91, Randell, Cui & Cohn ’92). Temporal relations (Allen ’83): 13 temporal relations between intervals: before , overlaps , . . . Cardinal directions (Frank ’92, Ligozat ’98): North , NorthWest , . . . Absolute directions (Skiadopoulos & Koubarakis ’01): Example: in Hong Kong, when facing Hainan Beijing is to the right. Relative size (Gerevini & Renz ’02): <, = , > , . . . Constraint-based Qualitative Reasoning – p.8/26

  9. Constraint Programming Constraint-based Qualitative Reasoning – p.9/26

  10. � � � � � � � � � � Constraint Programming An approach to programming in which the programming process is limited to generation of requirements (constraints); it results in a constraint satisfaction problem (CSP), solution of these requirements by general methods dealing with search space reduction (notably constraint propagation), or specialized methods for domain specific problems (constraint solvers), or their combination. Constraint-based Qualitative Reasoning – p.10/26

  11. � � � � Solving CSPs Search – Divide into subproblems. For example: split a domain of a variable. Constraint Propagation – Transform a CSP to a simpler but equivalent one. For example: (repeatedly) remove inconsistent values from a variable domain. Constraint-based Qualitative Reasoning – p.11/26

  12. Mapping QR problems to CP Constraint-based Qualitative Reasoning – p.12/26

  13. � � � � � � � � � � � � � � � � � � � � � � � � Example: the gardens puzzle 5 spatial objects: H1 (house 1), G1 (garden 1), H2 , G2 , R . 10 variables with domains, each associated with an ordered pair of spatial objects: Q [ H1 , G1 ] ∈ { inside,coveredby } , Q [ H2 , G2 ] ∈ { inside } , Q [ H1 , H2 ] ∈ { disjoint } , Q [ H1 , R ] ∈ { meet } , Q [ H2 , R ] ∈ { meet } , Q [ G1 , G2 ] ∈ { disjoint,meet } , Q [ H1 , G2 ] ∈ { disjoint,meet } , Q [ G1 , H2 ] ∈ { disjoint,meet } , Q [ G1 , R ] ∈ RCC8 , Q [ G2 , R ] ∈ RCC8 . Constraint-based Qualitative Reasoning – p.13/26

  14. � � � � � � Representation as a CSP, ctd Constraints S 3 : RCC8 composition table as a ternary relation. For each ordered triple A,B,C of the objects a constraint C A , B , C on the variables Q [ A , B ] , Q [ B , C ] , Q [ A , C ] : C A , B , C := S 3 ∩ ( D A , B × D B , C × D A , C ) . where Q [ A , B ] ∈ D A , B , Q [ B , C ] ∈ D B , C , Q [ A , C ] ∈ D A , C . In total 10 constraints. Constraint-based Qualitative Reasoning – p.14/26

  15. Evolving qualitative scenarios Constraint-based Qualitative Reasoning – p.15/26

  16. � � Evolving Scenarios now Q [ A , B ] Q [ A , B ] at some later time instance Simulation: sequence of evolving scenarios (CSPs) discrete linear time; t = 0 , 1 , . . . time index: Q [ A , B , t ] Temporal logic for specifying simulations eventually , next time , φ φ from now on , until . φ ψ U φ Q [ France , EU ] = inside Q [ France , EU ] � = inside Constraint-based Qualitative Reasoning – p.16/26

  17. Temporal specifications Example covered-by inside Conceptual neighbourhood equal (22 pairs) overlap meet disjoint contains covers Smooth transitions in time: ( Q [ A , B ] = meet → ( Q [ A , B ] = meet ∨ Q [ A , B ] = disjoint ∨ Q [ A , B ] = overlap )) Constraint-based Qualitative Reasoning – p.17/26

  18. Formulas as Constraints Assume simulation of finite length t max , evaluate formula at time t Constraint translation principle: unravel iteratively to simple constraints Q [ A , B ] ∈ Rels at t is Q [ A , B , t ] ∈ Rels � φ at t + 1 if t < t max φ at t is if t = t max ? is φ ∨ φ φ Result: Boolean constraints, arithmetic constraints and simple constraints on Q . Constraint-based Qualitative Reasoning – p.18/26

  19. � � � � � � Planning problems Two distinguished formulas: – φ first (initial situation), – φ goal (final situation). – φ first and φ goal do not contain any temporal operators. Typical state transition formulas: ψ A → ψ B . Viewed as a finite simulation: Translate φ at t max = “false” Constraint-based Qualitative Reasoning – p.19/26

  20. ✂ � ✄ ✁ Infinite simulations Backward loops employed. . . . . . . Q 1 Q 2 Q ℓ Q k translate φ at t max = translate φ at ℓ – Loop paths as in bounded model checking (Biere et al. ’03) – All simulation stages maintained in one CSP Constraint-based Qualitative Reasoning – p.20/26

  21. Case Study Constraint-based Qualitative Reasoning – p.21/26

  22. Juggling Qualitative formulation of open-ended juggling Objects: O := Hands ∪ Balls , Hands := { left-hand , right-hand } , Balls := { ball i | i ∈ [1 .. 3] } . Relations: (in hand) meet (in air) disjoint Constraint-based Qualitative Reasoning – p.22/26

  23. � � � � Specifications From some time on, at most one ball is not in the air: ( ∀ b ∈ Balls . ∀ h ∈ Hands . Q [ b, h ] = meet → ∀ b 2 ∈ Balls . b � = b 2 → ∀ h 2 ∈ Hands . Q [ b 2 , h 2 ] = disjoint ) . A ball thrown from one hand remains in the air until it lands in the other hand: ( ∀ b ∈ Balls . ∀ h 1 , h 2 ∈ Hands . h 1 � = h 2 ∧ Q [ h 1 , b ] = meet → Q [ h 1 , b ] = meet U ( Q [ h 1 , b ] = disjoint ∧ Q [ h 2 , b ] = disjoint ∧ ( Q [ h 1 , b ] = disjoint U Q [ h 2 , b ] = meet ))) . Constraint-based Qualitative Reasoning – p.23/26

  24. � � � � � � Specifications, ctd Initial formulation was incomplete: – several balls could be thrown at the same time instance, – balls could “overtake” each other in the air. Repaired using additional temporal formulas. For the resulting specifications our program finds infinite simulation of 8 steps, with a backward loop. Constraint-based Qualitative Reasoning – p.24/26

  25. Juggling Result: 1 2 2 3 3 1 1 3 3 1 1 2 2 1 2 3 2 3 2 1 3 2 1 3 State 1 State 2 State 3 State 4 State 5 State 6 State 7 State 8 (running time: 100 seconds) Constraint-based Qualitative Reasoning – p.25/26

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend