A log algorithm typically is one where you cut the size of the problem down by some multiplicative factor.
对数级复杂度的算法就是指,通过一系列常量级步数的操作,可以将问题的规模。
Linear algorithms tend to be things where, at one pass-through, you reduce the problem by a constant amount by one. If you reduce it by two, 1 it's going to be the same thing.
有问题么?,线性复杂度的算法,当进行了一个,常量级步数的操作的时候,将问题的规模缩小了一个。
Why not write the program in a way where you figure out dynamically when the program is run how much memory you need rather than hard coding in two with or within that constant.
为什么不写一个可以动态的方式写那个程序,程序可以动态分配内存,而不是用常量硬编码两个值。
And if you do so, you will end up with 1.312 mega joules per mole for this quantity K.
这样做之后,对于K常量你就能得到2,1。312百万焦耳每摩尔。
The constraint is the constraint of the experiment and the constraint of the experiment is that the enthalpy is constant. So the constraints we have here, is the constant enthalpy.
这个实验的限制,就是焓是常量,所以这里的限制是焓不变,我们考虑的这个过程。
And when we make these comparisons, one thing I want to point out is that we need to keep the constant principle quantum number constant, so we're talking about a certain state, so we could talk about the n equals 2 state, or the n equals 3 state.
当我们做这些比较时,我想指出的一件事是,我们需要保持常量原则,保持量子数是常数,所以我们在讨论一个确定的态时,我们可以谈论n等于2的态,或者n等于3的态。
Let me finish the picture here; here's my demand curve, here's my constant marginal cost at c, and I want to use this picture on the left now to figure out what the monopoly quantity is.
先把图画完,这条是需求曲线,这个是边际成本常量c,下面我们通过左边的图像,来找出垄断产量
The second one is, this multiplicative constant here is 3, in some sense also isn't all that crucial.
我们需要乘的常量是,在某种意义上来说这也不是很重要,对你的程序来说要运行300年。
Second step, hm. That also looks constant, you think? Oh but wait a minute. I'm accessing s.
第二步,恩,看起来也像常量,你认为呢?等等,我在进入这个数组。
Okay, so 1 is a viable answer in some contacts that needs constant time, the same amount of time no matter what.
在需要常量时间的情况下,答案是1,不管怎样,总时间是,相同的。
We have seen log, linear, quadratic, and exponential.
平方级的和指数级复杂度的方法,再说一遍,可能会有些常量。
And then the conversion of joules to electron volts is entry 42. If you multiply those two together you will end up with this quantity.
然后焦耳和电子伏的转换,是在第42个常量,如果你把这两个放一起,你将得到这个数值。
n If you want a literal percent, it's %% and then backslash n.
如果你想要一个百分比常量,就用%%,然后,反斜杠。
Square of the Planck constant times pi mass of the electron.
普朗克常量的平方,乘以π再乘电子的质量。
If you multiply entry 23, which is 13.6 electron volts I will show you what the electron volt is in a few minutes. We will just put it up here prematurely. But that is given in your chart.
如果乘上第23个常量,代表13。6电子伏,接下来我就会向你们说明什么是电子伏,我们先提前把它提出来,但那只是放在你们的图表中。
And as a consequence, access time in the list is constant, which is what I want.
这会占用一些额外的空间,回到问题本身,这么做的话,读取数组的时间就变成常量了。
It is the ratio of the Planck constant to its momentum .
那就是普朗克常量,比上它的动量。
So, and typically, we're not going to worry about those additive constants.
不是那些附加的常量,第二点是。
I have no idea if I'll make it this far or not.
好,里头有一些常量。
First step, constant, right? Nothing to do.
第一步,常量对不对?什么都没做。
We introduced a feature of C called a constant, but how many quizzes did I assume every student has?
我们引入一个C的特性,叫做常量,但是我能假设每个学生做了多少测验呢?
You can actually say big O of 1, big O of 1 being constant time, the same number of steps.
其复杂度为O,表示时间是一个常量,所用的步数是相同的。
It grows as b. The 3 doesn't matter, it's just a constant, it's growing linearly.
它按b来增长,3只是个常量,3没有作用,答案是线性增长的。
With this, if I can assume that accessing the i'th element of a list is constant, then you can't see that the rest of that analysis looks just like the log analysis I did before, and each step, no matter which branch I'm taking, I'm cutting the problem down in half.
读取数组中的第i个元素,是个常量时间的操作的话,我也就能像以前那样得到,这个算法是对数级复杂度的分析,并且每一步不管我选择哪个区间,我都可以把问题的规模缩小一半。
Now. You might look at that and say, well that's just a lot like what we had over here Right? We had some additive constant plus a simpler version of the same problem reduced in size by 1.
现在你可能会看着这个说,这很像我们以前做过的,对不对?我们用一些附加的常量,加上问题的另外一个规模缩小了1的,简化版本来代替这个问题本身。
So we're going to typically also not worry about the multiplicative constants. This factor here.
要乘的常量这个因素太关注,我们真正需要关注的是。
It's a slight misstatement in the sense that these should really be orders of growth.
可能还有些常量,取决于大小。
Don't think so, right? So, what does this suggest? Sorry?
对不起我没听清,常量?哦,常量意味着无论数组的大小?
And since we are not expecting the mass of the particle to change, what we really are saying is the uncertainty in its velocity times the uncertainty in its position is greater than the ratio of the Planck constant divided by 2 pi.
因为我们不期望,粒子质量发生变化,我们说的是,它速度的不确定度,乘以它位置的不确定度,比普朗克常量,除以2除以圆周率要大。
Well, you might say it's constant, right?
你可能说是常量对不对?
应用推荐