- Page 2:
This page intentionally left blank
- Page 6:
Advance praise for Constraint Logic
- Page 10:
CAMBRIDGE UNIVERSITY PRESS Cambridg
- Page 14:
vi Contents 3.5 Operators 52 3.6 Su
- Page 18:
viii Contents 12.3 The coins proble
- Page 22:
x Introduction ming language for na
- Page 26:
xii Introduction In 1991 the three
- Page 30:
xiv Introduction This is achieved t
- Page 36:
To Alma, Daniel and Ruth and to Dun
- Page 44:
1 Logic programming and pure Prolog
- Page 48:
1.2 Syntax 5 • atoms, denoted by
- Page 52:
1.3 The meaning of a program 7 each
- Page 56:
1.4 Computing with equations 9 p(X)
- Page 60:
1.4 Computing with equations 11 Rea
- Page 64:
1.4 Computing with equations 13 To
- Page 68:
1.5 Prolog: the first steps 15 Acco
- Page 72:
1.5 Prolog: the first steps 17 The
- Page 76:
1.5 Prolog: the first steps 19 For
- Page 80:
1.5 Prolog: the first steps 21 For
- Page 84:
1.6 Two simple pure Prolog programs
- Page 88:
1.6 Two simple pure Prolog programs
- Page 92:
1.8 Exercises 27 Exercise 1.2 Consi
- Page 96:
2 A reconstruction of pure Prolog 2
- Page 100:
2.2 The programming language L 0 31
- Page 104:
2.3 Translating pure Prolog into L
- Page 108:
2.4 Pure Prolog and declarative pro
- Page 112:
2.6 Summary 37 Its declarative inte
- Page 116:
Part II Elements of Prolog
- Page 122:
42 Arithmetic in Prolog 3.2 Arithme
- Page 126:
44 Arithmetic in Prolog [eclipse 2]
- Page 130:
46 Arithmetic in Prolog Then p/1 ca
- Page 134:
48 Arithmetic in Prolog The compari
- Page 138:
50 Arithmetic in Prolog % qs(Xs, Ys
- Page 142:
52 Arithmetic in Prolog 3.5 Operato
- Page 146:
54 Arithmetic in Prolog 3.5.3 Binar
- Page 150:
56 Arithmetic in Prolog • the cus
- Page 154:
58 Arithmetic in Prolog min(X, Y, Z
- Page 158:
60 Control and meta-programming to
- Page 162:
62 Control and meta-programming 4.2
- Page 166:
64 Control and meta-programming Yes
- Page 170:
66 Control and meta-programming Thi
- Page 174:
68 Control and meta-programming X =
- Page 178:
70 Control and meta-programming ass
- Page 182:
72 Control and meta-programming Ys
- Page 186:
74 Control and meta-programming Ys
- Page 190:
5 Manipulating structures 5.1 Struc
- Page 194:
78 Manipulating structures [eclipse
- Page 198:
80 Manipulating structures 5.3 Stru
- Page 202:
82 Manipulating structures and t a
- Page 206:
84 Manipulating structures a non-nu
- Page 210:
86 Manipulating structures Exercise
- Page 216:
6 Constraint programming: a primer
- Page 220:
6.3 Example classes of constraints
- Page 224:
• the assumed numeric constants,
- Page 228:
6.4 Constraint satisfaction problem
- Page 232:
6.4 Constraint satisfaction problem
- Page 236:
6.5 Constrained optimisation proble
- Page 240:
6.5 Constrained optimisation proble
- Page 244:
6.6 Solving CSPs and COPs 103 devel
- Page 248:
6.6 Solving CSPs and COPs 105 Fig.
- Page 252:
6.7 From CSPs and COPs to constrain
- Page 256:
6.9 Exercises 109 indicates the tot
- Page 260:
7.2 Iterating over lists and intege
- Page 264:
7.3 Iteration specifications in gen
- Page 268:
7.3 Iteration specifications in gen
- Page 272:
7.3 Iteration specifications in gen
- Page 276:
7.3 Iteration specifications in gen
- Page 280:
7.4 Arrays and iterations 121 7.4 A
- Page 284:
do true ), X is Array[3]. Array = [
- Page 288:
7.5 fromto/4: the most general iter
- Page 292:
7.5 fromto/4: the most general iter
- Page 296:
In = In Rest = Rest OutList = [3, 5
- Page 300:
7.7 Summary 131 8 7 6 5 4 3 2 1 a b
- Page 304:
8 Top-down search with passive cons
- Page 308:
8.3 Backtracking search in Prolog 1
- Page 312:
8.3 Backtracking search in Prolog 1
- Page 316:
8.4 Incomplete search 139 % choose_
- Page 320:
8.4 Incomplete search 141 % search(
- Page 324:
% share_credit(Domain, N, DomCredLi
- Page 328:
% share_credit(Domain, N, DomCredLi
- Page 332:
8.5 Non-logical variables 147 logic
- Page 336:
8.6 Counting the number of backtrac
- Page 340:
8.6 Counting the number of backtrac
- Page 344:
8.7 Summary 153 8.7 Summary In this
- Page 348:
9 The suspend library 9.1 Introduct
- Page 352:
9.3 Introducing the suspend library
- Page 356:
9.3 Introducing the suspend library
- Page 360:
9.4 Core constraints 161 [eclipse 6
- Page 364:
9.4 Core constraints 163 Yes (0.00s
- Page 368:
[S,E,N,D,M,O,R,Y] :: 0..9. 9.4 Core
- Page 372:
Yes (0.00s cpu) [eclipse 31]: $>(3,
- Page 376:
This predicate waits using the call
- Page 380:
9.6 Generating CSPs 171 we use the
- Page 384:
9.6 Generating CSPs 173 section 6.4
- Page 388:
9.7 Using the suspend library 175 Y
- Page 392:
9.7 Using the suspend library 177 T
- Page 396:
9.7 Using the suspend library 179 T
- Page 400:
9.9 Exercises 181 9.9 Exercises Exe
- Page 404:
Part IV Programming with active con
- Page 410:
186 Constraint propagation in ECL i
- Page 414:
188 Constraint propagation in ECL i
- Page 418:
190 Constraint propagation in ECL i
- Page 422:
192 Constraint propagation in ECL i
- Page 426:
194 Constraint propagation in ECL i
- Page 430:
196 Constraint propagation in ECL i
- Page 434:
198 Constraint propagation in ECL i
- Page 438:
200 Constraint propagation in ECL i
- Page 442:
202 Constraint propagation in ECL i
- Page 446:
204 Constraint propagation in ECL i
- Page 450:
206 Top-down search with active con
- Page 454:
208 Top-down search with active con
- Page 458:
210 Top-down search with active con
- Page 462:
212 Top-down search with active con
- Page 466:
214 Top-down search with active con
- Page 470:
216 Top-down search with active con
- Page 474:
218 Top-down search with active con
- Page 478:
220 Top-down search with active con
- Page 482:
222 Top-down search with active con
- Page 486:
224 Top-down search with active con
- Page 490:
226 Top-down search with active con
- Page 494:
228 Top-down search with active con
- Page 498:
12 Optimisation with active constra
- Page 502:
232 Optimisation with active constr
- Page 506:
234 Optimisation with active constr
- Page 510:
236 Optimisation with active constr
- Page 514:
238 Optimisation with active constr
- Page 518:
240 Optimisation with active constr
- Page 522:
242 Optimisation with active constr
- Page 526:
244 Optimisation with active constr
- Page 530:
246 Optimisation with active constr
- Page 534:
248 Optimisation with active constr
- Page 538:
250 Optimisation with active constr
- Page 542:
252 Optimisation with active constr
- Page 546:
254 Optimisation with active constr
- Page 550:
13 Constraints on reals 13.1 Introd
- Page 554:
258 Constraints on reals L W Fig. 1
- Page 558:
260 Constraints on reals compost_2(
- Page 562:
262 Constraints on reals Delayed go
- Page 566:
264 Constraints on reals Domain spl
- Page 570:
266 Constraints on reals 10 5 0 -5
- Page 574:
268 Constraints on reals search pre
- Page 578:
270 Constraints on reals mortgage(L
- Page 582:
272 Constraints on reals 13.8 Optim
- Page 586:
274 Constraints on reals solution w
- Page 590:
276 Constraints on reals optimisati
- Page 594:
14 Linear constraints over continuo
- Page 598:
280 Linear constraints over continu
- Page 602: 282 Linear constraints over continu
- Page 606: 284 Linear constraints over continu
- Page 610: 286 Linear constraints over continu
- Page 614: 288 Linear constraints over continu
- Page 618: 290 Linear constraints over continu
- Page 622: 292 Linear constraints over continu
- Page 626: 294 Linear constraints over continu
- Page 630: 296 Linear constraints over continu
- Page 634: 298 Linear constraints over continu
- Page 638: 300 Linear constraints over continu
- Page 642: 302 Linear constraints over continu
- Page 646: 304 Linear constraints over continu
- Page 650: 306 Solutions to selected exercises
- Page 656: vars(Term, []) :- atomic(Term), !.
- Page 660: nl_indent(N) :- nl, ( for(_I,1,N) d
- Page 664: Solutions to selected exercises 313
- Page 668: correct(List) :- ( foreach(El,List)
- Page 672: Solutions to selected exercises 317
- Page 676: Solutions to selected exercises 319
- Page 680: Bibliographic remarks 321 the July
- Page 684: Bibliography K. R. Apt [2003] Princ
- Page 688: Bibliography 325 A. Mackworth [1977
- Page 692: Index ./2, 81 //, 42 1e-n, 261 ::/2
- Page 696: Index 329 interpretation, 90 declar