Top Banner
A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln
26

A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Dec 21, 2015

Download

Documents

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

A New Efficient Algorithm for Solving the Simple Temporal

Problem

Lin Xu & Berthe Y. ChoueiryConstraint Systems LaboratoryUniversity of Nebraska-Lincoln

Page 2: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Outline Motivation for Simple Temporal Problem

(STP) STP TCSP DTP

Consistency properties & algorithms General CSPs STP

Contributions Use (improved) PPC for STP Refine it into STP Evaluation on random instances, 3 generators

Summary & new results

Page 3: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Temporal Reasoning in AIAn important task & exciting research topic,

otherwise we would not be here Temporal Logic Temporal Networks

Qualitative relations: Before, after, during, etc. interval algebra, point algebra

Quantitative/metric relations: 10 min before, during 15 min, etc. Simple TP (STP), Temporal CSP (TCSP), Disjunctive

TP (DTP)

Page 4: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Temporal Network: exampleTom has class at 8:00 a.m. Today, he gets up between 7:30 and 7:40 a.m. He prepares his breakfast (10-15 min). After breakfast (5-10 min), he goes to school by car (20-30 min). Will he be on time for class?

Page 5: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Simple Temporal Network (STP)

Variable: Time point for an event Domain: A set of real numbers (time instants) Constraint: An edge between time points ([5, 10] 5Pb-

Pa10)

Algorithm: Floyd-Warshall, polynomial time

Page 6: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Other Temporal Problems

Temporal CSP: Each edge is a disjunction of intervals

STP TCSP

Disjunctive Temporal Problem: Each constraint is a disjunction of edges

STP TCSP DTP

Page 7: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Search to solve the TCSP/DTP

TCSP [Dechter] and DTP [Stergiou & Koubarakis] are NP-hard They are solved with backtrack search Every node in the search tree is an STP to be solved An exponential number of STPs to be solved

Better STP-solver than Floyd-Warshall?… Yes

Page 8: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Properties of a (general) CSP Consistency properties

Decomposable Consistent Decomposable Minimal Path consistent (PC)

Algorithms for PC PC-1 (complete graph) [Montanari 74] PPC (triangulated graph) [Bliek & Sam-Haroud

99] Approximation algorithm: DPC [Dechter et al.

91]

Articulation points

Page 9: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Properties of an STP When distributive over in PC-1:

Decomposable Minimal PC [Montanari 74] PC-1 guarantees consistency

Convexity of constraints PPC & PC-1 yield same results [B & S-H 99] PC-1 collapses with F-W [Montanari 74]

Triangulation of the network Decomposition using AP is implicit No propagation between bi-connected

components

Page 10: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

New algorithms for STP

Use PPC for solving the STP improved [B&S-H 99] Simultaneously update all edges in a triangle

STP is a refinement of PPC considers the network as composed by triangles

instead of edges

Temporal graph

F-W STPPPC

Page 11: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Evaluation Implemented 2 new random generators Tested: 100 samples, 50, 100, 256, 512

nodes GenSTP-1 (2 versions)

Connected, solvable with 80% probability

SPRAND Sub-class of SPLIB, public domain library Problems have a structural constraint (cycle)

GenSTP-2 Courtesy of Ioannis Tsamardinos Structural constraint not guaranteed

Page 12: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Experiments

1. Managing queue in STP STP-front, STP-random, STP-back

2. Comparing F-W, PPC (new), DPC, STP Effect of using AP in F-W & DPC Computing the minimal network (not DPC) Counting constraint check & CPU time

Page 13: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Managing the queue in STP

Page 14: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Experiments

1. Managing queue in STP STP-front, STP-random, STP-back

2. Comparing F-W, PPC (new), DPC, STP Effect of using AP in F-W & DPC Computing the minimal network (not DPC) Counting constraint checks & CPU time

Page 15: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Finding the minimal STP

Page 16: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Determining consistency of STP

Page 17: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Advantages of STP A finer version of PPC Cheaper than PPC and F-W Guarantees the minimal network Automatically decomposes the graph

into its bi-connected components binds effort in size of largest component allows parallellization

Best known algorithm for solving STP use it search to solve TCSP or DTP where it

is applied an exponential number of times

Page 18: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Results of this paper

Is there a better algorithm for STP than F-W?

Constraint semantic: convexity PPC guarantees minimality and decomposability

Exploiting topology: AP + triangles Articulation points improves any STP solver Propagation over triangles make STP more

efficient than F-W and PPC

Page 19: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Beyond the temporal problem Exploiting constraint convexity: A new

some-pairs shortest path algorithm, determines consistency faster than F-W

Exploiting triangulation: A new path-consistency algorithm (improved PPC) Simultaneously updating edges in a triangle Propagating via adjacent triangles

Page 20: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

New results & future work Demonstrate the usefulness and

effectiveness of STP for solving:

TCSP [CP 03, IJCAI-WS 03] Use STP, currently the best STP solver AC algorithm, NewCyc & EdgeOrd heuristics

DTP [on-going] Incremental triangulation [Noubir 03, Berry

03]

Page 21: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

The end

Page 22: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

Algorithms for solving the STP

Graph Cost Consistency

Minimality

F-W/PC Complete (n3) Yes Yes

DPC Not necessarily

O (nW*(d)2)very cheap

Yes No

PPC Triangulated O (n3)usually

cheaper than F-W/PC

Yes Yes

STP Triangulated Always cheaper than

PPC

Yes YesOur approach requires triangulation of the constraint graph

Page 23: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

SPRAND: Constraint checks

Page 24: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

SPRAND: CPU Time

Page 25: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

GenSTP2: Constraint checks

Page 26: A New Efficient Algorithm for Solving the Simple Temporal Problem Lin Xu & Berthe Y. Choueiry Constraint Systems Laboratory University of Nebraska-Lincoln.

GenSTP2: CPU time