Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

wilkinson

wilkinson Matrix


Description

Generate the Wilkinson matrix of size n x n.The Wilkinson matrix for testing eigenvalue computations

Usage

wilkinson(n)

Arguments

n

integer

Details

The Wilkinson matrix for testing eigenvalue computations is a symmetric matrix with three non-zero diagonals and with several pairs of nearly equal eigenvalues.

Value

matrix of size n x n

Note

The two largest eigenvalues of wilkinson(21) agree to 14, but not 15 decimal places.

See Also

Examples

(a <- wilkinson(7))
eig(a)

pracma

Practical Numerical Math Functions

v2.3.3
GPL (>= 3)
Authors
Hans W. Borchers [aut, cre]
Initial release
2021-01-22

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.