Previous Up Next

6.27.3  Apply a function to the internal sparse format of a polynomial: map

The map command can apply a function to the coefficients of a polynomial written in internal sparse format. (See Section 6.40.28 for other uses of map.)


Example.
Input:

map(%%%{2,[2,1]%%%} + %%%{3,[1,4]%%%},(a,b,c)->a*b*c)

Output:

%%%{4,[2,1]%%%}+%%%{12,[1,4]%%%}

Previous Up Next