findRoots | R Documentation |
Find complex roots of polynomials in x that are quadratic polynomials in x^k
findRoots(coefs, k = 1)
coefs |
Coefficients |
k |
Order of x^k |
It is assumed that c_2k
is non-zero, and that at least one of
c_0
and c_k
are non-zero (otherwise, we have a double
root, which is not treated by fdaLm
in the present
implementation). An error is issued if these assumptions are violated.
A list with components
left |
The k roots with left most real components |
right |
The k roots with right most real components |
This function is intended for internal usage in fdaLm
to
find eigenvalues. If a robust and stable method of finding all the
complex roots is a polynomial were available, then this could be used
in fdaLm
instead enhancing the scope of this function.
Bo Markussen <bomar@math.ku.dk>
Solved using Section 5.6 in Press et al, "Numerical Recipies in C", second edition.
findRoots(c(-1,0,1),1)
findRoots(c(1,-1,1),2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.