f08fa {NAGFWrappers}R Documentation

f08fa: Computes all eigenvalues and, optionally, eigenvectors of a real symmetric matrix

Description

f08fa computes all the eigenvalues and, optionally, all the eigenvectors of a real n by n symmetric matrix A.

Usage

f08fa(jobz, uplo, a,
      n = nrow(a))

Arguments

jobz

string

If jobz='N', compute eigenvalues only.

uplo

string

If uplo='U', the upper triangular part of A is stored.

a

double array

The n by n matrix A.

See the Fortran Library documentation for a description of the storage layout for this array.

n

integer: default = nrow(a)

n

, the order of the matrix A.

Details

R interface to the NAG Fortran routine F08FAF.

Value

A

double array

If jobz='V', then if IN=0, a contains the orthonormal eigenvectors of the matrix A.

W

double array

If IN=0, the eigenvalues in ascending order.

INFO

integer

info = 0

unless the function detects an error (see the Errors section in Fortran library documentation).

Author(s)

NAG

References

http://www.nag.co.uk/numeric/FL/nagdoc_fl23/pdf/F08/f08faf.pdf

Examples


jobz<-'Vectors'

uplo<-'Upper'

a<-matrix(c(1,2,3,4,0,2,3,4,0,0,3,4,0,0,0,4),nrow=4,ncol=4,byrow=TRUE)



f08fa(jobz,uplo,a)


[Package NAGFWrappers version 24.0 Index]