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[agfmomentsolve] - solve the system of generating function equations associated with an attribute grammar
Calling Sequence
agfmomentsolve(eqns, num, neweqns)
Parameters
eqns
-
set of multivariate generating function equations
num
number of times to differentiate; non-negative integer
neweqns
(optional) set of equations that Maple attempts to solve
Description
The agfmomentsolve function accepts a set of multivariate generating functions. It attempts to solve the system of generating functions where the equations are differentiated num times with respect to each variable aside from size. It then evaluates the equations with each nonsize variable set to 1.
The functions are returned as univariate functions. Thus, it is important that the first variable marks size. The agfmomentsolve function is useful for finding averages and higher moments.
The modified equations are returned by using the third argument, neweqns. If it is specified, it is assigned to the system of equations.
If the solving computation is intensive, you can interrupt it and recover the equations. This allows you to intervene with some manual manipulation or specialized solving methods.
The agfmomentsolve function relies on solutions obtained by agfmomentsolve(eqns, num-j) where . Thus, if these cannot be solved, fail is returned.
For information on how to write combstruct grammar specifications, see combstruct and combstruct[specification].
Examples
First, obtain a system of equations by using gfeqns or agfeqns.
The following two examples use the variable to mark the number of internal nodes in a nonplane tree.
Given the equations, it is possible to solve the generating function for the number of trees. This can be obtained from the univariate system which is obtained from the multivariate system with set to 1. Further, cumulative generating functions for the number of internal nodes in a binary tree is determined by differentiating the multivariate generating function with respect to , and setting this variable to 1. That is, the value of the system that agfmomentsolve(eqns, 1) attempts to solve.
The coefficient of of , , is the number of trees with nodes, and is the total sum of all trees with nodes for the number of internal nodes. The average number of internal nodes for a tree on nodes is .
This agfmomentsolve function yields information that can be used to compute the variance.
See Also
combstruct, combstruct[agfeqns], combstruct[gfsolve], combstruct[specification]
Download Help Document