Contents Previous Next Subchapters Current Chapters-> pol2asc polval polyval polyvalm poladd polmul polcomp polder zero2pol roots poly pol2zero polcheb polyreduce mlmode_conv deconv residue compan monomial Parent Chapters-> Omatrix6 polynomial polyvalm Search Tools-> contents reference index search

Evaluating A Descending Polynomial Using Matrix Multiplication
 Syntax `polyvalm(`p`, `x`)` See Also polyval , polval

Description
Returns the evaluation of the descending polynomial corresponding to p at the square matrix x. The return value is ```                 n-1                 1            0      p[x] = p  x     + ... +  p    x     +  p   x              1                 n-1           n ```where n is the length of the vector p and ```       0                                  i+1        i      x  = I  and for i = 2, ... , n-1,  x    = x * x  ```where `*` denotes matrix multiplication and `I` denotes the identity matrix with same dimensions as x. The integer, real, double-precision, or complex vector p specifies the polynomial to be evaluated. The integer, real, double-precision, or complex matrix x specifies the argument to the polynomial. The return matrix has the same dimension as x and the same type as a binary operation between p and x. (See the coercion entry in the O-Matrix User's Guide.)

Example
If you enter ```      p = [1, 1, 1]      x = { ...          [ 1 , -1 ], ...          [ 0 ,  1 ] ...      }      polyvalm(p, x) ``` O-Matrix will reply ```      {      [ 3 , -3 ]      [ 0 , 3 ]      } ``` If you continue by entering ```      x * x  +  x  +  identity(2) ``` O-Matrix will reply ```      {      [ 3 , -3 ]      [ 0 , 3 ]      } ```