[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

6.9 Operations on functions


[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

6.9.1 call

call(name, args)

:: Call the function name with args.

return

a return value of name().

name

indefinite (function name)

args

a list of arguments

[0] A=igcd;
igcd
[1] call(A,[4,6]);
2
[2] (*A)(4,6);
2
References

vtype.


[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

6.9.2 functor, args, funargs

functor(func)

:: Functor of function form func.

args(func)

:: List of arguments of function form func.

funargs(func)

:: cons(functor(func),args(func)).

return

functor() : indeterminate, args(), funargs() : list

func

function form

[0] functor(sin(x));
sin
[0] args(sin(x));
[x]
[0] funargs(sin(3*cos(y)));
[sin,3*cos(y)]
[1] for (L=[sin,cos,tan];L!=[];L=cdr(L)) {A=car(L); 
print(eval((*A)(@pi/3)));}
0.86602540349122136831
0.5000000002
1.7320508058
References

vtype.


[ << ] [ < ] [ Up ] [ > ] [ >> ]

This document was generated on December 18, 2017 using texi2html 5.0.