skip to main content
10.1145/3297280.3298912acmconferencesArticle/Chapter ViewAbstractPublication PagessacConference Proceedingsconference-collections
research-article

Retrieval of individual solutions from encapsulated search with a potentially infinite search space

Published: 08 April 2019 Publication History

Abstract

Constraint-logic object-oriented programming facilitates the development of applications that occasionally solve search problems. To that end it is possible to define constraints imperatively on-the-fly, using conditions over free variables. As a result, the search space is defined dynamically at runtime, based on the evaluation of such conditions in control structures. Consequently, the search space can - intentionally or by accident - become infinitely large if recursion and/or loops are involved. It is therefore desirable that the corresponding encapsulated search can be controlled by application developers. To that end, we discuss mechanisms for encapsulating such a search space and retrieving solutions from it. Our implementation for Muli is based on an appropriately extended symbolic Java virtual machine and it leverages the Java Stream API to provide a control mechanism that integrates well with object-oriented programs. Moreover, we show how our language Muli behaves for some example programs.

References

[1]
Sergio Antoy and Andy Jost. 2016. A New Functional-Logic Compiler for Curry: Sprite. In LOPSTR 2016.
[2]
Bernd Bra4sZel, Michael Hanus, Björn Peemöller, and Fabian Reck. 2011. KiCS2: A New Compiler from Curry to Haskell. Functional and Constraint Logic Programming 6816 (2011), 1--18.
[3]
Jan C. Dageförde and Herbert Kuchen. 2018. A Constraint-logic Object-oriented Language. In Proceedings of the 33rd ACM/SIGAPP Symposium On Applied Computing. ACM, 1185--1194.
[4]
Jan C. Dageförde and Herbert Kuchen. 2018. An Operational Semantics for Constraint-Logic Imperative Programming. In Declarative Programming and Knowledge Management, Dietmar Seipel, Michael Hanus, and Salvador Abreu (Eds.). Springer, Cham, 64--80.
[5]
Enrico Denti, Andrea Omicini, and Alessandro Ricci. 2005. Multi-paradigm Java-Prolog integration in tuProlog. Science of Computer Programming 57, 2 (2005), 217--250.
[6]
J. Doyle and C. Meudec. 2003. IBIS: an Interactive Bytecode Inspection System, using symbolic execution and constraint logic programming. In 2nd PPPJ. 55--58.
[7]
Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides. 1995. Design patterns. Addison-Wesley, Reading, Mass.
[8]
Michael Hanus, Herbert Kuchen, and Juan Jose Moreno-Navarro. 1995. Curry: A Truly Functional Logic Language. ILPS'95 Workshop on Visions for the Future of Logic Programming (1995), 95--107.
[9]
James C. King. 1976. Symbolic execution and program testing. Commun. ACM 19, 7 (1976), 385--394.
[10]
Kostas Kougios. 2018. cloning: deep clone java objects. https://github.com/kostaskougios/cloning
[11]
Krzysztof Kuchcinski. 2003. Constraints-driven scheduling and resource assignment. ACM Transactions on Design Automation of Electronic Systems 8, 3 (2003), 355--383.
[12]
Tim Lindholm, Frank Yellin, Gilad Bracha, and Alex Buckley. 2015. The Java® Virtual Machine Specification - Java SE 8 Edition. https://docs.oracle.com/javase/specs/jvms/se8/jvms8.pdf
[13]
Wolfgang Lux and Herbert Kuchen. 1999. An Efficient Abstract Machine for Curry. In Informatik '99, K Beiersdörfer, G Engels, and W Schäfer (Eds.). Springer Verlag, 390--399.
[14]
Tim A Majchrzak and Herbert Kuchen. 2011. Logic Java: Combining Object-Oriented and Logic Programming. In WFLP. 122--137.
[15]
F. G. McCabe. 1992. Logic and Objects. Prentice Hall.
[16]
Chris Moss. 1994. Prolog++ - the power of object-oriented and logic programming. Addison-Wesley.
[17]
Martin Odersky, Philippe Altherr, Vincent Cremet, Gilles Dubochet, Burak Emir, Philipp Haller, Stéphane Micheloud, Nikolay Mihaylov, Adriaan Moors, Lukas Rytz, Michel Schinz, Erik Stenman, and Matthias Zenger. 2017. Scala Language Specification. http://www.scala-lang.org/files/archive/spec/2.12/
[18]
Oracle. 2018. Class Object. https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html
[19]
Oracle. 2018. Interface Stream<T>. https://docs.oracle.com/javase/8/docs/api/java/util/stream/Stream.html
[20]
Ludwig Ostermayer. 2015. Seamless Cooperation of Java and Prolog for Rule-Based Software Development. In Proceedings of RuleML 2015. http://ceur-ws.org/Vol-1417/paper2.pdf
[21]
Randall Scott. 2010. A Guide to Artificial Intelligence with Visual Prolog. Outskirts Press.
[22]
Ehud Shapiro and Akikazu Takeuchi. 1983. Object oriented programming in Concurrent Prolog. New Generation Computing 1, 1 (1983), 25--48.
[23]
The OptaPlanner Team. 2017. OptaPlanner User Guide, Version 7.0.0. JBoss. https://docs.optaplanner.org/7.0.0.Final/optaplanner-docs/html{_}single/index.html
[24]
Nikolai Tillmann and Jonathan de Halleux. 2008. Pex: White Box Test Generation for .NET. In 2nd International Conference on Tests and Proofs. 134--153.
[25]
Markus Triska. 2012. The Finite Domain Constraint Solver of SWI-Prolog. In FLOPS (LNCS), Vol. 7294. 307--316.
[26]
Raoul-Gabriel Urma, Mario Fusco, and Alan Mycroft. 2014. Java 8 in Action: Lambdas, Streams, and Functional-style Programming. Manning Publications Co., Greenwich, CT.
[27]
Peter Van Roy, Per Brand, Denys Duchier, Seif Haridi, Christian Schulte, and Martin Henz. 2003. Logic programming in the context of multiparadigm programming: the Oz experience. Theory and Practice of Logic Programming 3, 6 (2003), 717--763.
[28]
David H. D. Warren. 1983. An Abstract Prolog Instruction Set. Technical Report. SRI International, Menlo Park.
[29]
Jan Wielemaker. 2003. An Overview of the SWI-Prolog Programming Environment. In Workshop on LP Environments.

Cited By

View all
  • (2023)Applications of Muli: Solving Practical Problems with Constraint-Logic Object-Oriented ProgrammingAnalysis, Verification and Transformation for Declarative Programming and Intelligent Systems10.1007/978-3-031-31476-6_5(97-112)Online publication date: 17-May-2023
  • (2019)Structured Traversal of Search Trees in Constraint-Logic Object-Oriented ProgrammingDeclarative Programming and Knowledge Management10.1007/978-3-030-46714-2_13(199-214)Online publication date: 9-Sep-2019

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
SAC '19: Proceedings of the 34th ACM/SIGAPP Symposium on Applied Computing
April 2019
2682 pages
ISBN:9781450359337
DOI:10.1145/3297280
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 08 April 2019

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. constraint-logic object-oriented programming
  2. dynamic solution retrieval
  3. infinite search space
  4. multi-paradigm languages
  5. virtual machine implementation

Qualifiers

  • Research-article

Conference

SAC '19
Sponsor:

Acceptance Rates

Overall Acceptance Rate 1,650 of 6,669 submissions, 25%

Upcoming Conference

SAC '25
The 40th ACM/SIGAPP Symposium on Applied Computing
March 31 - April 4, 2025
Catania , Italy

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)0
  • Downloads (Last 6 weeks)0
Reflects downloads up to 05 Mar 2025

Other Metrics

Citations

Cited By

View all
  • (2023)Applications of Muli: Solving Practical Problems with Constraint-Logic Object-Oriented ProgrammingAnalysis, Verification and Transformation for Declarative Programming and Intelligent Systems10.1007/978-3-031-31476-6_5(97-112)Online publication date: 17-May-2023
  • (2019)Structured Traversal of Search Trees in Constraint-Logic Object-Oriented ProgrammingDeclarative Programming and Knowledge Management10.1007/978-3-030-46714-2_13(199-214)Online publication date: 9-Sep-2019

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media