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

Practical 1 - Final

This document contains the code and results for 3 questions from a lab assignment. Question 1 involves convolving polynomials and evaluating polynomials. Question 2 finds the residues of polynomial divisions. Question 3 iterates a logistic map equation to generate values that converge to a fixed point.

Uploaded by

muhammad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
52 views4 pages

Practical 1 - Final

This document contains the code and results for 3 questions from a lab assignment. Question 1 involves convolving polynomials and evaluating polynomials. Question 2 finds the residues of polynomial divisions. Question 3 iterates a logistic map equation to generate values that converge to a fixed point.

Uploaded by

muhammad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

ME-073

LAB #1
Question 1
p=[1 2 1];
q=[1 1];
%part a
Question1a=conv(p,q)
%part b(i)
Question1b_i=roots(p)
%part b(ii)
Question1b_ii=roots(q)
%part c(i)
Question1c_i=polyval(p,-1)
%part c(ii)
Question1c_ii=polyval(q,6)

Answers
Question1a =

1 3 3 1

Question1b_i =

-1
-1

Question1b_ii =

-1

Question1c_i =

Question1c_ii =

7
ME-073

Question 2
%part a
B=[2 5 3 6];
A=[1 6 11 6];
[r,p,k]=residue(B,A)
%part b
A=[1 1];
B=[1 2 3];
A=conv(A,A);
[r,p,k]=residue(B,A)

Answer
r=

-6.0000
-4.0000
3.0000
p=

-3.0000
-2.0000
-1.0000
k=

2
r=

0
2
p=

-1
-1
k=

1
ME-073

Question 3
p=2.9;
a(1)=0.5;
for n=2:100
a(n)=p*a(n-1)*(1-a(n-1));
end
a

Answer

a=
Columns 1 through 11
0.5000 0.7250 0.5782 0.7073 0.6004 0.6958 0.6139 0.6874 0.6232 0.6810
0.6300
Columns 12 through 22
0.6760 0.6352 0.6720 0.6392 0.6688 0.6424 0.6662 0.6449 0.6641 0.6469
0.6624
Columns 23 through 33
0.6485 0.6611 0.6498 0.6600 0.6508 0.6591 0.6516 0.6583 0.6523 0.6577
0.6529
Columns 34 through 44
0.6572 0.6533 0.6568 0.6537 0.6565 0.6539 0.6563 0.6542 0.6561 0.6544
0.6559
Columns 45 through 55
0.6545 0.6558 0.6546 0.6556 0.6547 0.6556 0.6548 0.6555 0.6549 0.6554
0.6549
Columns 56 through 66
0.6554 0.6550 0.6553 0.6550 0.6553 0.6551 0.6553 0.6551 0.6553 0.6551
0.6552
ME-073

Columns 67 through 77
0.6551 0.6552 0.6551 0.6552 0.6551 0.6552 0.6551 0.6552 0.6551 0.6552
0.6552
Columns 78 through 88
0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552
0.6552
Columns 89 through 99
0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552 0.6552
0.6552
Column 100
0.6552

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy