Previous Up Next

2.24.6  Leading coefficient of a polynomial : lcoeff

lcoeff takes as argument a polynomial given by a symbolic expression or by the list of it’s coefficients.
lcoeff returns the leading coefficient of this polynomial, that is the coefficient of the monomial of highest degree.
Input :

lcoeff([2,1,-1,0])

Output :

2

Input :

lcoeff(3*x^2+5*x,x)

Output :

3

Input :

lcoeff(3*x^2+5*x*y^2,y)

Output :

5*x

Previous Up Next