Previous Up Next

6.48.11  Companion matrix of a polynomial: companion

The companion command finds a matrix given its characteristic polynomial; specifically, if the polynomial is P(x)=xn+an−1xn−1+…+a−1x+a0, this matrix is equal to the identity matrix of size n−1 bordered with [0,0..,0,−a0] as first row, and with [−a0,−a1,…,−an−1] as last column.


Examples.


Previous Up Next