diff --git a/1111.png b/1111.png new file mode 100644 index 000000000..be3b89c3b Binary files /dev/null and b/1111.png differ diff --git a/ar_1.jpg b/ar_1.jpg new file mode 100644 index 000000000..9a470cb32 Binary files /dev/null and b/ar_1.jpg differ diff --git a/dadada.png b/dadada.png new file mode 100644 index 000000000..67c8c9374 Binary files /dev/null and b/dadada.png differ diff --git a/fig_11.jpg b/fig_11.jpg new file mode 100644 index 000000000..fb4bae219 Binary files /dev/null and b/fig_11.jpg differ diff --git a/fig_121.jpg b/fig_121.jpg new file mode 100644 index 000000000..09d28b508 Binary files /dev/null and b/fig_121.jpg differ diff --git a/fig_3.png b/fig_3.png new file mode 100644 index 000000000..a33a33757 Binary files /dev/null and b/fig_3.png differ diff --git a/fig_33.png b/fig_33.png new file mode 100644 index 000000000..effe42a66 Binary files /dev/null and b/fig_33.png differ diff --git a/fig_4.png b/fig_4.png new file mode 100644 index 000000000..9a82f1eca Binary files /dev/null and b/fig_4.png differ diff --git a/fig_el_1.jpg b/fig_el_1.jpg new file mode 100644 index 000000000..cbfaa32e5 Binary files /dev/null and b/fig_el_1.jpg differ diff --git a/fig_lissag_1.jpg b/fig_lissag_1.jpg new file mode 100644 index 000000000..ccb42134d Binary files /dev/null and b/fig_lissag_1.jpg differ diff --git a/gesl_1.jpg b/gesl_1.jpg new file mode 100644 index 000000000..e7f683beb Binary files /dev/null and b/gesl_1.jpg differ diff --git a/gip_33.png b/gip_33.png new file mode 100644 index 000000000..2a4f12a0a Binary files /dev/null and b/gip_33.png differ diff --git a/hw/1.py b/hw/1.py new file mode 100644 index 000000000..11594caf6 --- /dev/null +++ b/hw/1.py @@ -0,0 +1,4 @@ +import matplotlib.pyplot as plt + +plt.plot([5,1, 1, 5,5], [1,1, 5, 5,1]) +plt.savefig('fig_11.jpg') \ No newline at end of file diff --git a/hw/2.py b/hw/2.py new file mode 100644 index 000000000..8ac90e565 --- /dev/null +++ b/hw/2.py @@ -0,0 +1,13 @@ +import matplotlib.pyplot as plt +import numpy as np + + +def giperbola_plotter(x_min, x_max, N): + + x = np.linspace(x_min, x_max, N) + y = 1/(x+0.1) + + plt.plot(x, y, label='my giperbola') + plt.savefig('gip_33.png') + plt.close() +giperbola_plotter(-50, 50,10) \ No newline at end of file diff --git a/hw/3.py b/hw/3.py new file mode 100644 index 000000000..0d3d3106d --- /dev/null +++ b/hw/3.py @@ -0,0 +1,22 @@ +import matplotlib.pyplot as plt +from matplotlib.patches import Ellipse + +def circle_plotter(a=1,b=0.5): + + x = np.arange(-2*a, 2*b, 14) + y = np.arange(-2*a, 2*b, 16) + + # Переход к неявнозаданным координатам + X, Y = np.meshgrid(x, y) + + fxy = X**2 + Y**2 - radius**2 # Уравнение окружности + + # Команда рисования + plt.contour(X, Y, fxy, levels=[0]) + plt.axis('equal') + + plt.savefig('fig_4.png') + + +if __name__ == '__main__': + circle_plotter() \ No newline at end of file diff --git a/hw/4.py b/hw/4.py new file mode 100644 index 000000000..780b0e437 --- /dev/null +++ b/hw/4.py @@ -0,0 +1,14 @@ +import matplotlib.pyplot as plt +import numpy as np +def logarifm_spir(b): + phi=np.arange(0,8*np.pi,0.01) + r=np.exp(b*phi) + + x=r*np.cos(phi) + y=r*np.sin(phi) + + plt.plot(x,y) + plt.savefig('fig_121.jpg') +logarifm_spir(0.11) + + diff --git a/hw/4_2.py b/hw/4_2.py new file mode 100644 index 000000000..3a44ad61b --- /dev/null +++ b/hw/4_2.py @@ -0,0 +1,13 @@ +import matplotlib.pyplot as plt +import numpy as np + +def ar_spir(k): + phi=np.arange(0,8*np.pi,0.01) + r=k*phi + + x=r*np.cos(phi) + y=r*np.sin(phi) + + plt.plot(x,y) + plt.savefig('ar_1.jpg') +ar_spir(0.11) \ No newline at end of file diff --git a/hw/4_3.py b/hw/4_3.py new file mode 100644 index 000000000..a972a1c68 --- /dev/null +++ b/hw/4_3.py @@ -0,0 +1,14 @@ +import matplotlib.pyplot as plt +import numpy as np +def gesl_spir(k): + phi=np.arange(0.01, 8*np.pi,0.01) + r=k/np.sqrt(phi) + + x=r*np.cos(phi) + y=r*np.sin(phi) + + plt.plot(x,y) + plt.axis('equal') + plt.savefig('gesl_1.jpg') + +gesl_spir(1) diff --git a/hw/4_4.py b/hw/4_4.py new file mode 100644 index 000000000..41be1427b --- /dev/null +++ b/hw/4_4.py @@ -0,0 +1,12 @@ +import matplotlib.pyplot as plt +import numpy as np +def rosa_spir(k): + phi=np.arange(0,8*np.pi,0.01) + r=np.sin(k*phi) + + x=r*np.cos(phi) + y=r*np.sin(phi) + + plt.plot(x,y) + plt.savefig('rosa_1.jpg') +rosa_spir(10) \ No newline at end of file diff --git a/hw/dop1.py b/hw/dop1.py new file mode 100644 index 000000000..b502cfd7f --- /dev/null +++ b/hw/dop1.py @@ -0,0 +1,11 @@ +import matplotlib.pyplot as plt +import numpy as np +def fig_lissag(a=1, A=1, B=3,b=2): + t = np.linspace(0, 2 * np.pi, 500) + g=np.pi/2 + x=A*np.sin(a*t+b) + y=B*np.sin(b*t) + plt.plot(x,y) + plt.savefig('fig_lissag_1.jpg') + plt.close +fig_lissag() \ No newline at end of file diff --git a/hw/dop4.py b/hw/dop4.py new file mode 100644 index 000000000..ef31287de --- /dev/null +++ b/hw/dop4.py @@ -0,0 +1,9 @@ +import matplotlib.pyplot as plt +import numpy as np +def stupenka(N): + x=np.arange(0,N+1,0.0005) + y=x//1 + plt.plot(x,y) + plt.savefig('1111.png') + plt.close +stupenka(3) \ No newline at end of file diff --git a/hw/dop_2.py b/hw/dop_2.py new file mode 100644 index 000000000..50c2e8400 --- /dev/null +++ b/hw/dop_2.py @@ -0,0 +1,11 @@ +import matplotlib.pyplot as plt +import numpy as np +def fig_el(p,e): + phi=np.arange(0,8*np.pi,0.01) + r=p/(1+e*np.cos(phi)) + x=r*np.cos(phi) + y=r*np.sin(phi) + plt.plot(x,y) + plt.savefig('fig_el_1.jpg') + plt.close +fig_el(57,0.6) \ No newline at end of file diff --git a/hw/dop_3.py b/hw/dop_3.py new file mode 100644 index 000000000..b2381aeb3 --- /dev/null +++ b/hw/dop_3.py @@ -0,0 +1,9 @@ +import matplotlib.pyplot as plt +import numpy as np +def fig_el(x,a,b): + if x