Soft Computing

, Volume 21, Issue 18, pp 5181–5191 | Cite as

Real-time processing of k-NN queries over moving objects

  • Ziqiang Yu
  • Yuehui Chen
  • Kun Ma


Central to many location-based service applications is the task of processing k-nearest neighbor (k-NN) queries over moving objects. Many existing approaches adapt different index structures and design various search algorithms to deal with this problem. In these works, tree-based indexes and grid index are mainly utilized to maintain a large volume of moving objects and improve the performance of search algorithms. In fact, tree-based indexes and grid index have their own flaws for supporting processing k-NN queries over an ocean of moving objects. A tree-based index (such as R-tree) needs to constantly maintain the relationship between nodes with objects continuously moving, which usually causes a high maintenance cost. Grid index is widely used to support k-NN queries over moving objects, but the approaches based on grid index almost require an uncertain number of iterative calculations, which makes the performance of these approaches not predictable. To address this problem, we present a dynamic Strip Rectangle Index (SRI), which can reach a good balance between the maintenance cost and the performance of supporting k-NN queries over moving objects. SRI supplies two different index granularities that makes it better adapt to handle different data distributions than existing index structures. Based on SRI, we propose a search algorithm called SR-KNN that can rapidly calculate a final region with a filter-and-refine strategy to enhance the efficiency of process k-NN queries, rather than iteratively enlarging the search space like the grid-index-based approaches. Finally, we conduct experiments to fully evaluate the performance of our proposal.


k-NN queries Spatial–temporal data Search algorithm 



This work was supported in part by the Shandong Provincial Natural Science Foundation (ZR2016FB14), the Shandong Provincial Natural Science Foundation (ZR2014FQ029), the Shandong Provincial Key R&D Program (2015GGX106007), and the Project of Shandong Province Higher Educational Science and Technology Program (J16LN13)

Compliance with ethical standards

Conflict of interest

The authors declare no conflict of interest.

Ethical approval

This article does not contain any studies with human participants or animals performed by any of the authors.


  1. Baoli L, Qin L, Shiwen Y (2004) An adaptive k-nearest neighbor text categorization strategy. ACM Trans Asian Lang Inf Process (TALIP) 3(4):215–226CrossRefGoogle Scholar
  2. Chaudhuri S, Gravano L (1999) Evaluating top-k selection queries. In: VLDB, pp 399–410Google Scholar
  3. Cheung KL, Fu AW-C (1998) Enhanced nearest neighbour search on the r-tree. ACM SIGMOD Rec 27(3):16–21MathSciNetCrossRefGoogle Scholar
  4. Cui C, Ma J, Lian T, Chen Z, Wang S (2015) Improving image annotation via ranking-oriented neighbor search and learning-based keyword propagation. J Assoc Inf Sci Technol 66(1):82–98CrossRefGoogle Scholar
  5. Cui C, Shen J, Ma J, Lian T (2016) Social tag relevance learning via ranking-oriented neighbor voting. Multimedia Tools Appl 1–27Google Scholar
  6. Gedik B, Wu K, Yu P, Liu L (2006) Processing moving queries over moving objects using motion-adaptive indexes. Knowl Data Eng 18(5):651–668CrossRefGoogle Scholar
  7. Guttman A (1984) R-trees: a dynamic index structure for spatial searching. In: SIGMOD, pp 47–57Google Scholar
  8. Mokbel MF, Aref WG (2008) SOLE: scalable on-line execution of continuous queries on spatio-temporal data streams. VLDB J 17(5):971–995CrossRefGoogle Scholar
  9. Mokbel MF, Xiong X, Aref WG (2004) SINA: scalable incremental processing of continuous queries in spatio-temporal databases. In: SIGMOD, pp 623–634Google Scholar
  10. Mouratidis K, Bakiras S, Papadias D (2009) Continuous monitoring of spatial queries in wireless broadcast environments. IEEE Trans Mobile Comput 8(10):1297–1311CrossRefGoogle Scholar
  11. Nehme RV, Rundensteiner EA (2006) SCUBA: scalable cluster-based algorithm for evaluating continuous spatio-temporal queries on moving objects. In: EDBT, pp 1001–1019Google Scholar
  12. Raptopoulou K, Papadopoulos A, Manolopoulos Y (2003) Fast nearest-neighbor query processing in moving-object databases. GeoInformatica 7(2):113–137CrossRefGoogle Scholar
  13. Seidl T, Kriegel H (1998) Optimal multi-step k-nearest neighbor search. In: SIGMOD, pp 154–165Google Scholar
  14. Šidlauskas D, Šaltenis S, Jensen CS (2012) Parallel main-memory indexing for moving-object query and update workloads. In: SIGMOD, pp 37–48Google Scholar
  15. Tao Y, Papadias D, Shen Q (2002) Continuous nearest neighbor search. In: VLDB, pp 287–298Google Scholar
  16. Wang H, Zimmermann R (2008) Snapshot location-based query processing on moving objects in road networks. In: SIGSPATIAL GIS, pp 50:1–50:4Google Scholar
  17. Xiong X, Mokbel MF, Aref WG (2005) SEA-CNN: Scalable processing of continuous k-nearest neighbor queries in spatio-temporal databases. In: ICDE, pp 643–654Google Scholar
  18. Yang M, Liu Y, Yu Z (2015) Distributed grid-based k nearest neighbour query processing over moving objects. In: International Conference on Web-Age Information Management, pp 350–361Google Scholar
  19. Yu C, Ooi B, Tan K, Jagadish H (2001) Indexing the distance: an efficient method to knn processing. In: VLDB, pp 421–430Google Scholar
  20. Yu X, Pu K, Koudas N (2005) Monitoring k-nearest neighbor queries over moving objects. In: ICDE, pp 631–642Google Scholar
  21. Zheng B, Xu J, Lee W-C, Lee L (2006) Grid-partition index: a hybrid method for nearest-neighbor queries in wireless location-based services. VLDB J 15(1):21–39CrossRefGoogle Scholar
  22. Zheng B, Zheng K, Xiao X, Su H, Yin H, Zhou X, Li G (2016) Keyword-aware continuous KNN query on road networks. In: ICDE, pp 871–882Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2016

Authors and Affiliations

  1. 1.University of JinanJinanChina

Personalised recommendations