From 0afe26582f3290dd945f3949c5c4176e4a676d8b Mon Sep 17 00:00:00 2001 From: Marius Peter Date: Mon, 26 Aug 2019 16:59:51 -0700 Subject: course end --- hw4/prob_1.py | 11 +++++++++++ hw4/prob_2.py | 8 ++++++++ hw4/prob_5.py | 11 +++++++++++ hw5/5_9.pdf | Bin 0 -> 1237796 bytes hw5/6_2.pdf | Bin 0 -> 951344 bytes hw5/6_3.pdf | Bin 0 -> 643401 bytes hw5/6_7.pdf | Bin 0 -> 3634781 bytes hw5/6_9.pdf | Bin 0 -> 829452 bytes hw5/hw5.pdf | Bin 0 -> 65562 bytes hw5/matlab/1_a_rl.png | Bin 0 -> 24910 bytes hw5/matlab/1_b_rl.png | Bin 0 -> 21510 bytes hw5/matlab/1_c_rl.png | Bin 0 -> 39885 bytes hw5/matlab/2_1.png | Bin 0 -> 22146 bytes hw5/matlab/2_2.png | Bin 0 -> 16718 bytes hw5/matlab/2_3.png | Bin 0 -> 14638 bytes hw5/matlab/2_4.png | Bin 0 -> 15754 bytes hw5/matlab/mag and phase.pdf | Bin 0 -> 45991 bytes hw5/matlab/mag.png | Bin 0 -> 17982 bytes hw5/matlab/phase.png | Bin 0 -> 17049 bytes hw5/matlab/whole2.pdf | Bin 0 -> 78833 bytes 20 files changed, 30 insertions(+) create mode 100644 hw4/prob_1.py create mode 100644 hw4/prob_2.py create mode 100644 hw4/prob_5.py create mode 100644 hw5/5_9.pdf create mode 100644 hw5/6_2.pdf create mode 100644 hw5/6_3.pdf create mode 100644 hw5/6_7.pdf create mode 100644 hw5/6_9.pdf create mode 100644 hw5/hw5.pdf create mode 100644 hw5/matlab/1_a_rl.png create mode 100644 hw5/matlab/1_b_rl.png create mode 100644 hw5/matlab/1_c_rl.png create mode 100644 hw5/matlab/2_1.png create mode 100644 hw5/matlab/2_2.png create mode 100644 hw5/matlab/2_3.png create mode 100644 hw5/matlab/2_4.png create mode 100644 hw5/matlab/mag and phase.pdf create mode 100644 hw5/matlab/mag.png create mode 100644 hw5/matlab/phase.png create mode 100644 hw5/matlab/whole2.pdf diff --git a/hw4/prob_1.py b/hw4/prob_1.py new file mode 100644 index 0000000..92e8af6 --- /dev/null +++ b/hw4/prob_1.py @@ -0,0 +1,11 @@ +import numpy as np +import control +import matplotlib.pyplot as plt + +# L = control.TransferFunction((1), (1, 6, 5, 0, 0)) +# L = control.TransferFunction((1, 2), (1, 10, 0, 0)) +L = control.TransferFunction((1, 1), (1, -3, 0)) + +rlist, klist = control.rlocus(L, kvect=np.linspace(100, -100, num=1000)) + +plt.show() diff --git a/hw4/prob_2.py b/hw4/prob_2.py new file mode 100644 index 0000000..c53cddf --- /dev/null +++ b/hw4/prob_2.py @@ -0,0 +1,8 @@ +import numpy as np +from math import exp, cos, sin +import matplotlib.pyplot as plt + +t = [0.01 * x for x in range(500)] +y = [1.0015 - 1.0404 * exp(-0.432 * t) + 0.039 * exp(-11.5567 * t) for t in t] +plt.plot(t, y) +plt.show() diff --git a/hw4/prob_5.py b/hw4/prob_5.py new file mode 100644 index 0000000..94d0fa5 --- /dev/null +++ b/hw4/prob_5.py @@ -0,0 +1,11 @@ +from scipy import signal +import matplotlib.pyplot as plt + +s1 = signal.lti([1, 2], [1, 4, 4, 6, 0]) +w, mag, phase = signal.bode(s1) + +plt.figure() +plt.semilogx(w, mag) +plt.figure() +plt.semilogx(w, phase) +plt.show() diff --git a/hw5/5_9.pdf b/hw5/5_9.pdf new file mode 100644 index 0000000..597a154 Binary files /dev/null and b/hw5/5_9.pdf differ diff --git a/hw5/6_2.pdf b/hw5/6_2.pdf new file mode 100644 index 0000000..53ece2c Binary files /dev/null and b/hw5/6_2.pdf differ diff --git a/hw5/6_3.pdf b/hw5/6_3.pdf new file mode 100644 index 0000000..7a4cdd3 Binary files /dev/null and b/hw5/6_3.pdf differ diff --git a/hw5/6_7.pdf b/hw5/6_7.pdf new file mode 100644 index 0000000..61ff086 Binary files /dev/null and b/hw5/6_7.pdf differ diff --git a/hw5/6_9.pdf b/hw5/6_9.pdf new file mode 100644 index 0000000..34fa56e Binary files /dev/null and b/hw5/6_9.pdf differ diff --git a/hw5/hw5.pdf b/hw5/hw5.pdf new file mode 100644 index 0000000..46fd987 Binary files /dev/null and b/hw5/hw5.pdf differ diff --git a/hw5/matlab/1_a_rl.png b/hw5/matlab/1_a_rl.png new file mode 100644 index 0000000..46fa0d8 Binary files /dev/null and b/hw5/matlab/1_a_rl.png differ diff --git a/hw5/matlab/1_b_rl.png b/hw5/matlab/1_b_rl.png new file mode 100644 index 0000000..712f8e9 Binary files /dev/null and b/hw5/matlab/1_b_rl.png differ diff --git a/hw5/matlab/1_c_rl.png b/hw5/matlab/1_c_rl.png new file mode 100644 index 0000000..080d935 Binary files /dev/null and b/hw5/matlab/1_c_rl.png differ diff --git a/hw5/matlab/2_1.png b/hw5/matlab/2_1.png new file mode 100644 index 0000000..62b4c1f Binary files /dev/null and b/hw5/matlab/2_1.png differ diff --git a/hw5/matlab/2_2.png b/hw5/matlab/2_2.png new file mode 100644 index 0000000..c857a66 Binary files /dev/null and b/hw5/matlab/2_2.png differ diff --git a/hw5/matlab/2_3.png b/hw5/matlab/2_3.png new file mode 100644 index 0000000..ae49066 Binary files /dev/null and b/hw5/matlab/2_3.png differ diff --git a/hw5/matlab/2_4.png b/hw5/matlab/2_4.png new file mode 100644 index 0000000..5b9d32a Binary files /dev/null and b/hw5/matlab/2_4.png differ diff --git a/hw5/matlab/mag and phase.pdf b/hw5/matlab/mag and phase.pdf new file mode 100644 index 0000000..96b4393 Binary files /dev/null and b/hw5/matlab/mag and phase.pdf differ diff --git a/hw5/matlab/mag.png b/hw5/matlab/mag.png new file mode 100644 index 0000000..a4fd1de Binary files /dev/null and b/hw5/matlab/mag.png differ diff --git a/hw5/matlab/phase.png b/hw5/matlab/phase.png new file mode 100644 index 0000000..397511d Binary files /dev/null and b/hw5/matlab/phase.png differ diff --git a/hw5/matlab/whole2.pdf b/hw5/matlab/whole2.pdf new file mode 100644 index 0000000..d6b9af2 Binary files /dev/null and b/hw5/matlab/whole2.pdf differ -- cgit v1.2.3