+ All Categories
Home > Documents > Time-Parameterized Queries in Spatio-temporal Databases

Time-Parameterized Queries in Spatio-temporal Databases

Date post: 06-Apr-2018
Category:
Upload: jjivkov
View: 237 times
Download: 0 times
Share this document with a friend

of 12

Transcript
  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    1/12

    T i m e - P a r a m e t e r iz e d Q u e r i e s in S p a t io - T e m p o r a l D a t a b a s e sY u f e i T a o

    Department of Computer ScienceHong Kong University of Science and Technology

    Clear Water Bay, Hong Ko nght tp : / /www.cs .us t .hk/~ taoyf/

    D i m i t fi s P a p a d i a sDepartment of Computer Science

    Hong Kong University of Science and TechnologyClear Water Bay, Hong Kong

    http ://www.cs.ust.hk/~dimitris/A BS TRA CTTime-parameterized queries (TP queries for short) retrieve (i) theactual result at the time that the query is issued, (ii) the validityp er io d of the result given the current motion of the query and thedatabase objects, and (iii) the change that causes the expiration ofthe result. Due to the highly dynamic nature of several spatio-temporal applications, TP queries are important both asstandalone methods, as well as building blocks of more complexoperations. However, little work has been done towards theirefficient processing. In this paper, we propose a generalframework that covers time-parameterized variat ions of the mostcommon spatial queries, namely window queries, k-nearestneighbors and spatial joins. In particular, each of these TP queriesis reduced to nearest neighbor search where the distance functionsare defined according to the query type. This reduction allows theapplication and extension of well-known branch and boundtechniques to the current problem. The proposed methods can beapplied with mobi le queries, mobi le objects or both, given asuitable indexing method. Our experimental evaluat ion is basedon R-trees and their extensions for dynamic objects.KeywordsSpatio-temporal databases, nearest neighbor queries1 . INTRODUCTIONAs opposed to traditional, "instantaneous", queries that areevaluated only once to return a single result, continuous queriesmay require constant evaluation and update of the results as thequery conditions or database contents change [TGNO92,CDTW00]. Such queries are especially relevant to spatio-temporaldatabases, which are inherently dynamic and the result of anyquery is strongly related to the temporal context. An example of acont inuous spatio-temporal query is: "based on my currentdirection and speed of travel, which will be my nearest two gasstations for the next 5 minutes?". A result of the form, would imply that A,B will be thetwo nearest neighbors during interval [0,1), and B, C afterwards.Notice that the corresponding instantaneous query ("which are mynearest gas stations now?") is usually meaningless in highlydynamic environments; if the query point or the database objectsmove, the result may be invalidated immediately.Permission o make digital or hard copies of all or part of this work forpersonal or classroom use is granted without fee provided hat copies arenot made or distributed for profit or commercial advantage and thatcopies bear this notice and the ful l citation on the first page. To copyotherwise, or republish, to post on servers or to redistribute to lists,requires prior specific permissionand/or a fee.ACMSIGMOD'2002, June 4-6, Madison, Wisconsin,USA.Copyright 2002 ACM 1-58113-497-5/02/06...$5.00.

    Any spatial query has a continuous counterpart whose terminationclause depends on the user or application needs. Consider, forinstance, a window query, where the window (and possibly thedatabase objects) moves/changes with time. The terminationclause may be temporal (for the next 5 minutes), a condition onthe result (e.g., unti l exactly one object appears in the querywindow, or until the result changes three times), a condi tion onthe query window (until the window reaches a certain poi nt inspace) etc. A major difference from continuous queries in thecontext of traditional databases, is that in case of spatio-temporaldatabases, the object's dynamic behavior does not necessarilyrequire updates, but can be stored as a fimction of time usingappropriate indexes [BJSS98, TUW98, KGT99, AAE00,SJLL00]. Furthermore, even if the objects are static, the resul tsmay change due to the dynamic nature of the query itself (i.e.,moving query window), which can be also represented as afunction of time. Thus, a spatio-temporal continuous query can beevaluated instantly (i.e., at the current time) using time-parameterized information about the dynamic behavior of thequery and the database objects, in order to produce several results,each covering a validity period in the future.The buildi ng block of most conti nuous spatio-temporal queries iswhat we call the time-parame terized (T P) query. A TP queryreturns: (i) the objects that satisfy the corresponding spatial query,(ii) the expiry time of the result, and (iii) the change that causesthe expiration of the result. As an example, consider that a movinguser wants to find all hotels within a 5kin range from his/hercurrent position. In addition to a set of hotels (lets say A,B,C)currently within the 5kin range, the result contains the time (e.g.,1 minute) that this answer set is valid (given the direction and thespeed of the user 's movement ), as well as the new answer set afterthe change (e.g., at 1 minute hotel D will start to be within 5krn).In the previous example we assume that the query window isdynamic and the database objects are static. In other cases theopposite may be true, e.g., find all cars that are within a 5kinrange from hotel A. It is also possible that both the query and theobjects are dynamic, if for instance, the query and the databaseobjects are points denot ing moving airplanes. The same conceptcan be applied to other common query types, e.g., nearestneighbors and spatial joins (find all major residential areascurrent ly covered by typhoons, together with the earliest time thatthe situation is expected to change).TP queries, as standalone methods, are crucial in applicationsinvolving dynamic environments (e.g., location-based commercefor mobile communications , air-traffic control systems), whereany result should be accompanied by an expiry period in order tobe effective in practice. In addition, they constitute the primit ivecomponents based on which complex continuous queries can beconstructed. In this paper we propose a general framework for TPqueries in spatio-temporal databases, which can be applied for any

    33 4

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    2/12

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    3/12

    T h e a l g o r i t h m o f [ R K V 9 5 ] a n s w e r s a N N q u e r y b y t ra v e r s i n g t h eR - t r e e i n a d e p t h - f i r s t ( D F ) m a n n e r . S p e c i f i c a l l y , s t a r ti n g f r o m t h er o o t , a l l e n t r i e s a r e s o r t e d a c c o r d i n g t o t h e i r mindist f r o m t h eq u e r y p o i n t , a n d t h e e n t r y w i t h t h e l o w e s t v a l u e i s v i s i t e d f i r s t .T h e p r o c e s s i s r e p e a t e d r e c u r s i v e l y u n t i l t h e l e a f l e v e l w h e r e t h ef i r st p o t e n t i a l n e a r e s t n e i g h b o r i s f o u n d . D u r i n g b a c k t r a c k i n g t ot h e u p p e r l e v e l s , t h e a l g o r i t h m o n l y v i s i t s e n t r i e s w h o s e mindist iss m a l l e r t h a n t h e d i s t a n c e o f t h e n e a r e s t n e i g h b o r a l r e a d y f o u n d .A s a n e x a m p l e c o n s i d e r th e R - t r e e o f F i g u r e 2 . 3 , w h e r e t h en u m b e r i n e a c h e n t r y r e f e r s t o t h e mindist ( f o r i n t e r m e d i a t ee n t r i e s ) o r t h e a c t u a l d i s t a n c e ( f o r p o i n t o b j e c t s ) f r o m t h e q u e r yp o i n t ( t h e s e n u m b e r s a r e n o t s t o r e d b u t c o m p u t e d d y n a m i c a l l yd u r i n g q u e r y p r o c e s s i n g ) . D F w o u l d f i r st v i s it th e n o d e o f r o o te n t r y E~ ( s i n c e i t h a s t h e m i n i m u m mindist), a n d t h e n t h e n o d e o fE 4, w h e r e t h e f i r s t c a n d i d a t e o b j e c t ( a ) i s r e t r i e v e d . W h e nb a c k t r a c k i n g t o t h e p r e v i o u s l e v e l , e n t r y E 6 i s e x c l u d e d s i n c e i t smindist i s g r e a t e r t h a n t h e d i s t a n c e o f a , b u t E ~ h a s t o b e v i s i t e db e f o r e b a c k t r a c k i n g a g a in a t t h e r o o t l e v e l . Minmaxdist ( a n d o t h e rs i m i l a r b o u n d s ) c a n b e a p p l i e d to f u r t h e r p r u n e s e a r c h .T h e p e r f o r m a n c e o f D F w a s s h o w n t o b e s u b o p t i m a l in [ P M 9 7 ] ,w h i c h r e v e a l s t h a t a n o p t i m a l N N s e a r c h a l g o r i t h m o n l y n e e d s t ov i s i t t h o s e n o d e s w h o s e M B R s i n t e r s e c t t h e s o - c a l l e d "s e a r c hr e g i o n " , i . e . , a c i r c l e c e n t e r e d a t t h e q u e r y p o i n t w i t h r a d i u s e q u a lt o t h e d i s t a n c e b e t w e e n t h e q u e r y a n d i t s n e a r e s t n e i g h b o r ( s h a d e dc i r c l e i n F i g u r e 2 . 3 ) . B a s e d o n t h i s , [ C P Z 9 8 , W S B 9 8 , B B K + 0 1 ]i n v e s t i g a t e c o s t m o d e l s f o r p e r f o r m i n g N N q u e r i e s i n h i g h -d i m e n s i o n a l s p a c e .A b e s t - f i rs t ( B F ) a l g o r i t h m f o r K N N q u e r y p r o c e s s i n g u s i n g R -t r e e s i s p r o p o s e d i n [ H S 9 9 ] . B F k e e p s a heap w i t h t h e e n t r i e s o ft h e n o d e s v i s i t e d s o f a r . I n i t i a l l y t h e h e a p c o n t a i n s t h e e n t r i e s o ft h e r o o t s o r t e d a c c o r d i n g t o t h e i r mindist. I n F i g u r e 2 .3 w h e n E t i sv i s i t e d , it i s r e m o v e d f r o m t h e h e a p a n d t h e e n t r i e s o f i t s n o d e ( E4 ,E~, Er) a r e a d d e d t o g e t h e r w i t h t h e i r mindist. The n e x t e n t r yv i s i t e d i s E2 ( i t h a s t h e m i n i m u m mindist i n t h e h e a p ) , f o l l o w e d b yE 8, w h e r e t h e a c t u a l r e s u l t ( h ) i s f o u n d a n d t h e a l g o r i t h mt e r m i n a t e s . B F i s o p t i m a l i n t h e s e n s e t h a t i t o n l y v i s i t s t h e n o d e sn e c e s s a r y f o r o b t a i n i n g t h e n e a r e s t n e i g h b o r . I t s p e r f o r m a n c e i np r a c t i c e , h o w e v e r , m a y s u f f e r f ro m b u f f e r t h r a s h in g i f th ea v a i l a b l e m e m o r y i s n o t e n o u g h f o r t h e r e q u i r e d h e a p . I n t h i s c a s ep a r t o f t h e h e a p m u s t b e m i g r a t e d to t h e d i s k , w h i c h m a y i n c u rf r e q u e n t d i s k a c c e s s e s .

    ' isE

    f o l l o w E ~ 2 ~ - ~ 4 ~ - ~ j ~ - F 3 ~ - ~ 6 1 / ~ - I [ ] { e m pt y }

    Ej I I x axis Rep ort h and terminate2 4 6 8 10 "

    Root

    e , I i i E ~1 2 1 2 1 2 1 I 1 } 1 )1I I I I l ,E~ e~ ~8

    Figure 2 . 3: E x a m p l e o f B a B a l g o r i t h m s

    T h e B a B f r a m e w o r k a l s o a p p l i e s to c l o s e s t p a i r q u e r i e s th a t f i n dt h e p a i r o f o b j e c t s f r o m t w o d a t a s e t s , su c h t h a t t h e i r d i s t a n c e i s t h em i n i m u m a m o n g a l l p a i r s . C o r r a l e t a l , [ C M T V 0 0 ] p r o p o s ev a r i o u s a l g o r i th m s b a s e d o n t h e c o n c e p t s o f D F a n d B F t r a ve r s al .T h e d i f f e r e n c e f r o m N N i s t h a t t h e a l g o r i t h m s a c c e s s t w o i n d e xs t r u c t u r e s ( o n e f o r e a c h d a t a s e t ) s i m u l t a n e o u s l y . Mindist i s n o wd e f i n e d a s t h e m i n i m u m d i s t a n c e b e t w e e n t w o o b j e c t s t h a t c a n l i ei n t h e s u b t r e e s o f t w o i n t e r m e d i a t e e n t r i e s ( s e e F i g u r e 2 . 2 b ) . I f th emindist o f t w o i n t e r m e d i a t e e n t r i e s E l a n d E 2 ( o n e f r o m e a c h R -t r e e ) i s a l r e a d y g r e a t e r th a n t h e d i s t a n c e o f t h e c l o s e s t p a i r o fo b j e c t s f o u n d s o f a r , th e s u b - t r e e s o f E l a n d E 2 c a n n o t c o n t a i n ac l o s e s t p a ir . O t h e r n o n - B a B b a s e d m e t h o d s f o r n e a r e st n e i g h b o rs e a r c h c a n b e f o u n d i n [ K S F + 9 6 , S K 9 8 , C G 9 9 , B E K 9 8 ,Y O T J 0 1 ] .3 . T I M E - P A R A M E T E R I Z E D (TP) Q U E R I E ST h e o u t p u t o f a s p a t i o - t e m p o r a l T P q u e r y h a s t h e g e n e r a l f o r m< R , T , C > , w h e r e R i s t h e s e t o f o b j e c t s s a t i s f y i n g t h ec o r r e s p o n d i n g i n s t a n t a n e o u s q u e r y ( i . e . , c u r r e n t r e s u l t ) , T i s t h ee x p i r y t i m e o f R , a n d C t h e s e t o f o b j e c t s th a t w i l l a f f e c t R a t T .F r o m t h e s e t o f o b j e c t s i n t h e c u r r e n t r e s u l t R , a n d t h e s e t o fo b j e c t s C t h a t w i l l c a u s e c h a ng e s , w e c a n i n c r e m e n t a l l y c o m p u t et h e n e x t r e s u l t . W e r e f e r t o R a s t h e conventional, a n d ( T , C ) a sth e time-parameterized c o m p o n e n t o f t h e q u e r y . C o n s i d e r , f o ri n s ta n c e , t h e T P w i n d o w q u e r y ( s h a d e d w i n d o w ) o f F i g u r e 3 .1 a ,w h e r e o b j e c t s ( r e c t a n g l e a t o e ) a r e st a t i c a n d q u e r y q i s m o v i n ge a s t w i t h s p e e d 1 . T h e o u t p u t s h o u l d b e < { b } , l , { b } > m e a n i n g t h a to b j e c t b c u r r e n t l y i n t e r se c t s t h e q u e r y w i n d o w , b u t a f t e r 1 ti m eu n i t i t w i l l s t o p d o i n g s o ( t h e r e fo r e , b s h o u l d b e r e m o v e d f r o m t h er e s u lt , w h i c h w i l l b e c o m e e m p t y ).A n a i v e w a y t o p r o c e s s th e q u e r y i s to e x p a n d i t s w i n d o w s o t h a ti t i n c l u d e s a l l t h e a r e a t h a t t h e q u e r y w i l l c o v e r u p t o a t i m e t i nt h e f u t u r e , a n d t h e n p r o c e s s th i s e x t e n d e d w i n d o w ( u s i n g a r e g u l a rR - t r e e w i n d o w q u e r y ) t o f i n d a l l c a n d i d a t e o b j e c t s t h a t m a yc h a n g e t h e r e s u l t u p t o t i m e t . I n t h e e x a m p l e o f F i g u r e 3 . I a , t h ee x t e n d e d w i n d o w ( b o l d r e c ta n g l e ) c o r r e s p o n d s t o t h e a r e a t h a t t h eq u e r y w i l l c o v e r i n t h e n e x t t - - 4 t i m e u n i t s . F o r a l l c a n d i d a t eo b j e c t s (b,d,e), t h e i n t e rv a l d u n n g w h i c h t h e y b e l o n g t o t h e r e s u l ti s computed : f o r b th i s in t e rva l i s [0 ,1 ) , f o r d i t i s [2 ,4 ) , and fo r ei t i s [ 3 , 4 ) . G i v e n t h i s i n f o r m a t i o n w e c a n d e t e r m i n e t h ec o n v e n t i o n a l a n d t h e T P c o m p o n e n t s o f t h e q u e r y. T h i s m e t h o d ,h o w e v e r , h a s s o m e s e r i o u s s h o r t c o m i n g s : ( i ) T h e e s t i m a t i o n t o fh o w l o n g i n t h e f u t u re t o e x t e n d t h e q u e r y w i n d o w i s a d - h o e . A nu n d e r - e s t i m a t i o n m e a n s t h a t w e w i l l n o t b e a b l e t o c o m p u t e t h et i m e - p a r a m e t e r i z e d c o m p o n e n t , w h i l e a n o v e r - e s ti m a t i o n w i l li n c u r s i g n i f i c a n t c o m p u t a t i o n a l o v e r h e a d . ( i i ) T h e m e t h o d i s n o ta p p l i c a b l e t o o t h e r t y p e s o f q u e r ie s s u c h a s N N .O b s e r v e t h a t t h e r e s u l t o f a s p a t i a l q u e r y c h a n g e s i n t h e f u t u r eb e c a u s e s o m e o b j e c t s " i n f l u e n c e " i t s c o r r e c t n e s s . F o r i n s t a n c e , i fa n o b j e c t ( e . g . , b ) s a t i s f i e s t h e q u e r y a t t h e c u r r e n t t i m e , i t m a yi n f l u e n c e t h e r e s u l t w h e n i t n o l o n g e r s a t i s f i e s i t in t h e f u t u r e ( a tt i m e 1 ). O n t h e o t h e r h a n d , a n o b j e c t n o t c u r r e n t l y i n t h e r e s u l t( e . g ., d ) m a y i n f l u e n c e t h e q u e r y w h e n i t b e c o m e s a p a r t o f th er e s u l t ( a t t i m e 2 ) . F i g u r e 3 . 1 a s h o w s t h e i n f l u e n c e t i m e o f a l l

    F o r s i m p l i c i t y o f i l l u s t ra t i o n , w e o f t e n u s e s t a t i c 2 D o b j e c t s . T h ee x t e n s i o n t o m o b i l e o b j e c t s a n d h i g h e r d i m e n s i o n s , u n l e s se x p l i c i t l y st a t e d , i s s t r a ig h t f o r w a r d .

    3 3 6

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    4/12

    o b j e ct s . S o m e o b j e c ts , s u c h a s a a n d c , m a y n e v e r c h a n g e t h er e s u l t , i n w h i c h c a s e t h e i n f l u e n c e t i m e i s s e t to oo.

    dI0

    8

    a x i sa a ~ i n f lu e n c e s a t oo

    i n f l u e n c e s a t 2

    i n f l u e n ~ : ~ _ ~at 1 ~-1- '~1"~?: " 6i a [ ~ ( , | , ] m o v m g e a s t I

    [ ] \ t 1 ' 4i n f l u e n c e s t h e q u e r y q i n f l u e n c e sa t 3a t o o a t c u r r e n t t i m e

    I I I i I I t I I xla xi$ ,2 4 6 8 1 0 " t( a) T P w i n d o w q u e r y

    F i g u r e 3 . 1 : T h e

    d , axis10 '

    i n f l u e n c e s a t ~ i n f l u e n c e s a t 38 ' O a O g

    i n f l u e n c e s a t 1 . 5in f l uences t he quer y q fa t ~ a b a t cur r en t t ime0 ~ m o v i n g e a s t

    d a t s peed 1i n f l u e n c e s o o

    in f l uences a t oo2 c ei n f l u e n c e s a t 4 . 5. . . . . . . . ~ tax~"o 2 4 6 8 1o

    ( b ) T P N N q u e r yi n f l u e n c e t i m e

    T h e c o n c e p t o f " i n f l u e n c e t i m e " a l s o a p p l i e s to o t h e r t y p e s o fq u e r i e s . F i g u r e 3 . l b s h o w s a T P N N , w h e r e o b j e c t s ( p o i n t s a t o g )a r e s t a ti c a n d q u e r y p o i n t q i s m o v i n g e a s t w i t h s p e e d 1 . P o i n t d i st h e c u r r e n t n e a r e s t n e i g h b o r o f q . I n th i s c a s e , th e i n f l u e n c e t i m eo f a n o b j e c t s h o u l d b e i n t e r p r e t e d a s t h e t i m e t h a t i t s t a r t s t o g e tc l o s e r t o t h e q u e r y t h a n t h e c u r r e n t n e a r e s t n e i g h b o r . F o r e x a m p l e ,t h e i n f l u e n c e ti m e o f p o i n t g i s 3 , b e c a u s e a t th i s t i m e g w i l l c o m ec l o s e r t o q t h a n d . N o t i c e t h a t a n o n - i n f i n i t e ( i .e . , d i f f e re n t f r o moo ) i n f l u e n c e t i m e d o e s n o t n e c e s s a r i l y m e a n t h a t th e o b j e c t w i l lc h a n g e t h e r e s u l t ; g w i l l i n f l u e n c e t h e q u e r y a t t i m e 3 , o n l y i f t h er e s u l t d o e s n o t c h a n g e b e f o r e d u e t o a n o t h e r o b j e c t ( a c t u a l l y a tt i m e 3 t h e n e a r e s t n e i g h b o r i s o b j e c t f t . T h e i n f l u e n c e t i m e o fp o i n t s a , b , c i s oo b e c a u s e t h e y c a n n e v e r b e c l o s e r t o q t h a n i t sc u r r e n t n e ar e s t n e i g h b o r d ( o b s e r ve t h a t t h e i n f l u e n c e t i m e o f d i sa lso se t to oo ) .W e d e n o t e t h e i n f l u e n c e ti m e o f a n o b j e c t o w i t h r e s p e ct t o aq u e r y q a s T I N F (O , q) . T h e e x p i r y t i m e o f t h e c u r r e n t r e s u l t i s t h em i n i m u m i n f l u e n c e t i m e o f a l l o b je c ts . T h e r e f o r e, t h e t i m e -p a r a m e t e r iz e d c o m p o n e n t o f a T P q u e r y c a n b e re d u c e d t o an e a r e s t n e i g h b o r p r o b l e m b y t r e a t i n g T r N F (O ,q ) a s t h e d i s t a n c em e t r i c : t h e g o a l i s to f i n d t h e o b j e c t s ( C ) w i t h t h e m i n i m u m T iNF( T ) . T h e s e a r e t h e c a n d i d a t e s th a t m a y g e n e r a t e t h e c h a n g e o f th er e s u l t a t t h e e x p i r y t i m e ( b y a d d i n g t o o r d e l e t i n g f r o m t h ep r e v i o u s a n s w e r s e t ) . TiNF f o r i n t e r m e d i a t e e n t r i e s E i s d e f i n e d i na w a y s i m i l a r t o mi n d i s t i n N N s e a r c h : T iN F (E ,q ) i s t h e m i n i m u mi n f l u e n c e t i m e T i N F( O,q o f a n y o b j e c t o t h a t m a y l i e i n t h e s u b t r e eo f E . T h e a b o v e d i s c u s s i o n s e r v e s a s a h i g h - l e v e l a b s t r a c t i o n th a te s t a b l i s h e s th e c l o s e c o n n e c t i o n b e t w e e n t h e T P r e t r ie v a l a n d N Ns e a r c h . I n t h e s e q u e l w e d e r i v e s u i t a b l e T1NF(O,q and TtNF(E,q)m e t r i c s f o r v a r i o u s q u e r y t y p e s .3 .1 T h e T P W i n d o w Q u e r yI n o r d e r t o f i n d t h e i n f l u e n c e t i m e TiNF(O,q o f a n o b j e c t o w i t hr e s p e ct t o a q u e r y w i n d o w q , w e n e e d t h e i n t e r se c t i o n p e r i o d[ T s, Te ) d u r i n g w h i c h o w i l l i n t e r s e c t q . F i g u r e 3 . 2 a i l l u s t r a te s a ne x a m p l e w i t h a d y n a m i c q u e r y q , a n d t h r e e d y n a m i c o b je c t s u , v,w ( w i t h o u t l o s s o f g e n e r a l i t y , a s s u m e t h e c u r r e n t t i m e i s 0 ) .F i g u r e s 3 . 2 b a n d c s h o w t h e s i t u a t i o n s a t t i m e 1 a n d 3r e s p e c t i v e l y . T h e i n t e r s e c t i o n p e r i o d o f o b j e c t u i s [ 0 ,1 ) , o f v i s[ 1 ,3 ) , w h i l e t h e i n t e r s e c t i o n p e r i o d o f w i s [ ~ ,o o ). N o t i c e t h a td e p e n d i n g o n t h e v a l u e s o f t h e t w o d i f f e r e n t v e l o c i t i e s o n ad i m e n s i o n , it i s p o s s i b l e t h a t s o m e o b j e c t s ( e . g. , w ) m a y d i s a p p e a r( i .e . , tw o o p p o s i t e s i d e s o f t h e r e c t a n g l e w i l l m e e t ) i n t h e f u t u r e

    ( t im e 1 ). S u c h o b j e c ts s h o u l d b e t a k e n i n t o a c c o u n t d u r i n g q u e r yp r o c e s s i n g , s i n c e t h e y m a y n o t a f f e c t t h e r e s u l t a f t e r t h e i rd i s a p p e a r a n c e .

    y a x l sH

    . 1 ~ " lI ! Iquer y q ' -1 wI ~ r t

    ~ , , ~ ~ ~ , ~ t xq . x i s0 2 4 6 8 10 "

    ( a ) T h e c u r r e n t t i m e 0, , a x i s V a x i s

    1 0 I I8

    4u(t)

    2 w d i s s appear s u(3)[]i i i i i i i i i ixq xi s i t i i i i i , i ix ~ Xis

    2 4 6 8 10 " 0 2 4 6 8 10( b ) A t t i m e 1 ( c ) A t t i m e 3

    F i g u r e 3 . 2 : D e r i v i n g T I NF (O ,q )W e d e n o t e t h e M B R a n d v e l o c i t y v e c t o r o f a n o b j e c t o a s{[OiL,Ore] .. .. [OnL,O~R]} an d { [o.ViE,O.ViR] . . . . . [o.V~L,O.VnR]}re s pe c t i ve ly , w he re [ OuL ,O~] ( [o .VuL ,o .V~]) c o r r e s p ond s t o t hee x t e n t s ( v e l o c i t i e s ) a l o n g t h e i t h d i m e n s i o n ( i = 1 . . . . . n ) . T h e i - t hp r o j e c t io n o f a n o b j e c t o , w i l l d i s a p p e a r a t t i m e o . T ~ s p c o m p u t e das : ( i ) o .TiDsP = ~ , i f o .ViR -> o.ViL ( i i ) o .TiDsP =(OiR--OIL)/(o.VIL--o.ViR),o t h e r w i s e . T h e d i s a p p e a r a n c e t i m e O .T D sP ,i s t h e m i n i m u m o .T iD s P o f a l l d i m e n s i o n s . T h e i n f l u e n c e t i m eT ~ N v ( o , q ) o f e v e r y o b j e c t o s h o u l d b e n o l a t e r t h a nm i n ( o .T o s p , q .T D s P ) , a f t e r w h i c h t i m e e i t h e r o o r q w i l l h a v ed i s a p p e a r e d , t h u s a u t o m a t i c a l l y t e r m i n a t i n g t h e i n t e r s e c t i o np e r i o d .O b j e c t o a n d q u e r y q i n t e r s e c t i f a n d o n l y i f t h e y i n t e r se c t a l o n ga l l d i m e n s i o n s . N e x t w e p r e s e n t a m e t h o d 2 f o r c o m p u t i n g t h ei n t e r s e c t i o n p e r i o d [ Ti s, Ti e) a l o n g t h e i t h d i m e n s i o n , s t a r t in g w i t ht he c a s e w he re [ o iL ,o t R] doe s no t i n t e r s e c t [qiL,q~R] a t t h e c u r r e n tt i m e ( i . e ., o i s e i t he r t o t a l l y t o t he r i gh t , o r t o t a l l y t o t he l e f t o f q ) .I f o i s t o t h e r i g h t o f q ( F i g u r e 3 . 3 a ) , t h e n o a n d q w i l l s t a rti n t e r s e c t i n g a t t h e t i m e T iER ( = 1 ) w h e n t h e l e f t m o s t p o i n t O iL o f o ,m e e t s t h e r i g h t m o s t p o i n t q~R o f q . T iER i s c o m p u t e d a s f o l l o w s : ( i )TiER=e% if o.ViL->q.ViR, ( i . e . , t he y ne ve r m e e t ) , a nd ( i i ) T i ER =(o iL--q iR) /(q .ViR--o .ViL) , o t h e r w i s e . N o w c o n s i d e r th a t o i s t o t h el e f t o f q a s i n F i g u r e 3 . 3 b . I n t h i s c a s e , o a n d q , w i l l s t a rti n t e r s e c t i n g a t t h e t i m e T iR E ( = 2 ) , w h e n t h e r i g h t m o s t p o i n t OiR o fo , m e e t s t he l e f t m o s t po i n t q iL o f q : ( i ) T iR E =m , i f o .Vi a =q.ViL , a nd( i i ) TiRL=(OiR--qiL)/(q.ViL--o.V~R) o t h e r w i s e . T h u s i n t h e g e n e r a lc a s e , t h e t i m e T i s t h a t o a n d q , w i l l s ta r t i n t e r s e c t i n g o n d i m e n s i o n

    2 T P R - t r e e s a l s o e m p l o y a m e t h o d ( n a r r o w e r i n f o c u s a n d b a s e do n d i f f e r e n t c o n c e p t s ) to c o m p u t e t h e i n t e r s e c t i o n p e r i o d b e f o r es o m e d e s i g n a t e d f u t u r e t i m e [ S J L L 0 0 ] .

    3 3 7

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    5/12

    i i s T i t =m i n(T i L R ,T i R L ), p ro v i de d o f c our s e t h a t o a n d q do no td i s a p p e a r b e f o r e ( i n w h i c h c a s e T i ~= c o) .

    o.V iL= 1 o.V iR = 1----i1,q'Vi~=2 q'ViR ;3 iL=0 iR =lO

    qiL =-5 qiR =-2( a ) o to t h e r i g h t o f qo~_.~=1 o V.~ =-1 OiL=0 iR = 10, ~ o~_.~ = I o.ViR~=- IiL=-10 iR =0 , -q'4ViL=-2 q'V i~ :l q~.~b 1 q.ViR -1

    qiL =2 qiR =5 qiL =8 qiR =11( b ) o t o t h e l e f t o f q ( c ) o a n d q i n t e r s e c tFigure 3.3: E x a m p l e s o f i n t e r s e c t io n p e r i o d

    N e x t w e w i l l c o m p u t e t h e t i m e T ie t h a t o a n d q t h a t w i l l s t o pi n t e r s e c t i n g o n t h e i - t h d i m e n s i o n . I n o r d e r f o r [o iL ,O tR ] a n d[qiL,q~] t o s t o p i n t e r s e c t i n g , o b j e c t o m u s t m o v e e n t i r e l y t o t h er i g h t o r t o t h e l e ft o f t h e q u e r y . C o n t i n u i n g t h e e x a m p l e o f F i g u r e3 . 3 a , o a n d q w i l l k e e p i n t e r s e c t i n g f r o m t h e t i m e ( T i L R=l ) that OiLm e e t s q t R , t i l l t he t i m e ( T iR E =15) t ha t o t R m e e t s q i L . O n t h e o t he rh a n d , i n F i g u r e 3 . 3 b , o a n d q w i l l k e e p i n t e r s e c t i n g f r o m t h e t i m e( T IR E =2) t ha t o ~ m e e t s q i L , t i l l t he t i m e ( T IE R oo) t ha t o i l m e e t s q ~ .T h u s , T i e i s t h e m a x i m u m o f T i ER a n d T I R E, e x c e p t f o r t h e c a s e t h a tt h e i n t e r s e c t i o n o f p e r i o d i s t e r m i n a t e d b e f o r e d u e t o t h e o b j e c t o rqu e ry d i s a p pe a ra nc e . I n ge n e ra l , T i e = m i n(m a x( T iL R ,T i R L ), o .T os P ,q .T o s P) . I n t h e e x a m p l e o f F i g u r e 3 . 3 b , a l t h o u g h TiER co,T i e = o . T i D s P = 5 .F r o m T is a n d Ti e w e c a n c o m p u t e t h e i n t e r s e ct i o n p e r i o d o n a l ld i m e n s i o n s : [T s ,T e ) = ~ [ T , , ~ , ) . T h e i n f l u e n c e t im e T I N F( O ,q ) o fi=l.na n o b j e c t o n o t c u r r e n t l y i n t e r s e c t i n g t h e q u e r y , i s t h e e a r l i e s t t im et ha t i t w i l l s t a r t i n t e r s e c t i ng , i . e . , T m r( o , q ) =T ~.F o r t h e c a s e w h e r e o a n d q i n t e r s e c t a t t h e c u r r e n t t i m e , T i t = 0 fo ra l l d i m e n s i o n s , s o i t r e m a i n s t o d e r i v e th e e n d o f th e i n t e r s e c t i o np e r i o d T ie - T h i s i s s t r a i g h t f o r w a r d , b a s e d o n t h e o b s e r v a t i o n t h a t oa n d q w i l l s t o p i n t e r s e c t i n g a t t h e f i r st t i m e t h a t e i t h e r o i l m e e t sq iR , o r o t R m e e t s q i L , p r o v i d e d a g a i n t h e q u e r y o r t h e o b j e c t w i l lno t d i s a p pe a r be fo re , i . e . , T i ~=m i n(T i L R , T I R E, O.T Ds P , q .T Ds p). I nF i gu re 3 .3c , fo r i n s t a n c e , T i L R =5.5 , T i R E =l, O .T Ds p=5 , q .T os p =l .5 ,a n d T i e = T iR E = I. T h e e n d o f t h e i n t e r s e c t i o n p e r i o d T e o n a l ld i m e n s i o n s i s t h e m i n i m u m T i e , w h i c h i s a l so t h e i n f l u e n c e ti m eT n , F (o ,q ) o f a n o b j e c t o , c u r r e n t l y i n t e r s e c t i n g t h e q u e r y :T i N F( O ,q )= T e = r a i n (T i e ) . F i g u r e 3 . 4 p r e s e n t s t h e p s e u d o - c o d e f o rc o m p u t i n g t h e i n t e r s e c ti o n p e r i o d o f a n o b j e c t , ta k i n g i n t oa c c o u n t d i s a p p e a r a n c e t im e s .N e x t w e c o n s i d e r TiNv(E,q) f o r a n i n t e r m e d i a t e e n t r y E , w h i c hc o r r e s p o n d s t o t h e m i n i m u m p o s s i b l e i n f lu e n c e ti m e o f a n y o b j e c ti n t h e s u b t r e e o f E . I f t h e M B R o f E d o e s n o t c u r r e n t l y i n t er s e c t q,T ~NF ( E ,q ) i s t he t i m e i n t he fu t u re t h a t E s t a r t s t o i n t e r s e c t q ,b e c a u s e i t i s a ls o t h e e a r l i e s t t i m e w h e n a n y o f t h e o b j e c t s i n s i d e Ec a n i n t e r s e c t ( i n f l u e n c e ) q . I f E i n t e r s e c t s q a t t h e c u r r e n t t im e , w en e e d t o d i s t i n g u i s h t w o c a s e s w h e r e ( i ) E i s c o n t a i n e d i n q , o r ( i i)E p a r t i a l l y in t e r s e c t s q . F i g u r e 3 . 5 i l l u s tr a t e s th e s e t w o c a s e s w i t hs t a ti c o b j e c t s u , v , th e i r p a r e n t e n t r y E ( a l s o s t a ti c ) , a n d a d y n a m i cque ry q . F or t he f i r s t c a s e ( F i gure 3 .5a ) , T i NF ( E , q ) i s s e t t o t het i m e ( = 1 ) t h a t E s t a r ts t o p a r t i a l l y in t e r s e c t q b e c a u s e , b e f o r e t h i st i m e , a l l o b j e c t s i n E a r e a l w a y s c o n t a i n e d i n q, a n d h e n c e d o n o t

    i n f l u e n c e t h e q u e r y r e s u l t (1 i s a l s o t h e i n f l u e n c e t i m e o f u ) . F o rt h e s e c o n d c a s e ( F i g u r e 3 . 5 b ) , h o w e v e r , T i N ~ (E ,q ) m u s t b e s e t t o 0b e c a u s e s o m e o b j e c t i n s i d e E ( e . g ., v ) m a y i n f l u e n c e t h e r e s u l t a ss o o n a s t h e q u e r y m o v e s .C om put e _I n t e r s e c t i on _Pe r i od ( o , q )1. [Ts,Te)=[0,oo]2. for each dime nsion i2. com pute disappearance t ime o.TiDse, q.TiDsP3. TDse=min(o.TDsP, q.TDsP)4. T i L R = ( O i L - - q i R ) / ( q . V i R - - O . V i L )5. if TiLR

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    6/12

    that o and q do not disappear before. The algorithm for computingTp~ is give n in Figure 3.7.

    ~L~4 ~R~sq i L = 0 q i R = 1 0F i g u r e 3 .6 : Example of partial intersection time

    Compute PI Time (E, q, [Ts,Te))/*call this fimction ifq contains E at the current im e; thus Ts=0*/1. Tpt=oo2. for each dimension3. T~.L=(Eu~-qtL)/(q.VtL-E.VuL)4. Tipa~=(EtR-qiR)/(q.V~R-E.ViR)5. if TiLL~ Ts,Te) and TiR.R~ Ts,Te)6. Tipi=min(TiLL,UtR)7. if TiLLE Ts,Te) and TiRR~ Ts,Te)8. T~= TiLL9. if TiLL~ Ts,Te) and TutR~ Ts,Te)10. TiPi= Tiaa11. if TiLLS Ts,T) and TiRR~ Ts,T)12. TiPi= o13. Tpt=min(Tpi,Ttpi)14. returnTpiend Compute PI Time

    F i g u r e 3.7: Algorithm for comput ing TpiHaving defined Tnw for leaf and intermediate entries, we cane m p l o y any BaB algorithm to find the objects o with the minimu minfluence time Tn~(o,q), which is exactly the expiry time of theTP query. Next we address TP KNN queries.3 .2 T h e T P K N e a r e s t N e i g h b o r Q u e r yWe first consider single nearest neighbor (TP NN) queries beforeextending the solution to an arbitrary number of neighbors. Tofacilitate understanding, we present our solution for point data in2D space, although the discussion extends to rectangle objects(where the rationale is the same but the equations more complex).Our analysis focuses on deriving TiNF(o,q) and Tn~ (E,q ).Let P~r~ be the current nearest neighbor of q. The influence timeT l ~ (o ,q ) of an object o is the earliest t ime t in the future such thato(t) starts to get closer to q(t) than P~ov(t),where PRy(t), o(t), q(t)are the positions of P/cm o, q at time t respectively. In general,T ~ ( o , q ) is the mini mum t that satisfies the fo llowing conditions3:IIo(t),q(t)ll-O.If (ol ... . o~) are the coordinates,and (O.Vl,...o.V~) the velocities of a moving point o ondimensions i=1 .... ,n, the above inequality can be transformed intothe standard form Afl+Bt+C_

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    7/12

    S e l P l a n e _ A p p r o x _ m i n d i s t (E, q)1. if q is contained in E at the current t ime2. re turn NIL /*no edge se lected s ince TiNF(E,q)=O*/3 . s e ld im =ni l /*d im e ns ion selected plane is perpendicular to*/4. coord=velocity=nil /*the coordinate and velocity of the selectedp l a ne on d i m e ns i on sel_dim*/5. plane_dist=-oo /*the distance from q to the selected plane at thecurrent t ime*/6. for each dim ension i7. if qiplane_dist) /*q is further to the plan e on thisdim ension han previous dimensions*/9. sel dim=i; plane_dist=E iL-qi1 0 . c o o r d = E i L ;elocity=E.ViL11. else if qi>EiR12. if (qi-EiR>plane_dist) /*q is further to the plan e on thisdim ension than previous dimensions*/13. sel dim=i; plane_dist=qi-EiR1 4 . c o o r d = E i g ;elocity=E.V ig15. return the selected plan e (at posit ion coord o n d i m e n s io n sel_dim,m ov i ng at velocity)en d Se l_Plane _Approx _m indi s tF i g u r e 3 . 1 0 : S e l e c ti n g a p l a n e to a p p r o x i m a t e m i n d i s t

    W i t h o u t l o s s o f g e n e r a l i ty , a s s u m e t h a t t h e p l a n e I r e t u r n e d b y t h ep s e u d o - c o d e o f F i g u r e 3 . 1 0, i s p e r p e n d i c u l a r t o t h e i th d i m e n s i o na t p o i n t l i, a n d m o v e s a l o n g t h e d i m e n s i o n a t s p e e d l . V i . T i N F( E,q )i s th e m i n i m u m t th a t s a t i s fi e s th e c o n d i t i o n mindis t( l ( t ) ,q( t) ) _0 . U s i n g t h e u s u a l n o t a t i o n f o r q , t h e a b o v ei n e q u a l i t y i s e q u i v a l e n t t o :

    / I , o(q,-l,)+t.(q.V~-l.V~)l _< , - q , + t . . V ~ -q .,=w h i c h c a n b e t r a n s f o r m e d t o t h e s t a n d a r d ( a n d e a s i l y s o l v a b l e )fo rm At 2+B t +C _ 0 ( i .e . , o l a n d O e d on o t s a t i s f y t h e c o n d i t i o n ) , w h e r e [ T s , T e ) i s t h e i n t e r s e c t i o np e r i o d o f o b j e c ts o l a n d o 2

    T rNr(E t ,E 2) =T ~, wh e re T ~ i s t he s t a r t i ng po i n t o f t hei n t e r s e c ti o n p e r i o d [ T~ ,T e ) o f E 1 a n d E 2 ( u n l i k e T P w i n d o wq u e r i e s , th i s c a s e a l so i n c l u d e s c o n t a i n m e n t )

    T h e i n t e r s e c t i o n p e r i o d [ T~ ,T e ) f o r o b j e c t a n d i n t e r m e d i a t e e n t r yp a i r s i s c o m p u t e d b y t h e a l g o r i th m o f F i g u r e 3 .4 .3 .4 Q u e r y P r o c e s s i n gB o t h d e p t h - a n d b e s t - f i r s t s e a r c h ( a s d i s c u s s e d i n s e c t i o n 2 ) c a n b eu s e d f o r p r o c e s s i n g T P q u e r i e s . F i g u r e 3 . 1 2 ( D F ) a n d 3 . 1 3 ( B F )s h o w t h e p s e u d o - c o d e f o r w i n d o w q u e r ie s . T h e a l g o r i th m s u s et h r e e g l o b a l v a r i a b l e s R , T a n d C t o s t o r e t h e th r e e o u t c o m e s o f aq u e r y . I n o r d e r t o o b t a i n t h e c u r r e n t r e s u l t (R ) , b o t h a l g o r i th m sv i s i t e n t r i e s th a t i n t e r s e c t t h e o r i g i n a l w i n d o w a l t h o u g h t h e T n q F o ft h e s e e n t r ie s m a y b e g r e a t e r t h a n t h e m i n i m u m i n f l u e n c e t i m e ( T ) .F u r t h e r m o r e , w e n e e d t o d i s t i n g u i s h b e t w e e n ( i ) T iN F (O ,q )< T a n d( i i ) T i NF ( O, q) =T . I n t he f i r s t c a s e , o be c om e s t he on ly ob j e c t t ha ti n f l u e n c e s th e r e s u l t s o f a r , w h i l e i n t h e s e c o n d c a s e o i s a d d e d t ot h e s e t o f i n f l u e n c i n g o b j e c t s C ( i t i s p o s s i b l e t h a t m u l t i p l e o b j e c t sw i l l e n t e r o r e x i t t h e q u e r y w i n d o w a t t h e s a m e t i m e ) . T h ea l g o r i th m s f o r T P j o i n s a r e s i m i la r to t h o s e o f C P q u e r i e s . I np a r t i c u l a r , t h e y t r a v e r s e t h e R - ( o r T P R - ) t re e s o f t h e t w o d a t a s e t ss i m u l t a n e o u s l y , f o l l o w i n g p a i r s o f i n t e r m e d i a t e e n t ri e s (E l ,E2) , i fo n e o f t h e f o l l o w i n g c o n d i t i o n s h o l d s : ( i) th e M B R s o f E l a n d E 2i n t er s e c t (s o s o m e o b j e c ts m a y s a t i sf y t h e j o i n c o n d i t i o n i n t h e i rs u b t r e e s ) , o r ( i i ) T iN F (E 1 ,E 2 ) i s l e s s t h a n t h e m i n i m u m i n f l u e n c et i m e o f a ll o b j e c t p a i r s s e e n s o f a r ( i n th i s c a s e t h e i r s u b t r e e s m a yc o n t a i n o b j e c t p a i r s t h a t t r i g g e r t h e n e x t r e s u l t c h a n g e ) .

    3 4 0

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    8/12

    De p t h- f i r s t T P Wi n dow _Que ry ( c u rre nt node N)/*invoke by passing the roo t of R-tree*//*initially: T=oo, R=O, C = 0 */1. i f N i s a leaf2. for each object o3. if TINF(o,q)

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    9/12

    s , t o g e t t h e f i r s t N N ( R = { a } ) , t h e v a l i d i t y p e r i o d o f t h e r e s u l t (Tc o r r e s p o n d s t o p o i n t P l ) a n d t h e n e x t n e a r e s t n e i g h b o r ( C = { b } ) .T h e n , r e t r i e v e t h e T P c o m p o n e n t ( i . e . , C a n d T ) a t t h e p o i n t sw h e r e t h e r e i s a c h a n g e i n t h e r e s u l t ( i . e ., P l a n d P2), o r t h e p o i n t sw h e r e i s a c h a n g e i n t h e q u e r y d i r e c t i o n ( i. e ., p ) . T h a t i s , t h ep r o c e s s i n g o f t h e q u e r y i n v o l v e s o n e ( r e g u l a r ) N N s e a r c h , a n df o u r ( i n c l u d i n g t h e p o i n t o f o r i g i n ) c o m p u t a t i o n s o f t h e T Pc o m p o n e n t . T h i s repetitive a p p r o a c h c a n b e a p p l i e d fo r a n y q u e r yt y p e a n d t e r m i n a t i n g c o n d i t i o n s , s u c h a s " s t o p w h e n t h e r e s u l tc h a n g e s n t i m e s " , " s t o p w h e n t h e r e s u l t c o n t a i n s n o b j e c t s " , " s to pw h e n t h e q u e r y r e a c h e s a c e r t a i n p o i n t i n s p a c e " , e t c .M o r e e f f i c i e n t m e t h o d s a r e p o s s i b l e f o r c o n t i n u o u s q u e r i e s w h e r et h e i n f l u e n c e t i m e o f a n o b j e c t d o e s n o t d e p e n d o n t h e o t h e ro b j e c t s , b u t r e m a i n s c o n s t a n t t h r o u g h o u t t h e l i f e s p a n o f th e q u e r y( e . g ., T P w i n d o w s , j o i n s ) . C o n s i d e r f o r i n s t a n c e , a v a r i a t i o n o f t h ep r e v i o u s e x a m p l e w h e r e t h e g o a l i s t o " f i n d t h e p o i n t s w i t h i n l k mr a n g e d u r i n g m y r o u t e f r o m s t o e , t h r o u g h i n t e r m e d i a t e p o i n t p "( s e e F i g u r e 4 .2 ) . T h e r e s u l t ( < 0 , [ s , p ~ ) > , < { a } , [ P l , P2 )>, < 0, [P2,p3)>, . . . ) C a n b e d e t e r m i n e d b y a p p l y i n g t w i c e as l ig h t l y m o d i f i e d v e r s i o n o f t h e B F TP_Window a l g o r i t h m . T h ef i r s t a p p l i c a t i o n w i l l r e t r i e v e a l l o b j e c t s i n t e r se c t i n g W i ( a l l t h ea r e a t h a t th e q u e r y r a n g e w i l l c o v e r f r o m s t o p ) , w h i l e t h e s e c o n da p p l i c a t i o n w i l l c o v e r W E ( t h e a r e a c o v e r e d f r o m p t o e ) . W h e n a no b j e c t i s e n c o u n t e r e d , t w o i n f l u e n c e t i m e s ( t h e b e g i n n i n g a n d e n do f i t s s a t i s f a c t i o n p e r i o d ) a r e i n s e r t e d i n t o t h e h e a p u n t i l t h et e r m i n a t i o n c o n d i t i o n h o l d s . T h e r e s u l t i s th e n e a s i l y o b t a i n e d b yt h e o r d e r o f t h e o b j e c t s in t h e h e a p . T h i s continual a p p r o a c h c a na l s o b e m o d i f i e d f o r v a r i o u s t e r m i n a t i n g c o n d i t i o n s , b u t i s n o ta p p l i c a b l e t o q u e r i e s ( e .g . , N N ) w h e r e t h e i n f l u e n c e t im e s c h a n g ed u r i n g t h e q u e r y .

    point a s tarts to belong in the resul tF i g u r e 4 .2 E x a m p l e o f c o n ti n u o u s w i n d o w q u e r y

    4 . 2 E a r l ie s t E v e n t Q u e r i e sAn earliest event q u e r y r e t r i e v e s t h e f i r st f u t u r e t i m e t h a t a c e r t a i n" e v e n t " c a n h a p p e n i n s o m e d y n a m i c e n v i ro n m e n t . A l t h o u g h s u c hq u e r i e s c a n n o t b e c h a r a c t e r i z e d a s c o n t i n u o u s ( t h e y r e t u r n as i n g l e r e s u l t w i t h n o v a l i d i t y p e r i o d ) , t h e i r p r o c e s s i n g i s d i r e c t l yr e l a t e d t o T P q u e r i e s . F i g u r e 4 . 3 a s h o w s a n e x a m p l e , w h e r e t h eg o a l i s t o d e c i d e a m o v e m e n t d i r e c t i o n f o r t h e q u e r y p o i n t q( w h o s e m a x i m u m s p e e d i s 1 ) s u c h t h a t q c a n " c a t c h " o n e o f th ep o i n t s a s s o o n a s p o s s i b l e ( e . g . , a p e r s o n t r y i n g t o c a t c h a b u s ) . I nt h is e x a m p l e , i f q m o v e s t o w a r d s Dr, 02, and D3 , the f i r s t po in t st h a t i t w i l l e n c o u n t e r a r e e , f , a n d b ( a t t im e 3 , 3 , 2 ) r e s p e c t i v e l y . I tc a n b e e a s i l y v e r i f ie d t h a t d i r e c t i o n D3 i s i n d e e d t h e d i r e c t i o nt o w a r d s w h i c h q c a n c a t c h t h e e a r l i e s t p o i n t .E a r l i e s t e v e n t q u e r i e s c a n a l s o b e r e d u c e d t o n e a r e s t n e i g h b o rs e a r c h b y d e f i n i n g a p p r o p r i a t e T m F . A t a n y f u t u r e t i m e t , a l l t h ep o s s i b l e p o s i t i o n s th a t c a n b e r e a c h e d b y t h e q u e r y p o i n t qc o n s t i t u t e a vicinity circle cen te r ed a t q (0 ) ( i . e . , t he in i t i a l pos i t i ono f q u e r y q ) w i t h r a d i u s t .q .V ( q .V i s t h e m a x i m u m v e l o c i t y o f q ) .F i g u r e 4 . 3 b d e m o n s t r a t e s t h e v i c i n i t y c ir c l e o f q a t t i m e 2 . T h e

    ear l i es t t ime TIN F(O ,q) tha t a n o b jec t o ca n be cau gh t by q ( i . e . , of a l l s in t o t h e v i c i n i t y c i r c l e o f q ) i s t h e m i n i m u m t f o r w h i c h :IIo(t),q(O)ll_0 . Fo r in t e rm edia t e en t r i es , TiNF(E,q)c o r r e s p o n d s t o t h e e a r l i e s t t i m e t h a t q c a n c a t c h a n y p o i n t c o v e r e db y t h e M B R o f E , w h i c h i s t h e e a r l i e s t t i m e t s u c h t h a t E i n t e r s e c t st h e v i c i n i t y c i rc l e o f q a t t ( F i g u r e 4 . 3 c s h o w s a c a s e w h e r eT iN F(E ,q)=2). Thu s , T iN F(E ,q) i s t he mi n im um t t ha t s a t i s f i es thec o n d i t i o n s mindist(E,q)_0. Both thes e inequ al i t i es canb e s o l v e d a s s h o w n i n s e c t i o n 3 .

    d v~ is10

    CLe'cl,I J i 61 I 81 l ]olXa~is"

    ( a ) A n e x a m p l eoxis

    of q at time 2I I I i , , 1 , l i x ~ is

    (b ) T,NF(O,q)=2 (C ) TiN~(E,q)=2F i g u r e 4 .3 : A n e a r l i e st e v e n t p r o b l e m5 . E X P E R I M E N T A L E V A L U A T I O NI n t h i s s e c t io n , w e e v a l u a t e t h e e f f i c i e n c y o f th e p r o p o s e dm e t h o d s t h r o u g h e x t e n s i v e e x p e r i m e n t a t i o n w i t h s t a t i c a n dd y n a m i c d a t a s e t s ( q u e r ie s a r e a l w a y s d y n a m i c ) . A s s t a t i c d a ta s e t sw e u s e t h e L A f i l e [ T i g e r ] , w h i c h c o n t a i n s 1 3 0 K M B R s , a n d t h eC A f i l e [ S e q u o i a ] t h a t c o n t a i n s 6 4 K p o i n t s . D u e t o l i m i t e da v a i l a b i l i t y o f r e a l d a t a s e t s o f m o v i n g o b j e c t s , w e g e n e r a t e dd y n a m i c d a t a s e t s ( d e n s i t y = 0 . 5 ) w h e r e a l l v e l o c i t y c o m p o n e n t s o fo b j e c t s d i s t r ib u t e u n i f o r m l y i n [ - 0 . 1 , 0 . 1 ]. T h e c a r d i n a l i t y r a n g e sb e t w e e n 1 0 K a n d 1 00 K , w h i l e t h e d i s t r i b u t i o n o f o b j e c t s a t t h ec u r r e n t t im e c a n b e G a u s s i a n o r u n i f o r m i n a u n i t u n i v e r s e . I n th es e q u e l , w e r e f e r t o a s y n t h e t i c r e c t a n g l e d a t a s e t as RDDisT CARD,w h e r e D I S T a n d C A R D a r e i t s d i s t r i b u t i o n a n d c a r d i n a l i t y .S i m i l a r l y , sy n t h e t i c p o i n t d a t a s e t s a r e d e n o t e d a s P D D I sT ,CARD"T h e R - a n d T P R - t r e e i m p l e m e n t a t i o n s a re b a s e d o n [ B K S S 9 0 ]a n d [ S J L L 0 0 ] , r e s p e c t iv e l y . T h e d i s k p a g e i s s e t to 1 K b y t e s . W i t ht h i s s i z e , t h e n o d e c a p a c i t y in R - ( T P R - ) t r e e s i s 4 8 ( 2 6 ). U n l e s ss t a t e d o t h e r w i s e , a n L R U b u f f e r w i t h 5 0 p a g e s i s a s s u m e d .P e r f o rm a n c e i s m e a s u r e d b y t h e a v e r a g e n u m b e r o f d i s k a c c e s s e si n p e r f o rm i n g w o r k l o a d s o f 2 0 0 d y n a m i c q u e r ie s . T h e p o s i t io n s o fq u e r i e s i n a w o r k l o a d c o n f o r m t o t h e d i s t r i b u t i o n o f t h e q u e r i e dd a t a s e t i n o r d e r t o a v o i d q u e r i e s i n e m p t y s p a c e . T h e q u e r yv e l o c i t i e s r a n g e u n i f o r m l y i n [ - 0 . 1 , 0 . 1 ]. A l l w i n d o w q u e r i e s i n aw o r k l o a d h a v e t h e s a m e s i d e l e n g t h , d e n o t e d a s a p e r c e n t a g e o ft h e u n i v e r s e e x t e n t . W e f i r s t p r e s e n t t h e r e s u l t s f o r R - t r e e s o ns t a t ic d a t a s e t s , f o l l o w e d b y T P R - t r e e s o n d y n a m i c d a t a s e t s .

    3 4 2

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    10/12

    5 . 1 S t a t i c D a t a s e t sT h e f i r s t s e t o f e x p e r i m e n t s e v a l u a t e s th e p e r f o r m a n c e o f T Pw i n d o w q u e r i e s u s i n g L A d a t a s e t . S i n c e a T P q u e r y r e t r i e v e sm o r e i n f o r m a t i o n t h a n i t s c o n v e n t i o n a l c o m p o n e n t , i t i s a t l e a s t a se x p e n s i v e . I n o r d e r t o a s s e s s t h e a d d i t i o n a l c o s t , w e p e r f o r m T Pw i n d o w q u e r i e s w i t h e x t e n t s r a n g i n g f r o m 2 % t o 1 0 % ( i . e . ,c o v e r i n g u p t o 1 % o f t h e s p a t i a l u n i v e r s e ) . F ig u r e 5 . 1 a c o m p a r e st h e n u m b e r o f p a g e a c c e s s e s u s i n g t h e B F a n d D F a p p r o a c h , w i tht h a t o f t h e r e g u l a r q u e r ie s . B o t h D F a n d B F i n c u r m a r g i n a lo v e r h e a d ( 2 - 3 I / O s ) . T h i s i s e x p e c t e d b e c a u s e i n c a s e o f T Pw i n d o w s ( a n d j o i n s ) t h e c o n v e n t io n a l a n d T P c o m p o n e n t s a r ep r o c e s s e d i n a s i n g l e p a s s . T h e o b j e c t s w i t h t h e m i n i m u mi n f l u e n c e t i m e , a r e m o s t o R e n i n s i d e n o d e s t h a t i n t e r s e c t t h e q u e r yw i n d o w n o w , a n d t h e r e fo r e w i l l b e r e t r ie v e d b y t h e c o n v e n t i o n a lc o m p o n e n t a n y w a y .

    , ,

    o 2 % 4 % 6 % S % 10 %query( a ) C o s t o f T P w i n d o w q u e r ie s

    I l l w i ~ d o ~ q u e r y [ - ~0 2 % 4 % 6 % 8 % 1 0 %query siz*

    ( b ) C o s t o f T P c o m p o n e n tFigure 5 . 1 : T P w i n d o w q u e r y e v a l u a t i o n f o r s ta t i c d a t a s e tsI n o r d e r t o f u r t h e r a n a l y z e T P w i n d o w q u e r i e s , w e e v a l u a t e t h es a m e w o r k l o a d s w i t h o n l y t h e t i m e - p a r a m e t e r iz e d c o m p o n e n t s ,i . e ., w e r e t r i e v e t h e e x p i r y t im e a n d c h a n g e , b u t n o t t h e c u r r e n tr e s u l t . A s s h o w n i n F i g u r e 5 . 1 b , p r o c e s s i n g t h e T P c o m p o n e n t i su s u a l l y c h e a p e r t h a n r e g u l a r s p a t i a l q u e r i e s , a n d t h e d i f f e r e n c ei n c r e a s e s w i t h t h e q u e r y w i n d o w . T h i s i s e x p l a i n e d b y t h e f a c tt h a t t h e s e a r c h a r e a o f a T P w i n d o w q u e r y ( F i g u r e 3 . 1 4 a ) i su s u a l l y v e r y s m a l l , e s p e c i a l l y w h e n t h e o b j e c t t ri g g e r i n g t h ec h a n g e i s c l o s e .T h e e x c l u s iv e r e tr i e v al o f t h e T P c o m p o n e n t m a y b e p e r f o r m e d b yth e repetitive a p p r o a c h ( a s d i s c u s s e d i n s e c t i o n 4 . 1 ) d u r i n g t h ee v a l u a t i o n o f c o m p l e x c o n t i n u o u s q u e r i e s . I n c a s e o f w i n d o wq u e r i e s h o w e v e r , t h e continual a p p r o a c h ( a l s o d i s c u s s e d i ns e c t i o n 4 . 1 ) i s o b v i o u s l y m o r e e f f i c ie n t s in c e i t o n l y p e r f o r m s o n eq u e r y ( p r o v i d e d t h a t t h e v e l o c i t y v e c t o r o f t h e q u e r y r e m a i n sc o n s t a n t ). F i g u r e 5 . 2 d e m o n s t r a t e s t h e p a g e a c c e s s e s o f t h ec o n t i n u a l a p p r o a c h f o r w i n d o w q u e r i e s ( e x t e n t 6 % ) a s a f u n c t i o no f t h e n u m b e r o f r e s u l t c h a n g e s r e t ri e v e d .

    disk accesses

    42

    383 4 - - l - - B F

    30 I I I I5 0 1 0 0 1 5 0 2 0 0

    n u m b e r o f h a n g e sF i g u r e 5 . 2 : o n t i n u a l w i n d o w q u e r i e s o r s ta ti c a ta s e tsW e n o w p r o c e e d to e v a lu a t e P K N N q u er i es , s i n g p o i n t d a ta s etC A . R e c a l l t h a t p r o c e s s in g a T P K N N q u e r y is a l w a y s d iv i d e di n t o a n o r d i n a r y K N N q u e r y ( t h e f ir st a s s ) , f o l l o w e d b y t h e T Pc o m p o n e n t ( t h e s e c o nd p a s s) . F i g u r e 5 . 3 a c o m p a r e s t hep e r f o r m a n ce o f t h e t w o p a s s e s ( f o r T P 1 0 - N N q u e r ie s ) a s a

    f i m c t i o n o f n u m b e r o f (L R U ) b u f f e r p a g e s . W h e n t h e r e i s n ob u f f e r , th e s e c o n d p a s s r e q u i r e s m o r e d i s k a c c e s s e s ; h o w e v e r , t h ep e r f o r m a n c e o f th e s e c o n d s t e p i m p r o v e s f a s t e v e n w i t h a v e r ys m a l l b u f fe r . T h i s i s b e c a u s e t h e t w o p a s s e s h a v e s i m i l a r a c c e s sp a t t e r n s , a n d p a g e s l o a d e d f o r t h e c o n v e n t i o n a l c o m p o n e n t a r el a t e r a v a i l a b l e f o r T P p r o c e s s i n g . T h i s i s f u r t h e r c o n f i r m e d i nF i g u r e 5 . 3 b , w h i c h s h o w s t h e c o s t o f a c o m p l e t e T P q u e r y v e r s u st h a t o f a n o r d i n a r y K N N q u e r y ( c o s t s a r e s h o w n a s a f i m c t i o n o fK ) . N o t i c e t h a t , w h e n t h e r e i s n o b u f f e r , a T P q u e r y i ss i g n i f i c a n t l y m o r e e x p e n s i v e t h a n t h e c o r r e s p o n d i n g K N N q u e r y .T h e a d d i t i o n o f a b u f f e r w i t h C = 5 0 p a g e s , r e d u c e s t h i s d i f fe r e n c ec o n s i d e ra b l y ; t h e c o s t o f a B F T P K N N i s o n l y 1 0 % - 20 % h i g h e rt h a n t h a t o f t h e r e g u l a r q u e r y .

    1 0 ~ - c = c a c n e

    0 2 0 4 0 6 0 8 0 1 0 0 1 5 1 0 1 5 2 0n u m b e r o f b u f f e r p a g e s K - N N( a ) C o s t o f T P c o m p o n e n t ( b ) C o s t o f T P K N N q u e r ie sFigure 5 . 3: T P K N N q u e r y e v a l u a t i o n f o r s ta t i c d a t a s e tsF i g u r e 5 . 4 e v a l u a t e s t h e p e r f o r m a n c e o f c o n t i n u o u s ( s i n g l e ) N Nq u e r i e s ( s i m i l a r t o t h e e x a m p l e o f F i g u r e 5 . 1 a ) a s a f u n c t i o n o f t h er e s u l t c h a n g e s ( e . g . , h o w m a n y t i m e s t h e N N n e i g h b o r w i l l b eu p d a t e d d u r i n g t h e l i f e s p a n o f t h e q u e r y ) . T h e c o s t o f t h er e p e t i ti v e a p p r o a c h g r o w s l i n e a r ly w i th t h e n u m b e r o f q u e r yc h a n g e s r e t r i e v e d . I n c o m p a r i s o n t o F i g u r e 5 . 2 , t h e g r o w t h i sf a s t e r b e c a u s e n o w e a c h c h a n g e t r i g g e r s a n e w T P q u e r y , w h i l e i nt h e c o n t i n u a l a p p r o a c h t h e n u m b e r o f c h a n g e s o n l y a f f e c t sp e r f o r m a n c e i m p l i c i t l y b y i n c r e a s i n g t h e e x t e n t s o f th e q u e r yw i n d o w i n t h e f u t u r e . N e v e r t h e l e s s , a s d i s c u s s e d b e f o r e , t h ec o n t i n u a l a p p r o a c h i s n o t a p p l i c a b l e f o r T P N N .

    3 0 0 " d i s k a c c e s s e s2 5 0 ~ D F2 0 0 [ ] B F15 0I 0 0

    3~3 3~1 5 0 1 0 0 1 5 0 2 0 0n u m b e r o f c h a n g e sFigure 5 . 4: P e r f o r m a n c e o f c o n t i n u o u s K N N q u e r i e s

    T P j o i n s a r e m e a n i n g l e s s f o r s t a t i c d a t a s e t s , s i n c e a t l e a s t o n ed a t a s e t m u s t b e d y n a m i c i n o r d e r t o c h a n g e t h e r e s u l t . D y n a m i cd a t a s e t s a r e e v a l u a t e d i n t h e n e x t s e c t i o n .5 . 2 D y n a m i c D a t a s e t sI n o r d e r t o t e s t t h e v a l i d i t y a n d g e n e r a l i t y o f o u r o b s e r v a t i o n s , w er e p e a t e d t h e e x p e r i m e n t s o f t h e p r e v i o u s s e c t i o n u s i n g d y n a m i cda tase ts DS6Au.100K and PScAu,~00K (w ith 100K rec tang les a ndp o i n t s r e s p e c t i v e l y ) i n d e x e d b y T P R - t r e e s . F i g u r e s 5 . 5 t o 5 . 8cor r es pond to the d i ag rams in F igures 5 . 1 to 5 . 4 . The r es u l t s a r ev e r y s i m i l a r ( w i t h d y n a m i c d a t a s e t s b e i n g , i n g e n e r a l , m o r ee x p e n s i v e t o p r o c e s s ) a n d w e s i m p l y o u t l i n e t h e c o n c l u s i o n s : ( i )T P w i n d o w s i n v o l v e a l m o s t t h e s a m e c o s t a s t h e i r t r a d i t i o n a l

    3 4 3

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    11/12

    counterparts, s ince they, more or less, acces s the same no des, ( i i)TP KNN are more expensive than regular KNN queries, but thecost d if ference is insignif icant if a (small) buffer is used, ( i i i) BFoutperforms DF, but the gain is important only for continualqueries that extend far into the future (iv) the continual approach,whenever applicable, is preferable to the repetit ive method ofpro cess in g co n t in uo us quer ie s.3(~ [ ] OF ~ 300 [] DFH 1 I [ I o . , ]o ~ r . . . . a e ry 2 0 0 1 UWindowqueryi o o I ~

    2 % 4 % 6 % 8 % 1 o % [ ~ I , ~ . . . .2% 4% 6% 8% l iP /*q~cr s i z e s q u c ~ , ~z ~(a ) Co st o f T P w in d o w quer ie s (b ) Co st o f T P co mpo n en tF igu re 5 .5: T P w in d o w query eva luat io n fo r d y n amic d atase ts

    17 0 d i s k a c c e s s e s1 6 5 + D F

    15 515 014 514 0 , I , ,

    5 0 1 0 0 1 5 0 2 0 0n m n b e r o f c h a n g es

    F igu re 5 .6: Co n t in ua l w in d o w quer ie s fo r d y n amic d atase tsd i s k

    - d i s k a r . c e u e l ae ce s~ DF(C -50) ~ B F~ C -50) n K-NN(C-50)30 -4-- - DF(NC ) 4- -- B F(NC ) ~ KNN(NC )2 5 N C = m u t c h e

    10i i i ~ J2O 40 60 80 IO O

    number of paffa plges I 5 I0 15 20K-bIN(a ) Co st o f T P co mpo n en t (b ) Co st o fT P K N N quer ie sF igu re 5 .7 : T P K N N query evaluat ion fo r d y n amic d atase ts

    5 0 0 d i s k accesses

    4 0 0 [ ] D F [ - - L _ _0 B F

    30 0

    0 ~.al ~ S3 I i i q i1 5 0 1 0 0 1 5 0 2 0 0F igu re 5 .8: Per fo rman ce o f co n t in uo us K N N qu er ie s

    For testing TP Joins, we generated several dynamic rectangledatasets with different d istributions and cardinalit ies: DScAu,10K,DSGAu,50K, DSuNI,10K, DStm LsoK , DSuNI,100K.The f irst experiment(Figure 5 .9a ) pe r forms TP jo ins on uniform and Ganssian datasetsof the same cardinality , and compares the costs (page acce sses )with that of ordinary spatial jo ins ( implemented based on[BKS93]) a s a function of cardinality. TP join s are sl ightly moreexpen s ive b ecause: ( i ) so me ex tra n o d es sh o u ld b e accessed fo robjects producing the next result change, and (i i ) TP jo in s d eplo ydifferent visit ing orders from ordinary joins, which involve

    several heuristics to improve the access locality and util ize thebuffer [BKS93].An interesting observation is that, unlike TP window and KNNquer ie s , f or T P jo in s B F i s o utper fo rmed b y D F . T h is i s d ue to th efact that best-f irst traversal leads to worse access locality; thus, itis favored less by buffers (recall that we use a buffer of 50 pages).T h e same ph en o men o n w as o b served in [CMT V 00] fo r c lo ses tpair queries. Figure 5.9b further confirms this by i l lustrating theco sts o f th e tw o approach es un d er var io us b uf f er s ize s ( fo r jo in in gDSGAu.50K, DStn~n.50~- Fo r zer o buffer, D F and BF have alm ost thesame cost, but the addition of a small buffer is more beneficial toD F .

    2 0 0 0 0 " d i s k a c c e n e s D F

    1 5 0 0 0 [ ] B F J o i n

    1 0 0 0 0

    5O0O

    ~ - / 1 ,0 l O k 5 0 k

    15000

    15000

    10000

    50ooI O O k

    "ditk ~ D F

    i i i i i20 4O 60 80 I00n m b l n " o f b t t f f c ! x l t ~

    (a) TP join cos t vs. cardinality (b) TP join cos t vs. buffer sizeF igu re 5 .9 : T P jo in eva luat io n fo r d y n amic d atase tsNext w e s tud y co n t in uo us jo in s , w h ere w e re tr ieve th e curren tresult and the subsequent 1 , . . ,200 changes. Figure 5.10a showsth e n umb er o f page acces ses a s a f imct io n o f th e n umb er o f re su l tch an ges. T h e co s t i s a lmo s t co nstan t, even i f up to 200 ch an gesare retrieved. This is explained by the fact that the most import~tfactor in the total cost is the conventional component ( i .e . ,retrieval of the current result) . The TP component is minimal incomparison and does not affect the result s ignif icantly . Finally , wejoin a dynamic dataset (DScAu.100Q with a static one (LA). Theresults are similar to that of Figure 5.10a and in both cases DFoutperforms B F.

    8800 " d i s k a c c u s e s8600 = ~ -84OO82008 O O O78OO76OO74OO

    160GO d i r t "-'~',"-~'~

    1 5 0 0 0

    1 4 0 0 0

    1 3 0 0 0D F - 4 1 - - B F - - ~ - - D F - - I - - B Fi i i r i 1200 0 I I i I

    I 50 100 150 200 1 50 100 150 200n u m b e r o f c h a n g e s n u m b e r o f c h a n g e s(a) Dy namic datasets (b) Dy namic/static dataset

    F ig ure 5 .10: Co n t in uo us T P jo in s6 . C O N C L U S I O NRegular spatial queries are of l imited use in dynamicenvironments, unless the results are accompanied by an expectedvalidity period. In this paper we propose a general framework fortransforming any spatial query to a t ime-param eterized versionwhich, in addition to the current result , returns its ex piry t ime andthe changes. As shown in the experimental evaluation, the extrainformation is obtained at zero or minimal cost. W e belie ve thatour techniques are crucial for many emerging applications thatdeal with spatio-temporal data, such as mobile communicationsand weather prediction. The contributions of the paper aresummarized as fo l lo w s:

    3 4 4

  • 8/2/2019 Time-Parameterized Queries in Spatio-temporal Databases

    12/12

    I n t r o d u c ti o n o f t h e n o v e l c o n c e p t o f t i m e - p a ra m e t e f i z e dqueries. T e c h n i q u e s f o r t r a n s fo r m i n g t h e m o s t c o m m o n s p at ia lqu e r ie s to th e i r T P co u nte rp a rt s . Dev e lo p m ent o f e f fic ient p ro cess ing me th o d s . A p p l i c a t io n to o th e r q u e r y t y p e s s u c h a s c o n t i n u o u s a n dearl ies t even t queries .Al though we tr ied to cover several issues, there s t i l l exis tn u m e r o u s c h a l l e n g i n g p r o b l e m s a n d d i r e c t i o n s f o r f u t u r e w o r k .An o bvio u s o ne i s th e extens io n to o th e r qu e ry typ es . Fo rexamp le , a TP c lo ses t p a i r (TP CP) qu e ry id ent i f i e s fu tu rech ang es in th e c lo se s t p a ir s o f o bj ec t s f ro m tw o d ynam ic d a ta se ts( e .g . , " info rm a se t o f cu s to mers abo u t wh en th e i r nea re s t cabswi l l ch ange" ) . As wi th TP K NN qu e r ie s , th e inf lu ence t ime o f ap a i r o f o b j e c ts ( c u s t o m e r , c a b ) in t h e T P C P p r o b l e m d e p e n d s o nthe c losest pair now. Thus, an eff ic ient definit ion for TMiN(Ei,E2)i s d if f icu l t, becau se i t r equi res th e k no w led ge o f nea re s t cabs o fa l l cu s to mers .Fu r th e rmo re , no t ice th a t s eve ra l qu e r ie s d i scu ssed in th i s p ap e rc a n b e f o r m u l a te d a s c o m p u t a t i o n a l g e o m e t r y p r o b le m s .Co n t inu o u s KN N, fo r examp le , can be d e f ined a s fo l l o ws : g iven aset of points and a qu ery tra jectory, re tr iev e al l poin ts that aream o ng th e K nea res t ne igh bo rs o f any p o in t o n th e t r aj ecto ry. Ou rsolution (based on the repeti t ive approach) is output-sensit ive .Th e re m ay exis t o th e r me th o d s ( e .g. , ex tens io ns o f Vo ro no id i a g r am s ? ) w h e r e t h e r e s u l t i s i n d e p e n d e n t o f t h e n u m b e r o fch ang es and , th e re fo re , th ey ma y be p re fe rabl e fo r l o ngtrajectories . In any case, i t wo uld be interest in g to obtainth eo re t ica l bo u n d s fo r th e p e r fo rma nce o f TP and co nt inu o u ssp a t io - temp o ra l qu e r ie s .A C K N O W L E D G E M E N T ST h i s w o r k w a s s u p p o r t e d b y g r a n t s H K U S T 6 0 8 1 / 0 1 E a n dH K U S T 6 0 7 0 / 0 0 E f ro m H o n g K o n g R G C .

    REFERENCES[AAE00] Agarwa l , P .K. , Arge , L . , Er ick so n, J . I nd exingMo ving Po ints. A C M S IG M O D , 2 0 0 0 .[BBK K97 ] Berch to ld , S . , Bo h m , C. , Ke im , D .A. , Kr iegel , H . AC o s t M o d e l f o r N e a r e s t N e i g h b o r S e a r c h i n H i g h -Dimensional D ata Space. A C M P O D S , 1997.[BEK+98] Berchtold , S. , Ertl , B. , Keim, D. , Kriegel , H. , Seidl , T.

    Fas t Nea re s t Ne igh bo r Sea rch in High -Dimens io na lSpace. I E E E I CD E , 1998.[BB K+ 01] Berchtold , S. , Bohm , C. , Keim, D. , Krebs, F. , Kriegel ,

    H.P. On Op t imiz ing Nea re s t Ne igh bo r Qu er ie s inHigh -Dimens io na l Da ta Sp aces . ICDT, 2 0 0 1 .[BJS S98 ] Bl iuju te , R. , Jensen, C.S. , Sal tenis , S. , Sl ivinskas, G.

    R- t ree Based Ind exing o f No w-R e la t ive Bi temp o ralData . V L D B 1998.[BK S93 ] Brinkhoff , T. , Kriegel , H.P. , Seeger, B. Effic ientPro cess ing o f Sp at ial J o ins U s ing R- t rees . A C MSIGMOD, 1993.[BKSS90] Beck mann, N. , Kr iege l , H.P . , Sch ne id e r , R . , Seege r ,B. Th e R*- t ree : An Ef f ic ient and Ro bu s t AccessMeth o d fo r Po in t s and Rec tangle s . A C M S IG M O D ,1990.

    [CD TW 00] Ch en, J . , DeWit t , D . J . , T ian , F ., Wang , Y . Niaga raCQ :A S c a l a b l e C o n t i n u o u s Q u e r y S y s t e m f o r I n t e r n e tDatabases . A C M S IG M O D , 2 0 0 0 .[CG99] Ch au d h u r i , S . , Gravo n a , L . Eva lu a t ing To p -KSelection Queries . V L D B , 1999.[ C M T V 0 0 ] C o r r a l, A . , M a n o l o p o u l o s , Y . , T h e o d o f i d i s , Y . ,Vass i l ak o p o u lo s , M. Clo ses t Pa i r Qu e r ie s in Sp a t ia l

    Databases . A C M S IG M O D , 2 0 0 0 .[CPZ 98] Ciacc ia , P . , Pa te ll a , M. , Zez u la , P . A Co s t Mo d e l fo rSimilari ty Queries in Metric Spaces. A C M P O D S ,1998.[HS9 9] Samet, H. , Hjal tason, G. Dista nce Bro ws ing in Spatia lDatabases . A C M T O D S, 1999.[KGT 99] Ko l l io s , G. , Gu no p u lo s , D . , Tso t ra s , V. On Ind exingMobile Objects . A C M P O D S , 1999.[KSF+96] Ko m, F . , S id i ro p o u lo s , N. , Fa lo u tso s , C. , S iege l , E ,

    Pro to p ap as , Z . Fas t Nea re s t Ne igh bo r Sea rch inMed ica l Image Da tabases. V L D B , 1996.[ P M 9 7 ] P a p a d o p o u l o s , A . , M a n o l o p o u l o s , Y . P e r f o r m a n c e o f

    Nea re s t N e igh bo r Qu er ie s in R- tree s. ICDT, 1997.[RKV 95] Ro u s so p o u lo s , N. , Ke lly , S ., Vincent , F . Nea re s tNe ig h bo r Qu er ie s. A C M S 1 G M OD , 1995.[Sequ o ia ] h t tp : / /d ia s . c t i . gr / -y th eo d / re sea rch /d a ta se t s /spatial.html.[SJLL 00] Sal tenis, S. , Jensen, C. , Leutenegger, S . , Lo pez, M.

    I n d e x i n g t h e P o s i t i o n s o f C o n t i n u o u s l y M o v i n gObjects . A C M S IG M O D , 2000.[SK9 8] Seidl , T. , Kriegel , H. Optimal Mu lti-Step K-N eares tNe igh bo r Sea rch . A C M S I G M O D , 1998.[ S R 0 1 ] S o n g , Z . , R o u s s o p o u l o s , N . K - N e a r e s t N e i g h b o rS e a r c h f o r M o v i n g Q u e r y P o i n t. SSTD, 2 0 0 1 .[SW CD 97]Sis t l a , P . , Wo l f so n, O. , Ch amber la in , S . , Dao , S .M o d e l i n g a n d Q u e r y i n g M o v i n g O b j e ct s. I E E E I CD E ,1997.[TGN O92] Te r ry, D . , Go ld be rg , D . , Nich o l s , D . , Ok i , B .

    C o n t i n u o u s Q u e r i e s o v e r A p p e n d - O n l y D a t a b a s e s .A C M S IG M O D , 1992.[Tiger] http://dias.cti.gr/-ytheod/research/datasets/spatial.html.[TUW 98] Tayeb, J ., Ulu so ry , O., Wo l f so n, O. A Qu ad t ree BasedDyn amic At t ribu te Ind exing Meth o d . The ComputerJournal, Vol. 41(3) , pp . , 185-200, 1998.[WSB98] Weber, R. , Schek, H. , Blott , S. A Quanti ta t ive

    Ana lys i s and Pe r fo rm ance Stu d y fo r S imi la r ity-Sea rchMeth o d s in High -Dimens io na l Sp aces . V L D B , 1998.[YO TJ01 ] Yu , C. , Ooi, B.C. , Tan , K.L. , Jagadish , H.V. Index ingth e Dis tance : An Ef f ic ient Me th o d to KNNPro cess ing . V L D B , 2 0 0 1 .

    [ZL01] Zh eng , B. , Lee , D . Semant ic Cach ing in Lo ca t io n-D e p e n d e n t Q u e r y P r o c e s s i n g . SSTD, 2 0 0 1 .

    3 4 5


Recommended