Introduction to the Combinatorial Structures Package - Maple Programming Help

Online Help

All Products    Maple    MapleSim

Home : Support : Online Help : Applications and Example Worksheets : Discrete Mathematics : examples/combstruct_grammars

Introduction to the Combinatorial Structures Package

The combinatorial structures package, combstruct, is used to define and manipulate combinatorial structures.

With combstruct, you can define a combinatorial class of objects; generate uniformly at random, objects belonging to that class; count the number of objects of a given size; and analyze properties of the object.  For certain common structures which have been predefined in the system, it is possible to create an iterator which traverses all the objects in the given class, and to list all such objects at once.

There are two main portions to combstruct. The facility to define your structures using a grammar and using the predefined structures provided.

Note:  The predefined structures portion of combstruct provides an extension of the functions in the combinat package involving combinations, permutations, partitions, compositions, and subsets.  The combstruct functions do everything these functions do, and more as well as providing a consistent interface in terms of function names and syntax.

This worksheet is an introduction to the basics of how to define combstruct grammars and some basic uses. See the companion generating functions page for more details on how to determine equations, series representations and even solve for the generating functions of the objects. Also, there are several worksheets which describe some interesting applications and extensions of combstruct, at the level of additional functionality for attribute analysis, and some of complex examples. The help pages give an overview. In particular, see combstruct, combstruct[specification], and combstruct[structures].


For more examples, see the other combstruct example worksheets Sample Structures, and Generating Functions.  For more advanced examples, see Attribute Grammars.


First, load the combstruct package functions.


Return to Index for Example Worksheets

Download Help Document

Was this information helpful?

Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam