Sponsored links: Algebra eBooks
 

Help Index

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z

The Maxima on-line user's manual

Algebra Calculator

Search:

Map Calculator

Map

Function: map (<f>, <expr_1>, ..., <expr_n>) Returns an expression whose leading operator is the same as that of the expressions <expr_1>, ..., <expr_n> but whose subparts are the results of applying <f> to the corresponding subparts of the expressions. <f> is either the name of a function of n arguments or is a lambda form of n arguments.

X:makelist(i/324,i,500,510);
f(x):=floor(x*100+0.5)/100.0;
map(f,X);

maperror - if false will cause all of the mapping functions to (1) stop when they finish going down the shortest <expr_i> if not all of the <expr_i> are of the same length and (2) apply <f> to [<expr_1>, <expr_2>, ...] if the <expr_i> are not all the same type of object. If maperror is true then an error message will be given in the above two instances.

One of the uses of this function is to map a function (e.g. partfrac) onto each term of a very large expression where it ordinarily wouldnt be possible to use the function on the entire expression due to an exhaustion of list storage space in the course of the computation.

          (%i1) map(f,x+a*y+b*z);
          (%o1)                        f(b z) + f(a y) + f(x)
          (%i2) map(lambda([u],partfrac(u,x)),x+1/(x^3+4*x^2+5*x+2));
                                     1       1        1
          (%o2)                     ----- - ----- + -------- + x
                                   x + 2   x + 1          2
                                                   (x + 1)
          (%i3) map(ratsimp, x/(x^2+x)+(y^2+y)/y);
                                                1
          (%o3)                            y + ----- + 1
                                              x + 1
          (%i4) map("=",[a,b],[-0.5,3]);
          (%o4)                          [a = - 0.5, b = 3]

There are also some inexact matches for map. Try ?? map to see them.

(%o1)                                true
(%i2) 

Map Example

Related Examples

map-solve

solutions: solve(x^2=9);

xvals: map(rhs,soluti...

xvals[1];

Calculate

map

map(is,[true,true,tru...

Calculate

map-numer-plot2d-rhs-solve
plot2d([rhs(Parabel)],[x,0,100]);

A:[0,1000];

B:[50,3000];

C:[80,6000];

Calculate

map-transpose

Aufgabe:[[f(x):=x**2,...

transpose(Aufgabe);

funktion(x):=[x[1]];

Calculate

map

f(x) := (2^2-x^2)/(2-x);

map (f,[-3,-2.9,-2.5,...

Calculate

map

x : 4;

x;

f(x) := 4*x^3 - 10*x^...

Calculate

map

Punkt:[[3,0],[4,-1],[...

g(x):=x[2]=a*x[1]^2+b...

Gleichung:map(g,Punkt);

Calculate

map-solve

gl1 : 2 * t^2 - 8 * t...

lsg : solve (gl1);

/* Wenn Sie das Ergeb...

Calculate

map

x : 4;

x;

f(x) := 4*x^3 - 10*x^...

Calculate

map

f(x) := 2^2-x^2/2-x;

map(f,[3, 2.9, 2.5,2....

Calculate