Skip to main content
Log in

Exploiting spatial relations for grammar-based specification of multidimensional languages

  • Regular Paper
  • Published:
Knowledge and Information Systems Aims and scope Submit manuscript

This article has been updated

Abstract

As opposed to textual programming languages, multidimensional languages compiler construction paradigms lack standardization. To this aim, in this paper we present the spatial grammar (SG) formalism, a grammar model for multidimensional languages which has string-like productions containing more general spatial relations other than string concatenation, and we provide mapping rules to translate an SG specification into a translation schema. In this way, the SG formalism inherits and extends to the multidimensional context concepts and techniques of standard compiler generation tools like YACC.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13

Similar content being viewed by others

Change history

  • 05 June 2023

    Author name tagging has been updated.

References

  1. Aho A, Sethi R, Ullman J (1986) Compilers, principles, techniques, and tools, Addison-Wesley series in computer science and information processing. Addison-Wesley, Boston

  2. Allen JF (1983) Maintaining knowledge about temporal intervals. Commun ACM 26(11):832–843

    Article  MATH  Google Scholar 

  3. Balbiani P, Condotta J, del Cerro LF (1998) A model for reasoning about bidemsional temporal relations. In: Proceedings of the sixth international conference on principles of knowledge representation and reasoning (KR’98), Trento, Italy, June 2–5, 1998, pp 124–130

  4. Barredo Arrieta A, Díaz-Rodríguez N, Del Ser J, Bennetot A, Tabik S, Barbado A, Garcia S, Gil-Lopez S, Molina D, Benjamins R, Chatila R, Herrera F (2020) Explainable artificial intelligence (xai): concepts, taxonomies, opportunities and challenges toward responsible ai. Inf Fusion 58:82–115

    Article  Google Scholar 

  5. Becker G (2007) Combining rule-based and machine learning approaches for shape recognition. In: 36th Applied imagery pattern recognition workshop (aipr 2007), pp 65–70

  6. Chen J, Cohn AG, Liu D, Wang S, Ouyang J, Yu Q (2015) A survey of qualitative spatial representations. Knowl Eng Rev 30:106–136

    Article  Google Scholar 

  7. Clementini E, Felice PD, Oosterom P (1993) A small set of formal topological relationships suitable for end-user interaction. In: Proceedings of the third international symposium on advances in spatial databases (SSD’93). Springer, London, pp 277–295

  8. Crimi C, Guercio A, Nota G, Pacini G, Tortora G, Tucci M (1991) Relation grammars and their application to multi-dimensional languages. J Vis Lang Comput 2(4):333–346

    Article  Google Scholar 

  9. Della Penna G, Magazzeni D, Orefice S (2016) Extending visual information extraction to biomedical applications. Comput Syst Sci Eng 31(5):371–383

    Google Scholar 

  10. Della Penna G, Magazzeni D, Orefice S (2017) A formal framework to represent spatial knowledge. Knowl Inf Syst 51(1):311–338

    Article  Google Scholar 

  11. Della Penna G, Orefice S (2018) Qualitative representation of spatio-temporal knowledge. J Vis Lang Comput 49:1–16

    Article  Google Scholar 

  12. Della Penna G, Orefice S (2019) Using spatial relations for qualitative specification of gestures. Comput Syst Sci Eng 34(6):325–338

    Article  Google Scholar 

  13. Della Penna G, D’Angelo A (2022) PCT\_SGtoTS algorithm repository. https://github.com/gdellapenna/PCT_SGtoTS

  14. Egenhofer MJ, Mark DM, Herring J (1991) Categorizing binary topological relationships between regions, lines and points in geographic databases, Technical report, Department of Surveying Engineering, University of Maine

  15. Egenhofer MJ, Mark DM, Herring J (1994) The 9-intersection: formalism and its use for natural-language spatial predicates, Technical Report 94-1, National Center for Geographic Information and Analysis

  16. Engelfriet J (1997) Context-free graph grammars. In: Rozenberg G, Salomaa A (eds) Handbook of formal languages: volume 3 beyond words. Springer, Berlin, pp 125–214

    Chapter  Google Scholar 

  17. Flesca S, Furfaro F, Greco S (2006) A graph grammars based framework for querying graph-like data. Data Knowl Eng 59(3):652–680

    Article  MATH  Google Scholar 

  18. Fu M-Y, Huang Y-S (2010) A survey of traffic sign recognition. In: 2010 International conference on wavelet analysis and pattern recognition, pp 119–124

  19. Giammarresi D, Restivo A (1997) Two-dimensional languages. In: Rozenberg G, Salomaa A (eds) Handbook of formal languages: volume 3 beyond words. Springer, Berlin, pp 215–267

    Chapter  Google Scholar 

  20. GNU (2021) Gnu bison—the yacc-compatible parser generator. https://www.gnu.org/software/bison

  21. Goyal R, Egenhofer M (2001) Similarity of cardinal directions. In: Jensen C, Schneider M, Seeger B, Tsotras V (eds) Advances in spatial and temporal databases, vol 2121. Lecture notes in computer science. Springer, Berlin, pp 36–55

    Chapter  Google Scholar 

  22. JavaCC Community (2021) Java compiler compiler (javacc). https://javacc.github.io/javacc

  23. Johnson SC, Sethi R (1990) Yacc: a parser generator. In: UNIX Vol. II: research system, 10th edn. W. B. Saunders Company, USA, pp 347–374

  24. Krishnamurti R, Stouffs R (1993) Spatial grammars: motivation, comparison, and new results. In: Proceedings of the fifth international conference on computer-aided architectural design futures. North-Holland, NLD, pp 57–74

  25. Meyer-Baese A, Schmid V (2014) Chapter 6—statistical and syntactic pattern recognition. In: Meyer-Baese A, Schmid V (eds) Pattern recognition and signal analysis in medical imaging, 2nd edn. Academic Press, Oxford, pp 151–196

    Chapter  MATH  Google Scholar 

  26. Moratz R (2006) Representing relative direction as a binary relation of oriented points. In: Proceedings of the ECAI 2006, 17th European conference on artificial intelligence, August 29—September 1, 2006, Riva del Garda, Italy, including prestigious applications of intelligent systems (PAIS 2006), pp 407–411

  27. Moratz R, Ragni M (2008) Qualitative spatial reasoning about relative point position. J Vis Lang Comput 19(1):75–98

    Article  Google Scholar 

  28. Mossakowski T, Moratz R (2012) Qualitative reasoning about relative direction of oriented points. Artif Intell 180–181:34–45

    Article  MathSciNet  MATH  Google Scholar 

  29. Parr T (2021) Antlr (another tool for language recognition). https://www.antlr.org

  30. Randell DA, Cui Z, Cohn AG (1992) A spatial logic based on regions and connection. In: Proceedings of the 3rd international conference on principles of knowledge representation and reasoning (KR’92). Cambridge, MA, October 25–29, 1992, pp 165–176

  31. Rowe PDG, Reed C (2006) Cad grammars. In: Gero JS (ed) Design computing and cognition ’06. Springer, Dordrecht, pp 503–520

    Chapter  Google Scholar 

  32. Rozenberg G, Salomaa A (eds) (1997) Handbook of formal languages, vol 3: beyond words. Springer, Berlin

  33. Sanyal B, Mohapatra RK, Dash R (2020) Traffic sign recognition: a survey. In: 2020 International conference on artificial intelligence and signal processing (AISP), pp 1–6

  34. Skiadopoulos S, Koubarakis M (2004) Composing cardinal direction relations. Artif Intell 152(2):143–171

    Article  MathSciNet  MATH  Google Scholar 

  35. Zhu Z, Liang D, Zhang S, Huang X, Li B, Hu S (2016) Traffic-sign detection and classification in the wild. In: 2016 IEEE conference on computer vision and pattern recognition (CVPR), pp 2110–2118

Download references

Acknowledgements

We thank the anonymous reviewers and the journal editor for their useful comments and suggestions.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Giuseppe Della Penna.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Della Penna, G., Orefice, S. & D’Angelo, A. Exploiting spatial relations for grammar-based specification of multidimensional languages. Knowl Inf Syst 65, 3995–4020 (2023). https://doi.org/10.1007/s10115-023-01879-6

Download citation

  • Received:

  • Revised:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10115-023-01879-6

Keywords

Navigation