摘要: import numpy as np import pandas as pd import sympy as sp sp.init_printing(use_unicode=True) import matplotlib.pyplot as plt plt.rcParams['font.sans-s 阅读全文
posted @ 2024-10-15 13:31 唐锦珅 阅读(0) 评论(0) 推荐(0) 编辑
摘要: import numpy as np import pandas as pd import sympy as sp sp.init_printing(use_unicode=True) import matplotlib.pyplot as plt plt.rcParams['font.sans-s 阅读全文
posted @ 2024-10-15 13:29 唐锦珅 阅读(0) 评论(0) 推荐(0) 编辑
摘要: from scipy.optimize import linprog c=[0,0,3,2] A=[[-1,-1,0,0],[0,0,-1,-1],[3,0,2,0],[0,3,0,2],[100,90,80,70]] b=[[-30],[-30],[120],[48],[10000]] LB=[0 阅读全文
posted @ 2024-10-15 11:47 唐锦珅 阅读(0) 评论(0) 推荐(0) 编辑
摘要: import numpy as np import math from scipy.optimize import minimize, Bounds def func(x): return sum(math.sqrt(x[i]) for i in range(100)) def con(x): re 阅读全文
posted @ 2024-10-15 11:45 唐锦珅 阅读(0) 评论(0) 推荐(0) 编辑