Displaying 20 results from an estimated 10000 matches similar to: "Spectral Decomposition"
2003 Jul 03
2
SVD and spectral decompositions of a hermitian matrix
Hi:
I create a hermitian matrix and then perform its singular value
decomposition. But when I put it back, I don't get the original
hermitian matrix. I am having the same problem with spectral value
decomposition as well.
I am using R 1.7.0 on Windows. Here is my code:
X <- matrix(rnorm(16)+1i*rnorm(16),4)
X <- X + t(X)
X[upper.tri(X)] <- Conj(X[upper.tri(X)])
Y <-
2008 Jun 18
2
highest eigenvalues of a matrix
DeaR list,
I happily use eigen() to compute the eigenvalues and eigenvectors of
a fairly large matrix (200x200, say), but it seems over-killed as its
rank is limited to typically 2 or 3. I sort of remember being taught
that numerical techniques can find iteratively decreasing eigenvalues
and corresponding orthogonal eigenvectors, which would provide a nice
alternative (once I have the
2004 Oct 19
3
matrix of eigenvalues
I thought that the function
eigen(A)
will return a matrix with eigenvectors that are independent of each
other (thus forming a base and the matrix being invertible). This
seems not to be the case in the following example
A=matrix(c(1,2,0,1),nrow=2,byrow=T)
eigen(A) ->ev
solve(ev$vectors)
note that I try to get the upper triangular form with eigenvalues on
the diagonal and (possibly) 1 just
2003 Apr 03
2
Matrix eigenvectors in R and MatLab
Dear R-listers
Is there anyone who knows why I get different eigenvectors when I run
MatLab and R? I run both programs in Windows Me. Can I make R to produce
the same vectors as MatLab?
#R Matrix
PA9900<-c(11/24 ,10/53 ,0/1 ,0/1 ,29/43 ,1/24 ,27/53 ,0/1 ,0/1 ,13/43
,14/24 ,178/53 ,146/244 ,17/23 ,15/43 ,2/24 ,4/53 ,0/1 ,2/23 ,2/43 ,4/24
,58/53 ,26/244 ,0/1 ,5/43)
#R-syntax
2010 Jun 25
2
Forcing scalar multiplication.
I am trying to check the results from an Eigen decomposition and I need to force a scalar multiplication. The fundamental equation is: Ax = lx. Where 'l' is the eigen value and x is the eigen vector corresponding to the eigenvalue. 'R' returns the eigenvalues as a vector (e <- eigen(A); e$values). So in order to 'check' the result I would multiply the eigenvalues
2006 Mar 03
1
NA in eigen()
Hi,
I am using eigen to get an eigen decomposition of a square, symmetric
matrix. For some reason, I am getting a column in my eigen vectors (the
52nd column out of 601) that is a column of all NAs. I am using the option,
symmetric=T for eigen. I just discovered that I do not get this behavior
when I use the option EISPACK=T. With EISPACK=T, the 52nd eigenvector is
(up to rounding error) a
2002 Mar 11
1
Spectral decomposition
Hello all,
I have the square symetric matrix A:
2 1 1
1 2 1
1 1 2
My first question is what is the easiest way to enter this matriz in R?
Second, matrix A has an eigenvalue with multiplicity 2, in this case, how
could I find the two related ortogonal eigenvectors given below by R,
without the help of R, I mean, I want to know how R calculate this
eigenvectors related to the same eigenvalue.
2013 Jan 31
1
Using eigen() for extracting only few major eigenpairs
Hi everyone,
I am using eigen() to extract the 2 major eigenpairs from a large real
square symmetric matrix. The procedure is already rather efficient, but
becomes somehow slow for real time needs with moderately large matrices
(few thousand lines).
The R implementation statically extracts all eigenvalues (and optionally
associated eigenvectors). I heard about optimizations of the eigen
2013 Jun 18
1
eigen(symmetric=TRUE) for complex matrices
R-3.0.1 rev 62743, binary downloaded from CRAN just now; macosx 10.8.3
Hello,
eigen(symmetric=TRUE) behaves strangely when given complex matrices.
The following two lines define 'A', a 100x100 (real) symmetric matrix
which theoretical considerations [Bochner's theorem] show to be positive
definite:
jj <- matrix(0,100,100)
A <- exp(-0.1*(row(jj)-col(jj))^2)
A's being
2005 Apr 25
1
The eigen function
I'm using R version 2.0.1 on a Windows 2000 operating system. Here is some
actual code I executed:
> test
[,1] [,2]
[1,] 1000 500
[2,] 500 250
> eigen(test, symmetric=T)$values
[1] 1.250000e+03 -3.153033e-15
> eigen(test, symmetric=T)$values[2] >= 0
[1] FALSE
> eigen(test, symmetric=T, only.values=T)$values
[1] 1250 0
> eigen(test, symmetric=T,
2003 Jun 08
2
LDA: normalization of eigenvectors (see SPSS)
Hi dear R-users
I try to reproduce the steps included in a LDA. Concerning the eigenvectors there is
a difference to SPSS. In my textbook (Bortz)
it says, that the matrix with the eigenvectors
V
usually are not normalized to the length of 1, but in the way that the
following holds (SPSS does the same thing):
t(Vstar)%*%Derror%*%Vstar = I
where Vstar are the normalized eigenvectors. Derror
2010 Mar 19
1
Howto get unnormalized eigenvectors?
Hi,
I try to calculate the angle between two first eigenvectors of different covariance matrices of biological phenotypic traits for different populations. My issue here is, that all possibilities to do so seem to normalize the eigenvectors to length 1. Although the helpfile of eigen() states, that using eigen(, symmetric = FALSE, EISPACK =TRUE) skips normalization this is (I guess) not applicable
2013 May 19
1
Generate positive definite matrix with constraints
Hi, I have a question for my simulation problem:
I would like to generate a positive (or semi def positive) covariance
matrix, non singular, in wich the spectral decomposition returns me the same
values for all dimensions but differs only in eigenvectors.
Ex.
sigma
[,1] [,2]
[1,] 5.05 4.95
[2,] 4.95 5.05
> eigen(sigma)
$values
[1] 10.0 0.1
$vectors
[,1]
2011 Nov 14
2
How to compute eigenvectors and eigenvalues?
Hello.
Consider the following matrix:
mp <- matrix(c(0,1/4,1/4,3/4,0,1/4,1/4,3/4,1/2),3,3,byrow=T)
> mp
[,1] [,2] [,3]
[1,] 0.00 0.25 0.25
[2,] 0.75 0.00 0.25
[3,] 0.25 0.75 0.50
The eigenvectors of the previous matrix are 1, 0.25 and 0.25 and it is not a diagonalizable matrix.
When you try to find the eigenvalues and eigenvectors with R, R responses:
> eigen(mp)
$values
[1]
2004 Nov 05
1
fast partial spectral decompositions.
hello,
i want to compute the top k eigenvalues+eigenvectors of a (large)
real symmetric matrix. since it doesn't look like any top-level R
function does this, i'll call LAPACK from a C shlib and then
use .Call. the only LAPACK function i see to do this in
R_ext/Lapack.h is dsyevx. however, i know that in LAPACK dsyevr
can also return a partial eigendecomposition. why is dsyevr not
2004 Nov 05
1
fast partial spectral decompositions.
hello,
i want to compute the top k eigenvalues+eigenvectors of a (large)
real symmetric matrix. since it doesn't look like any top-level R
function does this, i'll call LAPACK from a C shlib and then
use .Call. the only LAPACK function i see to do this in
R_ext/Lapack.h is dsyevx. however, i know that in LAPACK dsyevr
can also return a partial eigendecomposition. why is dsyevr not
2012 Apr 19
2
Is the eigen-value decomposition in R generally stable/reliable for large matrix?
Say a matrix of size of thousands?
I am looking for an eigen-value decomposition algo in R to give good
eigenvalues...
Is that a hopeful thing?
Thank you!
[[alternative HTML version deleted]]
2003 Feb 06
6
Confused by SVD and Eigenvector Decomposition in PCA
Hey, All
In principal component analysis (PCA), we want to know how many percentage
the first principal component explain the total variances among the data.
Assume the data matrix X is zero-meaned, and
I used the following procedures:
C = covriance(X) %% calculate the covariance matrix;
[EVector,EValues]=eig(C) %%
L = diag(EValues) %%L is a column vector with eigenvalues as the elements
percent
2006 Aug 10
3
Geometrical Interpretation of Eigen value and Eigen vector
Dear all,
It is not a R related problem rather than statistical/mathematical. However
I am posting this query hoping that anyone can help me on this matter. My
problem is to get the Geometrical Interpretation of Eigen value and Eigen
vector of any square matrix. Can anyone give me a light on it?
Thanks and regards,
Arun
[[alternative HTML version deleted]]
2010 Apr 08
1
square root of inverse
Dear users,
How to get a symmetric square root of a positive definite matrix? I have
tried using spectral decomposition, but some eigen values come out to be
complex. Is there any function in R that can give the symmetric square root
of a pd matrix?
--
Arindam Fadikar
M.Stat
Indian Statistical Institute.
New Delhi, India
[[alternative HTML version deleted]]