gpt4 book ai didi

algorithm - 对于某个常数 c,阶乘(floor(log(n)))是大 O(n ^ c)吗?

转载 作者:塔克拉玛干 更新时间:2023-11-03 04:22:23 28 4
gpt4 key购买 nike

谁能解释一下阶乘(floor(log(n)))是否是某个常量 c 的大 O(n^c)?以及,如何证明以上答案?

最佳答案

没有。 Asymptotically, we have

floor(log n)! = Ω(((log n)/3)^log n)
= Ω(e^(log((log n) / 3)) * log n)
= Ω(n^(log log n - log 3))

指数 log log n - log 3 显然不在 O(1) 中。

关于algorithm - 对于某个常数 c,阶乘(floor(log(n)))是大 O(n ^ c)吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35673303/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com