Next:
Getting Started with B-Prolog
Up:
manual
Previous:
Acknowledgements
Index
Contents
Getting Started with B-Prolog
How to install B-Prolog
Windows
Linux
Mac
How to enter and quit B-Prolog
Command line arguments
The command line editor
How to run programs
Programs
Terms
Programs
Control constructs
Data Types and Built-ins
Terms
Type checking
Unification
Term comparison and manipulation
Numbers
Lists and structures
Arrays and the array subscript notation (not in ISO)
Set manipulation (not in ISO)
Hashtables (not in ISO)
Character-string operations
Declarative Loops and List Comprehensions (not in ISO)
The base foreach
foreach with accumulators
List comprehensions
Cautions on the use
Exception Handling
Exceptions
throw/1
catch/3
Directives and Prolog Flags
Mode declaration
include/1
Initialization
Dynamic declaration
multifile/1
Tabled predicate declaration
Table mode declaration
Prolog flags
Debugging
Execution modes
Debugging commands
Input and Output
Stream
Character input/output
Character code input/output
Byte input/output
Term input/output
Input/output of DEC-10 Prolog (not in ISO)
Formatted output of terms (not in ISO)
Dynamic Clauses and Global Variables
Predicates of ISO-Prolog
Predicates of DEC-10 Prolog (not in ISO)
Global variables (not in ISO)
Properties
Global heap variables (not in ISO)
Memory Management and Garbage Collection
Memory allocation
Garbage collection
Matching Clauses
Action Rules and Events
Syntax
Operational semantics
Another example
Timers and time events
Suspension and attributed variables
Constraints
CLP(Tree)
CLP(FD)
Finite-domain variables
Table constraints
Arithmetic constraints
Global constraints
Labeling and variable/value ordering
Optimization
CLP(Boolean)
CLP(Set)
Modeling with foreach and list comprehension
Programming Constraint Propagators
A constraint interpreter
Indexicals
Reification
Propagators for binary constraints
all_different(L)
A Common Interface to SAT and LP/MIP Solvers
Creating decision variables
Constraints
Solver invocation
Examples
A simple LP example
Graph coloring
Tabling
Table mode declarations
Linear tabling and the strategies
Primitives on tables
External Language Interface with C
Calling C from Prolog
Term representation
Fetching arguments of Prolog calls
Testing Prolog terms
Converting Prolog terms into C
Manipulating and writing Prolog terms
Building Prolog terms
Registering predicates defined in C
Calling Prolog from C
External Language Interface with Java
Installation
Data conversion between Java and B-Prolog
Calling Prolog from Java
Calling Java from Prolog
Interface with Operating Systems
Building standalone applications
Commands
Profiling
Statistics
Profile programs
Profile program executions
More statistics
Predefined Operators
Frequently Asked Questions
Useful Links
CGLIB: http://www.probp.com/cglib/
CHR Compilers: http://www.probp.com/chr/
JIPL: http://www.kprolog.com/jipl/index_e.html
Logtalk: http://www.logtalk.org/
PRISM: http://sato-www.cs.titech.ac.jp/prism/
Constraint Solvers: http://www.probp.com/solvers/
XML: http://www.probp.com/publib/xml.html
Bibliography
Index
Neng-Fa Zhou 2012-11-23