import numpy as np
import matplotlib.pyplot as plt
# Параметры
x = np.linspace(0, 20, 100)
y_nonlinear = 2 * (x**2) + 3 * x + 2 * x - 4 * (x - 4) - 6 * ((x - 2)**2)
y_linear = 2 * (x - 12) + 3 * (x - 12) + 2 * (x - 12) # Линеаризованное уравнение
# Построение графиков
plt.figure(figsize=(10, 5))
plt.plot(x, y_nonlinear, label='Нелинейная характеристика', color='blue')
plt.plot(x, y_linear, label='Линеаризованная характеристика', color='red', linestyle='--')
plt.title('Нелинейная и линеаризованная статические характеристики')
plt.xlabel('x')
plt.ylabel('y')
plt.legend()
plt.grid()
plt.show()
aW1wb3J0IG51bXB5IGFzIG5wCmltcG9ydCBtYXRwbG90bGliLnB5cGxvdCBhcyBwbHQKCiMg0J/QsNGA0LDQvNC10YLRgNGLCnggPSBucC5saW5zcGFjZSgwLCAyMCwgMTAwKQp5X25vbmxpbmVhciA9IDIgKiAoeCoqMikgKyAzICogeCArIDIgKiB4IC0gNCAqICh4IC0gNCkgLSA2ICogKCh4IC0gMikqKjIpCnlfbGluZWFyID0gMiAqICh4IC0gMTIpICsgMyAqICh4IC0gMTIpICsgMiAqICh4IC0gMTIpICAjINCb0LjQvdC10LDRgNC40LfQvtCy0LDQvdC90L7QtSDRg9GA0LDQstC90LXQvdC40LUKCiMg0J/QvtGB0YLRgNC+0LXQvdC40LUg0LPRgNCw0YTQuNC60L7QsgpwbHQuZmlndXJlKGZpZ3NpemU9KDEwLCA1KSkKcGx0LnBsb3QoeCwgeV9ub25saW5lYXIsIGxhYmVsPSfQndC10LvQuNC90LXQudC90LDRjyDRhdCw0YDQsNC60YLQtdGA0LjRgdGC0LjQutCwJywgY29sb3I9J2JsdWUnKQpwbHQucGxvdCh4LCB5X2xpbmVhciwgbGFiZWw9J9Cb0LjQvdC10LDRgNC40LfQvtCy0LDQvdC90LDRjyDRhdCw0YDQsNC60YLQtdGA0LjRgdGC0LjQutCwJywgY29sb3I9J3JlZCcsIGxpbmVzdHlsZT0nLS0nKQpwbHQudGl0bGUoJ9Cd0LXQu9C40L3QtdC50L3QsNGPINC4INC70LjQvdC10LDRgNC40LfQvtCy0LDQvdC90LDRjyDRgdGC0LDRgtC40YfQtdGB0LrQuNC1INGF0LDRgNCw0LrRgtC10YDQuNGB0YLQuNC60LgnKQpwbHQueGxhYmVsKCd4JykKcGx0LnlsYWJlbCgneScpCnBsdC5sZWdlbmQoKQpwbHQuZ3JpZCgpCnBsdC5zaG93KCkK