Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

04/12/16 0:15 MATLAB Command Window 1 of 2

>> %Nama : Rexzy Senolinggi


>> %NIM : 32215010
>> %Kelas : 2 A Teknik Telekomunikasi
>>
>> %Tugas 1
>> %Contoh soal 1
>> % s^3+4s^2+8s-12=0
>> p = [1 4 8 -12]

p =

1 4 8 -12

>> roots(p)

ans =

-2.4732 + 2.5621i
-2.4732 - 2.5621i
0.9463 + 0.0000i

>> %Contoh Soal 2


>> % s^3-4s^2+8s-12=0
>> p = [1 -4 2 8 -12]

p =

1 -4 2 8 -12

>> roots(p)

ans =

-1.5239 + 0.0000i
2.8198 + 0.0000i
1.3520 + 0.9822i
1.3520 - 0.9822i

>> %Contoh Soal 3


>> % s^4-s^3+2s^2+3=0
>> p = [1 1 2 2 3]

p =

1 1 2 2 3

>> roots(p)

ans =

0.4057 + 1.2928i
0.4057 - 1.2928i
-0.9057 + 0.9020i
-0.9057 - 0.9020i
04/12/16 0:15 MATLAB Command Window 2 of 2

>>

You might also like