Maple Professionel
Maple Académique
Maple Edition Étudiant
Maple Personal Edition
Maple Player
Maple Player for iPad
MapleSim Professionel
MapleSim Académique
Maple T.A. - Suite d'examens de classement
Maple T.A. MAA Placement Test Suite
Möbius - Didacticiels de mathématiques en ligne
Machine Design / Industrial Automation
Aéronautique
Ingénierie des véhicules
Robotics
Energie
System Simulation and Analysis
Model development for HIL
Modélisation du procédé pour la conception de systèmes de contrôle
Robotics/Motion Control/Mechatronics
Other Application Areas
Enseignement des mathématiques
Enseignement de l’ingénierie
Enseignement secondaire et supérieur (CPGE, BTS)
Tests et évaluations
Etudiants
Modélisation financière
Recherche opérationnelle
Calcul haute performance
Physique
Webinaires en direct
Webinaires enregistrés
Agenda des évènements
Forum MaplePrimes
Blog Maplesoft
Membres Maplesoft
Maple Ambassador Program
MapleCloud
Livres blancs techniques
Bulletin électronique
Livres Maple
Math Matters
Portail des applications
Galerie de modèles MapleSim
Cas d'Etudes Utilisateur
Exploring Engineering Fundamentals
Concepts d’enseignement avec Maple
Centre d’accueil utilisateur Maplesoft
Centre de ressources pour enseignants
Centre d’assistance aux étudiants
combstruct[draw] - draw random combinatorial object
combstruct[count] - count combinatorial objects of a specified size
Calling Sequence
draw([A, spec, typ], size=n)
draw(struct(args), size=n)
count([A, spec, typ], size=n)
count(struct(args), size=n)
Parameters
A
-
nonterminal of spec
spec
combinatorial specification
typ
labeling type; 'labeled' or 'unlabeled', the default is 'unlabeled'
n
(optional with structures) non-negative integer specifying the size of the object, or string 'allsizes'
struct
one of a pre-defined list of available structures
args
argument list that corresponds to the structure struct
Description
The draw function outputs a random object of size n in the class defined by the specification spec, with uniform distribution among all objects of the same size.
In the case of structures, the draw function returns an object of size n, or an object chosen from all possible sizes, or an object of the default size for that structure, if the size was not specified.
Use the string 'allsizes' which is available only for predefined structures when the object is chosen from all possible sizes.
The count function returns the number of such objects.
To learn how to write a grammar specification, see combstruct[specification].
For a list of available structures, see combstruct[structures].
Examples
See Also
combstruct, combstruct[specification], combstruct[structures]
Download Help Document