User loginNavigation |
Logic/DeclarativeHistory of Logic Programming: What went wrong, What was done about it, and What it might mean for the futureCarl Hewitt is speaking tomorrow at Stanford's CSLI CogLunch on the history of logic programming. A paper is here, so LtU readers can offer their perspectives on the argument. By Ehud Lamm at 2008-05-07 23:03 | History | Logic/Declarative | 25 comments | other blogs | 3366 reads
Pure, Declarative, and Constructive Arithmetic Relations
Pure, Declarative, and Constructive Arithmetic Relations. Oleg Kiselyov, William E. Byrd, Daniel P. Friedman, and Chung-chieh Shan. FLOPS 2008. (source code)
We present decidable logic programs for addition, multiplication, division with remainder, exponentiation, and logarithm with remainder over the unbounded domain of natural numbers. Our predicates represent relations without mode restrictions or annotations. They are fully decidable under the common, DFS-like, SLD resolution strategy of Prolog or under an interleaving refinement of DFS... So you've read The Reasoned Schemer and were excited about the fact that unlike the built-in operations in Prolog, arithmetic relations (over binary numbers) were fully implemented. For example, addition could also be used for subtraction and multiplication for factoring numbers and for generating all triples of numbers related by multiplication. Now comes this paper to explain the motivation behind some of the more arcane definitions needed to implement arithmetic in a fully relational style, and to prove their properties formally. The paper develops unary and binary arithmetic relations in pure Prolog (with no cuts, negation or introspection). LtU readers will also be interested in yet another embedding of pure Prolog into Haskell, that the authors offer. It is not meant to be the most optimal or convenient Prolog implementation (it wasn't even intended to be an implementation of a logic system). It was explicitly designed to be easier to reason about and so help prove certain properties of SLD or similar evaluation strategies. The main difference of DefinitionTree from other embeddings of Prolog in Haskell has to do with the generation of fresh names for logic variables. In DefinitionTree, name generation is not an effect, and the naming is fully decoupled from the evaluation. The evaluation no longer needs to carry a state for the generation of fresh names, hence the evaluator is easier to reason about equationally. NEXCEL, a Deductive SpreadsheetNEXCEL, a Deductive Spreadsheet, Iliano Cervesato. 2006.
This is a neat paper about using Datalog-style relations to extend spreadsheets with some deductive database features. It seems like Datalog represents a real sweet spot in the design space for logic programming -- I've seen a lot of people put it to effective use. By neelk at 2007-11-10 17:12 | DSL | Logic/Declarative | login or register to post comments | other blogs | 2648 reads
The End of an Architectural Era (It’s Time for a Complete Rewrite)The End of an Architectural Era (It’s Time for a Complete Rewrite). Michael Stonebraker, Samuel Madden, Daniel J. Abadi, Stavros Harizopoulos, Nabil Hachem, Pat Helland. VLDB 2007. A not directly PL-related paper about a new database architecture, but the authors provide some interesting and possibly controversial perspectives:
The somewhat performance-focused abstract:
A critical comment by Amazon's CTO, Werner Vogels. By msimoni at 2007-10-19 13:46 | DSL | Implementation | Logic/Declarative | Ruby | 22 comments | other blogs | 7842 reads
Escape from Zurg: An Exercise in Logic ProgrammingEscape from Zurg: An Exercise in Logic Programming by Martin Erwig. Journal of Functional Programming, Vol. 14, No. 3, 253-261, 2004
By Andris Birkmanis at 2007-09-01 15:04 | Functional | Logic/Declarative | Teaching & Learning | 19 comments | other blogs | 4870 reads
Theory and Practice of Constraint Handling RulesTheory and Practice of Constraint Handling Rules, Thom Fruewirth, Journal of Logic Programming, 1994.
In the last post, we had some requests for constraint programming, so here you go. Constraint solving programs are often essentially stateful algorithms, and I see CHR as a particularly nice way of handling all that state in a declarative way. (They have a very pretty semantics as proof search in linear logic, too.) Cloning-Based Context-Sensitive Pointer Alias Analysis Using Binary Decision DiagramsCloning-Based Context-Sensitive Pointer Alias Analysis Using Binary Decision Diagrams, John Whaley and Monica S. Lam. PLDI 2004.
Binary decision diagrams are one of the coolest data structures of the last 20 years, and are also one of the basic enabling data structures underlying modern SAT solvers. Using them to implement Datalog is a really clever idea. EDIT: I relied on memory instead of Google, and got it wrong about BDDs and SAT solving. Modern DPLL-based SAT solvers generally do not use BDDs, because when your solutions are far apart in the solution space the representing BDD would get quite large. BDDs are widely used in verification, though, and are also still one my favorite data structures. :) By neelk at 2007-08-08 08:12 | DSL | Implementation | Logic/Declarative | 4 comments | other blogs | 2055 reads
CLL: A Concurrent Language Built from Logical Principles
CLL: A Concurrent Language Built from Logical Principles by Deepak Garg, 2005.
In this report, we use both the Curry-Howard isomorphism and proof-search to design a concurrent programming language from logical principles. ... Our underlying logic is a first-order intuitionistic linear logic where all right synchronous connectives are restricted to a monad.Yet another example of using monads to embed effectful computations into a pure FP. Another interesting part is the methodology of derivation of a PL from a logic. By Andris Birkmanis at 2007-06-30 18:06 | Logic/Declarative | Semantics | Type Theory | 2 comments | other blogs | 3172 reads
Application-specific foreign-interface generationApplication-specific foreign-interface generation, John Reppy and Chunyan Song, October 2006.
FFIs are a perennial engineering problem, and it's very nice to see progress being made on automating what's automatable about building interfaces. Their interface specification language is built from two little DSLs. The first one is a language that for specifying how to map low level types to high level types, and the second one is a rewriting-based language for translating API functions, which makes use of the type mapping programs you defined earlier. The whole thing is quite pretty, and seems to read very well. An interesting gimme for you stack-language fans: the DSL that Reppy and Song use to specify type mappings from low-level to high-level types is a combinator-based language that reads a bit like Forth or Postscript. By neelk at 2007-06-20 20:52 | DSL | Functional | Implementation | Logic/Declarative | Semantics | 3 comments | other blogs | 2274 reads
Python in Pardus LinuxPardus Linux is a case study of functional Python. It's a Linux distribution built from semi-scratch, the main focii being package management and init subsystems - places where C and shell script make poor sense. A funded group has finally tackled these issues.
A package management software deals a lot with sets, lists, and dependency graphs....We have extensively used functional operators (map, filter, reduce) and list comprehensions, even metaclasses are used in a few places. Someone nudge Guido. Scheme or Oz might have been the better choice, but give them credit. They admit frankly to social acceptance issues. By Mark Evans at 2007-06-19 22:55 | Logic/Declarative | Object-Functional | Python | XML | 7 comments | other blogs | 4094 reads
|
Browse archivesActive forum topics |