自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(36)
  • 资源 (2)
  • 收藏
  • 关注

原创 K最近邻算法-k-nearest neighbors algorithm

K最近邻算法(k-nearest neighbors algorithm)WIKIIn pattern recognition, the k-nearest neighbors algorithm (k-NN) is a non-parametric method used for classification and regression.[1] In both cases, the i...

2018-10-26 10:00:00 526

原创 动态规划-Dynamic planning

动态规划(dynamic planning)WIKIDynamic programming is both a mathematical optimization method and a computer programming method.In both contexts it refers to simplifying a complicated problem by breaki...

2018-10-26 09:59:46 475

原创 贪婪算法-Greedy algorithm

贪婪算法(greedy algorithm)WIKIA greedy algorithm is an algorithmic paradigm that follows the problem solving heuristic of making the locally optimal choice at each stage[1] with the intent of finding ...

2018-10-26 09:59:37 4802

原创 广度优先搜索-Breadth-first search

广度优先搜索(Breadth-first seaech)WIKIBreadth-first search (BFS) is an algorithm for traversing or searching tree or graph data structures. It starts at the tree root (or some arbitrary node of a graph,...

2018-10-26 09:59:27 292

原创 散列表-Hash table

散列函数(hash function)WIKIA hash function is any function that can be used to map data of arbitrary size to data of a fixed size.定义无论输入什么数据,输出一个数值工作原理 散列函数总是将同样的输入映射到相同的索引 散列函数将不同的输入映...

2018-10-26 09:59:18 158

原创 快速排序-Quicksort

分而治之(divide and conquer,D&C)WIKIIn computer science, divide and conquer is an algorithm design paradigm based on multi-branched recursion. A divide and conquer algorithm works by recursively b...

2018-10-26 09:59:02 204

原创 递归-Recursion

递归(recursion)WIKIRecursion in computer science is a method where the solution to a problem depends on solutions to smaller instances of the same problem (as opposed to iteration).示例:找钥匙方法一:Whi...

2018-10-25 20:59:47 183

原创 二分查找-Binary search

二分查找WIKIIn computer science, binary search, also known as half-interval search,[1] logarithmic search,[2] or binary chop,[3] is a search algorithm that finds the position of a target value within ...

2018-10-25 20:57:48 150

原创 选择排序-Selection sort

选择排序复杂度:O(n2)WIKIIn computer science, selection sort is a sorting algorithm, specifically an in-place comparison sort.工作原理在一个长度为N的无序数组中,在第一趟遍历N个数据,找出其中最小的数值与第一个元素交换,第二趟遍历剩下的N-1个数据,找出其中最小的数...

2018-10-25 20:56:46 132

原创 数组和链表-Array and Linked list

数组和链表数组数组必须相连若超出预留空间(添加元素):预留更多空间缺点: 用不上,浪费内存 超出内存要转移 链表链表中的元素可以存储在内存任何地方,链表的每个元素都存储了下一个元素的地址,从而使一系列随机的内存地址串在一起缺点: 读取元素效率低:从第一个开始读取   数组 链表 ...

2018-10-25 20:55:21 164

原创 EM算法及其推广-expectation maximization algorithm

WIKIIn statistics, an expectation–maximization (EM) algorithm is an iterative method to find maximum likelihood or maximum a posteriori (MAP) estimates of parameters in statistical models, where the...

2018-10-25 09:01:45 207

原创 提升算法-boosting algorithm

WIKIBoosting is a machine learning ensemble meta-algorithm for primarily reducing bias, and also variance[1] in supervised learning, and a family of machine learning algorithms that convert weak lea...

2018-10-25 09:01:32 767

原创 支持向量机-support vector machines

WIKIIn machine learning, support vector machines (SVMs, also support vector networks[1]) are supervised learning models with associated learning algorithms that analyze data used for classification ...

2018-10-25 09:01:20 380

原创 逻辑斯谛回归与最大熵模型-logistic regression and maximum entropy model

Logistic回归模型WIKIIn statistics, the logistic model (or logit model) is a statistical model that is usually taken to apply to a binary dependent variable.Logistic分布曲线在中心附近增长速度较快,在两端增长速度较慢B...

2018-10-25 09:01:05 246 1

原创 决策树-decision tree

WIKIDecision tree learning uses a decision tree (as a predictive model) to go from observations about an item (represented in the branches) to conclusions about the item's target value (represented ...

2018-10-25 09:00:52 255 1

原创 贝叶斯估计-naive Bayes

WIKIIn machine learning, naive Bayes classifiers are a family of simple "probabilistic classifiers" based on applying Bayes' theorem with strong (naive) independenceassumptions between the features....

2018-10-25 09:00:29 266 1

原创 K近邻法-k-nearest neighbor,KNN

WIKIIn pattern recognition, the k-nearest neighbors algorithm (k-NN) is a non-parametric method used for classification and regression.[1] In both cases, the input consists of the k closest training...

2018-10-24 20:46:07 462

原创 感知机(Perceptron)

WIKIIn machine learning, the perceptron is an algorithm for supervised learning of binary classifiers (functions that can decide whether an input, represented by a vector of numbers, belongs to some...

2018-10-24 20:45:18 524

原创 20. Valid Parentheses

"""Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid.An input string is valid if:Open brackets must be closed by the same type...

2018-10-24 19:43:12 88

原创 14. Longest Common Prefix

"""Write a function to find the longest common prefix string amongst an array of strings.If there is no common prefix, return an empty string "".Example 1:Input: ["flower","flow","flight"]Out.

2018-10-24 19:41:30 92

原创 13. Roman to Integer

"""Roman numerals are represented by seven different symbols: I, V, X, L, C, D and M.Symbol ValueI 1V 5X 10L 50C 100D ...

2018-10-24 19:39:41 110

原创 9. Palindrome Number

"""Determine whether an integer is a palindrome. An integer is a palindrome when it reads the same backward as forward.Example 1:Input: 121Output: trueExample 2:Input: -121Output: falseExp...

2018-10-24 19:35:49 80

原创 7. Reverse Integer

"""Given a 32-bit signed integer, reverse digits of an integer.Example 1:Input: 123Output: 321Example 2:Input: -123Output: -321Example 3:Input: 120Output: 21Note:Assume we are dealing...

2018-10-24 19:32:39 74

原创 1.Two Sum

class Solution(object): def twoSum(self, nums, target): """ :type nums: List[int] :type target: int :rtype: List[int] """ length=len(nums) ...

2018-10-24 19:28:05 72

原创 Python self是什么

类变量和实例变量 类变量可以被所有的实例使用 所有实例得到的类变量相同 实例变量属于实例 Class SomeClass:    variable_1 = “ This is a class variable”    variable_2 = 100    #this is also a class variable.     def __init__...

2018-10-24 16:11:45 624

原创 非支配解Non-dominated solution/帕累托解Pareto set

当目标函数处于冲突状态时,就不会存在使所有目标函数同时达到最大或最小的最优解,于是我们只能寻求非劣解(又称非支配解或帕累托解) 可以通过定义评价函数进一步最Pareto set进行评价,得到在Pareto set的最佳满意解  ...

2018-10-21 10:55:46 13291

原创 进化计算/进化算法×传统数学优化方法×机器学习

进化算法VS传统数学优化方法 进化算法是基于种群的搜索 进化算法是随机的搜索算法,不需要梯度,不需要解析的目标函数  进化算法优势 适用于没有解析目标函数和无法得到目标函数梯度信息的优化问题 基于种群,一次运行得到一组解,so求解多目标优化问题具有优势 随机搜索,so搜索全局最优解能力比较强 并行计算 适用于解决同时有整数和连续...

2018-10-21 10:54:53 5165

原创 2018年研究生数学建模竞赛B题(数模竞赛第二题思路)

Q1:根据目标函数建立通信网络(城市对直连)-网络生成问题目标函数:城市A人口*城市B人口*城市对连边容量约束: 城市对直连 连边最大距离约束 所有城市连入网络 连边数量约束 A:遗传算法求解: 初始化:随机生成K条连边的染色体(后面会变异,出现异常值) 适应度计算:对每条染色体判断进行连边数量惩罚、城市未连接惩罚、距离惩罚,计算...

2018-09-28 16:07:34 5526

原创 Kaggle Titanic

https://github.com/hanyunxuan/Kaggle/blob/master/Titanic_hanyunxuan.ipynb

2018-07-03 20:45:47 115

转载 python def __init__

用途:初始化实例的值.这些值一般要供其他方法调用要求:只初始化值,不要返回值(就是别用return)class Parent: classAttr=100 def __init__(self,x): self.x=x+Parent.classAttr X=Parent(2)print X.x

2017-11-01 11:37:23 1214

转载 python assert

1、assert语句用来声明某个条件是真的。2、如果你非常确信某个你使用的列表中至少有一个元素,而你想要检验这一点,并且在它非真的时候引发一个错误,那么assert语句是应用在这种情形下的理想语句。3、当assert语句失败的时候,会引发一AssertionError。

2017-11-01 11:35:16 131

转载 遗传算法

https://www.zhihu.com/question/23293449

2017-10-21 20:31:38 204

原创 matlab大规模交叉节点判断

Q:给出所有点连接关系(矩阵形式)及节点坐标,找出所有交叉节点idea:1缩小范围四点判断(a-b,c-d),排除①a和b的经度(纬度)最大值<c和d的经度(纬度)最小值②a和b的经度(纬度)最小值>c和d的经度(纬度)最大值的情况basic knowledge:经度东>西,纬度北>南如图,经度:max(a,b)<min(c,d),不可能相交2...

2017-10-21 20:12:54 678

原创 matlab 大量数据写入excel

excel 2003 最大65536*256excel 2007 和 2010 最大 1048576*16384 xlswrite('Output.xlsx',Data(1:1000000,1),1,'A1:A1000000');将Data的第一行1:1000000列写入Excel名为Output的sheet1的A1:A1000000

2017-10-21 20:12:10 12451

原创 matlab cplex使用

安装cplex安装yalmip http://blog.csdn.net/xixi_0921/article/details/47981869示例% value:5 constraint:2% max z=2x1+x2+4x3+3x4+x5% 2x2+x3+4x4+2x5% 3x1+4x2+5x3-x4-x5% x1,x2f=-[2 1 4 3 1]

2017-10-20 19:49:49 15265 1

转载 CSDN博客积分规则

博客积分是CSDN对用户努力的认可和奖励,也是衡量博客水平的重要标准。博客等级也将由博客积分唯一决定。积分规则具体如下:1、每发布一篇原创或者翻译文章:可获得10分;2、每发布一篇转载文章:可获得2分;3、博主的文章每被评论一次:可获得1分;4、每发表一次评论:可获得1分(自己给自己评论、博主回复评论不获得积分);5、博文阅读次数每超过100次:可获得1分,阅读加分最高加到100分,即文章

2017-09-09 15:42:24 233

NSGA-Ⅲ算法 matlab

多目标求解算法。

2019-04-08

读取xls、xlsx文件所需jar包

读取xls、xlsx文件所需jar包..........................................................................................................................................................................................................................................................

2017-09-09

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除