Abstract
Structural recursion, in the form of, for example, folds on lists and catamorphisms on algebraic data structures including trees, plays an important role in functional programming, by providing a systematic way for constructing and manipulating functional programs. It is, however, a challenge to define structural recursions for graph data structures, the most ubiquitous sort of data in computing. This is because unlike lists and trees, graphs are essentially not inductive and cannot be formalized as an initial algebra in general. In this paper, we borrow from the database community the idea of structural recursion on how to restrict recursions on infinite unordered regular trees so that they preserve the finiteness property and become terminating, which are desirable properties for query languages. We propose a new graph transformation language called lambdaFG for transforming and querying ordered graphs, based on the well-defined bisimulation relation on ordered graphs with special epsilon-edges. The language lambdaFG is a higher order graph transformation language that extends the simply typed lambda calculus with graph constructors and more powerful structural recursions, which is extended for transformations on the sibling dimension. It not only gives a general framework for manipulating graphs and reasoning about them, but also provides a solution to the open problem of how to define a structural recursion on ordered graphs, with the help of the bisimilarity for ordered graphs with epsilon-edges.
- K. Asada, S. Hidaka, H. Kato, Z. Hu, and K. Nakano. Parameterized graph transformation languages with monads. Technical Report GRACE-TR-2012-07, GRACE Center, National Institute of Informatics, 2012. http://www.biglab.org/papers.html.Google Scholar
- K. Asada, S. Hidaka, H. Kato, Z. Hu, and K. Nakano. A parameterized graph transformation calculus for finite graphs with monadic branches, 2013. To appear in PPDP'13. Google Scholar
Digital Library
- R. Bird and O. de Moor. Algebras of Programming. Prentice Hall, 1996. Google Scholar
Digital Library
- V. Breazu-Tannen, P. Buneman, and S. Naqvi. Structural recursion as a query language. In Proc. of the Third International Workshop on Database Programming Languages(DBPL 91), pages 9--19, 1991. Google Scholar
Digital Library
- P. Buneman, M. F. Fernandez, and D. Suciu. UnQL: a query language and algebra for semistructured data based on structural recursion. VLDB Journal: Very Large Data Bases, 9 (1): 76--110, 2000. Google Scholar
Digital Library
- F. W. Burton and H.-K. Yang. Manipulating multilinked data structures in a pure functional language. Softw. Pract. Exper., 20: 1167--1185, November 1990. Google Scholar
Digital Library
- S. Dal Zilio, D. Lugiez, and C. Meyssonnier. A logic you can count on. POPL'04, pages 135--146, New York, NY, USA, 2004. ACM. Google Scholar
Digital Library
- H. Ehrig, K. Ehrig, U. Prange, and G. Taentzer. Fundamentals of Algebraic Graph Transformation. Springer-Verlag, 2006. Google Scholar
Digital Library
- M. Erwig. Functional programming with graphs. ICFP '97, pages 52--65, New York, NY, USA, 1997. ACM. Google Scholar
Digital Library
- L. Fegaras and T. Sheard. Revisiting catamorphisms over datatypes with embedded functions. POPL '96, St. Petersburg Beach, Florida, Jan. 1996. Google Scholar
Digital Library
- J. Gibbons. An initial-algebra approach to directed acyclic graphs. In Mathematics of Program Construction, MPC '95, pages 282--303, London, UK, 1995. Springer-Verlag. Google Scholar
Digital Library
- A. Gill, J. Launchbury, and S. P. Jones. A short cut to deforestation. In Proc. Conference on Functional Programming Languages and Computer Architecture, pages 223--232, Copenhagen, June 1993. Google Scholar
Digital Library
- S. Ginali. Regular trees and the free iterative theory. J. Comput. Syst. Sci., 18 (3): 228--242, 1979.Google Scholar
Cross Ref
- M. Hamana. Initial algebra semantics for cyclic sharing structures. TLCA '09, pages 127--141, Berlin, Heidelberg, 2009. Springer-Verlag. Google Scholar
Digital Library
- M. Hasegawa. The uniformity principle on traced monoidal categories. Electr. Notes Theor. Comput. Sci., 69: 137--155, 2002.Google Scholar
Cross Ref
- S. Hidaka, Z. Hu, K. Inaba, H. Kato, K. Matsuda, and K. Nakano. Bidirectionalizing graph transformations. In ACM SIGPLAN International Conference on Functional Programming, pages 205--216. ACM, 2010. Google Scholar
Digital Library
- S. Hidaka, Z. Hu, K. Inaba, H. Kato, K. Matsuda, K. Nakano, and I. Sasano. Marker-directed Optimization of UnCAL Graph Transformations. In LOPSTR'11, volume 7225 of LNCS, pages 123--138. Springer, 2012. Google Scholar
Digital Library
- Z. Hu, H. Iwasaki, M. Takeichi, and A. Takano. Tupling calculation eliminates multiple data traversals. ICFP'97, pages 164--175, Amsterdam, The Netherlands, June 1997. ACM Press. Google Scholar
Digital Library
- Z. Hu, T. Yokoyama, and M. Takeichi. Program optimizations and transformations in calculational form. In Summer School on Generative and Transformational Techniques in Software Engineering, pages 139--164, Braga, Portugal, 2006. Springer, LNCS 4043. Google Scholar
Digital Library
- B. Jacobs. From coalgebraic to monoidal traces. Electronic Notes in Theoretical Computer Science, 264 (2): 125 -- 140, 2010. Proceedings of the Tenth Workshop on Coalgebraic Methods in Computer Science (CMCS 2010). Google Scholar
Digital Library
- T. Johnsson. Efficient graph algorithms using lazy monolithic arrays. J. Funct. Program., 8: 323--333, July 1998. Google Scholar
Digital Library
- vin(2006)}JoBe06F. Jouault and J. Bézivin. KM3: A DSL for metamodel specification. In Formal Methods for Open Object-Based Distributed Systems, pages 171--185. LNCS 4037, Springer, 2006. Google Scholar
Digital Library
- A. J. Kfoury and J. Tiuryn. Type reconstruction in finite-rank fragments of the polymorphic lambda-calculus (extended summary). In LICS, pages 2--11, 1990.Google Scholar
- D. J. King and J. Launchbury. Structuring depth-first search algorithms in Haskell. POPL '95, pages 344--354, New York, 1995. ACM. Google Scholar
Digital Library
- S. Lombardy and J. Sakarovitch. The removal of weighted $\varepsilon$-transitions. CIAA'12, pages 345--352. Springer-Verlag, 2012. Google Scholar
Digital Library
- E. Meijer, M. Fokkinga, and R. Paterson. Functional programming with bananas, lenses, envelopes and barbed wire. In Proc. Conference on Functional Programming Languages and Computer Architecturerm (LNCS 523), pages 124--144, Cambridge, Massachuetts, Aug. 1991. Google Scholar
Digital Library
- J. C. Mitchell. Foundations for programming languages. Foundation of computing series. MIT Press, 1996. Google Scholar
Digital Library
- B. C. Oliveira and W. R. Cook. Functional programming with structured graphs. ICFP '12, pages 77--88, New York, 2012. ACM. Google Scholar
Digital Library
- C. Picard and R. Matthes. Permutations in Coinductive Graph Representation. In D. Pattinson and L. Schröder, editors, Coalgebraic Methods in Computer Science, volume 7399 of LNCS, pages 218--237. Springer, 2012.Google Scholar
Cross Ref
- E. L. Robertson, L. V. Saxton, D. V. Gucht, and S. Vansummeren. Structural recursion as a query language on lists and ordered trees. Theory of Computing Systems, 44 (4): 590--619, 2009. Google Scholar
Digital Library
- A. Takano and E. Meijer. Shortcut deforestation in calculational form. FPCA '95, pages 306--313, New York, 1995. ACM. Google Scholar
Digital Library
- L. Wong. Querying Nested Collections. PhD thesis, Philadelphia, PA, USA, 1994. Google Scholar
Digital Library
Index Terms
Structural recursion for querying ordered graphs
Recommendations
Structural recursion for querying ordered graphs
ICFP '13: Proceedings of the 18th ACM SIGPLAN international conference on Functional programmingStructural recursion, in the form of, for example, folds on lists and catamorphisms on algebraic data structures including trees, plays an important role in functional programming, by providing a systematic way for constructing and manipulating ...
Tilings in vertex ordered graphs
AbstractOver recent years there has been much interest in both Turán and Ramsey properties of vertex ordered graphs. In this paper we initiate the study of embedding spanning structures into vertex ordered graphs. In particular, we introduce a ...
Twin-width IV: ordered graphs and matrices
STOC 2022: Proceedings of the 54th Annual ACM SIGACT Symposium on Theory of ComputingWe establish a list of characterizations of bounded twin-width for hereditary classes of totally ordered graphs: as classes of at most exponential growth studied in enumerative combinatorics, as monadically NIP classes studied in model theory, as ...







Comments