Microsoft word - 6_operaciebi_matricebze.doc
sakomunikacio sistemas da mikroprocesorul makontrolebel instruments SeuZlia miiRos maRali garCevis gamonasaxi. erT-erTi maTgani iupiteris “mTvare” - hanimedi - naCvenebia fotoze, romelic gadaiRo kosmosurma Tanamgzavrma ‘Galileo’. fotogamonasaxis kompiuteruli interpretacia sakmaod rTulia. kargi algoriTmis dawera moiTxovs safuZvlian codnas gamonasaxis Sesaxeb. gamonasaxze muSaobisas zogjer unda SegveZlos gavyveT miZravi obieqtis kvals erTi gamonasaxidan meoreze, imisaTvis rom davadginoT am obieqtis moZraobis siCqare da mimarTuleba. aseTi tipis amocanebis algoriTmi rTuli Sesadgenia.
sainJinro monacemebis warmosadgenad matrica Zalze moxerxebuli formaa. wina TavSi ganvixileT maTematikuri gamoTvlebi da funqciebi, romlebic gamoiyeneba matricebis Sesabamis elementebs Soris maTematikuri operaciebis Sesasruleblad. am TavSi ganvixilavT maTematikur operaciebs uSualod matricebs Soris. pirvel rigSi ganvixilavT maTematikur operaciebs romelTa saSualebiT matricidan an matricebidan axal matricas vRebulobT. Semdeg gagacnobT funqciebs, romlebic matricebis manipulirebis saSualebas iZleva da igi erTi formidan meoreSi gadahyavs.
sainJinro amocanebSi matricebi gamoiyeneba rogorc moxerxebuli saSualeba monacemebis warmosadgenad. am ganyofilebaSi ganvixilavT gamoTvlebs, romelSic monawileobs matricis saxiT warmodgenili monacemebi. am TavSi ZiriTadad SevexebiT matricebs, romlebic Seicaven orze met svets da striqons. gavixsenoT, rom skalaruli gamravleba da metricebis Sekreba – gamokleba warmoebs Sesabamis elementebs Soris operaciebis SesrulebiT. am TavSi matricebis gamravlebas ganvixilavT, xolo gayofas TavSi, sadac saubari iqneba wrfiv gantolebaTa sistemis amoxsnaze.
transponirebuli matrica es aris axali matrica, romlis svetebic sawyisi matricis striqonebia. transponirebuls aRniSnaven niSniT “ ” magaliTad ganvixiloT matrica A da misi transponirebuli A:
Tu davakvirdebiT vnaxavT,rom elementi (3,1) gardaisaxa elementSi (1,3) anu A(3,1) = A(1,3), xolo A(4,2) = A(2,4). faqtiurad indeqsebi icvleba ise, rom A(i,j) = A(j,i). unda gvaxsovdes, rom Tu matrica ar aris kvadratuli (kvadratuli matricis svetebis da striqonebis raodenoba erTnairia), maSin matrica da misi transponirebuli sxvadasxva zomisaa. transponirebis operacias xSirad viyenebT, roca gvsurs striqoni veqtoridan miviRoT sveti veqtori. Tu A matrica Seicavs kompleqsur ricxvebs, maSin A mogvcems transponirebul matricas, magarm misi elementebi iqneba sawyisi matricis elementebis kompleqsuri SeuRlebuli, amitom, Tu gvsurs transponirebuli matricis miReba ise, rom misi elementebis mniSvneloba ar Seicvalos, unda visargebloT brZanebiT A. an conj(A). magaliTad:
>> Z=[1+2i, 2+4i, 2+4i; 2i, 6i, 7i]; >> Z' ans = 1.0000 - 2.0000i 0 - 2.0000i 2.0000 - 4.0000i 0 - 6.0000i 2.0000 - 4.0000i 0 - 7.0000i >> Z.'
1.0000 + 2.0000i 0 + 2.0000i 2.0000 + 4.0000i 0 + 6.0000i 2.0000 + 4.0000i 0 + 7.0000i
ori erTnairi zomis veqtoris skalaruli namravli aris skalari romelic tolia am veqtorebis Sesabamis elementTa urTierTnamravlTa jamisa. magaliTad, Tu A da B N elementiani veqtorebia, maSin maTi skalaruli namravli ase gamoiTvleba:
dot _
product
A
B
a b B
sailustraciod davuSvaT, A da B Semdegi veqtorebia:
skalarul namravls sxvanairad Sida namravls (
inner product ) uwodeben
MATLAB saSualebiT skalaruli namravli SeiZleba gamovTvaloT Semdegnairad:
gavixsenoT, rom A. * B Secavs am veqtorebis Sesabamis wevrTa namravls. Tu orive striqoni veqtori, an orive sveti veqtoria, A.*B agreTve veqtoria, aviRebT am veqtoris elementTa jams da miviRebT skalarul namravls. Tu A striqoni veqtoria, xolo B sveti veqtori, maSin skalaruli namravli ori gziT SegviZlia gamovTvaloT:
MATLAB–s agreTve gaaCnia funqcia veqtorebis skalaruli namravlis
gamosaTvlelad –
dot. dot(A,B) igive Sedegs mogvcems rasac - sum(A.*B).
Tu A matricas gavamravlebT B miviRebT C matricas, romlis elementebic A matricis striqonebis B matricis svetebze skalarul namravls warmoadgens:
radganac skalaruli namravli moiTxovs, rom veqtorebi elementTa erTnaior raodenobas Seicavdnen, amiTom roca matricebs vamravlebT erTmaneTze, pirveli matrica (A) TiToeul striqonSi unda Seicavdes imden wevrs, ramdensac Seicavs meore matricis (B) TiToeuli sveti. amgvarad, Tu A da B Secaven 5 striqonsa da 5 svets, maSin maTi gadamravlebis Sedegad miRebuli matrica C unda Seicavdes 5 striqonsa da 5 svets. aseTi (kvadratuli matricebisaTvis SegviZlia gamovTvaloT rogorc A*B, aseve B*A, Tumca sazogadod isini tolo ar iqneba. Tu A Seicavs 2 striqonsa da 3 svets, da B Seicavs 3 striqonsa da 3 svets, maTi namravli C = AB Seicavs 2 striqonsa da 3 svets:
pirveli elementi namravlSi C = AB iqneba:
a b
a b
a b
a b 21 5( )1 15 2
aseve gamoviTvliT sxva elementebsac da miviRebT matricas:
Cven ver gamoviTvliT B*A, B yovel striqonSi ar Seicavs imdensave elements, ramdensac AYyovel svetSi. arsebobs martivi wesi imis dasadgenad, SesaZlebelia Tu ara mocemuli matricebis gamravleba. davweroT ori matrices zomebi erTmaneTis gverdiT. Tu Sida ori ricxvi tolia, aseTi matricebis gamravleba SesaZlebelia da namravlis zoma ganisazRvreba gare ricxvebis mixedviT. magaliTad ganvixiloT mocemuli A da B matricebis SemTxveva. A mtricis zomaa 23, B – 33:
Sida ricxvebi tolia da =3, ese igi matricebis namravli arsebobs da misi zomaa 23. B*A SemTxvevaSi:
Sida ricxvebi ar aris toli da ar asebobs aseTi namravli. MATLAB-Si matricebis gamravleba aRiniSneba niSniT “ * ”. imisaTvis rom MATLAB -Si SevqmnaT A da B matricebi da Semdeg A gavamravloT B, gvWirdeba brZanebebi:
A = [2, 5, 1; 0, 3, -1]; B = [1, 0, 2; -1, 4, -2; 5, 2, 1];
Tu MATLAB mivcemT brZanebas B*A, miviRebT informacias, rom aseTi namravli ar arsebobs. umartivesi gza ori striqoni veqtoris skalaruli namravlis sapovnelad Semdegia:
Tu davuSvebT, rom maTi sigrZea N da visargeblebT zemoT aRwerili wesiT, romelic gvaZlevs namravli matricis zomas, miviRebT:
F*G namravli matricis zomaa 11, anu ori veqtoris skalaruli namravli skalaruli sididea. Tu F da G sveti veqtorebia, maT skalarul namravls ase gamoviTvliT:
SesaZlebelia gamoviTvaloT ori veqtoris gare namravli (outer product). davuSvaT F da G Semdegi veqtorebia;
namravli arsebobs da Sedegad miiReba matrica, romlis zomaa [3 3]. gare namravli iseve ganisazRvreba, rogorc Cveulebriv matricebis gamravleba. imisaTvis, rom matricebi sworad gavamravloT, kargad unda davukvirdeT maT zomas, da amis Semdeg SevarCioT transponirebis operaciebi da TanamamravlTa saTanado mimdevroba. rogorc vnaxeT, roca F da G veqtorebi striqoni veqtorebia, maSin FG skalaria, FG [3 3] zomis matrica, xolo F*G saerTod ar arsebibs. davuSvaT I kvadratuli erTeulovani matricaa. (gavixsenoT me-3 Tavidan rom erTeulovani iseTi matricaa, romlis mTavari diagonalis elementebi erTis tolia, yvela sxva elementi ki 0-is). Tu A igive zomis kvadratuli matricaa, maSin AI = IA=A. es gamoTvlebi gviCvenebs, rom matricis gamravlebiT erTeulovan matricaze igive matricas miviRebT.
gavixsenoT, rom Tu A matricaa A.^2 iseTi operaciaa, romelsac A yvela elementi kvadratSi ahyavs. Tu gvinda kvadratSi aviyvanoT matrica anu SevasruloT moqmedeba A*A,vwerT A^2. A^4 igivea, rac A*A*A*A. roca xarisxis maCvenebeli ar aris mTeli ricxvi, ufro rTul operaciasTan gvaqvs saqme. am dros saWiroa iseTi sidideebis codna, rogoricaa matricis maxasiaTebeli ricxvi da maxasiTebeli veqtori. rogorc vnaxeT, or matricas Soris gamravlebis operacia rom SevasruloT, pirveli matricis svetebis raodenoba meore matricis striqonebis raodenobas unda udrides, aqedan gamomdinare, imisaTvis, rom matrica avaxarisxoT, igi aucileblad kvadratuli unda iyos.
gansazRvrisaTvis, A kvadratuli matricis Sebrunebuli aris iseTi matrica A-1, rom sruldeba piroba AA-1 =A-1A = erTeulovan matricas. magaliTd ganvixiloT ori matrica A da B:
Tu gamoviTvliT namravls A*B da B*A, miviRebT Semdeg matricebs:
amitom A da B urTieTSebrunebuli matricebia, anu A = B-1 da B = A-1.
Sebrunebuli matricis gamoTvla mosawyeni da damRleli procesia. sabednirod
MATLAB Seicavs funqcias
inv , romelic gamoiTvlis matricis Sebrunebuls. (ar
moviyvanT algoriTms matricis Sebrunebulis gamosaTvlelad, igi ganxiluli iqneba
wrfiv algebrasTan dakavSirebul TavSi. amgvarad, Tu mivcemT brZanebas inv(A),
Sedegad miviRebT B matricas da piriqiT.
matricis Sebrunebulis gamoTvla gvWirdeba mravali sainJinro amocanis
gadasawyvetad. mogvianebiT ganvixilavT zogierT aseT amocanas.
MATLA-is saSualebiT SeqmeniT Semdegi matricebi da SeasruleT miTiTebuli moqmedebani:
2. DB 3. BC’ 4. (CB)D’ 5. B-1 6. BB-1 7. B-1B 8. AC’ 9. (AC’)-1 10. (AC’)-1(AC’) 11. IB 12. BI
4.1.6 determinanti matricis determinanti skalaria, romelic matricis elementebis saSualebiT gamoiTvleba. determinants farTo gamoyeneba aqvs mravali problemis amoxsnisas, maT Soris matricis Sebrunebulis gamoTvlis da wrfiv gantolebaTa sistemis amoxsnisas. 22 zomis matricis determinanti Semdegnairad gamoiTvleba:
33 zomis matricis determinanti Semdegnairad gamoiTvleba:
|A| = a1,1a2,2 a3,3+a2,1a2,3 a3,2+ a1,3a2,1 a3,2- a3,1a2,2 a1,3- a3,2a2,3 a1,1- a3,3a2,1 a1,2
|A| = 5 + 6 + 0 – 0 – 4 – (-3), anu 10
ufro rTulia procesi ufro meti elementebis Semcveli matricis determinantis
gamosaTvlelad. ar mogvyavs sazogadod determinantis gamoTvlis procesis sruli
aRwera, radgan MATLAB saSualebiT SegviZlia gamoviTvaloT determinanti
funqciiT
det , romlis argumentia kvadratuli matrica.
genur inJineriaSi did rols TamaSobs iseTi mowyobiloba, rogoricaa proteinis (cilis) sinTezatori. mas SeuZlia gansazRvros aminomJavaTa rigi, mimdevroba cilis jaWvisebur molekulaSi. aminomJavaTa rigi exmareba genetikosebs daadginon (gaaigivon) geni, romelsac Seicavs Seqmnili cila. fermentebis saSualebiT SesaZlebelia kavSiris darRveva mezobel genebs Soris, imisaTvis rom gamocalkevdes saWiro geni DNA (dezoqsiribonukleinis mJava)-dan. es geni Semdeg SehyavT sxva organizmSi, rogorc baqteria, romelic Semdeg gamravldeba axal garemoSi. arsebobs mxolod 20 sxvadasxva aminomJava. cilis molekulea Seicavs asoboT aminomJavas, romlebic dakavSirebuli arian erTmaneTTan garkveuli rigiT. mocemul amocanaSi davuSvaT rom dadgenilia proteinis molekulaSi aminomJavaTa momdevroba da unda gamovTvaloT cilis molekuluri wona. cxrilSi mocemulia anbanis mixedviT dalagebuli aminomJavaTa mwkrivi, maTi mokle aRniSvna da molekuluri wona.
am amocanis sawyisi monacemebia monacemTa faili protein.dat, romelic Seicavs aminomJavaTa raodenobas da tips cilis TiToeul molekulaSi. davuSvaT monacemTa faili Seiqmna cilis sintezatoris saSualebiT. failis monacemTa yoveli striqoni Seesabameba erT cilas da Seicavs 20 mTel ricxvs, romelic Seesabameba cxrilSi aminomJavas rigiT nomers. amrigad Semdegi striqoni:
Seesabameba cilas aminomJavaTa mimdevrobiT – LysGluMetAspSerGlu.
INPUT/OUTPUT aRwera
naxazze mocemuli INPUT/OUTPUT diagrama, romelic gviCvenebs, rom sawyisi monacemebi warmodgenilia failis saxiT, romelic Seicavs monacemebs cilis molekuluri Semcvelobis Sesaxeb - romeli tipis aminomJavas Seicavs mocemuli cila da ra raodenobiT.
davuSvaT gvaqvs cilis molekula LysGluMetAspSerGlu. maTi Sesabamisi molekuluri wonebia :
aqedan gamomdinare, cilis molekuluri wona iqneba 825. monacemTa failSi am cilas Seesabameba striqoni:
cilis molekuluri wona rom miviRoT calkeuli aminomJavas raodenoba unda gavamravloT Sesabamis molekulur wonaze da miRebuli Sedegebi SevkriboT. aseTi namravlebis jami SegviZlia ganvixiloT rogorc cilis veqtoris da wonaTa veqtoris skalaruli namravli. Tu gvinda gamovTvaloT molekuluri wona cilaTa jgufisaTvis, Sedegi SegviZlia miviRoT matricebis gadamravlebiT Semdegnairad:
0 0 0 1 0 2 0 0 0 0 0 1 1 0 0 1 0 0 0 0 131 825
0 1 0 0 0 1 1 0 0 3 0 0 0 0 0 0 0 1 0 0 131
MATLAB amoxsna
MATLAB saSualebiT es amocana Zalze martivad amoixsneba. informacia aminmJavebis Sesaxeb wakiTxuli iqneba monacemTa failidan da Seiqmneba matrica protein, ganisazRvreba sveti veqtori mw, romlis elementebic iqneba anbanis mixedviT dalagebul aminomJavaTa molekuluri wonebi. am ori matricis gadamravlebiT miviRebT axal matricas, romlis elementebic iqneba cilis molekuluri wonebi.
Tthis program computes the molecular weights for
a group of protein molekules. A data file contains
the occurence and number of amino acids in each
load protein.dat mw=[89 175 132 132 121 146 146 75 156 131 131 147 . 149 165 116 105 119 203 181 117];
[rows cols] = size(protein); for k=1:rows fprintf('protein %3.0f: molecular weight = %5.0f \n',k, weights(k)) end
davuSvaT cilaTa jgufi, romlisTvisac viTvliT molekulur wonebs aseTia:
GlyIleSerThrTrp AspHisProGln ThrTyrSerTrpLysMetHisMet AlaValLeuValMet LysGluMetAspSerGluLysGluGluGlu
0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 1 1 1 0 0 0 0 0 1 0 0 1 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 2 0 0 1 1 1 1 0 1 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 2 0 0 0 1 0 4 0 1 0 0 0 2 1 0 0 1 0 0 0 0
MATLAB dagvibeWdavs molekulur wonebs cilebisaTvis:
protein 1: molecular weight = 633 protein 2: molecular weight = 550 protein 3: molecular weight = 1209 protein 4: molecular weight = 603 protein 5: molecular weight = 1339
4.1.7 Semobruneba
SesaZlebelia matrica A SemovabrunoT 90 gradusiT saaTis isris sawinaaRmdego
mimarTulebiT brZanebiT -
rot90 . Tu gvaqvs:
Tu gavuSvebT brZanebas : B = rot90(A); miviRebT:
am brZanebas SeiZleba meore argumentic hqondes, romelic gansazRvravs ramdenjer Semobrundes matrica 90 gradusiT. brZanebebi:
matrica SegviZlia ‘gadavabrunoT’ marjvnidan marcxniv
fliplr an zemodan qvemoT
(vertikalurad)
flipud :
A = [1 2; 4 8; -2 0]; B = fliplr(A); C = flipud(B);
A 4 8
B 8 4
C 4 8
brZaneba
reshape mocemul matricas Seucvlis formas – Tanafardobas striqonebis
da svetebis raodenobas Soris. funqciis argumentebi ise unda SeirCes, rom sawyis
da Sedegad miRebul matricebis elementTa raodenoba erTnairi iyos. am funqcias
gaaCnia sami argumenti. pirveli, Tavad matricaa, bolo ori ki gansazRvravs axali
matricis striqonebis da svetebis raodenobas. magaliTad ganvixiloT Semdegi
brZanebebi:
A = [2 5 6 –1; 3 –2 10 0]; B = reshape(A,4,2); C = reshape(A,8,1);
matricis nawilis amoReba axali matricis saxiT
funqciebi
diag, triu, tril saSualebas gvaZlevs matricis elementebi amoviRoT. samive
brZanebaSi igulisxmeba matricis mTavari diagonali, Tu igi kvadratuli araa.
mTavari im diagonals ewodeba, romelic iwyeba zeda marcxena kuTxidan da
elementebis svetis da striqonis mimTiTebeli indeqsebi erTnairia – a1,1, a2,2 da a.S.
mTavari diagonali aqvT rogorc kvadratul, aseve arakvadratul matricebs.
magaliTadAA matricis mTavari diagonalis elementebia 2, -2. B – 2, 10, xolo C –
2. funqcia
diag(A) Seqmnis svet veqtors, romlis elementebic A matricis mTavari
diagonalis elementebs Seicavs.
SeiZleba am funqcias meore argumentic hqondes
diag(A,k). im SemTxvevaSi Tu gvsurs
diagonalis rigi mivuTiToT. Tu k > 0, mTavari diagonalis zemoT k-ur diagonali
SeirCeva, Tu k <0, MmTavari diagonalis qvemoT k-uri diagonali iqneba SerCeuli.
Tu
diag funqciis argumentad nacvlad matricisa SerCeulia veqtori, maSin funqcia
Seqmnis kvadratul matricas, romlis mTavari diagonalc mocemuli veqtoris
elementebia, yvela sxva elementi ki 0-is tolia. magaliTad:
funqcia
triu(A) Seqmnis matricas, romelic Seicavs A matricis mTavari diagonalis
da mis zemoT ganlagebul elementebs, danarCeni elementebi nulis tolia. am
funqcias SeiZleba meore argumentic hqondes. funqcia
triu(A,k) mogvcems matricas,
romelic igive zomisa, rac A , Seicavs mis elementebs k-uri diagonals zemoT, an
qvemoT, sxva yvela elementi 0-is tolia. ganvixiloT MATLAB brZanebebi:
A = [1:2:7; 3:3:12; 4:-1:1; 1:4]; B = triu(A); C = triu(A,-1); D = triu(A,3);
Tril funqcia msgavsia
triu funqciisa, mxolod is Qqmnis qveda samkuTxa matricas. Tu
wina magaliTSi SevcvliT
triu funqcias
tril – iT, miviRebT:
gansazRvreT matricebi, romelic Seiqmneba Semdegi funqciebis moqmedebis Sedegad, Tu viciT, rom:
1. rot90(B) 2. rot90(A,3) 3. fliplr(A) 4. flipud(fliplr(B)) 5. reshape(A,4,3) 6. reshape(A,6,2) 7. reshape(A,2,6)
8. reshape(flipud(B),8,2) 9. triu(B) 10. triu(B,-1) 11. tril(A,2) 12. diag(rot90(B))
gamonasaxTa SeTavseba
(image alignment) cifruli gamonasaxi warmodgenilia matricis saxiT, romlis elementebic
sinaTlis intensivobas Seesabameba. aseTi matricis elementebs piqselebs anu
suraTis elementebs uwodeben. maRali garCevis gamonasaxi Seicavs elementTa did
raodenobas, dabali garCevis – mcire raodenobas. magaliTad maRali garCevis
gamonasaxi SesaZloa Seicavdes 1024 striqons da amdenive svets, ese igi
piqselebis saerTo raodenoba milionze meti iqneba. TiToeuli sidide aseT
matricaSi aris kodi, romelic sinaTlis intensivobas Seesabameba. kodi SeiZleba
Seicavdes informacias feris an Sav-TeTri gamonasaxis SemTxvevaSi nacrisfris
sxvadasxva tonalobebis Sesaxeb.
davuSvaT gamonasaxi warmodgenilia 6 striqoniani da 6 svetiani matricis saxiT.
aseve davuSvaT, rom matricis TiToeuli elementi 0 da 7 Sorisaa moTavsebuli,
rac ruxi feris tonalobebs eTanadeba. magaliTad:
davuSvaT gvaqvs erTidaigive obieqtis ori gamonasaxi eTidaigive garCeviT da ruxi feris tonalobaTa kodiT. aseve davuSvaT, rom ar viciT gamonasaxebs erTmaneTis mimarT rogori mdebareoba ukaviaT. imisaTvis, rom isini erTmaneTs SevuTavsoT, erTerTi maTgani ucvleld davtovoT, meore ki matriculi manipulaciebiT SevuTavsoT mas. isini SeTavsebulad CaTvleba, roca Sesabamisi elementebis mniSvnelobebi erTmaneTs daemTxveva. magaliTad davuSvaT A da B matricebi erTidaigive obieqtis gamonasaxebia:
imisaTvis, rom B SevuTavsoT A, igi unda SemovabrunoT 270 gradusiT saaTis isris sawinaaRmdegod (an 90 gradusiT saaTis isris mimarTulebiT). anda gadavabrunoT B
qvemodan zemoT da SemovabrunoT 90 gradusiT saaTis isris sawinaaRmdegod. SeamowmeT samive gza, raTa darwmundeT, rom gamonasaxebi amgvarad SeTavsdebian. imisaTvis, rom ganvsazRvroT SeuTavsda Tu ara ori gamonasaxi (image 1 da image 2) erTmaneTs, SegviZlia gamovTvaloT sxvaobebi Sesabamis elementebs Soris da miRebuli Sedegebi SevkriboT. amas mivaRwevT MATLAB brZanebiT:
sum funqcia orjer gavimeoreT imitom, rom yvela sxvaoba Segvekriba. pirveli
sum mogvcems veqtors, romlis elementebia Sesabamisi svetebis elementebis jami, xolo
meore
sum Sekrebs am veqtoris elementebs. samwuxarod, SesaZloa es jami 0
gamovides. ganvixiloT ori gamonasaxis Sesabamisi matrica:
Tu gamoviTvliT am ori matricis Sesabamisi elementebs Soris sxvaobebis jams miviRebT 5 + (-5) = 0. Tumca cxadad Cans, rom isini arTidaigive gamonasaxebi namdvilad ar aris. 0 imitom miviReT, rom dadebiTma da uaryofiTma sxvaobebma gaabaTila erTmaneTi. Tu sxvaobebs kvadratSi aviyvanT, an maT absolutur sidides aviRebT da ise daviTvliT jams, es sidideebi erTmaneTs veRar gaabaTilebs. MATLAB brZanebiT miiReba ase gamoTvlili sxvaobaTa jami, romelsac vuwodebT manZilis zomas:
distance = sum(sum(image1 – image2).^2));
SegviZlia daviTvaloT es manZilebi yvela SesaZlo SeTavsebis SemTxvevaSi. ori gamonasaxi CaiTvleba SeTavsebulad, Tu manZili 0 tolia. Tu gaviTvaliswinebT, rom erTidaimave obieqtis ori sxvadasxva gamonasaxis Sesabamis elementebs SeiZleba mcired gansxvavebuli mniSvnelobebi hqondes (gamowveuli instrumentuli cTomilebiT an sakomunikacio arxebSi xmauriT), SegviZlia gamovTvaloT manZilebi yvela SesaZlo SeTavsebisTvis da Semdeg avirCioT maT Soris umciresi.
ganvsazRvroT ori gamonasaxis SeTavsebisaTvis ra saxis manipulaciebia saWiro.
INPUT/OUTPUT aRwera
nax. 6.2 warmoadgens INPUT/OUTPUT diagramas, sadac naCvenebia, rom sawyis monacemebs viRebT ori failidan, Sedegi ki warmoadgens sidides: erTerTi gamonasaxis 90 gradusiT ramdenjer Sebruneba dagvWirda, rom igi meore gamonasaxs SeTavseboda.
Tu SevabrunebT D mimdevrobiT 0, 90, 180, 270, miviRebT:
axla Tu gamoviTvliT manZilebs (elementebs Siris sxvaobaTa kvadratebis jams) C matricasa da D –s am oTx versias Soris, miviRebT: 19, 7, 1 da 13 Sesabamisad. rogirc vxedavT minimaluri manZili = 1, rasac Seesabameba saaTis isris sawinaaRmdegod 180 gradusiT Semobruneba.
MATLAB amoxsna
vuSvebT, rom ori gamonasaxi Cawerilia ASCII monacemTa failis saxiT. saWiroa 4
ciklis gamoTvla, rom miviRoT mobrunebis 4 sxvadasxva mniSvneloba. Semdeg
vsargeblobT
min funqciiT, rom SevarCioT minimaluri manZili da misi Sesabamisi
mdebareoba manZilebis veqtorSi. ase ganvsazRvravT Tu ramdenjer SemovabruneT
gamonasaxi SeTavsebis misaRwevad.
This program determines the best alignment between
for k=0:3 a=rot90(image2,k); distance(k+1)=sum(sum(image1-a).^2); end
[minval, minloc]=min(distance); fprintf('Image alignment best at %3.0f degrees \n',. (minloc-1)*90) fprintf('(counterclockwise) \n \n')
SevniSvavT, rom es programa imuSavebs nebismieri garCevis gamonasaxebisaTvis. erTaderTi moTxovnaa, rom gamonasaxebis Sesabamis matricebs erTnairi zoma hqondeT. Tu am programas SevamowmebT zemoT ganxiluli A da B matricebisaTvis miviRebT:
Image alignment best at 270 degrees (counterclockwise)
am TavSi SevajameT matriculi gamoTvlebis da manipulaciebis operaciebi.
ganvsazRvreT matricis transponirebuli da Sebrunebuli. vnaxeT rogor
gamovTvaloT ori veqtoris skalaruli namravli da rogor gadavamravloT erTi
matrica meoreze. gavecaniT MATLAB funqciebs, romelTa saSualebiTac SegviZlia
SevcvaloT matricis forma da struqtura. funqciiT
rot90 SegviZlia SemovabrunoT
matricis elementebi saaTis isris sawinarmdego momarTulebiT.
reshape funqcia
saSualebas gvaZlevs SevqmnaT axali matrica elementebis igive raodenobiT. gavecaniT
funqciebs, romelTa saSualebiT SegviZlia matricidan amoviRoT elementebi da ase
SevqmnaT axali matrica an veqtori.
amoiRebs matricis mTavari diagonalis elementebs
gadaabrunebs matricas marcxnidan marjvniv (horizontalurad)
gadabrunebs matricas zemodan qvemoT (vertikalurad)
Semoabrunebs matricas 90 gradusiT saaTis isris sawinaaRmdegod
problemebi 1 - 10 dakavSirebulia am TavSi ganxilul amocanebTan, xolo 11 – 21 ukavSirdeba sxva sainJinro amocanebs.
cilis molekuluri wonebi. es amocanebi ukavSirdeba am TavSi gnxilul amocanas cilis molekuluri wonis gansazRvris Taobaze.
1. Secvale programa ise, rom gamoiTvalos da daibeWdos cilis rigiTi nomeri da
molekuluri wona im cilisaTvis, romelsac udidesi molekuluri wona gaaCnia.
2. Secvale programa ise, rom daibeWdos ganxiluli jgufis mixedviT cilis
3. Secvale programa ise, rom dagvibeWdos failSi Caweril monacemebSi calkeuli
aminomJava sul ramdenjer gvxvdeba. daibeWdos Semdegi formatiT
4. Secvale programa ise, rom dabeWdos im cilis rigiTi nomeri da molekuluri
wona, romelic aminomJavaTa yvelaze met saxeobas Seicavs.
5. Secvale programa ise, rom dabeWdos arsebuli monacemebis safuZvelze
saSualod aminomJavas ramden saxeobas Seicavs calkeuli cilis molekula.
gamonasaxTa SeTavseba. es amocanebu ukavSirdeba am TavSi ganxilul amocanas erTidaigive obieqtis ori gamonasaxis SeTavsebis Taobaze.
6. Secvale programa ise, rom dabeWdos agreTve gamoTvlili manZilebi gamonasaxis
7. Secvale programa ise, rom dabeWdos Semobrunebis kuTxe gradusebSi saaTis
8. Secvale programa ise, rom SeTavsebisas gamiyenos MATLAB funqciebi fliplr da
Secvale programa ise, rom Seadaros gamonasaxebi meore gamonasaxis gadabrunebiT marcxnidan marjvniv (horizontalurad) da aseve saaTis isris mimarTulebiT 90, 180 da 270 gradusiT Semobrunebuli gamonasaxis gadabrunebiT. (moifiqreT, ratom ar CavrTeT damatebiT SemTxveva zemodan qvemoT (vertikalurad) gadabruneba?)
10. Secvale programa ise, rom manZili gamoTvalos rogorc Sesabamis elementebs
Soris sxvaobaTa absoluturi sidideebis jami. SeadareT orive SemTxvevaSi miRebuli Sedegebi.
aminomJavebi. cilis molekulis Semadgeneli aminomJavebi Seicavs Semdeg qimiur elementebs: Jangbadi(O), naxSirbadi(C), axoti(N), gogirdi(S) da wyalbadi(H), rogorc naCvenebia cxrilSi davuSvaT am cxrilis monacemebi Cawerilia failSi elements.dat. am elementTa atomuri wonebia:
Oxigen 15.9994 Carbon 12.011 Nitrogen 14.00674 Sulfur 32.066 Hydrogen 1.00794
11. dawereT programa, romelic gamoiTvlis TiToeuli aminomJavas molekulur
wonas da Seqmnis monacemTa fails aaweights.dat, romelic Seicavs monacemebs failidan elements.dat plus aminomJavas molekuluri wona.
12. 11 amocanisaTvis dawerili peograma Secvale ise, rom gamoTvalos da dabeWdos
13. 11 amocanisaTvis dawerili peograma Secvale ise, rom gamoTvalos da dabeWdos
im aminomJavas rigiTi nomeri romelsac aqvs udidesi da umciresi molekuluri wona.
matriculi analizi. SeqmeniT matrica amocanis pirobis gaTvaliswinebiT da SeinaxeT igi ASCII failSi array.dat, romelsac Semdeg waikoTxavs programa da gaaanalizebs.
14. dawereT programa, romelic waikiTxavs matricas failidan array.dat,
gansazRvravs aris Tu ara igi zeda samkuTxa matrica da dabeWdavs Sesabamisad: “Upper Triangular” an “Not Upper Triangular”
15. dawereT programa, romelic waikiTxavs matricas failidan array.dat,
gansazRvravs aris Tu ara igi qveda samkuTxa matrica da dabeWdavs Sesabamisad: “Lower Triangular” an “Not Lower Triangular”
16. dawereT programa, romelic waikiTxavs matricas failidan array.dat,
gansazRvravs aris Tu ara igi diagonaluri matrica da dabeWdavs Sesabamisad: “Diagonal” an “Not Diagonal”. Tu diagonaluri matrica agreTve erTeulovanicaa, dabeWdavs “Identity” “Diagonal” nacvlad.
17. simetriuli ewodeba kvadratul matricas, romelic simetriulia mTavari
diagonalis mimarT. aseTi matricas transponirebuli igive matricis tolia. dawereT programa, romelic waikiTxvs matricas failidan array.dat, gansazRvravs aris Tu ara igi simetriuli da dabeWdavs Sesabamisad: “Symmetric” an “Not Symmetric”
18. toeplicis (Toeplitz) matrica ewodeba iseT matricas, romlis diagonalis
elementebi erTmaneTis tolia, magram sxvadasxva digonalis elementebi gansxvavdeba. dawereT programa, romelic waikiTxvs matricas failidan array.dat, gansazRvravs aris Tu ara igi toeplicis (Toeplitz) da dabeWdavs Sesabamisad: “Toeplitz” an “Not Toeplitz”.
tridiagonaluri matrica ewodeba iseT matricas, romlis mxolod mTavari diagonalis, mTavari diagonalis zeda da qveda ori diagonalis elementebia aranulovani. dawereT programa, romelic waikiTxvs matricas failidan array.dat, gansazRvravs aris Tu ara igi tridiagonaluri da dabeWdavs Sesabamisad: “Tridiagonal” an “Not Tridiagonal”.
20. zogierTi ricxviTi meTodi saWiroebs matricis striqonebis iseT gadalagebas,
roca saWiroa pirvel striqonad gadavides is atriqoni, romelic Secavs pirveli svetis elementebs Soris absoluturi sididiT udides. Semdeg Tu ganvixilavT darCenil striqonebs meore striqonad gadava is striqoni, romelic Secavs me-2 svetis elementebs Soris absoluturi sididiT udides. procesi grZeldeba, vidre am wesiT ar dalagdeba matrica mTlianad. am process uwodeben (row pivoting). dawereT aseTi programa da daalageT Tqvens mir Seqmnili 10 striqoniani matrica.
21. Column pivoting iTvalicwinebs monacemTa imis msgavs gadalagebas, rogoc row
pivoting, mxoloD am SemTxvevaSi svetebis gadalageba xdeba: pirveli sveti Seicavs pirveli striqonis absoluturi sididiT udides mniSvnelobas da a.S. dawereT Sesabamisi programa.
Source: http://emc.ge/docs/6_operaciebi_matricebze.pdf
Health Questions on the Job: FAQ Q: I’ve applied for a new job and I have to take a drug test. The drug test form asks if I take any medication. What do I do? A: If you are taking any medication that may show a false positive on a drug test (for example, Sustiva or Marinol) you should be sure to list it on the form. Usually the test is performed not by your employer, but by an outsid
Domperidone for Improving Breastmilk Production What is domperidone? Domperidone (Motilium) is a peripheral dopamine antagonist general y used for control ing nausea and vomiting, dyspepsia (upset stomach), diabetic gastroparesis (poor stomach emptying which occurs in diabetics) and gastric reflux (heartburn). It blocks peripheral dopamine receptors in the intestinal wal and in the naus
A |
B |
C |
D |
E |
F |
G |
H |
I |
J |
K |
L |
M |
N |
O |
P |
Q |
R |
S |
T |
U |
V |
W |
X |
Y |
Z |
0-9 |