Solving Eigenvalues for a 3x3 matrix
Solving Eigenvalues for a 3x3 matrix
(OP)
Pals
anyone has or would like to type here a faster vb code for finding eigenvalues of a 3x3 matrix
respects
ijr
anyone has or would like to type here a faster vb code for finding eigenvalues of a 3x3 matrix
respects
ijr





RE: Solving Eigenvalues for a 3x3 matrix
RE: Solving Eigenvalues for a 3x3 matrix
Cheers
Greg Locock
New here? Try reading these, they might help FAQ731-376: Eng-Tips.com Forum Policies http://eng-tips.com/market.cfm?
RE: Solving Eigenvalues for a 3x3 matrix
you mean to say there is a built in function. Why didnt you just say that?
thanks anyway
ijr
RE: Solving Eigenvalues for a 3x3 matrix
RE: Solving Eigenvalues for a 3x3 matrix
Cheers
Greg Locock
New here? Try reading these, they might help FAQ731-376: Eng-Tips.com Forum Policies http://eng-tips.com/market.cfm?
RE: Solving Eigenvalues for a 3x3 matrix
Ax = Lambda*x
where A is nxn, x is nx1, Lambda is scalar.
But I might be wrong. If there is can you outline it Greg?
=====================================
Eng-tips forums: The best place on the web for engineering discussions.
RE: Solving Eigenvalues for a 3x3 matrix
htt
OP still hasn't defined faster than what.
Cheers
Greg Locock
New here? Try reading these, they might help FAQ731-376: Eng-Tips.com Forum Policies http://eng-tips.com/market.cfm?
RE: Solving Eigenvalues for a 3x3 matrix
Here's the code:
CODE
Dim a As Double, b As Double, c As Double
Dim d As Double, e As Double, f As Double
Dim g As Double, h As Double, i As Double
Dim ac As Double, bc As Double, cc As Double, dc As Double
MatrixA = MatrixA.Value2
a = MatrixA(1, 1)
b = MatrixA(1, 2)
c = MatrixA(1, 3)
d = MatrixA(2, 1)
e = MatrixA(2, 2)
f = MatrixA(2, 3)
g = MatrixA(3, 1)
h = MatrixA(3, 2)
i = MatrixA(3, 3)
ac = -1
bc = a + e + i
cc = f * h + b * d + c * g - a * e - a * i - e * i
dc = b * f * g + c * d * h - a * f * h - b * d * i - c * e * g + a * e * i
Eigen3x3 = CubicC(ac, bc, cc, dc)
End Function
The function to solve the cubic is included in the attached file.
Doug Jenkins
Interactive Design Services
http://newtonexcelbach.wordpress.com/
RE: Solving Eigenvalues for a 3x3 matrix
Thanks for the great posts. This solves my problem. I can move on from here.
Sorry for keeping you busy with the word "fast". How can you make me so responsible for that pals? Anyway, let me explain. No standard calculator around me or excel does it easily, so anything that can make me enter a matrix and gets me eigenvalues and eigenvectors is "fast". The algorithm above gets me eigenvalues, thats helpful.
There are numerical analysis that explain this, but I just figured out pals here have a better way around that would save me from learning the power method etc.
respects
ijr
RE: Solving Eigenvalues for a 3x3 matrix
Cheers
Greg Locock
New here? Try reading these, they might help FAQ731-376: Eng-Tips.com Forum Policies http://eng-tips.com/market.cfm?
RE: Solving Eigenvalues for a 3x3 matrix
I am now going into Matlab.
Anyway, your posts and IDS's simplified life for now.
respects
IJR