Iterator[Trees]
Convert
convert between tree formats
Calling Sequence
Parameters
Description
Examples
Compatibility
Convert(tree,fin,fout)
tree
-
Array; tree to convert
fin
A,C,D,E,LR,P,S,Z; format of input
fout
A,C,D,E,LR,P,S,Z; format of output
The Convert command converts one tree format to another.
The tree parameter is an Array corresponding to a tree format. It may consist of two Array, L and R, if the input format is LR.
The fin and fout parameters specify the input format and the desired output format. The symbols A, C, D, E, LR, P, S, Z specify each of the formats. See Iterator[Trees] for a description of each format.
with⁡Iterator:-Trees:
Generate a random tree, in LR format, with 10 internal nodes.
L,R≔Random⁡10,format=LR
L,R≔2045070900,10306008000
Convert the two arrays to a tree in Z format.
Convert⁡L,R,LR,Z
12456910121319
The Iterator[Trees][Convert] command was introduced in Maple 2016.
For more information on Maple 2016 changes, see Updates in Maple 2016.
See Also
Iterator
Download Help Document