{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,8,19]],"date-time":"2026-08-19T20:10:04Z","timestamp":1787170204380,"version":"build-2736575974"},"reference-count":43,"publisher":"Cambridge University Press (CUP)","license":[{"start":{"date-parts":[[2022,7,5]],"date-time":"2022-07-05T00:00:00Z","timestamp":1656979200000},"content-version":"unspecified","delay-in-days":185,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"content-domain":{"domain":["cambridge.org"],"crossmark-restriction":true},"short-container-title":["J. Funct. Prog."],"published-print":{"date-parts":[[2022]]},"abstract":"<jats:title>Abstract<\/jats:title>\n                  <jats:p>\n                    Modern programming languages typically provide some form of comprehension syntax which renders programs manipulating collection types more readable and understandable. However, comprehension syntax corresponds to nested loops in general. There is no simple way of using it to express efficient general synchronized iterations on multiple ordered collections, such as linear-time algorithms for low-selectivity database joins.\n                    <jats:italic>Synchrony fold<\/jats:italic>\n                    is proposed here as a novel characterization of synchronized iteration. Central to this characterization is a\n                    <jats:italic>monotonic<\/jats:italic>\n                    <jats:monospace>isBefore<\/jats:monospace>\n                    <jats:italic>predicate<\/jats:italic>\n                    for relating the orderings on the two collections being iterated on and an\n                    <jats:italic>antimonotonic<\/jats:italic>\n                    <jats:monospace>canSee<\/jats:monospace>\n                    <jats:italic>predicate<\/jats:italic>\n                    for identifying matching pairs in the two collections to synchronize and act on. A restriction is then placed on Synchrony fold, cutting its extensional expressive power to match that of comprehension syntax, giving us\n                    <jats:italic>Synchrony generator<\/jats:italic>\n                    . Synchrony generator retains sufficient intensional expressive power for expressing efficient synchronized iteration on ordered collections. In particular, it is proved to be a natural generalization of the database merge join algorithm, extending the latter to more general database joins. Finally,\n                    <jats:italic>Synchrony iterator<\/jats:italic>\n                    is derived from Synchrony generator as a novel form of iterator. While Synchrony iterator has the same extensional and intensional expressive power as Synchrony generator, the former is better dovetailed with comprehension syntax. Thereby, algorithms requiring synchronized iterations on multiple ordered collections, including those for efficient general database joins, become expressible naturally in comprehension syntax.\n                  <\/jats:p>","DOI":"10.1017\/s0956796822000041","type":"journal-article","created":{"date-parts":[[2022,7,5]],"date-time":"2022-07-05T05:16:20Z","timestamp":1656998180000},"update-policy":"https:\/\/doi.org\/10.1017\/policypage","source":"Crossref","is-referenced-by-count":2,"title":["Iterating on multiple collections in synchrony"],"prefix":"10.1017","volume":"32","author":[{"given":"STEFANO","family":"PERNA","sequence":"first","affiliation":[],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"VAL","family":"TANNEN","sequence":"additional","affiliation":[],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0003-1241-5441","authenticated-orcid":false,"given":"LIMSOON","family":"WONG","sequence":"additional","affiliation":[],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"56","published-online":{"date-parts":[[2022,7,5]]},"reference":[{"key":"S0956796822000041_ref8","unstructured":"DeWitt, D. J. , Naughton, J. F. & Schneider, D. A. (1991) An evaluation of non-equijoin algorithms. In Proceedings of 17th International Conference on Very Large Data Bases, pp. 443\u2013452."},{"key":"S0956796822000041_ref25","doi-asserted-by":"publisher","DOI":"10.1017\/S0956796802004355"},{"key":"S0956796822000041_ref26","doi-asserted-by":"publisher","DOI":"10.1145\/128762.128764"},{"key":"S0956796822000041_ref4","doi-asserted-by":"publisher","DOI":"10.1145\/3236762"},{"key":"S0956796822000041_ref7","doi-asserted-by":"publisher","DOI":"10.1016\/0304-3975(91)90039-5"},{"key":"S0956796822000041_ref19","volume-title":"The Art of Computer Programming: Sorting and Searching","author":"Knuth","year":"1973"},{"key":"S0956796822000041_ref14","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-319-30936-1_7"},{"key":"S0956796822000041_ref15","doi-asserted-by":"publisher","DOI":"10.1145\/3236781"},{"key":"S0956796822000041_ref23","doi-asserted-by":"publisher","DOI":"10.1145\/3241625.2976007"},{"key":"S0956796822000041_ref29","doi-asserted-by":"publisher","DOI":"10.1145\/3003665.3003667"},{"key":"S0956796822000041_ref31","doi-asserted-by":"publisher","DOI":"10.1109\/ICDE.2016.7498316"},{"key":"S0956796822000041_ref37","unstructured":"Trinder, P. W. (1991) Comprehensions, a query notation for DBPLs. In Proceedings of 3rd International Workshop on Database Programming Languages, Nahplion, Greece. Morgan Kaufmann, pp. 49\u201362."},{"key":"S0956796822000041_ref2","doi-asserted-by":"publisher","DOI":"10.1137\/S0097539701390859"},{"key":"S0956796822000041_ref39","doi-asserted-by":"publisher","DOI":"10.1016\/0304-3975(90)90147-A"},{"key":"S0956796822000041_ref42","doi-asserted-by":"publisher","DOI":"10.1145\/2463664.2463670"},{"key":"S0956796822000041_ref6","doi-asserted-by":"publisher","DOI":"10.1016\/0304-3975(95)00024-Q"},{"key":"S0956796822000041_ref36","doi-asserted-by":"publisher","DOI":"10.1007\/3-540-58907-4_10"},{"key":"S0956796822000041_ref30","unstructured":"Perna, S. , Pinoli, P. , Tannen, V. , Ceri, S. & Wong, L. (2021) Synchronized iteration for genomic data processing. Available at: https:\/\/www.comp.nus.edu.sg\/ wongls\/projects\/synchrony\/synchrony-gmql-v12.pdf."},{"key":"S0956796822000041_ref40","unstructured":"Wadler, P. & Peyton Jones, S. (2007) Comprehensive comprehension: Comprehensions with \u2018order by\u2019 and \u2018group by\u2019. In Haskell\u201907: Proceedings of ACM SIGPLAN Workshop on Haskell, pp. 61\u201372."},{"key":"S0956796822000041_ref22","doi-asserted-by":"publisher","DOI":"10.1016\/j.entcs.2011.02.018"},{"key":"S0956796822000041_ref11","doi-asserted-by":"publisher","DOI":"10.1145\/322358.322370"},{"key":"S0956796822000041_ref16","doi-asserted-by":"crossref","unstructured":"Gulino, A. , Kaitoua, A. & Ceri, S. (2018) Optimal binning for genomics. IEEE Trans. Comput. 68(1), 125\u2013138.","DOI":"10.1109\/TC.2018.2854880"},{"key":"S0956796822000041_ref10","doi-asserted-by":"publisher","DOI":"10.1016\/0167-6423(91)90036-W"},{"key":"S0956796822000041_ref28","volume-title":"Programming in Scala: A Comprehensive Step-by-Step Guide","author":"Odersky","year":"2019"},{"key":"S0956796822000041_ref35","doi-asserted-by":"publisher","DOI":"10.1006\/jcss.1997.1526"},{"key":"S0956796822000041_ref33","volume-title":"Concepts of Programming Languages","author":"Sebesta","year":"2010"},{"key":"S0956796822000041_ref17","doi-asserted-by":"publisher","DOI":"10.1007\/s10990-011-9078-8"},{"key":"S0956796822000041_ref5","doi-asserted-by":"publisher","DOI":"10.1145\/181550.181564"},{"key":"S0956796822000041_ref43","unstructured":"Wong, L. (2021) Addressing an intensional expressiveness gap of comprehension syntax. Available at: https:\/\/www.comp.nus.edu.sg\/~wongls\/projects\/synchrony\/v5-wls-natural2021.pdf"},{"key":"S0956796822000041_ref13","doi-asserted-by":"publisher","DOI":"10.1016\/S0049-237X(08)71879-2"},{"key":"S0956796822000041_ref20","doi-asserted-by":"publisher","DOI":"10.1007\/978-1-4471-3564-7_16"},{"key":"S0956796822000041_ref38","doi-asserted-by":"publisher","DOI":"10.1016\/S0304-3975(99)00301-1"},{"key":"S0956796822000041_ref34","volume-title":"Database System Concepts","author":"Silberschatz","year":"2016"},{"key":"S0956796822000041_ref41","doi-asserted-by":"publisher","DOI":"10.1006\/jcss.1996.0037"},{"key":"S0956796822000041_ref27","doi-asserted-by":"publisher","DOI":"10.1093\/bioinformatics\/bts277"},{"key":"S0956796822000041_ref18","volume-title":"The Pragmatic Programmer: From Journeyman to Master","author":"Hunt","year":"2000"},{"key":"S0956796822000041_ref1","doi-asserted-by":"publisher","DOI":"10.1145\/103418.103444"},{"key":"S0956796822000041_ref3","doi-asserted-by":"publisher","DOI":"10.1147\/sj.164.0363"},{"key":"S0956796822000041_ref9","doi-asserted-by":"publisher","DOI":"10.1007\/s00778-021-00692-3"},{"key":"S0956796822000041_ref21","doi-asserted-by":"publisher","DOI":"10.1006\/jcss.1997.1523"},{"key":"S0956796822000041_ref32","volume-title":"Denotational Semantics: A Methodology For Language Development","author":"Schmidt","year":"1986"},{"key":"S0956796822000041_ref24","doi-asserted-by":"publisher","DOI":"10.1093\/bioinformatics\/bty688"},{"key":"S0956796822000041_ref12","doi-asserted-by":"publisher","DOI":"10.1017\/S0956796800003658"}],"container-title":["Journal of Functional Programming"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/www.cambridge.org\/core\/services\/aop-cambridge-core\/content\/view\/S0956796822000041","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2026,5,26]],"date-time":"2026-05-26T22:36:58Z","timestamp":1779835018000},"score":1,"resource":{"primary":{"URL":"https:\/\/www.cambridge.org\/core\/product\/identifier\/S0956796822000041\/type\/journal_article"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2022]]},"references-count":43,"alternative-id":["S0956796822000041"],"URL":"https:\/\/doi.org\/10.1017\/s0956796822000041","relation":{},"ISSN":["0956-7968","1469-7653"],"issn-type":[{"value":"0956-7968","type":"print"},{"value":"1469-7653","type":"electronic"}],"subject":[],"published":{"date-parts":[[2022]]},"assertion":[{"value":"\u00a9 The Author(s), 2022. Published by Cambridge University Press","name":"copyright","label":"Copyright","group":{"name":"copyright_and_licensing","label":"Copyright and Licensing"}},{"value":"This is an Open Access article, distributed under the terms of the Creative Commons Attribution licence (https:\/\/creativecommons.org\/licenses\/by\/4.0\/), which permits unrestricted re-use, distribution, and reproduction in any medium, provided the original work is properly cited.","name":"license","label":"License","group":{"name":"copyright_and_licensing","label":"Copyright and Licensing"}},{"value":"This content has been made available to all.","name":"free","label":"Free to read"}],"article-number":"e9"}}