首页 > 编程语言 > 详细

网易公开课_算法导论_笔记A

时间:2017-03-01 20:42:10      阅读:277      评论:0      收藏:0      [点我收藏+]

http://open.163.com/special/opencourse/algorithms.html

 

个人理解

  渐进分析 is to ignore machine-dependent constants and, instead of the actual running time

       look at the growth of the running time 

  (以下 = 表近似、a = b = c、a与c无直接关联)

  算法复杂度 = 时间复杂度 = 程序执行次数

                     = 以函数表示,保留最高指数,代表算法所需执行次数。其中常数项k,理解为外部固定因素,呈线性关系。(如计算机性能)

    (时间复杂度主要考虑内存的使用,maybe会忽视cpu的执行次数)

  性能 形容词,量词,最为评价的基准,位于考虑最底层。

  weighted average

    Tc( 每种输入运行的时间) * Tp(出现的概率)

  insertion sort,时间复杂度 n^2

    算术级数

      连续整数求和(等差求和)

    theta notation (n^2)

  merge sort,时间复杂度 nlgn

    2叉树并归,长度nlg,宽度n(对n个数进行iteration)

    树的最后一层,不一定满,may是另一个常数

    

 

网易公开课_算法导论_笔记A

原文:http://www.cnblogs.com/banana17/p/6485903.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!