Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Problem while using function 'eig' in Win 7 and Win XP

Subject: Problem while using function 'eig' in Win 7 and Win XP

From: Kamal

Date: 30 Jun, 2011 11:17:10

Message: 1 of 4

Hi,
I am facing some weird problem while using 'eig' command in Win 7 and Win XP. For some datasets, the output of eig i.e. eigen vectors and values in Win 7 is coming different if I use the same dataset in win XP. As a result of that, I am not able to migrate my application from XP to win7. Does eig command behaves differently in both these OS??

Regards
Kamal

Subject: Problem while using function 'eig' in Win 7 and Win XP

From: Nasser M. Abbasi

Date: 30 Jun, 2011 11:46:18

Message: 2 of 4

On 6/30/2011 4:17 AM, Kamal wrote:
> Hi,
> I am facing some weird problem while using 'eig' command in Win 7 and Win XP. For some datasets,
> the output of eig i.e. eigen vectors and values in Win 7 is coming different if I
> use the same dataset in win XP. As a result of that, I am not able to migrate
> my application from XP to win7. Does eig command behaves differently in both these OS??
>
> Regards
> Kamal

Is this same Matlab on same OS's?

if the changes is just a sign change in the components of the
eignevector and sign difference in the eigenvalues, then that should
be ok. Can you show the result of a small matrix, say 5x5 on both
systems so one can see what is the difference?


--Nasser

Subject: Problem while using function 'eig' in Win 7 and Win XP

From: Kamal

Date: 30 Jun, 2011 11:58:09

Message: 3 of 4

"Nasser M. Abbasi" <nma@12000.org> wrote in message <iuhnme$g4d$1@speranza.aioe.org>...
> On 6/30/2011 4:17 AM, Kamal wrote:
> > Hi,
> > I am facing some weird problem while using 'eig' command in Win 7 and Win XP. For some datasets,
> > the output of eig i.e. eigen vectors and values in Win 7 is coming different if I
> > use the same dataset in win XP. As a result of that, I am not able to migrate
> > my application from XP to win7. Does eig command behaves differently in both these OS??
> >
> > Regards
> > Kamal
>
> Is this same Matlab on same OS's?
>
> if the changes is just a sign change in the components of the
> eignevector and sign difference in the eigenvalues, then that should
> be ok. Can you show the result of a small matrix, say 5x5 on both
> systems so one can see what is the difference?
>
>
> --Nasser
>
Hi Nasser,

This problem is not occuring for all datasets. I took a 1542 x 1542 matrix and then run this function. Yes there was a sign change. But the problem is I am using the absolute values of these eigen values for my calculation. Because of which my final output is not coming correct.
Regards

Subject: Problem while using function 'eig' in Win 7 and Win XP

From: Roger Stafford

Date: 30 Jun, 2011 16:02:09

Message: 4 of 4

"Kamal " <kamal_pandey01@infosys.com> wrote in message <iuhlvm$nlq$1@newscl01ah.mathworks.com>...
> Hi,
> I am facing some weird problem while using 'eig' command in Win 7 and Win XP. For some datasets, the output of eig i.e. eigen vectors and values in Win 7 is coming different if I use the same dataset in win XP. As a result of that, I am not able to migrate my application from XP to win7. Does eig command behaves differently in both these OS??
>
> Regards
> Kamal
- - - - - - - - - -
  The eigenvectors of a given matrix are free to undergo a sign change, or in the case of complex vectors, by a multiple of a complex root of unity. In the case of equal eigenvalues, the associated eigenvectors can be any set of orthonormal vectors spanning the corresponding vector subspace.

  However, there is nothing arbitrary about the eigenvalues. They are precisely determined by the characteristic equation - that is, they are the roots of the characteristic polynomial and that is invariable.

  All these statements of course must allow for differences in rounding errors. I do not know to what extent rounding errors on a large 1542 x 1542 matrix would be subject to differences between systems. They might be appreciable for such a large matrix.

Roger Stafford

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us