上一页 1 2 3 4 5 6 ··· 12 下一页
摘要: python函数图形1绘制; import matplotlib.pyplot as plt import numpy as np x = np.arange(0, 10, 0.0001) y1 = x ** 2 y2 = np.cos(x * 2) y3 = y1 * y2 plt.plot(x, 阅读全文
posted @ 2024-06-03 22:29 catsahsy 阅读(3) 评论(0) 推荐(0) 编辑
摘要: python豆瓣图书评论数据分析与可视化; import re from collections import Counter import requests from lxml import etree import pandas as pd import jieba import matplot 阅读全文
posted @ 2024-05-31 21:31 catsahsy 阅读(3) 评论(0) 推荐(0) 编辑
摘要: MATLAB最优化工具箱的使用 % 定义二次项系数矩阵 H 和线性项系数向量 f H = 2 * eye(3); % H 是单位矩阵的 2 倍,因为目标函数是 x_1^2 + x_2^2 + x_3^2 f = [0; 0; 0]; % f 为零向量 % 定义等式约束矩阵 Aeq 和向量 beq A 阅读全文
posted @ 2024-05-30 22:01 catsahsy 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 共轭梯度法程序设计 function [x, k] = fr_conjugate_gradient() % 初始猜测 x = [1; 2; 2; 2]; % 计算初始梯度 g = grad_f(x); % 初始搜索方向 d = -g; % 终止准则的容差 tol = 1e-6; % 最大迭代次数 m 阅读全文
posted @ 2024-05-29 22:48 catsahsy 阅读(2) 评论(0) 推荐(0) 编辑
摘要: 刷题 阅读全文
posted @ 2024-05-28 22:23 catsahsy 阅读(2) 评论(0) 推荐(0) 编辑
摘要: 刷英语六级题 阅读全文
posted @ 2024-05-27 22:35 catsahsy 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 看黑马程序员 阅读全文
posted @ 2024-05-24 22:56 catsahsy 阅读(1) 评论(0) 推荐(0) 编辑
摘要: Newton法程序设计 function [x_opt, f_opt, iterations] = newtons_method(f, gradient, hessian, x0, epsilon) x = x0; iterations = 0; while norm(gradient(x)) > 阅读全文
posted @ 2024-05-23 22:18 catsahsy 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 工程数学 黄金分割法 function [xmin, fmin, iter] = golds(func, a, b, tol) % func: 要优化的函数句柄 % a, b: 初始搜索区间的下界和上界 % tol: 精度要求 % 黄金分割比例 phi = (sqrt(5) - 1) / 2; c1 阅读全文
posted @ 2024-05-22 20:22 catsahsy 阅读(3) 评论(0) 推荐(0) 编辑
摘要: python 中国大学排名数据分析与可视化; import requests from bs4 import BeautifulSoup as bs import pandas as pd from matplotlib import pyplot as plt def get_rank(url): 阅读全文
posted @ 2024-05-21 23:03 catsahsy 阅读(1) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 12 下一页