0% found this document useful (0 votes)
48 views4 pages

- z − fl (z) z - ≤ β /β β β

The document provides information and exercises related to numerical analysis. It begins with exercises on solving systems of differential equations and computing eigenvalues. It then provides exercises on matrix properties and algorithms. Specifically, it asks to: 1) Derive an algorithm to compute the LU decomposition of a lower Hessenberg matrix without pivoting, returning the L and U matrices. 2) Modify the algorithm to provide additional output regarding the nonzero elements below the subdiagonal at each step. 3) Provide MATLAB code to more efficiently solve a system of linear equations where the matrix has a Vandermonde structure based on a vector input.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
48 views4 pages

- z − fl (z) z - ≤ β /β β β

The document provides information and exercises related to numerical analysis. It begins with exercises on solving systems of differential equations and computing eigenvalues. It then provides exercises on matrix properties and algorithms. Specifically, it asks to: 1) Derive an algorithm to compute the LU decomposition of a lower Hessenberg matrix without pivoting, returning the L and U matrices. 2) Modify the algorithm to provide additional output regarding the nonzero elements below the subdiagonal at each step. 3) Provide MATLAB code to more efficiently solve a system of linear equations where the matrix has a Vandermonde structure based on a vector input.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

EPISTHMONIKOS UPOLOGISMOS I Septmbrioc 2003 Ta paraktw jmata kai oi apantseic touc ja enai qrsima gia souc tan parntec

sthn extash Septembrou


I. Na apantsete sntoma kai periektik sta paraktw erwtmata (stic erwtseic Swst/Ljoc prpei na dikaiologsete tic apantseic gia na bajmologhjete). 1a) 'Estw to ssthma arijmn kinhtc upodiastolc me bsh kai t duadik yhfa sthn our. Na orsete th monda stroggleushc kai na thn upologsete wc sunrthsh twn , t. Eplush. (Kef. 3.2): To mgisto sqetik sflma stroggleushc gia mh mhdenikoc arijmoc. To mgisto sqetik sflma gia mh mhdenik z G enai | z (z) | z = et 1 e / 2 1t = u. 2

1b) 'Estw to ssthma arijmn kinhtc upodiastolc IEEE me bsh = 2 kai t duadik yhfa sthn our, na ap ta opoa enai krummno. Na orsete to yilon thc mhqanc kai na to upologsete wc sunrthsh twn kai t. Eplush. (Kef. 3.2): To yilon thc mhqanc enai h apstash thc mondac ap ton amswc epmeno megaltero a.k.u., stw 1+ Gia to sugkekrimno ssthma autc enai o 1+ = 1 + 21t , epomnwc M = 21t . 2a) Swst Ljoc: An duo mhtra enai nw Hessenberg tte to ginmen touc ja enai epshc nw Hessenberg. Eplush. LAJOS pwc mporete na dexete me tuqaa genik mhtra nw Hessenberg megjouc 3. 2b) Swst Ljoc: An duo mhtra enai Toeplitz tte to jroism touc ja enai epshc Toeplitz. Eplush. SWSTO: Sta mhtra Toeplitz ta stoiqea kje diagwnou (kriac kai mh) enai sa. Epomnwc an ta mhtra A, B enai Toeplitz kai C = A + B tte i,j = i,j + i,j all i,j = ji kai i,j = ji gia k ]n1 . Epomnwc i,j = ji + ji kai ta stoiqea stoiqea [ 1n , 2n , ..., 0 , 1 , ..., n1 ] kai omowc [ k=1n tou C pou brskontai stic diagwnouc enai dia kajc i+s,j+s = ji + ji . 3a) 'Estw ti to upologistik sac ssthma ektele thn ananwsh prthc txhc me meglh taqthta kai ti mporete na dsete thn entol gia thn ananwsh msw miac sunrthshc MATLAB , stw r1upd, ste ektelntac B = r1upd(A, x, y) na epistrfetai B = A + xy . Na gryete algrijmo pou dojntwn A Rmn , B Rnk , C Rmk na upologzei to C C + AB pou na axiopoie aut th sunrthsh gia thn taqterh ektlesh tou pollaplasiasmo. Eplush. Arke na ekmetalleutome th gnwst sqsh (bl. biblo EU kai shmeiseic paradsewn)
n

C=C+
i=1

A(1 : m, i)B(i, 1 : n).

O algrijmoc ja enai for i = 1 : n, C = r1upd (C,A(1:m,i) B(i,1:k)) end 3b) Swst Ljoc: 'Estw oi idiotimc enc summetriko mhtrou, |1 | |2 | |n |, taxinomhmnec wc proc to mtro touc. Tte o dekthc katstashc tou mhtrou, wc proc thn eukledeia nrma, enai soc me 2 (A) = |1 |/|n |. Eplush. SWSTO. Epanalambnoume th jewra (den qreizetai plrhc anptuxh gia th lsh). O dekthc katstashc enai 2 (A) = A 2 A1 . Epeid to mhtro enai summetrik, diagwniopoietai me orjognio metasqhmatism omoithtac Q ste = Q AQ. Epshc, 1 = Q A1 Q. Epshc A 2 = QQ 2 = 2 = |1 |. Omowc, A1 2 = Q1 Q 2 = 1 2 = 1/|n | kai to apotlesma petai. 4)'Estw h prxh B = B + (xy )p , pou B Rnn , x, y Rn kai p jetikc arijmc. Sumbolzoume me min = min /, pou enai o arijmc prxewn a.k.u. kai min o elqistoc arijmc metaforn metax thc kriac mnmhc kai thc krufc mnmhc kai twn kataqwrhtn. Upojtontac ti h ywsh enc bajmwto se

dnamh enai isodnamh me mia prxh kinhtc upodiastolc na upologsete to min wc sunrthsh mnon tou n. Eplush. Epeid zhtome to min qoume arket kruf mnmh kai kataqwrhtc ste a) na fortsoume arqik la ta dedomna ap thn kria mnmh, b) na ektelsoume tic prxeic apojhkeontac ta endimesa apotelsmata stouc kataqwrhtc kai g) na eggryoume ta apotelsmata sthn kria mnmh (bl. Kef. 2 biblou). Epomnwc, min = 2n2 + 2n + 1 (h monda antoistoiqe sto p. Se kje perptwsh, roi thc txhc O(1) den poluendiafroun). Gia na upologsoume to , ja axiopoisoume to gegonc ti to (xy )p mpore na
p1

grafte wc x (y x) (y x) y epomnwc ektelome tic paraktw prxeic: = y x dhl. 2n 1 prxeic, to ( p1 x), dhl. 1 + n prxeic, kai to B = B + ( p1 x)y , dhl. 2n2 prxeic. Sunolik dhlad = 2n2 + 3n prxeic (upologzontac thn ywsh se dnamh wc mia prxh). Prosoq ti prta pollaplasizoume to p1 me to x kai met upologzoume thn ananwsh prthc txhc, alloic ja eqame n2 epiplon pollaplasiasmoc. Sqetik me tic metaforc, min = (2n2 + 3n)/(2n2 + 2n + 1). Prosxte ti qreisthkan O(n2 ) jseic krufc mnmhc. Axzei na shmeiwje ti an epiqeirsete na ektelsete thn prxh me aplok trpo, p.q. kstouc O(n3 ), den ja mporsete na apofgete thn exrthsh ap to p. H lsh tou (4) sthn ekdoq B = A + (Bxy )s gnetai anloga. Prosxte ti epeid h prxh enai B = A + (Bxy )s , qreizontai n2 perissterec metaforc (gia to A). Epshc, ston upologism, h dispash enai Bx(y Bx) (y Bx)y en gia oikonoma prpei na upologsoume prta to Bx kai na to epanaqrhsimopoisoume kai sta eswterik ginmena ant na upologsoume to y B .

II. (18 b.) O paraktw kdikac MATLAB mpore na ulopoihje tsi ste na pargei to apotlesma (Y Rnm ) pol pio grgora. Upojtoume ti 1 < m < n kai ti h myvec (n) pargei dinusma (stlh) ap n nisouc arijmoc. Na exhgsete t tropopoiseic prpei na gnoun kai na gryete ton taqtero kdika, qrhsimopointac, an qreizetai, kai llec gnwstc entolc kai sunartseic thc MATLAB . function [Y] = vansolve(B); [n,m]= size(B); x=myvec(n); V=[ ]; for i=1:n for j=1:n, V(i,j) = x(i)^(j-1); end end for k=1:m, Y(:,k) = V\B(:,k); end
Eplush. To prto tmma tou kdika kataskeuzei anstrofo mhtro Vandermonde megjouc n me pargon dinusma to x. To teleutao tmma tou kdika epilei m sustmata me to dio summetrik kai jetik orismno mhtro (V V ) me dexi mlh tic stlec tou B . Gia to prto mroc tou kdika, mporome na epitaqnoume a) profortnontac to mhtro V , b) qrhsimopointac anadromik upologism ant gia ywsh se dnamh, g) qrhsimopointac pio ntona diansmata sth diatpwsh tou progrmmatoc. Gia to detero mroc tou kdika, axiopoiome a) to gegonc ti prkeitai gia to dio mhtro, ra mporome na knoume thn paragontopohsh mno mia for. To mhtro enai antistryimo (all me pol kak dekth katstashc ektc ap orismnec periptseic stoiqewn) giat ta stoiqea tou x enai nisa metax touc. Shmeinoume ti uprqoun kai llec pio sunoptikc ulopoiseic, p.q.

x*ones(1,n).^(ones(n,1)*[0:n-1]) function [Y] = vansolve(B); [n,m]= size(B); V=ones(n); x=myvec(n); for j=2:n V(:,j) = V(:,j-1).*x; end [L,U]=lu(V); Y = U\(L\B);

III. (26 b.) Na gryete algrijmo pou dojntoc enc mhtrou ktw Hessenberg, A Rnn , na ektele paragontopohsh LU qwrc odghsh (epomnwc, o algrijmoc mpore kai na apotqei an ta dedomna den enai
2

katllhla) axiopointac th dom tou A kai epistrfontac touc pargontec L, U stic jseic tou A. b) Na tropopoisete ton algrijmo me bsh tic exc epiplon prodiagrafc: O algrijmoc ja prpei na upologzei (k) ,..., se kje na ap ta k = 1, ..., n 1 bmata to suntelest max{00 k1 } , pou k := maxi,j |ij | enai ta stoiqea me mgisth apluth tim stic jseic (k + 1 : n, k + 1 : n) tou mhtreou Lk L1 A pou qei prokyei met ap k bmata thc LU . An o suntelestc gnei megalteroc ap kpoio prokajorismno mgejoc, stw M , o algrijmoc prpei na stamat kai na epistrfei sto qrsth mnuma ti prpei na qrhsimopoihje odghsh. Eidllwc, o algrijmoc prpei na epistrfei touc pargontec LU stic jseic tou A. Mporete na qrhsimopoisete tic sunartseic MATLAB error(MSG) pou tupnei sthn ojnh to mnuma MSG kai stamat thn ektlesh thc sunrthshc kai max(X) pou epistrfei to mgisto stoiqeo enc diansmatoc X to dinusma me stoiqea to mgisto kje stlhc tou mhtrou X. Eplush. a) O algrijmoc paragontopohshc - qwrc odghsh - enai o akloujoc (prokptei mesa ap thn klasik LU qwrc odghsh efson lhfje upyh h mhdenik dom tou mhtrou): for j = 1 : n 1 A(j + 1, j) = A(j + 1, j)/A(j, j) A(j + 1, j + 1 : n) = A(j + 1, j + 1 : n) A(j + 1, j)A(j, j + 1 : n) end b) Tropopoiome wc exc: r = 1; for j = 1 : n 1 if r < M A(j + 1, j) = A(j + 1, j)/A(j, j) A(j + 1, j + 1 : n) = A(j + 1, j + 1 : n) A(j + 1, j)A(j, j + 1 : n) r = max (max(max(abs(A(j + 1 : n, j + 1 : n))))/s, r) else error(Must use pivoting) end end

IV. (20 b.) 'Estw oi jetiko arijmo kinhtc upodiastolc 1 ..., n > 0 kai o upologismc y = 1; forj = 1 : n y = y ( + j ) end a) Na dexete ti o algrijmoc upologismo enai psw stajerc. b) Na dexete ti o dekthc katstashc tou n 1 y(1 , ..., n , ) wc proc th nrma megstou enai fragmnoc ap P = j=1 +j . Eplush. a) Ekola fanetai ti
n n n1

(y) =

( + j )
j=1 j=1

(1 + j )
j=1

(1 + j )

pou j enai to sflma stroggleushc pou prokptei ap thn prsjesh + j kai j enai to sflma stroggleushc pou prokptei kat ton pollaplasiasm y = (y) ( + j ). Mporome na jewrsoume ti den prokptei sflma kat ton prto pollaplasiasm me to 1. Kai stic duo periptseic, ta sflmata enai fragmna ap th monda stroggleushc u. Ap th jewra (lmma) qoume ti
n n1

(1 + j )
j=1 j=1

(1 + j ) = 1 + 2n1 , |2n1 | 2n1 =

(2n 1)u 1 (2n 1)u

Epomnwc,
n

(y) =

(1 + 2n1 )

( + j )
j=1

= =

( + 1 )(1 + 2n1 )
j=2 n

( + j )

( + 1 )
j=2

( + j ),

pou = (1+2n1 ) kai 1 = 1 (1+2n1 ). Epomnwc, to upologismno apotlesma mpore na jewrhje wc to akribc ginmeno all me stoiqea 1 , 2 , , ..., n , . O algrijmoc enai psw eustajc giat |1 1 |/|1 | 2n1 kai parmoia gia to . b) Smfwna me th jewra (Kef. 3.5) o dekthc katstashc enai

(y) =
pou J enai h Iakwbian J R1(n+1)

[1 , ..., n , ] |y|

J =[

y y y ]. ,, , 1 n

Ja qrhsimopoisoume th nrma megstou. All

y = j
en

( + i ) := pj
i=j

y =

pj .
j=1 n

Epomnwc, h nrma megstou J = max{|p1 |, ..., |pn |, | j=1 pj |} kai kajc la ta stoiqea enai jetik, n J = j=1 pj . Epshc h nrma megstou [1 , ..., n , ] = ap aut pou gnwrzoume gia ta stoiqea. Epomnwc o dekthc katstashc enai

(y)

= =

n j=1 ( n j=1

+ j )

pj
j=1

1 + j

You might also like