krylov | R Documentation |
Given \bold{A}
an n
by n
real matrix and an n
-vector \bold{b}
,
this function constructs the Krylov matrix \bold{K}
, where
\bold{K} = [\bold{b},\bold{Ab},\dots,\bold{A}^{m-1}\bold{b}].
krylov(a, b, m = ncol(a))
a |
a numeric square matrix of order |
b |
a numeric vector of length |
m |
length of the Krylov sequence. |
Returns an n
by m
matrix.
a <- matrix(c(1, 3, 2, -5, 1, 7, 1, 5, -4), ncol = 3, byrow = TRUE)
b <- c(1, 1, 1)
k <- krylov(a, b, m = 4)
k
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.