CN103544291B - Mobile object CKNN querying method based on RRN-Tree in road network - Google Patents

Mobile object CKNN querying method based on RRN-Tree in road network Download PDF

Info

Publication number
CN103544291B
CN103544291B CN201310520592.5A CN201310520592A CN103544291B CN 103544291 B CN103544291 B CN 103544291B CN 201310520592 A CN201310520592 A CN 201310520592A CN 103544291 B CN103544291 B CN 103544291B
Authority
CN
China
Prior art keywords
section
query
inquiry
knn
road network
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CN201310520592.5A
Other languages
Chinese (zh)
Other versions
CN103544291A (en
Inventor
孙海龙
王春艳
于鸣
刘丹
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Northeast Forestry University
Original Assignee
Northeast Forestry University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Northeast Forestry University filed Critical Northeast Forestry University
Priority to CN201310520592.5A priority Critical patent/CN103544291B/en
Publication of CN103544291A publication Critical patent/CN103544291A/en
Application granted granted Critical
Publication of CN103544291B publication Critical patent/CN103544291B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9537Spatial or temporal dependent retrieval, e.g. spatiotemporal queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/29Geographical information databases

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Remote Sensing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

Mobile object CKNN querying method based on RRN-Tree in road network, relates to a kind of data enquire method. In order to solve existing employing index structure, road network section is carried out to index, road network is modeled as to oriented/non-directed graph, process arest neighbors inquiry request based on internal storage data structure, but when road network data volume greatly, section is when more, search efficiency sharply reduces; And, based on the modeling pattern of figure, cannot reflect mobile object at the parting of the ways turn to relation, cannot solve and there is crossroad and turn to and the problem of the Complicated Road Network network arest neighbors inquiry of U-shaped turning constraint. It proposes RRN-Tree index structure, road network and point of interest object are carried out to index, while is that the crosspoint on path is set up in abutting connection with chained list in index structure, the annexation between storage Chu Ge section, crossroad, thus complete road network CKNN inquiry under Complex Constraints condition. For road network CKNN inquiry.

Description

Mobile object CKNN querying method based on RRN-Tree in road network
Technical field
The present invention relates to a kind of data enquire method.
Background technology
Along with the development of wireless communication technology with there is the portable equipment such as mobile phone, PDA general of GPS positioning functionAnd position-based service (LBS, LocationBasedService) is able to fast development, be widely used in geography informationThe fields such as system, emergency service, auto navigation and tourism path planning. Space querying and position-based service are closely related, itsIn the continuous K arest neighbors inquiry of mobile object based on road network (CKNN, ContinounsKNearestNeighbors)Be exactly the important inquiry request of a class, can under road network environment, constantly search the nearest K of the given query object of distance individualArest neighbors target, for example, in fire-fighting command, searches 4 fire fighting trucks nearest apart from command centre. Solve the pass of problemsKey is: 1) calculate in real time fast the shortest path between any two mobile objects; 2) maintenance that mobile object location upgradesWith management.
For the CKNN inquiry problem of road network, scholars have done a few thing both at home and abroad. Kolahdouzan proposesIE/UBA method, utilizes Voronoi figure to process the CNN problem of cyberspace, by reducing the KNN calculation times in query pathImprove efficiency of algorithm, but in the time that the increase of K value, object distribution density increase, efficiency of algorithm sharply declines. Cho is for IE/UBA sideIn method, query performance is subject to object distribution Effects of Density to propose UNICONS technology, makes full use of precomputation aggregation node(CondensingPoint) arest neighbors improves shortest path computational speed; For completing CKNN inquiry, query path is divided intoSome subsegments, snapshot formula is calculated the KNNs of each subsegment end points, and the object in KNNs and the subsegment of each end points forms finally to be looked intoAsk result. Above method be all research query object be mobile and point of interest to as if static situation. Mouratidis[3]CarryGo out IMA/GMA method and process query object and point of interest object any mobile CKNN inquiry problem on road network. This algorithmBe the CKNN inquiry classic algorithm of current generally acknowledged processing based on road network, system adopts the data structure storage based on internal memoryNetwork edge, node and Query Information, propose IMA/GMA algorithm process inquiry request. IMA algorithm is opened from limit, query object placeBeginning extended network limit, and point of interest object on traverses network limit, form initial KNNs query results, simultaneously taking query point asRoot, sets up query expansion tree, the continuous-query request while processing inquiry request, mobile object and the renewal of roadside, road weight; GMA adoptsBy IMA and shared execution mechanism, the core of algorithm is the concept that is called sequence (Seqence), that is: the knot of the inquiry request in sequenceFruit is object in sequence and the union of the sequence end points KNNs of place result, in the time that multiple queries request is in same sequence, can be total toEnjoy acquired Query Result. In order to safeguard the renewal of Query Result, in the time calculating initial KNNs, set up and affect list. IMA/GMA method adopts mode storage networking and the mobile object based on internal memory, is not suitable for large-scale road network. Wang proposes MovNetFramework is processed the location-based inquiry under road network environment, uses the R tree index road network based on disk, based on internal memoryThe position of Grid Index management mobile object upgrade, by mesh overlay computational algorithm, road network and grid unit are closedConnection, completes location-based range query and KNN inquiry. Demisyurek uses dijkstra's algorithm for IMA/GMA algorithmThe shortcoming of blindness reflection when blindness expansion and object's position upgrade when network distance calculates, proposition ER-CKNN algorithm, based onPMR-QuadTree index road network, upgrades based on Grid Index management mobile object location, uses and is called edge-Bitmap-encoding technology, in conjunction with A* heuristic search algorithm, improves shortest path computational speed; Meanwhile, in the time of inquiry, makeWith Euclidean distance constraint (EuclideanRestriction) restriction k nearest neighbor region of search; When object's position upgrades, Zhi Dui districtMobile object in territory upgrades, thereby accelerates query processing speed. Liao Wei[6]For the CKNN inquiry based on road networkProcess, propose a kind of new road network Directed Graph Model, utilize respectively Hash table and linear linked list structure pair based on internal memoryMobile object current location and road network Directed Graph Model carry out store and management. by introduce unilateral network distance metric andBilateral network distance metric, proposes unilateral network expansion (UNE) algorithm and bilateral network expansion (BNE) algorithm to support different languagesThe continuous k nearest neighbor query processing of justice, and adopt impact tree and extension of network strategy to reduce the search that continuous k nearest neighbor inquiry is upgradedCost. Zhao Liang[7]During for data frequent updating, query performance decline problem, in conjunction with Multi-core technology, has proposed a kind of baseIn the continuous query processing framework of multithreading. This framework is all Query Results of re-computation periodically, and query processing is divided into orderData Update stage and the query execution stage of carrying out, use respectively the method for tasks in parallel and data parallel to carry out each stageOperation. Design the data structure of Data Update stage use, proposed the k nearest neighbor query process tactic in query processing stage,Comprise off-line precomputation and online two parts of k nearest neighbor Query Processing Algorithm, and to k nearest neighbor algorithm complexity and multithreading processingThe speed-up ratio of framework has been carried out theory analysis.
But above document is all to adopt a kind of index structure to carry out index to road network section, by road network modelingFor oriented/non-directed graph, process arest neighbors inquiry request based on internal storage data structure, but when road network data volume is large, roadWhen section is more, search efficiency sharply reduces; And, based on the modeling pattern of figure, cannot reflect mobile object at the parting of the waysTurn to relation, cannot solve and there is crossroad and turn to and the Complicated Road Network network arest neighbors inquiry problem of U-shaped turning constraint.
Summary of the invention
The object of the invention is, in order to solve existing employing index structure, road network section is carried out to index, by road networkBe modeled as oriented/non-directed graph, process arest neighbors inquiry request based on internal storage data structure, but work as road network data volumeGreatly, section is when more, search efficiency sharply reduces; And, based on the modeling pattern of figure, cannot reflect that mobile object is at crossCrossing turn to relation, cannot solve and there is crossroad and turn to and the Complicated Road Network network arest neighbors inquiry of U-shaped turning constraintProblem, provides the mobile object CKNN querying method based on RRN-Tree in a kind of road network.
Mobile object CKNN querying method based on RRN-Tree in road network, the performing step of this querying method is:
Step 1: first, define respectively road network G, route r, section seg, intersection j, mobile object o and KNNMonitoring section;
Described road network G is two tuple G=(R, J), and wherein R is route set in road network, every route bagContaining some sections, J is the crosspoint set of many routes in road network;
Described route r refers to a fullpath can independently naming in road network, is defined as:
r = ( r i d , l e n , ( jid j , pos j ) j = 1 m ) ;
Wherein, rid is route mark; Len represents path length, len ∈ [0,1];Represent on routeIntersection and on route the relative location sets of route starting point, posj∈[0,1];
Described section seg refers to the stretch line between adjacent intersection, is defined as:
seg=(sid,rid,ps,pe,dir);
Wherein, sid, rid represent respectively the mark of section and place route; ps、peRepresent starting point and the terminal in section;{ 1,0,1}, on duty be to represent that mobile object allows the motion from starting point to terminal direction on this section, is worth for-1 at 1 o'clock to dir ∈Represent the motion from road segment end to starting point direction, 0 represents that this section allows opposing traffic;
Described intersection j refers to the crossover node of many routes, is defined as:
The mark that wherein jid is intersection; (ridj,posj) represent the position of this intersection on j article of route;AdjList be intersection in abutting connection with list, store the annexation in this each section of crossing intersection part; Described mobile object o isRefer to, in road network, mobile object o is modeled as: o=(oid, x, y, rid, pos, dir'); Wherein, oid, rid show respectivelyShow mobile object mark and place route mark thereof; X, y represents the latitude and longitude coordinates of mobile object; Pos represents mobile object distanceFrom the distance of place route starting point, pos ∈ [0,1]; Dir' represents the traffic direction of mobile object, and value is that 1 expression is from place roadDuan Qidian is to terminal direction operation, be worth for-1 be to move to starting point direction from the terminal in section, place;
Described KNN monitoring section refers to taking query object q as root, and KNN_dist is apart from the upper limit, all sections that are connected with qThe query region forming;
Step 2, structure RRN-Tree index structure, will introduce in index structure in abutting connection with chained list technology, use in abutting connection with chained listAnnexation on expression route between the roadside, road of crossing intersection part, expansion thought in limit Network Based, the K of calculating query objectIndividual arest neighbors object; In the time of calculating K NN query results, set up k nearest neighbor monitoring section simultaneously;
Described RRN-Tree index structure is made up of three parts: the top layer 2DR-that the route of road network is carried out to indexTree, represent the bottom R-in abutting connection with mobile object on chained list and each route of index of crossover node syntople on routeTree;
The described top layer 2DR-Tree that the route of road network is carried out to index, its leaf node is a triple: <mbb,polypt,treept>;
Wherein, mbb represents the outer packet boundary of minimum of the corresponding polyline of route; Polypt points to the actual expression of route,Treept points to bottom R tree;
The bottom R-Tree of mobile object on each route of described index, its leaf node is two tuples a: < mbb',Childpt >, wherein mbb' represents the MBBs set of all child nodes, childpt points to child nodes, that is: index routeThe bottom R tree pointer of the mobile object on corresponding each section and section;
Being formed by hash table and two-stage single linked list in abutting connection with chained list of crossover node syntople on described expression route,Hash matrix section is identical with implication in MON-Tree, and first order single linked list represents each node on route, second level node tableShow the out-degree of certain node;
Step 3: the RRN-Tree index structure constructed according to step 2, carries out the CKNN inquiry based on road network;
The described inquiry of the CKNN based on road network comprises that the first initial set of KNN inquiry calculates and two rank are upgraded in CKNN inquirySection:
First, described in the first stage, just initial set calculating of KNN inquiry refers to: when query object sends KNN based on current locationWhen inquiry request, first by section, the quick locating query object place of RRN-Tree index structure, and by two ends in sectionClick and enter queue, and sort from small to large according to the distance of Distance query point; Then read Distance query and put nearest point of interest pairResemble and deposit in result queue, in the time that number of objects is less than K, continue expansion along the summit, section of query object direction of advance, logicalCross read summit, section determine the annexation in each section in abutting connection with chained list, on the section that has annexation, extensive lookups is nearestAdjacency pair resembles, until find K object; Finally, in order to improve the search efficiency of continuous-query, look into K object distanceThe distance of asking point is apart from the upper limit, has the section of annexation to set up KNN inquiry monitoring section, every dropping on by all with query pointObject in this monitored area will become candidate's KNN result;
Second stage is carried out CKNN inquiry renewal, and described CKNN inquiry is upgraded and is divided into two kinds of situations: when query point object positionPut constantly, and point of interest object is while moving, and the KNN monitoring section that utilizes query script to generate can reduce inquiry and upgrade cost; When looking intoAsk a some object while moving, the KNN inquiry of applying the above-mentioned first stage just initial set calculate search algorithm recalculate inquiry pleaseAsk.
Advantage of the present invention is:
The CKNN inquiry problem of existing research based on road network is mainly the shape with section and node by road networkFormula is carried out modeling, change into based on internal memory oriented/non-directed graph, there are two problems in this model: the one, section in road networkData volume is large, cause index structure branch too much, mobile object upgrades frequent; The 2nd, figure method for expressing can not process ten wellThe traffic rules such as word crossing turns to, U-shaped turning. For this problem, to road network modeling, a kind of new rope is proposed based on routeGuiding structure: RRN-Tree (RoutebasedRoadNetworksTree), limit Network Based extended mode, solves complicated barRoad network CKNN inquiry under part. Experimental result shows, under diverse network density and point of interest object distribution density, based onThe query performance of RRN-Tree indexing means is all better than classical IMA/GMA algorithm, and performance improves 1.5~2.13 times.
Brief description of the drawings
Fig. 1 is the road network model figure based on section;
Fig. 2 is the road network model figure based on route;
Fig. 3 is the route to road network in the RRN-Tree index structure described in detailed description of the invention one(Route) carry out the bottom R-Tree of mobile object on the top layer 2DR-Tree of index and each route of index;
Fig. 4 is crossover node adjacency on the expression route in the RRN-Tree index structure described in detailed description of the invention oneRelation in abutting connection with chained list;
Fig. 5 is the road network model figure that one-way traffic has the relation of turning to;
Fig. 6 is with DmaxFor apart from the upper limit, query point q is root, the road network model figure of calculating K NN monitored area;
Fig. 7 is mobile object CKNN querying method and the IMA/ based on RRN-Tree in road network of the present inventionGMA algorithm CPU response time under POI number of objects and distribution density situation of change under LA road network environment contrasts situation;Along with POI number of objects increases, the CPU response time obviously declines, but POI quantity reaches 20K when above, and variation is tending towards flatSlow, wherein,Represent IMA/GMA,Represent method of the present invention;
Fig. 8 is mobile object CKNN querying method and the IMA/ based on RRN-Tree in road network of the present inventionGMA algorithm CPU response time under POI number of objects and distribution density situation of change under SF road network environment contrasts situation; ,Wherein,Represent IMA/GMA,Represent method of the present invention;
Fig. 9: be mobile object CKNN querying method and the IMA/ based on RRN-Tree in road network of the present inventionGMA algorithm is the impact of POI distribution density on inquiry under LA road network, wherein,Represent IMA/GMA,RepresentativeMethod of the present invention;
Figure 10 is mobile object CKNN querying method and the IMA/ based on RRN-Tree in road network of the present inventionGMA algorithm is the impact of POI distribution density on inquiry under SF road network, wherein,Represent IMA/GMA,Represent thisThe method of invention;
Figure 11 is mobile object CKNN querying method and the IMA/ based on RRN-Tree in road network of the present inventionGMA algorithm inquiry request under SF road network environment is counted the affect situation of K on query performance; As can be seen from the figure, along with KValue increases, and CPU constantly increases running time, but the fortune that is starkly lower than IMA/GMA algorithm running time of method of the present inventionLine time;
Figure 12 is mobile object CKNN querying method and the IMA/ based on RRN-Tree in road network of the present inventionGMA algorithm inquiry request under LA road network environment is counted the affect situation of K on query performance; As can be seen from the figure, along with KValue increases, and CPU constantly increases running time, but the fortune that is starkly lower than IMA/GMA algorithm running time of method of the present inventionLine time.
Detailed description of the invention
Detailed description of the invention one: below in conjunction with Fig. 1 to Figure 12, present embodiment is described, the road network described in present embodimentMobile object CKNN querying method based on RRN-Tree in network, the performing step of this querying method is:
Step 1: first, define respectively road network G, route r, section seg, intersection j, mobile object o and KNNMonitoring section;
Described road network G is two tuple G=(R, J), and wherein R is route set in road network, every route bagContaining some sections, J is the crosspoint set of many routes in road network;
Described route r refers to a fullpath can independently naming in road network, is defined as:
r = ( r i d , l e n , ( jid j , pos j ) j = 1 m ) ;
Wherein, rid is route mark; Len represents path length, len ∈ [0,1];Represent on routeIntersection and on route the relative location sets of route starting point, posj∈[0,1];
Described section seg refers to the stretch line between adjacent intersection, is defined as:
seg=(sid,rid,ps,pe,dir);
Wherein, sid, rid represent respectively the mark of section and place route; ps、peRepresent starting point and the terminal in section;{ 1,0,1}, on duty be to represent that mobile object allows the motion from starting point to terminal direction on this section, is worth for-1 at 1 o'clock to dir ∈Represent the motion from road segment end to starting point direction, 0 represents that this section allows opposing traffic;
Described intersection j refers to the crossover node of many routes, is defined as:
The mark that wherein jid is intersection; (ridj,posj) represent the position of this intersection on j article of route;AdjList be intersection in abutting connection with list, store the annexation in this each section of crossing intersection part;
Described mobile object o refers in road network, and mobile object o is modeled as: o=(oid, x, y, rid, pos,dir);
Wherein, oid, rid represent respectively mobile object and place route thereof; X, y represents the latitude and longitude coordinates of mobile object;Pos represents the distance of mobile object apart from place route starting point, pos ∈ [0,1]; Dir represents the traffic direction of mobile object, valueBe that 1 expression moves from section, place starting point to terminal direction, be worth for-1 be to move to starting point direction from the terminal in section, place;
Described KNN monitoring section refers to taking query object q as root, and KNN_dist is apart from the upper limit, all sections that are connected with qThe query region forming;
Step 2, structure RRN-Tree (RoutebasedRoadNetworks) index structure, will be in abutting connection with chained list technologyIntroduce in index structure, use in abutting connection with chained list and represent the annexation between the roadside, road of crossing intersection part on route, based on netNetwork limit expansion thought, K arest neighbors object of calculating query object; In the time of calculating K NN query results, set up k nearest neighbor prison simultaneouslySurvey district;
Described RRN-Tree (RoutebasedRoadNetworks) index structure is made up of three parts: to road networkThe route (Route) of network carry out index top layer 2DR-Tree, represent crossover node syntople on route in abutting connection with chained list andThe bottom R-Tree of mobile object on each route of index;
The described route (Route) to road network carries out the top layer 2DR-Tree of index, and its leaf node is one threeTuple:<mbb, polypt, treept>;
Wherein, mbb represents the outer packet boundary of minimum of the corresponding polyline of route; Polypt points to the actual expression of route,Treept points to bottom R tree;
The bottom R-Tree of mobile object on each route of described index, its leaf node is two tuples a: < mbb,Childpt >, wherein mbb represents the MBBs set of all child nodes, childpt points to child nodes, that is: index routeThe bottom R tree pointer of the mobile object on corresponding each section and section;
Being formed by hash table and two-stage single linked list in abutting connection with chained list of crossover node syntople on described expression route,Hash matrix section is identical with implication in MON-Tree, and first order single linked list represents each node on route, second level node tableShow the out-degree of certain node;
Step 3: RRN-Tree (RoutebasedRoadNetworks) index structure constructed according to step 2,Carry out the CKNN inquiry based on road network;
The described inquiry of the CKNN based on road network comprises that the first initial set of KNN inquiry calculates and two rank are upgraded in CKNN inquirySection:
First, described in the first stage, just initial set calculating of KNN inquiry refers to: when query object sends KNN based on current locationWhen inquiry request, first by section, the quick locating query object place of RRN-Tree index structure, and by two ends in sectionClick and enter queue, and sort from small to large according to the distance of Distance query point; Then read Distance query and put nearest point of interest pairResemble and deposit in result queue, in the time that number of objects is less than K, continue expansion along the summit, section of query object direction of advance, logicalCross read summit, section determine the annexation in each section in abutting connection with chained list, on the section that has annexation, extensive lookups is nearestAdjacency pair resembles, until find K object; Finally, in order to improve the search efficiency of continuous-query, look into K object distanceThe distance of asking point is apart from the upper limit, has the section of annexation to set up KNN inquiry monitoring section, every dropping on by all with query pointObject in this monitored area will become candidate's KNN result;
Second stage is carried out CKNN inquiry renewal, and described CKNN inquiry is upgraded and is divided into two kinds of situations: when query point object positionPut constantly, and point of interest object is while moving, and the KNN monitoring section that utilizes query script to generate can reduce inquiry and upgrade cost; When looking intoAsk a some object while moving, the KNN inquiry of applying the above-mentioned first stage just initial set calculate search algorithm recalculate inquiry pleaseAsk.
Detailed description of the invention two: below in conjunction with Fig. 1 to Figure 12, present embodiment is described, present embodiment is to embodimentOne further illustrate, the KNN inquiry specific implementation process that just initial set calculates described in the step 3 described in present embodimentFor:
First, set up Priority Queues PQueue and preserve the abutment points in query script, the unit in this Priority Queues PQueueElement sorts according to the distance of Distance query point is ascending, and the initial value of establishing Priority Queues PQueue is for empty;
Set up the queue ResultList that preserves Query Result, the length of this queue ResultList is K, unit in queueElement is pressed the distance ascending order of Distance query point and is arranged, and establishes queue ResultList initial value for empty;
In the time sending inquiry request, establish q and represent query point, oiThe indicate point of interest of inquiry, wherein, i is positive integer, logicalCross the path r at the constructed quick locating query point q of the RRN-Tree index structure place of step 21And by bottom R tree locationThe section at query point placeSearch and on this section, have a point of interest o1, by o1And be kept at queue Re to the distance of qIn sultList, now, ResultList={ < o1,1>};
Because sectionBe one way traffic, enter queue PQueue by road segment end and to the distance of query point, that is:PQueue={<p2, 1 > }, not interested point between query point, algorithm is with p2For starting point, by RRN-Tree in abutting connection with chained listSearch and p2Adjacent sectionContinue expansion, by the terminal p in each section1、p3、p4、p5And arriveThe distance of query point enter queue and by apart from ascending order arrange, now, PQueue={ < p3,4>,<p1,5>,<p5,6>,<p4,13>, by the element p of distance value minimum in queue3Dequeue, not interested some object on this section, with p3For starting point, continue to expandOpen up to p6, now, PQueue={ < p1,5>,<p5,6>,<p6,7>,<p4,13>};
The node p of distance minimum of a value in queue1Dequeue, in sectionUpper, comprise object o2, added ReSultList queue, ResultList={ < o1,1>,<o2,3>};
By inquiring about the known in abutting connection with chained list of RRN-Tree, by node p1No longer expansion, continues p5Node placeReason, in sectionUpper, comprise object o3, join ResultList queue, inquire about p simultaneously5Node in abutting connection with chained list, continueContinuous expansion, can obtain result: ResultList={ < o1,1>,<o2,3>,<o3,4>},PQueue={<p6,7>,<p4,13>,<p5-7, 17 > } wherein, p5-7Represent to arrive node 7 through node 5; Similarly, by expanding all the other nodes, obtain result and be: ResultList={<o1,1>,<o2,3>,<o3,4>,<o5,8>},PQueue={<p5-7,17>,<p4-7,20>};
Now, 4 arest neighbors objects have been obtained, apart from upper bound Dmax=8; In fact, the distance value in PQueue >Dmax, the distance value that continues expansion must not meet the demands, and upgrades, with D for ease of inquiry belowmaxFor apart from the upper limit, inquire aboutPoint q is root, and calculating K NN monitored area completes just initial set calculating of KNN inquiry.
Detailed description of the invention three: below in conjunction with Fig. 1 to Figure 12, present embodiment is described, present embodiment is to embodimentOne further illustrate, the inquiry of CKNN described in the step 3 described in present embodiment is upgraded and is divided into two kinds of situations, works as query pointObject's position is constant, and point of interest object is while moving, and the KNN monitoring section that utilizes query script to generate can reduce inquiry and upgrade costImplementation procedure be:
In the time that query point object is motionless, due to the invariant position of query object, last time query generation KNN monitored area alsoConstant, according to the difference that drops on number of objects K ' value in KNN monitored area after the renewal of point of interest object, can be divided into three kinds of situations and divideOther places reason:
One, in the time falling into the point of interest object K '=K of KNN monitored area, only need to by RRN-Tree search allMobile object on section in KNN monitored area, by the object set on Nei Nei section, KNN monitored area as a result of;
Two, when falling into the point of interest object K ' of KNN monitoring section > when K, need be to all mobile object weights in KNN monitoring sectionThe new network distance calculating between query object, and according to sorting from small to large, get a front K object,, upgrade meanwhileKNN_dist also adjusts KNN monitoring section, uses to continue while upgrading next time;
Three, in the time falling into the point of interest object K ' < K of KNN monitoring section, need former KNN monitored area to continue expansion, thisIn be not to start again to expand from query object, only need start expansion from the mark of KNN monitored area.
In the time that query point object moves, the application KNN inquiry search algorithm that just initial set calculates recalculates inquiry requestSpecific implementation process is:
Inquiry request in the time processing query object and mobile object and upgrade simultaneously, due to the road network at one-way trafficIn, turning to of each crossroad is regular different, and in the time that mobile object moves to crossroad, the connectedness between section occursChange, be divided into two kinds according to the motion conditions of query object, after query object position is upgraded, still move in original sectionUpper, do not change the direction of motion, can make full use of KNN monitoring section, improve computational speed; Otherwise, according to just initial set meter of KNN inquiryCalculate inquiry again.
Specific embodiment: the present embodiment is close from point of interest object (POIs) quantity, inquiry request number, point of interest object distributionThe aspects such as degree, road network scale and IMA/GMA algorithm are tested contrast, and test data of experiment collection is from TIGER/Line]UnderThe Los Angeles city (LosAngeles, LA) of carrying and the road network of city of San Francisco (SanFrancisco, SF)Data, utilize Brinkhoff[10]The mobile object generator based on road network of design generates point of interest object set. DownloadShp formatted data through crossover tool, generate node node data and roadside, edge road data, as mobile object generatorEnter factor. Modeling pattern for ease of employing based on path is to road network modeling and set up index, to two road networksNetwork data centralization section of the same name merges, and forms a fullpath. Experiment parameter is as shown in table 1. Experimental system adoptsJava language is write, and running environment is AMD2.31GHz tri-core processors, internal memory 2G, WindowsXPSP3 operating system. OftenInferior test only changes one of them parameter value, and other parameters adopt default value.
Table 1 experiment parameter
Table1experimentparameter
Definition 7 (POI distribution densities): the quantity of point of interest object on road network in every square kilometre of area, is denoted as:
According to the POI number of objects producing in experimentation and road network region area, POI distribution density spanBetween [2,10].
Point of interest number of objects and the distribution density impact on query time described in the present embodiment
Fig. 5, Fig. 6 have provided respectively algorithm and IMA/GMA algorithm POI number of objects under LA, SF road network environment hereinAnd CPU response time under distribution density situation of change contrasts situation. As can be seen from Figure 5, CPU response time and POI coupleResemble number and all inversely proportional relation of distribution density, in Fig. 5, along with POI number of objects increases, the CPU response time obviously declines, butBe that POI quantity reaches 20K when above, variation tends towards stability. In Fig. 6, also there is similar situation of change. Algorithm profit in this paperIndex of reference structure is carried out index to road network, utilizes the adjacency list of node to represent the annexation between road, Adoption NetworkLimit extended mode is searched arest neighbors object, has avoided shortest path consuming time in IMA/GMA algorithm to calculate, therefore, and algorithm hereinImprove 1.5-2.13 doubly than IMA/GMA algorithm performance.
Inquiry request described in the present embodiment is counted the impact of K on query time:
Fig. 7 provides this paper algorithm and IMA/GMA algorithm inquiry request under LA, SF road network environment is counted K to inquiry propertyThe situation that affects of energy. As can be seen from the figure, along with K value increases, CPU constantly increases running time, but proposes algorithm hereinThe running time that is starkly lower than IMA/GMA algorithm running time. Reason is, algorithm is that crosspoint on path is set up hereinIn abutting connection with list, between each section, storage crosspoint place, turn to relation, i.e. annexation between each section, therefore, is calculatingWhen shortest path, do not meet and turn to regular section to be filtered, and IMA/GMA algorithm is calculating when shortest path, employingBe extended mode blindly, increased CPU expense.
CKNN inquiry based on road network is an important application in position-based service. For existing CKNN methodWhen processing road network area is larger, inefficiency and the inquiry problem that can not process single flow route net, propose RRN-Tree ropeGuiding structure, carries out index to road network and point of interest object, is that the crosspoint on path is set up adjacent in index structure simultaneouslyChain link table, the annexation between storage Chu Ge section, crossroad, thus complete road network CKNN under Complex Constraints conditionInquiry. Experimental result shows, proposes algorithm performance herein and is better than IMA/GMA algorithm. Direction relations as inquiry constraints,In inquiry, often used, future work direction has two: (1) carries out direction relations and arest neighbors inquiry based on road networkThe mixing search algorithm combining; (2) study Reverse Nearest based on road network and general based on RNN-Tree index structureRate arest neighbors[Inquiry problem.
The present invention is not limited to above-mentioned embodiment, can also be the reasonable of technical characterictic described in the respective embodiments described aboveCombination.

Claims (3)

1. the mobile object CKNN querying method based on RRN-Tree in road network, is characterized in that: the reality of this querying methodExisting step is:
Step 1: first, define respectively road network G, route r, section seg, intersection j, mobile object o and KNN monitoringDistrict;
Described road network G is two tuple G=(R, J), and wherein R is route set in road network, if every route comprisesTrunk section, J is the crosspoint set of many routes in road network;
Described route r refers to a fullpath can independently naming in road network, is defined as:
r = ( r i d , l e n , ( jid j , pos j ) j = 1 m ) ;
Wherein, rid is route mark; Len represents path length, len ∈ [0,1];Represent the intersection on routeCrossing and on route the relative location sets of route starting point, posj∈[0,1];
Described section seg refers to the stretch line between adjacent intersection, is defined as:
seg=(sid,rid,ps,pe,dir);
Wherein, sid, rid represent respectively the mark of section and place route; ps、peRepresent starting point and the terminal in section; Dir ∈{ 1,0,1}, on duty is to represent that mobile object allows the motion from starting point to terminal direction on this section, is worth for-1 expression at 1 o'clockThe motion from road segment end to starting point direction, 0 represents that this section allows opposing traffic;
Described intersection j refers to the crossover node of many routes, is defined as:
The mark that wherein jid is intersection; (ridj,posj) represent the position of this intersection on j article of route;AdjList be intersection in abutting connection with list, store the annexation in this each section of crossing intersection part;
Described mobile object o refers in road network, and mobile object o is modeled as: o=(oid, x, y, rid, pos,dir');
Wherein, oid, rid represent respectively mobile object mark and place route mark thereof; X, y represents the longitude and latitude of mobile objectCoordinate; Pos represents the distance of mobile object apart from place route starting point, pos ∈ [0,1]; Dir' represents the operation of mobile objectDirection, value is that 1 expression moves from section, place starting point to terminal direction, be worth for-1 be from the terminal in section, place to starting point sideTo operation;
Described KNN monitoring section refers to taking query object q as root, and KNN_dist is apart from the upper limit, and all sections that are connected with q formQuery region;
Step 2, structure RRN-Tree index structure, will introduce in index structure in abutting connection with chained list technology, use in abutting connection with chained list and representAnnexation on route between the roadside, road of crossing intersection part, expansion thought in limit Network Based, the K that calculates query object is individualNeighbour's object; In the time of calculating K NN query results, set up k nearest neighbor monitoring section simultaneously;
Described RRN-Tree index structure is made up of three parts: to the route of road network carry out index top layer 2DR-Tree,Represent the bottom R-Tree in abutting connection with mobile object on chained list and each route of index of crossover node syntople on route;
The described top layer 2DR-Tree that the route of road network is carried out to index, its leaf node is triple a: < mbb,polypt,treept>;
Wherein, mbb represents the outer packet boundary of minimum of the corresponding polyline of route; Polypt points to the actual expression of route,Treept points to bottom R tree;
The bottom R-Tree of mobile object on each route of described index, its leaf node is two tuples a: < mbb',Childpt >, wherein mbb' represents the MBBs set of all child nodes, childpt points to child nodes, that is: index routeThe bottom R tree pointer of the mobile object on corresponding each section and section;
Being made up of hash table and two-stage single linked list in abutting connection with chained list of crossover node syntople on described expression route, hash showsPart is identical with implication in MON-Tree, and first order single linked list represents each node on route, and second level node represents certain jointThe out-degree of point;
Step 3: the RRN-Tree index structure constructed according to step 2, carries out the CKNN inquiry based on road network;
The described inquiry of the CKNN based on road network comprises that the first initial set of KNN inquiry calculates and two stages are upgraded in CKNN inquiry:
First, described in the first stage, just initial set calculating of KNN inquiry refers to: when query object sends KNN inquiry based on current locationWhen request, first by section, the quick locating query object place of RRN-Tree index structure, and two end points in section are enteredQueue, and sort from small to large according to the distance of Distance query point; Then reading Distance query puts nearest point of interest object and depositsEnter in result queue, in the time that number of objects is less than K, continue expansion along the summit, section of query object direction of advance, by readingThat gets summit, section determines the annexation in each section, extensive lookups arest neighbors pair on the section that has annexation in abutting connection with chained listResemble, until find K object; Finally, in order to improve the search efficiency of continuous-query, with K object distance query pointDistance be apart from the upper limit, have the section of annexation to set up KNN inquiry monitoring section, every this prison that drops on all and query pointThe object of surveying in region will become candidate's KNN result;
Second stage is carried out CKNN inquiry and is upgraded, and the two kinds of situations that are divided into are upgraded in described CKNN inquiry: when query point object's position notBecome, and point of interest object is while moving, the KNN monitoring section that utilizes query script to generate can reduce inquiry and upgrade cost; Work as query pointWhen object moves, the KNN inquiry search algorithm that just initial set calculates of applying the above-mentioned first stage recalculates inquiry request.
2. the mobile object CKNN querying method based on RRN-Tree in road network according to claim 1, its featureBe that the inquiry of KNN described in the step 3 specific implementation process that just initial set calculates is:
First, set up Priority Queues PQueue and preserve the abutment points in query script, the element in this Priority Queues PQueue is pressedRange is from ascending sequence of distance of query point, and the initial value of establishing Priority Queues PQueue is for empty;
Set up the queue ResultList that preserves Query Result, the length of this queue ResultList is K, and in queue, element is by distanceDistance ascending order from query point is arranged, and establishes queue ResultList initial value for empty;
In the time sending inquiry request, establish q and represent query point, oiIndicate inquiry point of interest, wherein, i is positive integer, by stepThe path r at the rapid two constructed quick locating query point q of RRN-Tree index structure places1And by bottom R tree locating queryThe section at some placeSearch and on this section, have a point of interest o1, by o1And be kept at queue to the distance of qIn ResultList, now, ResultList={ < o1,1>};
Because sectionBe one way traffic, enter queue PQueue, that is: PQueue=by road segment end and to the distance of query point{<p2, 1 > }, not interested point between query point, algorithm is with p2For starting point, by searching and p in abutting connection with chained list in RRN-Tree2Adjacent sectionContinue expansion, by the terminal p in each section1、p3、p4、p5And arrive query pointDistance enter queue and by apart from ascending order arrange, now,
PQueue={<p3,4>,<p1,5>,<p5,6>,<p4, 13 > }, by the element p of distance value minimum in queue3Dequeue, shouldNot interested some object on section, with p3For starting point, continue to extend to p6, now,
PQueue={<p1,5>,<p5,6>,<p6,7>,<p4,13>};
The node p of distance minimum of a value in queue1Dequeue, in sectionUpper, comprise object o2, added ResultListQueue, ResultList={ < o1,1>,<o2,3>};
By inquiring about the known in abutting connection with chained list of RRN-Tree, by node p1No longer expansion, continues p5Node is processed,SectionUpper, comprise object o3, join ResultList queue, inquire about p simultaneously5Node in abutting connection with chained list, continue expansion,Can obtain result: ResultList={ < o1,1>,<o2,3>,<o3,4>},PQueue={<p6,7>,<p4,13>,<p5-7,17>}Wherein, p5-7Represent to arrive node 7 through node 5; Similarly, by expanding all the other nodes, obtain result and be:
ResultList={<o1,1>,<o2,3>,<o3,4>,<o5,8>},PQueue={<p5-7,17>,<p4-7,20>};
Now, 4 arest neighbors objects have been obtained, apart from upper bound Dmax=8; In fact, the distance value in PQueue > Dmax, continueThe distance value of continuous expansion must not meet the demands, and upgrades, with D for ease of inquiry belowmaxFor apart from the upper limit, query point q isRoot, calculating K NN monitored area, completes just initial set calculating of KNN inquiry.
3. the mobile object CKNN querying method based on RRN-Tree in road network according to claim 1, its featureBe that the two kinds of situations that are divided into are upgraded in CKNN inquiry described in step 3, when query point object's position is constant, and point of interest object movesTime, the implementation procedure that the KNN monitoring section that utilizes query script to generate can reduce inquiry renewal cost is:
In the time that query point object is motionless, due to the invariant position of query object, last time query generation KNN monitored area not yetBecome, after upgrading according to point of interest object, drop on the difference of number of objects K ' value in KNN monitored area, can be divided into three kinds of situations respectivelyProcess:
One,, in the time falling into the point of interest object K '=K of KNN monitored area, only need to search and allly supervise at KNN by RRN-TreeSurvey the mobile object on the section in region, by the object set on Nei Nei section, KNN monitored area as a result of;
Two, when falling into the point of interest object K ' of KNN monitoring section > when K, need again count all mobile objects in KNN monitoring sectionCalculate the network distance between query object, and according to sorting from small to large, get a front K object, meanwhile, upgrade KNN_Dist also adjusts KNN monitoring section, uses to continue while upgrading next time;
Three,, in the time falling into the point of interest object K ' < K of KNN monitoring section, need former KNN monitored area to continue expansion, here onlyNeed start expansion from the mark of KNN monitored area;
In the time that query point object moves, the application KNN inquiry search algorithm that just initial set calculates recalculates the concrete of inquiry requestImplementation procedure is:
Inquiry request in the time processing query object and mobile object and upgrade simultaneously, due in the road network of one-way traffic,Turning to of each crossroad is regular different, and in the time that mobile object moves to crossroad, the connectedness between section changesBecome, be divided into two kinds according to the motion conditions of query object, after query object position is upgraded, still move on original section,Do not change the direction of motion, can make full use of KNN monitoring section, improve computational speed; Otherwise, according to just initial set calculating of KNN inquiryAgain inquiry.
CN201310520592.5A 2013-10-29 2013-10-29 Mobile object CKNN querying method based on RRN-Tree in road network Expired - Fee Related CN103544291B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310520592.5A CN103544291B (en) 2013-10-29 2013-10-29 Mobile object CKNN querying method based on RRN-Tree in road network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310520592.5A CN103544291B (en) 2013-10-29 2013-10-29 Mobile object CKNN querying method based on RRN-Tree in road network

Publications (2)

Publication Number Publication Date
CN103544291A CN103544291A (en) 2014-01-29
CN103544291B true CN103544291B (en) 2016-05-18

Family

ID=49967743

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310520592.5A Expired - Fee Related CN103544291B (en) 2013-10-29 2013-10-29 Mobile object CKNN querying method based on RRN-Tree in road network

Country Status (1)

Country Link
CN (1) CN103544291B (en)

Families Citing this family (25)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104408117B (en) * 2014-11-26 2017-08-15 浙江大学 Best consumer's real-time searching method based on road network continuous polymerization K-NN search
CN104915504A (en) * 2015-06-18 2015-09-16 莫毓昌 BFS strategy improvement method used for novel calculation network reliability evaluation
CN104978420B (en) * 2015-06-30 2018-09-07 百度在线网络技术(北京)有限公司 Traffic route matching process and device
CN106095802B (en) * 2016-05-31 2019-08-09 南京邮电大学 Full-time state Indexing for Moving Object on city road network based on R tree
CN106503827B (en) * 2016-09-21 2020-12-11 国网河北省电力公司 Method and device for processing multi-time sequence mixed integer programming problem
CN106570062B (en) * 2016-10-08 2021-01-05 中国人民解放军理工大学 Road network track uncertain moving object range query system and method
CN108536704B (en) * 2017-03-02 2022-02-08 华为技术有限公司 Track query method, system and device
CN107122858B (en) * 2017-04-26 2020-07-03 大连民族大学 Partition board conveying path planning method for complex push type movable partition system
CN107917716B (en) * 2018-01-02 2021-07-06 广东工业大学 Fixed line navigation method, device, terminal and computer readable storage medium
CN109000675B (en) * 2018-06-20 2021-04-23 北京三快在线科技有限公司 Method and device for acquiring path information, electronic equipment and storage medium
CN110657805A (en) * 2018-09-30 2020-01-07 北京奇虎科技有限公司 Method and device for searching moving target based on road scene
CN109492150B (en) * 2018-10-30 2021-07-27 石家庄铁道大学 Reverse nearest neighbor query method and device based on semantic track big data
CN109597866B (en) * 2018-11-22 2020-05-19 成都理工大学 Traffic rule-based continuous nearest neighbor monitoring method for moving object in road network
CN110045714B (en) * 2019-04-08 2022-05-17 沈阳化工大学 Industrial process monitoring method based on weight nearest neighbor rule
CN110263108B (en) * 2019-05-10 2023-07-11 南京航空航天大学 Keyword Skyline fuzzy query method and system based on road network
CN110457352B (en) * 2019-07-31 2023-05-19 东南大学 Neighboring vehicle query method based on microscopic traffic simulation vehicle data structure
CN111221864B (en) * 2019-12-27 2022-07-08 江苏艾佳家居用品有限公司 Intelligent index recommendation method based on mysql slow query log word frequency analysis
CN111813778B (en) * 2020-07-08 2024-03-29 安徽工业大学 Approximate keyword storage and query method for large-scale road network data
CN111998869B (en) * 2020-09-29 2021-05-04 北京嘀嘀无限科技发展有限公司 Route generation method and device, electronic equipment and computer-readable storage medium
CN112836145B (en) * 2021-02-18 2023-06-02 沈阳航空航天大学 Neighbor query method facing mobile object in dynamic directed road network
CN112989079B (en) * 2021-04-22 2021-08-03 北京电信易通信息技术股份有限公司 Novel image data retrieval method and system
CN113607183A (en) * 2021-08-05 2021-11-05 北京中交兴路信息科技有限公司 Transportation route planning method and device for vehicle, storage medium and terminal
CN113886652B (en) * 2021-10-09 2022-06-17 北京欧拉认知智能科技有限公司 Memory-priority multimode graph data storage and calculation method and system
CN114461144B (en) * 2022-01-19 2024-04-19 清华大学 Data storage device, data processing method and road side equipment for collaborative driving
CN117236247B (en) * 2023-11-16 2024-01-23 零壹半导体技术(常州)有限公司 Signal shielding wire generation method for chip test

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102253961A (en) * 2011-05-17 2011-11-23 复旦大学 Method for querying road network k aggregation nearest neighboring node based on Voronoi graph
CN103020130A (en) * 2012-11-20 2013-04-03 北京航空航天大学 k nearest neighbor query method oriented to support area in LBS (Location-based Service) of urban road network
CN103164529A (en) * 2012-11-01 2013-06-19 沈阳建筑大学 Reverse k nearest neighbor query method based on Voronoi pictures

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8392418B2 (en) * 2009-06-25 2013-03-05 University Of Tennessee Research Foundation Method and apparatus for predicting object properties and events using similarity-based information retrieval and model
JP5333815B2 (en) * 2008-02-19 2013-11-06 株式会社日立製作所 k nearest neighbor search method, k nearest neighbor search program, and k nearest neighbor search device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102253961A (en) * 2011-05-17 2011-11-23 复旦大学 Method for querying road network k aggregation nearest neighboring node based on Voronoi graph
CN103164529A (en) * 2012-11-01 2013-06-19 沈阳建筑大学 Reverse k nearest neighbor query method based on Voronoi pictures
CN103020130A (en) * 2012-11-20 2013-04-03 北京航空航天大学 k nearest neighbor query method oriented to support area in LBS (Location-based Service) of urban road network

Also Published As

Publication number Publication date
CN103544291A (en) 2014-01-29

Similar Documents

Publication Publication Date Title
CN103544291B (en) Mobile object CKNN querying method based on RRN-Tree in road network
Malviya et al. A continuous query system for dynamic route planning
Han et al. Neat: Road network aware trajectory clustering
CN111445093B (en) Power transmission line emergency repair path optimization system and method
CN102810118B (en) A kind of change weighs net K nearest neighbor search method
CN106052701B (en) A kind of method of vehicle routing choice under traffic overflow state
CN102749084A (en) Path selecting method oriented to massive traffic information
Liu et al. Popular route planning with travel cost estimation
CN110807931A (en) Traffic network directed graph path model construction and solving method based on steering relation
Lee et al. Crowd-sourced carpool recommendation based on simple and efficient trajectory grouping
Cai et al. A novel vector-based dynamic path planning method in urban road network
Yin et al. A totally Astar-based multi-path algorithm for the recognition of reasonable route sets in vehicle navigation systems
Yuan et al. A map-matching algorithm with low-frequency floating car data based on matching path
Zhu et al. On using broadcast index for efficient execution of shortest path continuous queries
Jiang et al. Modelling turning restrictions in traffic networks for vehicle navigation system
CN116167235A (en) Road network model generation method, device and equipment
Sun et al. Parallel computing of KNN Query in road network based on MapReduce
Roth Efficient many-to-many path planning and the Traveling Salesman Problem on road networks
CN112269845B (en) Method for quickly matching electronic road map and bus route facing to different source data
Li et al. Intelligent augmented keyword search on spatial entities in real-life internet of vehicles
Wei et al. Mining popular routes from social media
Li et al. Diversified routing queries in dynamic road networks
Al-Baghdadi et al. Efficient path routing over road networks in the presence of ad-hoc obstacles (technical report)
CN113465612B (en) Parallel path planning method and system based on double-layer index
Zhang et al. Study on the Influence of Road Network on the Spatial Distribution of Tourism Resources–A Case Study of the Sichuan-Tibet Scenic Byway

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20160518

Termination date: 20171029

CF01 Termination of patent right due to non-payment of annual fee