当前位置: 首页 > news >正文 策划方案网站长沙seo优化 news 2025/10/26 18:28:11 策划方案网站,长沙seo优化,crm客户关系管理平台,张家界做旅游网站参考来源#xff1a; 维基百科#xff1a;https://en.wikipedia.org/wiki/Time_complexity 1 什么是时间复杂度#xff1f; 时间复杂度 定性描述了算法的运行时间。#xff08;并不是表示解决一个问题花了多少时间#xff0c;而是描述问题规模扩大与算法运行时间增加的…参考来源 维基百科https://en.wikipedia.org/wiki/Time_complexity 1 什么是时间复杂度 时间复杂度 定性描述了算法的运行时间。并不是表示解决一个问题花了多少时间而是描述问题规模扩大与算法运行时间增加的关系 常见的时间复杂度有 常数时间O(1)如访问数组中的单个元素 对数时间O(log n)如二分搜索 线性时间O(n)如对所有元素的求和 准线性时间O(nlogn)如快排算法 多项式时间 为常数 1.1 多项式时间 An algorithm is said to be of polynomial time if its running time is upper bounded by a polynomial expression in the size of the input for the algorithm. 1.1.1 强多项式时间和弱多项式时间 Strongly polynomial time is defined in the arithmetic model of computation. In this model of computation the basic arithmetic operations (addition, subtraction, multiplication, division, and comparison) take a unit time step to perform, regardless of the sizes of the operands. The algorithm runs in strongly polynomial time if the number of operations in the arithmetic model of computation is bounded by a polynomial in the number of integers in the input instance; andthe space used by the algorithm is bounded by a polynomial in the size of the input. An algorithm which runs in polynomial time but which is not strongly polynomial is said to run in weakly polynomial time. 强多项式时间算法时间复杂度不会因输入数据的大小改变而与输入数据的结构复杂度有关。 1.2 非多项式时间 1.2.1 指数时间 1.2.2 阶乘时间 1.2.3 伪多项式时间 算法的时间复杂度是关于输入数据的大小的多项式时间却是输入数据长度的指数时间。如素数的检测。 2 什么是问题 P所有可以由一个确定型图灵机在多项式时间内解决的问题。 2.1 NP NP所有可以在多项式时间内验证它的解是否正确的问题/可以在非确定型图灵机上在多项式时间内解决的问题。 2.2 NPC NP-Complete一个决定性问题A若是NPC则表示它对NP是完备的1、它是一个NP问题2、其他属于NP的问题都可以多项式时间内归约成它。 只要任意一个NPC问题找到了多项式时间算法那么NP问题都可以多项式时间内解决即PNP。但目前NPC大多只有指数或者阶乘复杂度的算法 or 伪多项式时间算法。 2.3 NPH NP-HardA若是NP-Hard其他属于NP的问题都可以在多项式时间内归约成它。 2.4 NPC问题的相互推导 3 算法复杂性分析 3.1 时间复杂度 一般算法的每次运行输入不同带来的具体复杂度也不同因此考虑算法在最坏、最好、平均情况下的时间复杂度其中最坏复杂度比较有实践价值。 而对于类似3N^24NlogN7此类复杂度当时3N^2称为其渐进复杂性。因此可以看出比较两个算法效率时只要关心渐进复杂性的阶就可以引入渐进意义下的符号. O存在常数C和自然数N_0使得NN_0时有f(N)Cg(N)则称f(N)在N充分大时有上界且g(N)是它的一个上界。f(N)O(g(n)) 存在常数C和自然数N_0使得NN_0时有f(N)Cg(N)则称f(N)在N充分大时有下界且g(N)是它的一个下界。f(N)\Omega(g(n)) f(N)O(g(n)) f(N)\Omega(g(n)) 同阶 o给定任意都存在正整数N_0使得NN_0时有f(N)/g(N). 3.2 空间复杂度 文章转载自: http://www.morning.xpqsk.cn.gov.cn.xpqsk.cn http://www.morning.tnfyj.cn.gov.cn.tnfyj.cn http://www.morning.yckwt.cn.gov.cn.yckwt.cn http://www.morning.cmzgt.cn.gov.cn.cmzgt.cn http://www.morning.lnbcg.cn.gov.cn.lnbcg.cn http://www.morning.rkmhp.cn.gov.cn.rkmhp.cn http://www.morning.fbjnr.cn.gov.cn.fbjnr.cn http://www.morning.bhpjc.cn.gov.cn.bhpjc.cn http://www.morning.cjqcx.cn.gov.cn.cjqcx.cn http://www.morning.knsmh.cn.gov.cn.knsmh.cn http://www.morning.brrxz.cn.gov.cn.brrxz.cn http://www.morning.ymhjb.cn.gov.cn.ymhjb.cn http://www.morning.tndhm.cn.gov.cn.tndhm.cn http://www.morning.sfzwm.cn.gov.cn.sfzwm.cn http://www.morning.dgwrz.cn.gov.cn.dgwrz.cn http://www.morning.rfrxt.cn.gov.cn.rfrxt.cn http://www.morning.hfnbr.cn.gov.cn.hfnbr.cn http://www.morning.kjgdm.cn.gov.cn.kjgdm.cn http://www.morning.hxxyp.cn.gov.cn.hxxyp.cn http://www.morning.lqlc.cn.gov.cn.lqlc.cn http://www.morning.smxrx.cn.gov.cn.smxrx.cn http://www.morning.rdnpg.cn.gov.cn.rdnpg.cn http://www.morning.sjftk.cn.gov.cn.sjftk.cn http://www.morning.jwtjf.cn.gov.cn.jwtjf.cn http://www.morning.ubpsa.cn.gov.cn.ubpsa.cn http://www.morning.smdnl.cn.gov.cn.smdnl.cn http://www.morning.bhjyh.cn.gov.cn.bhjyh.cn http://www.morning.knpmj.cn.gov.cn.knpmj.cn http://www.morning.pswzc.cn.gov.cn.pswzc.cn http://www.morning.duqianw.com.gov.cn.duqianw.com http://www.morning.dwgcx.cn.gov.cn.dwgcx.cn http://www.morning.jgnst.cn.gov.cn.jgnst.cn http://www.morning.mtxrq.cn.gov.cn.mtxrq.cn http://www.morning.xqkcs.cn.gov.cn.xqkcs.cn http://www.morning.cfnsn.cn.gov.cn.cfnsn.cn http://www.morning.bgygx.cn.gov.cn.bgygx.cn http://www.morning.lonlie.com.gov.cn.lonlie.com http://www.morning.yhywx.cn.gov.cn.yhywx.cn http://www.morning.gnzsd.cn.gov.cn.gnzsd.cn http://www.morning.hqllx.cn.gov.cn.hqllx.cn http://www.morning.lekbiao.com.gov.cn.lekbiao.com http://www.morning.mfrb.cn.gov.cn.mfrb.cn http://www.morning.fmrwl.cn.gov.cn.fmrwl.cn http://www.morning.mbrbk.cn.gov.cn.mbrbk.cn http://www.morning.ykwbx.cn.gov.cn.ykwbx.cn http://www.morning.nhzzn.cn.gov.cn.nhzzn.cn http://www.morning.tpqrc.cn.gov.cn.tpqrc.cn http://www.morning.wdqhg.cn.gov.cn.wdqhg.cn http://www.morning.ttvtv.cn.gov.cn.ttvtv.cn http://www.morning.drwpn.cn.gov.cn.drwpn.cn http://www.morning.yppln.cn.gov.cn.yppln.cn http://www.morning.xphcg.cn.gov.cn.xphcg.cn http://www.morning.jgttx.cn.gov.cn.jgttx.cn http://www.morning.tkfnp.cn.gov.cn.tkfnp.cn http://www.morning.wqbzt.cn.gov.cn.wqbzt.cn http://www.morning.smyxl.cn.gov.cn.smyxl.cn http://www.morning.mgbcf.cn.gov.cn.mgbcf.cn http://www.morning.xtlty.cn.gov.cn.xtlty.cn http://www.morning.xrtsx.cn.gov.cn.xrtsx.cn http://www.morning.kjdxh.cn.gov.cn.kjdxh.cn http://www.morning.ksggl.cn.gov.cn.ksggl.cn http://www.morning.grqlc.cn.gov.cn.grqlc.cn http://www.morning.rycd.cn.gov.cn.rycd.cn http://www.morning.mjats.com.gov.cn.mjats.com http://www.morning.tfpmf.cn.gov.cn.tfpmf.cn http://www.morning.rcww.cn.gov.cn.rcww.cn http://www.morning.mpsnb.cn.gov.cn.mpsnb.cn http://www.morning.dgsx.cn.gov.cn.dgsx.cn http://www.morning.jyzqn.cn.gov.cn.jyzqn.cn http://www.morning.haibuli.com.gov.cn.haibuli.com http://www.morning.xxrwp.cn.gov.cn.xxrwp.cn http://www.morning.bppml.cn.gov.cn.bppml.cn http://www.morning.jnzfs.cn.gov.cn.jnzfs.cn http://www.morning.lmhh.cn.gov.cn.lmhh.cn http://www.morning.btwrj.cn.gov.cn.btwrj.cn http://www.morning.fpjxs.cn.gov.cn.fpjxs.cn http://www.morning.hxlch.cn.gov.cn.hxlch.cn http://www.morning.khtjn.cn.gov.cn.khtjn.cn http://www.morning.wanjia-sd.com.gov.cn.wanjia-sd.com http://www.morning.gnjtg.cn.gov.cn.gnjtg.cn 查看全文 http://www.tj-hxxt.cn/news/251698.html 相关文章: 电影网站如何做采集qq企业邮箱注册申请 给公司做网站要多少钱网站建设费用申报 安阳百度网站制作多少钱色盲怎么治疗 模板的网站都有哪些内容房产信息网官方 企业做网站需要注意什么问题建建建设网站 北京企业响应式网站建设北京做推广的公司 创建网站代码是什么情况好的h5网站模板 南京做网站的公司排名正在运营的网站被注销备案怎么办 dnf免做卡网站wordpress 更改首页 大红门做网站的公司帝国网站管理系统前台 庄辉个人网站建设教学seo发包技术教程 网站入门晋中网络推广 自己做音乐网站挣钱吗广州建站平台哪家好 消防设备网站建设私有云可以建设网站 团购网站 seo大连做网站优化 wordpress文章编辑器路径seo是什么意思 简洁的网站如何做网站百科 微信手机官方网站wordpress 后台主题 wordpress付费插件网站知名电子商务网站有哪些 设计师培训大纲宁波seo超级外链工具 番禺制作网站系统网页游戏网站大全突袭 自己学习建设网站江苏建设教育培训网 用手机怎样制作网站浪味仙儿 wordpress 自己做的网站怎么改背景图高级感ppt模板免费 如何寻找建设网站的公司做网站推广需要做什么 企业网站建设需要提供什么内容天津网站制作价格 网站免费正能量软件下载视频适合一人开店的加盟店 海南定安建设局网站医药公司网站建设方案 怎么制作网站的链接宏网站备案域名购买 网站开发开发需求文档无锡谁做网站好