摘要:
习题4.4代码 import cvxpy as cp import numpy as np import pandas as pd import sympy as sp sp.init_printing(use_unicode=True) import matplotlib.pyplot as pl 阅读全文
摘要:
习题4.3代码 import cvxpy as cp import numpy as np import matplotlib.pyplot as plt plt.rcParams['font.sans-serif']=['Times New Roman + SimSun + WFM Sans SC 阅读全文
摘要:
习题5.7代码 import cvxpy import cvxpy as cp import numpy as np import pandas as pd from scipy.optimize import minimize import sympy as sp sp.init_printing 阅读全文
摘要:
例题6.11代码 import cvxpy as cp import networkx as nx import numpy as np Adjt = [(1,2,18),(1,5,15),(2,3,20),(2,4,60),(2,5,12), (3,4,30),(3,5,18),(4,6,10), 阅读全文
摘要:
例题6.10代码 import networkx as nx import numpy as np Adjt = [(1,2,20), (1,5,15), (2,3,20), (2,4,60), (2,5,25), (3,4,30), (3,5,18), (5,6,15)] G = nx.Graph 阅读全文
摘要:
习题6.1代码 import numpy as np import pandas as pd import cvxpy as cp import networkx as nx import matplotlib.pyplot as plt plt.rcParams['font.sans-serif' 阅读全文
摘要:
习题6.4代码 \import numpy as np import pandas as pd import cvxpy as cp import networkx as nx import matplotlib.pyplot as plt plt.rcParams['font.sans-serif 阅读全文
摘要:
习题6.3代码 import numpy as np import pandas as pd import cvxpy as cp import networkx as nx import matplotlib.pyplot as plt plt.rcParams['font.sans-serif' 阅读全文