GraphTheory
PrueferCode
compute Pruefer code
Calling Sequence
Parameters
Description
Examples
Details
References
Compatibility
PrueferCode(L)
PrueferCode(T)
T
-
tree
L
list, Vector, or Array of positive integers
PrueferCode(L) returns a tree which corresponds to the Prüfer encoding of L. The input L must be a list, Vector, or 1-D Array whose elements are positive integers less than or equal to numelems(L)+2.
PrueferCode(T) returns a list of positive integers comprising the Prüfer encoding of a tree T.
The Prüfer encoding of a tree was first used by Heinz Prüfer to prove Cayley's formula, which states that the number of trees on n labeled vertices is .
"Prüfer sequence", Wikipedia. https://en.wikipedia.org/wiki/Pruefer_sequence
The GraphTheory[PrueferCode] command was introduced in Maple 2021.
For more information on Maple 2021 changes, see Updates in Maple 2021.
See Also
IsTree
Newick
Download Help Document