ENGINEERING COMPUAION Lectre Stephe Roberts Michelms erm Compttio of mtri eigevles d eigevectors opics covered i this lectre:. Itertive Power method for pproimtig the domit eigevle. he Ryleigh Qotiet method. Defltio techiqes. Awreess of other methods for pproimtig eigevles Egieerig Compttio ECL- Motivtio My problems c be cst s eigevle - eigevector problems. e.g. Vibrtig mechicl systems d resoces. Yo kow tht the eigevles give ω - (resot freqecies) d the eigevectors give the trl modes of vibrtio. Electricl copled - resot circits. Stress d stri clcltios. Geometry trsforms sig mtrices. Stbility of o-lier systems (eg cotrol egieerig) How c we se compters to fid eigevles d eigevectors efficietly? Egieerig Compttio ECL-
Notes before we proceed.. he mericl methods discssed i this lectre come ito their ow whe delig with lrge mtrices. We will se them o smll mtrices (~ ) for demostrtio prposes, eve thogh the eigevles d eigevectors cold be fod directly!. I prctice se the roties fod i pckges (e.g. fctio eig i MALAB). hey re optimised d will void sties.. We ll keep to symmetric mtrices - geerl osymmetric mtrices re mch hrder! Egieerig Compttio ECL- Revisio o eigevles d eigevectors he eigevles or chrcteristic roots of N N mtri A re the N rel or comple mber i sch tht the eqtio A hs o-trivil soltios,,,..., N. If A is symmetric the the eigevles re rel. Rewritig A s ( A I ), the s re the roots of the polyomil determit eqtio ( I ) A. he eigevectors or chrcteristic vectors of A re the set of N-vectors i (some books se q i ) which re the o-trivil soltios of A. i.e. A for ech i. i i i Recll tht, if oe of the i re repeted, ormlised ( ) eigevectors form orthoorml set. i.e., bt for ll i j. Ay vector c be epressed i terms of tht orthoorml set: L N N. i i i j i Egieerig Compttio ECL-
Power Method for eigevles d eigevectors Egieerig Compttio ECL-5 Power Method for eigevles d eigevectors Assme tht for mtri A there is iqe (ie oly oe) lrgest eigevector, sy, where m, j,k N. j j he we c fid by the Power method s described below: Cosider the th itertio A. Let s strt with iitil gess L of the eigevectors of A. N N epressed i terms he Do it gi A A A L A L L A N N N N N N N N After itertios A L N N N Egieerig Compttio ECL-6
Egieerig Compttio ECL-7 After itertios N N N A L Sice we hve defied s the lrgest eigevle, evetlly the term will domite, provided, d >. I this cse the vector will be prllel to the eigevector correspodig to the lrgest eigevle. o esre tht the limit remis fiite d ozero we modify the bove slightly to tke the rtio s A he sig of is positive if the sig of the correspodig terms i re the sme s i, d egtive if they lterte. As before, will be prllel to the lrgest eigevector so we hve fod both d Egieerig Compttio ECL-8 Emple Let s try this o the mtri 7 7 which hs eigevles, 6 d d ormlised eigevectors 6 d,.
Write smll MALAB fctio: fctio [,lmbd]powermt(a,,it) % clcltes the lrgest eigevle d correspodig eigevector of % mtri A by the power method sig s the strtig vector d % crryig ot it iterctios. % ; for :it ew A*; lmbd orm(ew,if)/orm(,if); fpritf(' %d lmbd %g %g %g %g \',, lmbd, '); ew; ed /orm(); %ormlise fpritf(' %d ormlised %g %g %g\',, '); %ed Egieerig Compttio ECL-9 R it with iitil gess [ ] : powermt(a,[ ]',) lmbd lmbd.8 8 lmbd. 5 88 lmbd.67 56 67 5 lmbd.88 76 7 768 6 lmbd.977 89888 9766 55 7 lmbd.955 5.95e6 5.9797e6 6.86e6 8 lmbd.9767 7.87e7 7.666e7 7.96e7 9 lmbd.988 8.588e8 8.5996e8 8.66e8 lmbd.99.95e.96e.96e ormlised.57768.5775.5776 Yo c see tht slowly trs towrds the eigevector d gets very close to fter itertios. Egieerig Compttio ECL- 5
Now try with strtig vector [ -] :» powermt(a,[ -]',) lmbd - lmbd 6 - lmbd 6 8-8 lmbd 6 8-8 5 lmbd 6 68-68 6 lmbd 6 888-888 7 lmbd 6 8-8 8 lmbd 6 9968-9968 9 lmbd 6 8988-8988 lmbd 6 5.885e6-5.885e6 ormlised.777 -.777 Note tht it does ot work i this cse. We hve fod the secod lrgest eigevle isted. he problem is tht is perpediclr to d so i L N N. So we mst lwys hve compoet of prllel to. A soltio is to lwys try cople of o prllel strtig vectors. Egieerig Compttio ECL- Covergece Properties If we cosider oly the two lrgest eigevles, the he proportiol error ths decys with sccessive itertios s. Sice the redctio per itertio is, this is ; lier covergece. Cofirm this by plottig the error i or emple: sig powermt.m Egieerig Compttio ECL- 6
Power method error - Error - - - -5-6 6 8 6 8 Itertio mber Egieerig Compttio ECL- Smmry:. he Power method c be sed to fid the domit eigevle of symmetric mtri.. he method hs lier covergece.. he method reqires iitil gess d it is ot obvios how this c be chose i prctice.. he method does work if the domit eigevle hs mltiplicity r. he estimted eigevector will the be lier combitio of the r eigevectors. Egieerig Compttio ECL- 7
Ryleigh Qotiet method Egieerig Compttio ECL-5 he Ryleigh qotiet method. Modify the power method by clcltig the Ryleigh Qotiet t ech itertio: r ( ) A ( ) ( ) his c be doe with etr lie of code: ryleigh ('*ew)/('*); Rig this with ryleigh gives fr more rpid rte of covergece, d this shows i the error plot from ryleigh Egieerig Compttio ECL-6 8
» ryleigh(a,[ ]',) lmbd ryleigh.9 lmbd.8 ryleigh.76 lmbd. ryleigh.98 lmbd.67 ryleigh.98 5 lmbd.88 ryleigh.996 6 lmbd.977 ryleigh.999 7 lmbd.955 ryleigh.9998 8 lmbd.9767 ryleigh.9999 9 lmbd.988 ryleigh lmbd.99 ryleigh ormlised.57768.5775.5776 Egieerig Compttio ECL-7 Compriso of Ryleigh coefficiet & Power method error - Error - -6 Power Method -8 - - 6 8 6 8 Itertio mber Ryleigh Method Egieerig Compttio ECL-8 9
Egieerig Compttio ECL-9 Covergece Properties Followig the previos error lysis, cosiderig oly the two lrgest eigevles, ( ) ( ) ( ) ( ) ( ) r ) ( ) ( A I this cse the proportiol error ths decys with sccessive itertios s. Sice the redctio per itertio is, this is ; qdrtic or secod order covergece d is mch fster. Egieerig Compttio ECL- Defltio techiqes
Defltio techiqes So fr we hve cosidered how to fid the lrgest eigevle. Sppose we hve doe this, the how do we fid the rest? As first ttempt, ote tht if we c clclte the iverse mtri A -, we c clclte the smllest eigevle, becse if we pre-mltiply the eigevle-eigevector eqtio A by A - d reverse the i i i eqtio, we get A i, d so the eigevles of the iverse of i i mtri re the iverses of the eigevles. Uforttely, fidig A - for lrge mtri c pose problems. A more geerl wy forwrd, is, fter fidig the lrgest eigevle, to mke it ito the smllest by defltio d the go o to fid the ew lrgest oe, sy. Egieerig Compttio ECL- Hotellig s defltio: Cosider ( A ) A ( ). j j j j j If j, the ( A ) ( ) If j, the ( A ) j j j ( ) j j ths, ( A ).. hs the sme eigevectors s A, d the sme eigevles s A ecept tht the lrgest oe hs bee replced by. ths we c se the power method with Ryleigh s coefficiet to fid the et biggest d so o. j Egieerig Compttio ECL-
Egieerig Compttio ECL- Emple For or mtri 7 7 which hs lrgest eigevle, correspodig to the eigevector,. Replce A by 7 7 B d pply Ryleigh: Egieerig Compttio ECL-» ryleigh(b,[ ]',) lmbd rleigh.857 lmbd 6 rleigh 6 lmbd 6 rleigh 6 ormlised -.777.777 we get the secod eigevle immeditely. Bt we might hve troble with the rd (why?). Wrig. I prctice, Hotellig s defltio sffers from rodig errors for lrge mtrices d hs bee replced by sperior, bt similr, methods sch s Wieldt s defltio (look it p i Kreyzig 7th ed., p. 6) (Brde d Fires). Pckges sch s MALAB se more sophisticted d robst methods.
ry MALAB fctio eig to get eigevles d eigevectors:» [eigevectors,eigevles] eig(a) eigevectors.85e- -7.7e- 5.775e- -8.65e-.8e-6 5.775e-.85e- 7.7e- 5.775e- eigevles -.857e-5 6.e.e Note the rodig errors he vles re ~ -5, ot ectly. Egieerig Compttio ECL-5 Illstrtive Emple For it msses re rrged i sqre (see digrm) d re itercoected by sprigs. the horizotl d verticl sprigs hve it stiffess, d the digol sprigs hve two times it stiffess. Egieerig Compttio ECL-6
Egieerig Compttio ECL-7 - Cosider the effect of movig mss distce to the right. he sprig will eert force k o mss, d force o mss. he movemet of sprig is oly d, resolvig horizotlly gives force o mss i the directio. Cosidertio of the horizotl forces o mss de to movemets of ll the msses gives (ssmig sisoidl motio): y y y y m ω & & Egieerig Compttio ECL-8 Writig ot the similr eqtios of motio of ll for msses, d reversig the sigs gives mtri eigevle/eigevector eqtio K ω, where K d co-ordite vector y y y y
R this throgh MALAB: [eigevectors,eigevles] eig(k) eigevectors -..7 -.586 -.87 -.7 -. -.56.56 -.5 -. -.57.86 -.55 -.569.56 -.56. -.7 -.586 -.87.7 -. -.56 -.56 -...68.668.56 -.57 -.56 -.56.9.65 -.66.776 -..8.56 -.56. -..68.668 -.56 -.57 -.56.56 -.9 -.65 -.66.776..8.56.56.5. -.57.86.55 -.569.56.56 eigevles.. -. -.... 6. Egieerig Compttio ECL-9 Why re the eigevles. repeted? wht do. eigevles represet? Wht is the mimm freqecy? C yo idetify some of the modes of vibrtio? Egieerig Compttio ECL- 5
Advced Methods his hs oly bee itrodctory to some of the methods of fidig eigvles d eigevectors. We hve focsed o methods for fidig the domit eigevle/eigevector d briefly metioed defltio methods which c be sed to fid the other eigevles. I prctice yo my come cross other methods. I prticlr,. he Iverse Power Method vrit o the power method tht is fster th the ltter d fids the closest eigevle to the iitil gess.. Mtri redctio methods sch s the QR lgorithm (Fires d Brde p 57) for fidig ll the eigevles which i prctice re better th defltio-bsed methods which sffer from rod-off errors. So why do t we se mtri redctio methods ll the time? Mtri methods re ot efficiet i some cses, sch s for the lysis of very lrge systems (eg comple fiite elemet models) which my hve millios of vribles d yo my oly be iterested i fidig sbset of the eigevles ( s). I this cse sig the Power or Ryleigh method is more efficiet. hese methods do ot form prt of the officil corse syllbs bt yo shold be wre of their eistece d sefless i prctice. Egieerig Compttio ECL- 6