forked from johannesgerer/jburkardt-cpp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
combo.html
832 lines (794 loc) · 25 KB
/
combo.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
<html>
<head>
<title>
COMBO - Kreher and Stinson Combinatorial Routines
</title>
</head>
<body bgcolor="#EEEEEE" link="#CC0000" alink="#FF3300" vlink="#000055">
<h1 align = "center">
COMBO <br> Kreher and Stinson Combinatorial Routines
</h1>
<hr>
<p>
<b>COMBO</b>
is a C++ library which
includes routines for ranking, unranking, enumerating and
randomly selecting balanced sequences, cycles, graphs, Gray codes,
subsets, partitions, permutations, restricted growth functions,
Pruefer codes and trees.
</p>
<p>
Routines are available to count, list, rank and unrank such objects
<ul>
<li>
<b>BAL</b>, balanced sequences;
</li>
<li>
<b>CYCLE</b>, permutations of the first N integers in cycle form;
</li>
<li>
<b>GRAPH</b>, graphs stored as a list of edges.
</li>
<li>
<b>GRAY</b>, Gray codes;
</li>
<li>
<b>KNAPSACK</b>, optimally filling a knapsack of given size using
a set of smaller objects;
</li>
<li>
<b>KSUBSET</b>, subsets of size exactly K from a set of N objects;
</li>
<li>
<b>NPART</b>, partitions of an integer having exactly N parts;
</li>
<li>
<b>PART</b>, partitions of an integer;
</li>
<li>
<b>PERM</b>, permutations of the first N integers in standard form;
</li>
<li>
<b>PRUEFER</b>, Pruefer codes;
</li>
<li>
<b>RGF</b>, restricted growth functions;
</li>
<li>
<b>SETPART</b>, partitions of a set;
</li>
<li>
<b>SUBSET</b>, subsets of a set of N objects;
</li>
<li>
<b>TABLEAU</b>, tableaus;
</li>
<li>
<b>TREE</b>, trees;
</li>
</ul>
</p>
<p>
Some of these sets of objects can be ordered in several different
ways, and in some cases, a separate set of ranking, unranking, and
successor routines are available for the various orderings
(lexical, colexical, revolving door, Trotter-Johnson).
</p>
<p>
Kreher and Stinson provide C source-code for the routines,
as well as other information, at
<a href = "http://www.math.mtu.edu/~kreher/cages.html">
their web site.</a>
</p>
<h3 align = "center">
Licensing:
</h3>
<p>
The computer code and data files described and made available on this web page
are distributed under
<a href = "../../txt/gnu_lgpl.txt">the GNU LGPL license.</a>
</p>
<h3 align = "center">
Languages:
</h3>
<p>
<b>COMBO</b> is available in
<a href = "../../c_src/combo/combo.html">a C version</a> and
<a href = "../../cpp_src/combo/combo.html">a C++ version</a> and
<a href = "../../f77_src/combo/combo.html">a FORTRAN77 version</a> and
<a href = "../../f_src/combo/combo.html">a FORTRAN90 version</a> and
<a href = "../../m_src/combo/combo.html">a MATLAB version</a>.
</p>
<h3 align = "center">
Related Data and Programs:
</h3>
<p>
<a href = "../../cpp_src/change_making/change_making.html">
CHANGE_MAKING</a>,
a C++ library which
considers the change making problem,
in which a given sum is to be formed using coins of various denominations.
</p>
<p>
<a href = "../../cpp_src/floyd/floyd.html">
FLOYD</a>,
a C++ library which
implements Floyd's algorithm for finding the shortest distance between pairs of
nodes on a directed graph.
</p>
<p>
<a href = "../../cpp_src/knapsack_01/knapsack_01.html">
KNAPSACK_01</a>,
a C++ library which
uses brute force to solve small versions of the 0/1 knapsack problem;
</p>
<p>
<a href = "../../cpp_src/legendre_product_polynomial/legendre_product_polynomial.html">
LEGENDRE_PRODUCT_POLYNOMIAL</a>,
a C++ library which
defines Legendre product polynomials, creating a multivariate
polynomial as the product of univariate Legendre polynomials.
</p>
<p>
<a href = "../../cpp_src/monomial/monomial.html">
MONOMIAL</a>,
a C++ library which
enumerates, lists, ranks, unranks and randomizes multivariate monomials
in a space of M dimensions, with total degree less than N,
equal to N, or lying within a given range.
</p>
<p>
<a href = "../../cpp_src/partition_problem/partition_problem.html">
PARTITION_PROBLEM</a>,
a C++ library which
seeks solutions of the partition problem, splitting a set of integers into
two subsets with equal sum.
</p>
<p>
<a href = "../../cpp_src/polynomial/polynomial.html">
POLYNOMIAL</a>,
a C++ library which
adds, multiplies, differentiates, evaluates and prints multivariate
polynomials in a space of M dimensions.
</p>
<p>
<a href = "../../f_src/select/select.html">
SELECT</a>,
a FORTRAN90 library which
generates various combinatorial objects.
</p>
<p>
<a href = "../../cpp_src/subset/subset.html">
SUBSET</a>,
a C++ library which
generates, ranks and unranks various combinatorial objects.
</p>
<p>
<a href = "../../cpp_src/subset_sum/subset_sum.html">
SUBSET_SUM</a>,
a C++ library which
seeks solutions of the subset sum problem.
</p>
<p>
<a href = "../../cpp_src/unicycle/unicycle.html">
UNICYCLE</a>,
a C++ library which
considers permutations containing a single cycle, sometimes called
cyclic permutations.
</p>
<h3 align = "center">
Reference:
</h3>
<p>
<ol>
<li>
Milton Abramowitz, Irene Stegun,<br>
Handbook of Mathematical Functions,<br>
National Bureau of Standards, 1964,<br>
ISBN: 0-486-61272-4,<br>
LC: QA47.A34.
</li>
<li>
Paul Bratley, Bennett Fox, Linus Schrage,<br>
A Guide to Simulation,<br>
Second Edition,<br>
Springer, 1987,<br>
ISBN: 0387964673,<br>
LC: QA76.9.C65.B73.
</li>
<li>
William Cody, Kenneth Hillstrom,<br>
Chebyshev Approximations for the Natural Logarithm of the
Gamma Function,
Mathematics of Computation,<br>
Volume 21, Number 98, April 1967, pages 198-203.
</li>
<li>
Robert Fenichel,<br>
Algorithm 329:
Distribution of Indistinguishable Objects into
Distinguishable Slots,<br>
Communications of the ACM,<br>
Volume 11, Number 6, June 1968, page 430.
</li>
<li>
Bennett Fox,<br>
Algorithm 647:
Implementation and Relative Efficiency of Quasirandom
Sequence Generators,<br>
ACM Transactions on Mathematical Software,<br>
Volume 12, Number 4, December 1986, pages 362-376.
</li>
<li>
John Hart, Ward Cheney, Charles Lawson, Hans Maehly,
Charles Mesztenyi, John Rice, Henry Thacher,
Christoph Witzgall,<br>
Computer Approximations,<br>
Wiley, 1968,<br>
LC: QA297.C64.
</li>
<li>
Brian Hayes,<br>
The Easiest Hard Problem,<br>
American Scientist,<br>
Volume 90, Number 2, March-April 2002, pages 113-117.
</li>
<li>
Donald Kreher, Douglas Simpson,<br>
Combinatorial Algorithms,<br>
CRC Press, 1998,<br>
ISBN: 0-8493-3988-X,<br>
LC: QA164.K73.
</li>
<li>
Pierre LEcuyer,<br>
Random Number Generation,<br>
in Handbook of Simulation,<br>
edited by Jerry Banks,<br>
Wiley, 1998,<br>
ISBN: 0471134031,<br>
LC: T57.62.H37.
</li>
<li>
Peter Lewis, Allen Goodman, James Miller,<br>
A Pseudo-Random Number Generator for the System/360,<br>
IBM Systems Journal,<br>
Volume 8, 1969, pages 136-143.
</li>
<li>
Albert Nijenhuis, Herbert Wilf,<br>
Combinatorial Algorithms for Computers and Calculators,<br>
Second Edition,<br>
Academic Press, 1978,<br>
ISBN: 0-12-519260-6,<br>
LC: QA164.N54.
</li>
<li>
Robert Sedgewick,<br>
Algorithms in C,<br>
Addison-Wesley, 1990,<br>
ISBN: 0-201-51425-7,<br>
LC: QA76.73.C15S43.
</li>
<li>
Jack vanLint, Richard Wilson,<br>
A Course in Combinatorics,<br>
Cambridge, 1992,<br>
ISBN: 0-521-42260-4,<br>
LC: QA164.L56.
</li>
<li>
ML Wolfson, HV Wright,<br>
Algorithm 160:
Combinatorial of M Things Taken N at a Time,<br>
Communications of the ACM,<br>
Volume 6, Number 4, April 1963, page 161.
</li>
</ol>
</p>
<h3 align = "center">
Source Code:
</h3>
<p>
<ul>
<li>
<a href = "combo.cpp">combo.cpp</a>, the source code;
</li>
<li>
<a href = "combo.hpp">combo.hpp</a>, the include file;
</li>
<li>
<a href = "combo.sh">combo.sh</a>,
commands to compile the source code;
</li>
</ul>
</p>
<h3 align = "center">
Examples and Tests:
</h3>
<p>
<ul>
<li>
<a href = "combo_prb.cpp">combo_prb.cpp</a>, the calling program;
</li>
<li>
<a href = "combo_prb.sh">combo_prb.sh</a>,
commands to compile, link and run the calling program;
</li>
<li>
<a href = "combo_prb_output.txt">combo_prb_output.txt</a>,
the output file.
</li>
</ul>
</p>
<h3 align = "center">
List of Routines:
</h3>
<p>
<ul>
<li>
<b>BACKTRACK</b> supervises a backtrack search.
</li>
<li>
<b>BAL_SEQ_CHECK</b> checks a balanced sequence.
</li>
<li>
<b>BAL_SEQ_ENUM</b> enumerates the balanced sequences.
</li>
<li>
<b>BAL_SEQ_RANK</b> ranks a balanced sequence.
</li>
<li>
<b>BAL_SEQ_SUCCESSOR</b> computes the lexical balanced sequence successor.
</li>
<li>
<b>BAL_SEQ_TO_TABLEAU</b> converts a balanced sequence to a 2 by N tableau.
</li>
<li>
<b>BAL_SEQ_UNRANK</b> unranks a balanced sequence.
</li>
<li>
<b>BELL_NUMBERS</b> computes the Bell numbers.
</li>
<li>
<b>BELL_VALUES</b> returns some values of the Bell numbers.
</li>
<li>
<b>BINOMIAL</b> computes the binomial coefficient C(N,K).
</li>
<li>
<b>COMBIN</b> computes the combinatorial coefficient C(N,K).
</li>
<li>
<b>CYCLE_CHECK</b> checks a permutation in cycle form.
</li>
<li>
<b>CYCLE_TO_PERM</b> converts a permutation from cycle to array form.
</li>
<li>
<b>DIST_ENUM</b> returns the number of distributions of indistinguishable objects.
</li>
<li>
<b>DIST_NEXT</b> returns the next distribution of indistinguishable objects.
</li>
<li>
<b>EDGE_CHECK</b> checks a graph stored by edges.
</li>
<li>
<b>EDGE_DEGREE</b> returns the degree of the nodes of a graph stored by edges.
</li>
<li>
<b>EDGE_ENUM</b> enumerates the maximum number of edges in a graph on N_NODE nodes.
</li>
<li>
<b>FALL</b> computes the falling factorial function [X]_N.
</li>
<li>
<b>GRAY_CODE_CHECK</b> checks a Gray code element.
</li>
<li>
<b>GRAY_CODE_ENUM</b> enumerates the Gray codes on N digits.
</li>
<li>
<b>GRAY_CODE_RANK</b> computes the rank of a Gray code element.
</li>
<li>
<b>GRAY_CODE_SUCCESSOR</b> computes the binary reflected Gray code successor.
</li>
<li>
<b>GRAY_CODE_UNRANK</b> computes the Gray code element of given rank.
</li>
<li>
<b>I4_FACTORIAL</b> computes the factorial of N.
</li>
<li>
<b>I4_FACTORIAL_VALUES</b> returns values of the factorial function.
</li>
<li>
<b>I4_HUGE</b> returns a "huge" I4.
</li>
<li>
<b>I4_MAX</b> returns the maximum of two I4's.
</li>
<li>
<b>I4_MIN</b> returns the minimum of two I4's.
</li>
<li>
<b>I4_POWER</b> returns the value of I^J.
</li>
<li>
<b>I4_UNIFORM</b> returns a scaled pseudorandom I4.
</li>
<li>
<b>I4MAT_PRINT</b> prints an I4MAT.
</li>
<li>
<b>I4MAT_PRINT_SOME</b> prints some of an I4MAT.
</li>
<li>
<b>I4VEC_BACKTRACK</b> supervises a backtrack search for an I4VEC.
</li>
<li>
<b>I4VEC_INDICATOR</b> sets an I4VEC to the indicator vector.
</li>
<li>
<b>I4VEC_MAX</b> returns the value of the maximum element in an I4VEC.
</li>
<li>
<b>I4VEC_PART1</b> partitions an integer N into NPART parts.
</li>
<li>
<b>I4VEC_PART2</b> partitions an integer N into NPART nearly equal parts.
</li>
<li>
<b>I4VEC_PART2_NEW</b> partitions an integer N into NPART nearly equal parts.
</li>
<li>
<b>I4VEC_PRINT</b> prints an I4VEC.
</li>
<li>
<b>I4VEC_REVERSE</b> reverses the elements of an I4VEC.
</li>
<li>
<b>I4VEC_SEARCH_BINARY_A</b> searches an ascending sorted I4VEC for a value.
</li>
<li>
<b>I4VEC_SEARCH_BINARY_D</b> searches a descending sorted I4VEC for a value.
</li>
<li>
<b>I4VEC_SORT_INSERT_A</b> uses an ascending insertion sort on an I4VEC.
</li>
<li>
<b>I4VEC_SORT_INSERT_D</b> uses a descending insertion sort on an I4VEC.
</li>
<li>
<b>I4VEC_SUM</b> sums the entries of an I4VEC.
</li>
<li>
<b>I4VEC_TRANSPOSE_PRINT</b> prints an I4VEC "transposed".
</li>
<li>
<b>KNAPSACK_01</b> solves the 0/1 knapsack problem.
</li>
<li>
<b>KNAPSACK_RATIONAL</b> solves the rational knapsack problem.
</li>
<li>
<b>KNAPSACK_REORDER</b> reorders the knapsack data by "profit density".
</li>
<li>
<b>KSUBSET_COLEX_CHECK</b> checks a K subset in colex form.
</li>
<li>
<b>KSUBSET_COLEX_RANK</b> computes the colex rank of a K subset.
</li>
<li>
<b>KSUBSET_COLEX_SUCCESSOR</b> computes the K subset colex successor.
</li>
<li>
<b>KSUBSET_COLEX_UNRANK</b> computes the K subset of given colex rank.
</li>
<li>
<b>KSUBSET_ENUM</b> enumerates the K element subsets of an N set.
</li>
<li>
<b>KSUBSET_LEX_CHECK</b> checks a K subset in lex form.
</li>
<li>
<b>KSUBSET_LEX_RANK</b> computes the lexicographic rank of a K subset.
</li>
<li>
<b>KSUBSET_LEX_SUCCESSOR</b> computes the K subset lexicographic successor.
</li>
<li>
<b>KSUBSET_LEX_UNRANK</b> computes the K subset of given lexicographic rank.
</li>
<li>
<b>KSUBSET_REVDOOR_RANK</b> computes the revolving door rank of a K subset.
</li>
<li>
<b>KSUBSET_REVDOOR_SUCCESSOR</b> computes the K subset revolving door successor.
</li>
<li>
<b>KSUBSET_REVDOOR_UNRANK</b> computes the K subset of given revolving door rank.
</li>
<li>
<b>MARRIAGE</b> finds a stable set of marriages for given preferences.
</li>
<li>
<b>MOUNTAIN</b> enumerates the mountains.
</li>
<li>
<b>NPART_ENUM</b> enumerates the number of partitions of N with NPART parts.
</li>
<li>
<b>NPART_RSF_LEX_RANDOM</b> returns a random RSF NPART partition.
</li>
<li>
<b>NPART_RSF_LEX_RANK</b> computes the lex rank of an RSF NPART partition.
</li>
<li>
<b>NPART_RSF_LEX_SUCCESSOR</b> computes the RSF lex successor for NPART partitions.
</li>
<li>
<b>NPART_RSF_LEX_UNRANK</b> unranks an RSF NPART partition in the lex ordering.
</li>
<li>
<b>NPART_SF_LEX_SUCCESSOR</b> computes SF NPART partition.
</li>
<li>
<b>NPART_TABLE</b> tabulates the number of partitions of N having NPART parts.
</li>
<li>
<b>PART_ENUM</b> enumerates the number of partitions of N.
</li>
<li>
<b>PART_RSF_CHECK</b> checks a reverse standard form partition of an integer.
</li>
<li>
<b>PART_SF_CHECK</b> checks a standard form partition of an integer.
</li>
<li>
<b>PART_SF_CONJUGATE</b> computes the conjugate of a partition.
</li>
<li>
<b>PART_SF_MAJORIZE</b> determines if partition A majorizes partition B.
</li>
<li>
<b>PART_SUCCESSOR</b> computes the lexicographic partition successor.
</li>
<li>
<b>PART_TABLE</b> tabulates the number of partitions of N.
</li>
<li>
<b>PARTITION_GREEDY</b> attacks the partition problem with a greedy algorithm.
</li>
<li>
<b>PARTN_ENUM</b> enumerates the partitions of N with maximum element NMAX.
</li>
<li>
<b>PARTN_SF_CHECK</b> checks an SF partition of an integer with largest entry NMAX.
</li>
<li>
<b>PARTN_SUCCESSOR</b> computes partitions whose largest part is NMAX.
</li>
<li>
<b>PERM_CHECK</b> checks a representation of a permutation.
</li>
<li>
<b>PERM_ENUM</b> enumerates the permutations on N digits.
</li>
<li>
<b>PERM_INV</b> computes the inverse of a permutation.
</li>
<li>
<b>PERM_LEX_RANK</b> computes the lexicographic rank of a permutation.
</li>
<li>
<b>PERM_LEX_SUCCESSOR</b> computes the lexicographic permutation successor.
</li>
<li>
<b>PERM_LEX_UNRANK</b> computes the permutation of given lexicographic rank.
</li>
<li>
<b>PERM_MUL</b> computes the product of two permutations.
</li>
<li>
<b>PERM_PARITY</b> computes the parity of a permutation.
</li>
<li>
<b>PERM_PRINT</b> prints a permutation.
</li>
<li>
<b>PERM_TJ_RANK</b> computes the Trotter-Johnson rank of a permutation.
</li>
<li>
<b>PERM_TJ_SUCCESSOR</b> computes the Trotter-Johnson permutation successor.
</li>
<li>
<b>PERM_TJ_UNRANK</b> computes the permutation of given Trotter-Johnson rank.
</li>
<li>
<b>PERM_TO_CYCLE</b> converts a permutation from array to cycle form.
</li>
<li>
<b>PRUEFER_CHECK</b> checks a Pruefer code.
</li>
<li>
<b>PRUEFER_ENUM</b> enumerates the Pruefer codes on N-2 digits.
</li>
<li>
<b>PRUEFER_RANK</b> ranks a Pruefer code.
</li>
<li>
<b>PRUEFER_SUCCESSOR</b> computes the lexical Pruefer sequence successor.
</li>
<li>
<b>PRUEFER_TO_TREE</b> converts a Pruefer code to a tree.
</li>
<li>
<b>PRUEFER_TO_TREE_NEW</b> converts a Pruefer code to a tree.
</li>
<li>
<b>PRUEFER_UNRANK</b> unranks a Pruefer code.
</li>
<li>
<b>QUEENS</b> finds possible positions for the K-th nonattacking queen.
</li>
<li>
<b>R4_NINT</b> returns the nearest integer to an R4.
</li>
<li>
<b>R4_UNIFORM</b> returns a scaled pseudorandom R4.
</li>
<li>
<b>R8_ABS</b> returns the absolute value of an R8.
</li>
<li>
<b>R8_ADD</b> adds two R8's.
</li>
<li>
<b>R8_EPSILON</b> returns the R8 roundoff unit.
</li>
<li>
<b>R8_GAMMA_LOG</b> calculates the natural logarithm of GAMMA ( X ) for positive X.
</li>
<li>
<b>R8_HUGE</b> returns a "huge" R8.
</li>
<li>
<b>R8_NINT</b> returns the nearest integer to an R8.
</li>
<li>
<b>R8VEC_BACKTRACK</b> supervises a backtrack search for a real vector.
</li>
<li>
<b>R8VEC_DOT_PRODUCT</b> computes the dot product of a pair of R8VEC's.
</li>
<li>
<b>RGF_CHECK</b> checks a restricted growth function.
</li>
<li>
<b>RGF_ENUM</b> enumerates the restricted growth functions on M.
</li>
<li>
<b>RGF_G_TABLE</b> tabulates the generalized restricted growth functions.
</li>
<li>
<b>RGF_RANK</b> ranks a restricted growth function.
</li>
<li>
<b>RGF_SUCCESSOR</b> generates the next restricted growth function.
</li>
<li>
<b>RGF_TO_SETPART</b> converts a restricted growth function to a set partition.
</li>
<li>
<b>RGF_UNRANK</b> returns the restricted growth function of a given rank.
</li>
<li>
<b>S_LEN_TRIM</b> returns the length of a string to the last nonblank.
</li>
<li>
<b>SETPART_CHECK</b> checks a set partition.
</li>
<li>
<b>SETPART_ENUM</b> enumerates the partitions of a set of M elements.
</li>
<li>
<b>SETPART_TO_RGF</b> converts a set partition to a restricted growth function.
</li>
<li>
<b>STIRLING_NUMBERS1</b> computes Stirling numbers of the first kind.
</li>
<li>
<b>STIRLING_NUMBERS2</b> computes Stirling numbers of the second kind.
</li>
<li>
<b>SUBSET_CHECK</b> checks a subset.
</li>
<li>
<b>SUBSET_COLEX_RANK</b> computes the colexicographic rank of a subset.
</li>
<li>
<b>SUBSET_COLEX_SUCCESSOR</b> computes the subset colexicographic successor.
</li>
<li>
<b>SUBSET_COLEX_UNRANK</b> computes the subset of given colexicographic rank.
</li>
<li>
<b>SUBSET_COMPLEMENT</b> computes the complement of a set.
</li>
<li>
<b>SUBSET_DISTANCE</b> computes the Hamming distance between two sets.
</li>
<li>
<b>SUBSET_ENUM</b> enumerates the subsets of a set with N elements.
</li>
<li>
<b>SUBSET_INTERSECT</b> computes the intersection of two sets.
</li>
<li>
<b>SUBSET_LEX_RANK</b> computes the lexicographic rank of a subset.
</li>
<li>
<b>SUBSET_LEX_SUCCESSOR</b> computes the subset lexicographic successor.
</li>
<li>
<b>SUBSET_LEX_UNRANK</b> computes the subset of given lexicographic rank.
</li>
<li>
<b>SUBSET_UNION</b> computes the union of two sets.
</li>
<li>
<b>SUBSET_WEIGHT</b> computes the Hamming weight of a set.
</li>
<li>
<b>SUBSET_XOR</b> computes the symmetric difference of two sets.
</li>
<li>
<b>SUBSETSUM_SWAP</b> seeks a solution of the subset sum problem by swapping.
</li>
<li>
<b>TABLEAU_CHECK</b> checks a 2 by N tableau.
</li>
<li>
<b>TABLEAU_ENUM</b> enumerates the 2 by N standard tableaus.
</li>
<li>
<b>TABLEAU_TO_BAL_SEQ</b> converts a 2 by N tableau to a balanced sequence.
</li>
<li>
<b>TIMESTAMP</b> prints the current YMDHMS date as a time stamp.
</li>
<li>
<b>TREE_CHECK</b> checks a tree.
</li>
<li>
<b>TREE_ENUM</b> enumerates the trees on N nodes.
</li>
<li>
<b>TREE_RANK</b> ranks a tree.
</li>
<li>
<b>TREE_SUCCESSOR</b> returns the successor of a tree.
</li>
<li>
<b>TREE_TO_PRUEFER</b> converts a tree to a Pruefer code.
</li>
<li>
<b>TREE_UNRANK</b> unranks a tree.
</li>
</ul>
</p>
<p>
You can go up one level to <a href = "../cpp_src.html">
the C++ source codes</a>.
</p>
<hr>
<i>
Last revised on 28 July 2011.
</i>
<!-- John Burkardt -->
</body>
</html>