Convert - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


Iterator[Trees]

  

Convert

  

convert between tree formats

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

Convert(tree,fin,fout)

Parameters

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

Description

• 

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.

Examples

withIterator:-Trees:

Generate a random tree, in LR format, with 10 internal nodes.

L,RRandom10,format=LR

L,R2045070900,10306008000

(1)

Convert the two arrays to a tree in Z format.

ConvertL,R,LR,Z

12456910121319

(2)

Compatibility

• 

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

Iterator[Trees]