Top Banner
1 Sistem Persamaan Linier
47

Gauss Gauss Jordan

Feb 18, 2016

Download

Documents

Lia Mufaricha

analisa numerik
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Gauss Gauss Jordan

1

Sistem Persamaan Linier

Page 2: Gauss Gauss Jordan

2

Persamaan linier :

Persamaan yang semua variabelnya berpangkat 1 atau 0 dan

tidak terjadi perkalian antar variabelnya.

Contoh: (1) x + y + 2z = 9 PL

(2) 2x + y = 9 PL

(3) 2xy – z = 9 Bukan PL

Solusi PL (1) : berupa suatu “tripel” dengan masing-masing

nilai sesuai urutan (nilai-x, nilai-y, nilai-z) yang memenuhi

persamaan tersebut.

Himpunan solusi untuk persamaan (1) di atas:

{ … ( 0, 1, 4), (1, 0, 4), (4, 5, 0), …. }

Himpunan solusi juga disebut Ruang Solusi (solution space)

Page 3: Gauss Gauss Jordan

3

Misal :

atau

atau

terserah variable mana yang akan diumpamakan, rumus

berbeda, tapi hasil akhir untuk x, y, dan z tetap sama

429

5

0

tsx

sy

tz

5

4

sy

tx

02

9

stz

529

0

4

tsy

sz

tx

Page 4: Gauss Gauss Jordan

4

Sistem Persamaan Linier:

Suatu sistem dengan beberapa (2 atau lebih) persamaan linier.

Contoh:

x + y = 3

3x – 5y = 1

Ruang Solusi:

berupa semua ordered-pair (nilai-x, nilai-y) yang harus

memenuhi semua persamaan linier dalam sistem tersebut;

untuk sistem ini ruang solusinya { (2, 1) }

Page 5: Gauss Gauss Jordan

5

Solusi Sistem Persamaan Linier

a. Cara Biasa → Seperti SMA

a. Cara Biasa (untuk mengingat kembali):

I. x + y = 3 3x + 3y = 9

3x – 5y = 1 3x – 5y = 1

8y = 8 y = 1

3x – 5 = 1 3x = 6 x = 2

II. y = 3 – x

3x – 5(3 – x) = 1 atau 3x – 15 + 5x = 1 8x = 16 x = 2

y = 3 – x y = 1

Page 6: Gauss Gauss Jordan

6

Interpretasi Geometrik:

Sistem menggambarkan 2 garis lurus pada sebuah bidang datar.

g1: x + y = 3

g2: 3x – 5y = 1

Solusi: g1 dan g2 berpotongan di (2, 1)

Kemungkinan:

berpotongan di 1 titik tidak berpotongan berimpit

X+y = 5

X+y = 7

Var => sama

Konst => tidak

X+y = 5

2X+2y = 10

Kelipatan

Page 7: Gauss Gauss Jordan

7

Solusi Sistem Persamaan Linier

a. Cara Biasa → Seperti SMA

b. Eliminasi Gauss

c. Eliminasi Gauss - Jordan

Page 8: Gauss Gauss Jordan

SISTEM PERSAMAAN LINIER (SPL)

Bentuk umum :

dimana x1, x2, . . . , xn variabel tak diketahui, aij , bi,

i = 1, 2, . . . , m; j = 1, 2, . . . , n bil. diketahui.

Ini adalah SPL dengan m persamaan dan n variabel.

SPL

Mempunyai penyelesaian

disebut KONSISTEN

Tidak mempunyai penyelesaian

disebut TIDAK KONSISTEN

TUNGGAL

BANYAK

Page 9: Gauss Gauss Jordan

9

b. Eliminasi Gauss (ringkasan):

Sistem Persamaan → Matriks → Eliminasi → Substitusi

Linier Augmented Gauss Balik

OBE

Page 10: Gauss Gauss Jordan

10

Matriks Augmented : (Matriks yang diperbesar)

Matriks yang entri-entrinya dibentuk dari koefisien-koefisien

Sistem Persamaan Linier

Contoh : x + y + 2z = 9

2x + 4y – 3z = 1

3x + 6y – 5z = 0

Matriks Augmented-nya : 1 1 2 9

2 4 -3 1

3 6 -5 0

Page 11: Gauss Gauss Jordan

11

Operasi Baris Elementer (OBE)

(Elementary Row Operation - ERO) Perhatikan bahwa tiap baris dari matriks merepresentasikan persamaan linier

1. Mengalikan suatu baris dengan bilangan nyata k 0

2. Menukar posisi dua baris

3. Menambah baris-i dengan k kali baris-j

Page 12: Gauss Gauss Jordan

12

Penyelesaian Sistem Persamaan Linier

b. Eliminasi Gauss

c. x + y + 2z = 9 1 1 2 9

2x + 4y – 3z = 1 2 4 -3 1

3x + 6y – 5z = 0 3 6 -5 0

lalu diusahakan berbentuk 1 1 2 9

0 1 ? ?

0 0 1 ?

dengan proses Operasi Baris Elementer (OBE)

(Elementary Row Operation - ERO)

ditulis

dalam

bentuk

matriks

augmented

Page 13: Gauss Gauss Jordan

13

O.B.E

sebuah baris dengan kostanta 0

sebuah baris dengan konstanta 0 kemudian pada baris lain

Menukar dua buah baris

Ciri-ciri eliminasi Gauss (Eselon Baris)

Jika suatu baris tidak semua nol, maka bilangan pertama yang tidak nol adalah 1 (1 utama)

Baris nol terletak paling bawah

1 utama baris berikutnya berada di kanan 1 utama baris di atasnya.

Dibawah 1 utama harus 0

Page 14: Gauss Gauss Jordan

14

Page 15: Gauss Gauss Jordan

15

Page 16: Gauss Gauss Jordan

16

Page 17: Gauss Gauss Jordan

17

Contoh :

Ciri-ciri eliminasi Gauss Jordan (Eselon Baris

Tereduksi)

Jika suatu baris tidak semua nol, maka bilangan

pertama yang tidak nol adalah 1 (1 utama)

Baris nol terletak paling bawah

1 utama baris berikutnya berada di kanan 1utama

baris diatasnya..

Tiap kolom yang mengandung 1 utama mempunyai

nol di tempat lain

Contoh :

5100

2610

7341

10000

01100

06210

1100

7010

4001

00000

31000

10210

Page 18: Gauss Gauss Jordan

18

Eliminasi Gauss menggunakan O.B.E :

* + =

* + =

* + =

Substitusi Balik

271130

17720

9211[baris 1 -2] + baris 2

9

2

1

1

2

2

2

2

1

3

4

2

17

7

2

0

[baris 1 -3] + baris 3

9

2

1

1

3

3

3

3

0

5

6

3

27

11

3

0

baris 2 * 1/2

2/32/100

2/172/710

9211[baris 2 -3] + baris 3

2/17

2/7

1

0

3

3

3

3

27

11

3

0

2/3

2/1

0

0

baris 3 -2

31002

17

2

710

9211 z = 3

2

2/17)3(2/7

2/172

7

y

y

zy

1

9)3(22

92

x

x

zyx 3,2,1 zyx

Page 19: Gauss Gauss Jordan

19

x y z

1 1 2 9 Substitusi Balik:

0 2 -7 -17

0 0 -½ -3/2 -1/2 z = -3/2 z = 3

1 1 2 9

0 2 -7 -17 2y – 7z = - 17

0 0 -½ -3/2 2y = 21 – 17 y = 2

1 1 2 9 x + y + 2z = 9

0 2 -7 -17 x = – 2 – 6 + 9 x = 1

0 0 -½ -3/2

z

y

z

Page 20: Gauss Gauss Jordan

20

Bentuk eselon baris:

1. Entri-entri dalam sebuah baris tidak semuanya nol, maka

entri pertama yang tidak nol harus 1 (disebut 1-utama /

leading-1)

2. Baris-baris yang semua entrinya 0, dikelompokkan di bagian

bawah matriks

3. Posisi 1-utama dari baris yang lebih bawah harus lebih ke

kanan d/p 1-utama baris yang lebih atas

Bentuk eselon baris tereduksi:

1, 2, 3, ditambah

4. Semua entri (yang lain) dari kolom yang berisi 1-utama

harus di-0-kan

Page 21: Gauss Gauss Jordan

21

c. Eliminasi Gauss-Jordan (ringkasan):

Sistem Persamaan → Matriks → Eliminasi → Solusi

Linier Augmented Gauss-Jordan (langsung)

OBE

Page 22: Gauss Gauss Jordan

22

Page 23: Gauss Gauss Jordan

23

Eliminasi Gauss-Jordan (contoh yang sama)

x + y + 2z = 9 1 1 2 9

2x + 4y – 3z = 1 2 4 -3 1

3x + 6y – 5z = 0 3 6 -5 0

dan diusahakan berbentuk 1 0 0 ?

0 1 0 ?

0 0 1 ?

dengan proses Operasi Baris Elementer (OBE)

(Elementary Row Operation - ERO)

Page 24: Gauss Gauss Jordan

24

Eliminasi Gauss-Jordan menggunakan O.B.E

idem Gauss

disambung dengan :

* + =

* + =

* + =

3100

2/172/710

9211

baris 3

2

7 + baris 2

3

1

0

0

2/7

2/7

2/7

2/7

2/17

2/7

1

0

2

0

1

0

3100

2010

9211

baris 3 -2 + baris 1

3

1

0

0

2

2

2

2

9

2

1

1

3

0

1

1

3100

2010

3011 baris 2 -1 + baris 3

2

0

1

0

1

1

1

1

3

0

1

1

1

0

0

1

3100

2010

1001

3

2

1

z

y

x

Page 25: Gauss Gauss Jordan

25

CONTOH

In the left column below we solve a system of equations by operating on

the equations in the system, and in the right column we solve the same

system by operating on the rows of the augmented matrix.

x + y + 2z = 9

2x + 4y – 3z = 1

3x + 6y -5z = 0

0563

1342

9211

Add -2 times the first equation

to the second to obtain Add -2 times the first row

to the second to obtain

x + y + 2z = 9

2y – 7z = -17

3x + 6y -5z = 0

0563

17720

9211

Add -3 times the first row

to the third to obtain

Add -3 times the first equation

to the third to obtain

x + y + 2z = 9

2y – 7z = -17

3y -11z = -27

271130

17720

9211

Page 26: Gauss Gauss Jordan

26

Multiply the second equation

by ½ to obtain

Multiply the second row by

½ to obtain

27113

2

17

2

7

92

zy

zy

zyx

2711302

17

2

710

9211

Add -3 times the second

equation to the third to obtain

Add -3 times the second

row to the third to obtain

2

3

2

1

2

17

2

7

92

z

zy

zyx

2

3

2

100

2

17

2

710

9211

Multiply the third equation by

-2 to obtain

Multiply the third row by -2

to obtain

3

2

17

2

7

92

z

zy

zyx

31002

17

2

710

9211

Page 27: Gauss Gauss Jordan

27

Add -1 times the second equation

to the first to obtain Add -1 times the second

row to the first to obtain

3

2

17

2

7

2

35

2

11

z

zy

zx

31002

17

2

710

2

35

2

1101

Add -11/2 times the third equation to

the first and 7/2 times the third

equation to the second to obtain

Add -11/2 times the third row to the

first and 7/2 times the third row to

the second to obtain

3

2

1

z

y

x

3100

2010

1001

The solution : x = 1, y = 2, z = 3

Page 28: Gauss Gauss Jordan

28

Halaman 11

Step 1. Locate the leftmost column that does not

consist entirely of zeros.

Step 2. Interchange the top row with another row, if necessary, to

bring a nonzero entry to the top of the column found in Step 1.

156542

281261042

1270200

156542

281261042

1270200

Leftmost nonzero column

156542

1270200

281261042The first and second rows in the

preceding matrix were interchanged

Page 29: Gauss Gauss Jordan

29

Step 3 if the entry that is now at the top of the coloumn found in step 1 is

a, multiply the first row by 1/a in order to introduce a leading 1

1 2 -5 3 6 14

0 0 -2 0 7 12

0 0 5 0 -17 -29

1 2 -5 3 6 14

0 0 -2 0 7 12

2 4 -5 6 -5 -1

step 4 add suitable multiples of the top row to the rows below so that all

entries below the leading 1 to zeros

step 5 Now cover the top row in the matrix and begin again with step 1

applied to the submatrix that remains. Continue in this way until

the entire matrix is in row-echelon form

1 2 -5 3 6 14

0 0 -2 0 7 12

0 0 5 0 -17 -29

The first row of the

preceding

matrix was multiplied by ½

-2 times the first row

of the preceding matrix was

added to the third row

left most nonzero coloumn in the

submatrix

Page 30: Gauss Gauss Jordan

30

1 2 -5 3 6 14

0 0 1 0 -3,5 -6

0 0 5 0 -17 29

1 2 -5 3 6 14

0 0 1 0 -3,5 -6

0 0 5 0 -17 29

1 2 -5 3 6 14

0 0 1 0 -3,5 -6

0 0 0 0 0.5 1

The first row in the submatrix

was multiplied

by -1/2 to introduce a leading 1

-5 times the first row of the submatirx

was added to the second row of the submatrix

to introduce a zero below the leading 1

The top row in the submatrix was

covered, and we returned again

to the step 1

The first(and only) row in the submatrix

was multiplied by 2 to introduce a leading 1

•The entire matrix is now in row-echelonform. To find the reduce row-echelon form we need the following additional step

leftmost non zero coloumn

in the new submatrix

1 2 -5 3 6 14

0 0 1 0 -3,5 -6

0 0 0 0 1 2

Page 31: Gauss Gauss Jordan

31

Step 6 Begining with the last nonzero row and working upward, add suitable

multiplies of each row to the rows above to introduce zeros above the

leading 1’s

1 2 -5 3 0 2

0 0 1 0 0 1

0 0 0 0 0 1

1 2 -5 3 6 14

0 0 1 0 0 1

0 0 0 0 1 2

1 2 0 3 0 7

0 0 1 0 0 1

0 0 0 0 1 2

7/2 times the third row of the

preceding matrix was added

to the second row

-6 times the third row was

added

to the first row

5 times the second row was

added to the first row

The last matrix is in reduced row echelon form

Page 32: Gauss Gauss Jordan

32

Suatu SPL mempunyai 3 kemungkinan jawaban, yaitu :

1. Mempunyai jawaban tunggal

2. Mempunyai banyak jawaban

3. Tidak mempunyai jawaban

Contoh :

Tentukan nilai a agar SPL berikut:

i. Mempunyai jawaban tunggal

ii. Mempunyai banyak jawaban

iii. Tidak mempunyai jawaban

x – 2y + 3z = 1

2x – 3y + 9z = 4

x – 3y + (a2 - 4)z = 1 + a

Page 33: Gauss Gauss Jordan

33

Penyelesaian :

Matriks Eselon SPL di atas adalah :

i. Mempunyai jawaban tunggal

a2 – 4 ≠ 0 a ≠ -2 dan a ≠ 2

ii. Mempunyai banyak jawaban

a2 – 4 = 0 dan a +2 = 0 a = -2

iii. Tidak mempunyai jawaban

a2 – 4 = 0 dan a + 2 ≠ 0 a = 2

aa 2400

2310

1321

2

Page 34: Gauss Gauss Jordan

34

Sistem Persamaan Linier Homogen :

1. Sistem Persamaan Linier dikatakan homogen jika semua suku di

kanan tanda “=“ adalah 0.

2. Solusi Sistem Persamaan Linier Homogen:

Solusi Trivial ( semua xi = 0; i = 1 .. n ): pasti ada

Solusi Non-trivial ( solusi trivial, plus solusi di mana ada xi ≠ 0 )

Contoh: lihat contoh 6 halaman 18 dan verifikasi proses penyelesaiannya

2 2 -1 0 1 0

-1 -1 2 -3 1 0

1 1 -2 0 -1 0

0 0 1 1 1 0

Page 35: Gauss Gauss Jordan

35

Contoh: lihat contoh 6 halaman 18 dan verifikasi proses penyelesaiannya

2 2 -1 0 1 0 -1 -1 2 -3 1 0 1 1 -2 0 -1 0 0 0 1 1 1 0

1 1 -1/2 0 1/2 0 -1 -1 2 -3 1 0 1 1 -2 0 -1 0 0 0 1 1 1 0

1 1 -1/2 0 1/2 0

0 0 3/2 -3 3/2 0

0 0 -3/2 0 -3/2 0

0 0 1 1 1 0

Brs-1 (1/2)

Brs-2 + brs-1

Brs-3 – brs-1

Page 36: Gauss Gauss Jordan

36

1 1 -1/2 0 1/2 0

0 0 3/2 -3 3/2 0

0 0 -3/2 0 -3/2 0

0 0 1 1 1 0

1 1 -1/2 0 1/2 0

0 0 1 -2 1 0

0 0 1 0 1 0

0 0 1 1 1 0

1 1 -1/2 0 1/2 0

0 0 1 -2 1 0

0 0 0 2 0 0

0 0 0 3 0 0

Brs-2 (2/3)

Brs-3 (– 2/3)

Brs-3 – brs-2

Brs-4 – brs-2

Page 37: Gauss Gauss Jordan

37

1 1 -1/2 0 1/2 0

0 0 1 -2 1 0

0 0 0 2 0 0

0 0 0 3 0 0

1 1 -1/2 0 1/2 0

0 0 1 -2 1 0

0 0 0 1 0 0

0 0 0 1 0 0

1 1 -1/2 0 1/2 0

0 0 1 -2 1 0

0 0 0 1 0 0

0 0 0 0 0 0

Brs-3 (1/2)

Brs-4 (1/3)

Brs-4 – brs-3

Page 38: Gauss Gauss Jordan

38

1 1 -1/2 0 1/2 0

0 0 1 -2 1 0

0 0 0 1 0 0

0 0 0 0 0 0

1 1 -1/2 0 1/2 0

0 0 1 0 1 0

0 0 0 1 0 0

0 0 0 0 0 0

1 1 0 0 1 0

0 0 1 0 1 0

0 0 0 1 0 0

0 0 0 0 0 0

baris-1 + (1/2) baris-2

Page 39: Gauss Gauss Jordan

39

1 1 0 0 1 0

0 0 1 0 1 0

0 0 0 1 0 0

0 0 0 0 0 0

x1 + x2 + x5 = 0

x3 + x5 = 0

x4 = 0

x5 = s x3 + x5 = 0 x3 = – x5

x2 = t x1 + x2 + x5 = 0 x1 = – x2 – x5

Ruang solusinya = { (-t-s, t, -s, 0, s ) }

Catt => yang diumpamakan dahulu adalah index terbesar

Page 40: Gauss Gauss Jordan

40

Teorema:

Sistem Persamaan Linier Homogen dengan variabel

lebih banyak d/p. persamaan mempunyai tak

berhingga banyak pemecahan.

Ditinjau dari matriksnya:

Sistem Persamaan Linier Homogen dengan kolom lebih banyak

d/p. baris mempunyai tak berhingga banyak pemecahan.

Page 41: Gauss Gauss Jordan

41

Contoh menggunakan Matlab

• Soal

x + y + 2z = 9

2x + 4y – 3z = 1

3x + 6y – 5z = 0

Buat matrix pada Matlab

Page 42: Gauss Gauss Jordan

42

Matlab Mengenol-kan baris ke-2, kolom 1

Baris 2 = Baris 1 * -2 + baris 2

Page 43: Gauss Gauss Jordan

43

Matlab Mengenol-kan baris ke-3, kolom 1

Baris 3 = Baris 1 * -3 + baris 3

Page 44: Gauss Gauss Jordan

44

Matlab Membuat nilai 1 pada kolom 2 dan baris 2

Baris 2 = Baris 2 * 1/2

Page 45: Gauss Gauss Jordan

45

PR

• Contoh pada slide 3, coba tukar antara

baris pertama dengan baris 3, apakah

hasilnya tetap sama ? Jawab dengan

menggunakan Gauss-Jordan (dgn tangan)

x + y

+ 2z =

9

2x +

4y –

3z =

1

3x +

6y –

5z =

0

3x +

6y –

5z =

0

2x +

4y –

3z =

1

x + y

+ 2z =

9

Page 46: Gauss Gauss Jordan

46

PR

• Contoh pada slide 8, coba kerjakan 2 SPL

yang seharusnya jawabannya sama, tapi

kenapa berbeda? Jawab dengan

menggunakan Gauss-Jordan (dengan

tangan)

x1 + 1/2x2 + 1/3x3 = 1

1/2x1 + 1/3x2 + 1/4x3 = 0

1/3x1 + 1/4x2 + 1/5x3 = 0

x1 + 0,5x2 + 0,33x3 = 1

0,5x1 + 0,33x2 + 0,25x3 = 0

0,33x1 + 0,25x2 + 0,2x3 = 0

Page 47: Gauss Gauss Jordan

47

PR kerjakan 2 saja

• 1.1 3.b, 4.c, 5.d, 11

• 1.2 6.b, 7.c, 8.a, 13.b, 14.c, 15.b, 17,

22