up previous next

Eval

Syntax

Eval(E:OBJECT,L:LIST):OBJECT
    

Summary

substitute numbers or polynomials for indeterminates

Description

This function substitutes the N-th element of L for the N-th indeterminate of the current ring for all N less than or equal to the minimum of the number of indeterminates of the current ring and the number of components of L.

example

    
Use Q[xy];
Eval(x^2+y,[2, 3]);
7
-------------------------------
Eval(x^2+y,[2]);
y + 4
-------------------------------
F:=x(x-1)(x-2)y(y-1)(y-2)/36;
P:=[1/2, -2/3];
Eval(F, P);
-5/162
-------------------------------
Eval([x+y,x-y],[2,1]);
[3, 1]
-------------------------------
Eval([x+y,x-y],[x^2,y^2]);
[x^2 + y^2, x^2 - y^2]
-------------------------------
Eval([x+y,x-y],[y]);
[2y, 0]
-------------------------------
        
    

See Also