They aren't being lazy, practice is the only way. Take classes you have to do proofs in and look online for class notes and old tests with answers from other colleges that go over proofs.
I'll start off my answer by admitting that as a CS student, I had a really tough time grasping a formal way of thinking, and it's never easy, unless you have a talent for it.
I'm afraid there is no better answer than practice and study.
A formal mathematical and algorithmic way of thinking and visioning problems is a skill which first demands a very deep understanding of the subjects you are dealing with. Second, it requires you have good knowledge of existing proofs. Try to envision yourself as some of the great scientists who came up with the algorithms you are studying. Understand how you would have tried to tackle that specific problem. Then see how they proved the correctness of their algorithm.
I can only recommend the greatest textbook in this subject which is Intro to Algorithms by CLRS. If you go through it from start to finish, including every exercise, you will enhance your skills.
Practice is really the only way, but it can helped along by reading proofs as well. I won't touch on practice because the other answerers have covered everything that I can think of, so I'll just talk about what I mean by reading.
Textbooks are very fond of writing out the "important" proofs. Its very nice, because they often prove very powerful statements, and are really fancy. But just as you shouldn't learn to be a world-class gymnast from day 1 by emulating an Olympian (as in, you'll probably break your spine), you shouldn't read any really big proofs (at first). What I found was helpful was reading smaller proofs, usually from returned homework (I assume you're a student) or occasionally a textbook that wisens up.
The reason why I think reading proofs is helpful is because there are a small set of "tricks" or "ideas" that constitute huge chunks of schoolwork proofs, and even more advanced ones. Data structure qualities and recurrence relations usually involve thinking related to proof by induction, proofs involving computability with finite state machines sometimes use the pigeonhole principle, and more rarely the idea of diagonalization (very infrequent, don't worry about it). And of course, just about every other proof uses proof by contradiction. I'm sure there are other handy tools that have slipped my mind, but I hope you get the idea.
Figuring out when, how, and why you'd approach a problem with one particular method or another is what takes practice and experience. I suggest reading proofs in addition to practice because it can often show you creative ways of using a proving method you've already encountered.
As a final note, try to remember when you first learned to program. How did you get better? Proving things and programming things are not too dissimilar, in my opinion. :)
You get into the mind set for doing mathematical proofs by becoming a mathematician. I don't mean the last statement in a tautological way, but realize that a mathematical proof, as published in a mathematical journal, is something of a rhetorical artifact; i.e., it is a proof because a body of mathematicians agree that it is a proof. Ideally, the arguments in the proof could all be reduced to symbolic logic, but this is not how it is done in practice. The utter failure of computer-generated proofs to do valuable mathematics provides some evidence for this.
I get into the mind set by doing proofs and having them accepted by other mathematicians. I agree with the others that "practice" is essential. You don't do proofs unless you try, try, and try. Often the light dawns slowly.
The best resources are, of course, other mathematicians, and reading proofs. There are very few, if any, who can do true mathematical proofs without being part of the mathematical community.
I'm afraid that "practice" really is the best answer here.
Its very similar to programming: once you get the hang of it, you find patterns which solve problems particularly well, and you can create a picture of the high-level design of novel systems which you've never implemented before. However, neophyte programmers aren't aware of patterns: they hack away at code until they accidentally stumble on some solution which appears to "work".
When you're given a problem to prove, you can usually identify properties ("Do I have a set of distinct objects?", "Am I generating permutations?", "Am I looking to minimize/maximize some value?", etc). Sooner or later, proofs will clump together into vaguely similar group, where techniques used to solve one problem can easily apply to novel variations.
I have no idea. Probably the same way you get good at composing music.
When I try to prove something I'm not following some fixed strategy, I just think about the problem. Then [undefined amount of time] later, my mind returns a result and I jump up to write it down.
But practicing definitely helps. When I started trying to prove extremely simple statements, like DeMorgan's laws, I was completely hopeless. So I sat down and did the fifty or so optional example problems on a worksheet we were given. Now it feels natural to prove something.
Practice and study makes perfect sense, agreed. Some tricks, that I found useful:
Make notes on everything you study (I've tried just to read books -- a lot of material just passes through).
In addition to previous point: do all (or most) proofs by youself, use book/lecture notes as a guide; a lot of proofs contains phrases like "we can see now, that XXX". And XXX is not always trivial conclusion.
Make exercises; for example, in CLRS book there are dozens of exercises. Exercises are good way to get the ideas behind algorithms/correct proofs.
If you want to better understand the internals of algorithm -- consider participating in online programming contests like UVa's.
发布评论
评论(7)
他们并不是懒惰,练习是唯一的方法。参加必须做校样的课程,并在网上查找课堂笔记和旧测试以及其他大学提供的校样答案。
They aren't being lazy, practice is the only way. Take classes you have to do proofs in and look online for class notes and old tests with answers from other colleges that go over proofs.
我首先要承认,作为一名计算机科学学生,我很难掌握正式的思维方式,而且这从来都不是一件容易的事,除非你有这方面的天赋。
恐怕没有比实践和学习更好的答案了。
思考和想象问题的正式数学和算法方式是一项技能,首先需要对您正在处理的主题有非常深入的了解。其次,它要求您对现有证明有很好的了解。尝试将自己想象成一些伟大的科学家,他们提出了您正在研究的算法。了解您将如何尝试解决该特定问题。然后看看他们如何证明他们算法的正确性。
我只能推荐这个主题中最好的教科书,即 CLRS 的算法简介 。如果您从头到尾完成它,包括每一个练习,您将提高您的技能。
I'll start off my answer by admitting that as a CS student, I had a really tough time grasping a formal way of thinking, and it's never easy, unless you have a talent for it.
I'm afraid there is no better answer than practice and study.
A formal mathematical and algorithmic way of thinking and visioning problems is a skill which first demands a very deep understanding of the subjects you are dealing with. Second, it requires you have good knowledge of existing proofs. Try to envision yourself as some of the great scientists who came up with the algorithms you are studying. Understand how you would have tried to tackle that specific problem. Then see how they proved the correctness of their algorithm.
I can only recommend the greatest textbook in this subject which is Intro to Algorithms by CLRS. If you go through it from start to finish, including every exercise, you will enhance your skills.
实践确实是唯一的方法,但阅读证明也能有所帮助。我不会谈论练习,因为其他回答者已经涵盖了我能想到的所有内容,所以我只谈谈我所说的阅读的意思。
教科书很喜欢把“重要”的证明写出来。这非常好,因为它们经常被证明是非常有力的陈述,而且非常奇特。但正如你不应该从第一天起就通过模仿奥运选手来学习成为世界级体操运动员(例如,你可能会折断脊柱),你也不应该阅读任何真正重要的证明(一开始)。我发现阅读较小的校样是有帮助的,通常来自返还的作业(我假设你是一名学生),或者偶尔是一本能让人变得明智的教科书。
我认为阅读校样很有帮助的原因是,有一小部分“技巧”或“想法”构成了大量的作业证明,甚至是更高级的证明。数据结构质量和递归关系通常涉及与归纳证明相关的思维,涉及有限状态机可计算性的证明有时会使用鸽子洞原理,而很少使用 >对角化(非常罕见,不用担心)。当然,几乎所有其他证明都使用反证法。我确信还有其他方便的工具我已经忘记了,但我希望您能理解。
弄清楚何时、如何以及为什么要使用一种或另一种特定方法来解决问题需要练习和经验。我建议除了练习之外还阅读证明,因为它通常可以向您展示使用已经遇到的证明方法的创造性方法。
最后一点,请尝试记住您第一次学习编程的时间。你是怎么好起来的?在我看来,证明事物和编程事物并没有太大不同。 :)
Practice is really the only way, but it can helped along by reading proofs as well. I won't touch on practice because the other answerers have covered everything that I can think of, so I'll just talk about what I mean by reading.
Textbooks are very fond of writing out the "important" proofs. Its very nice, because they often prove very powerful statements, and are really fancy. But just as you shouldn't learn to be a world-class gymnast from day 1 by emulating an Olympian (as in, you'll probably break your spine), you shouldn't read any really big proofs (at first). What I found was helpful was reading smaller proofs, usually from returned homework (I assume you're a student) or occasionally a textbook that wisens up.
The reason why I think reading proofs is helpful is because there are a small set of "tricks" or "ideas" that constitute huge chunks of schoolwork proofs, and even more advanced ones. Data structure qualities and recurrence relations usually involve thinking related to proof by induction, proofs involving computability with finite state machines sometimes use the pigeonhole principle, and more rarely the idea of diagonalization (very infrequent, don't worry about it). And of course, just about every other proof uses proof by contradiction. I'm sure there are other handy tools that have slipped my mind, but I hope you get the idea.
Figuring out when, how, and why you'd approach a problem with one particular method or another is what takes practice and experience. I suggest reading proofs in addition to practice because it can often show you creative ways of using a proving method you've already encountered.
As a final note, try to remember when you first learned to program. How did you get better? Proving things and programming things are not too dissimilar, in my opinion. :)
通过成为一名数学家,你就进入了进行数学证明的心态。我并不是以同义反复的方式来指最后一个陈述,而是要意识到,在数学期刊上发表的数学证明是某种修辞上的产物;也就是说,它是一个证明,因为一群数学家都同意它是一个证明。理想情况下,证明中的论证都可以简化为符号逻辑,但实践中并非如此。计算机生成的证明在进行有价值的数学方面的彻底失败为此提供了一些证据。
我通过做证明并让其他数学家接受它们来进入思维定势。我同意其他人的观点,“练习”是必不可少的。除非你尝试、尝试、再尝试,否则你不会做证明。往往天色会慢慢亮起。
当然,最好的资源是其他数学家和阅读校样。如果不是数学界的一员,很少有人能够做出真正的数学证明。
You get into the mind set for doing mathematical proofs by becoming a mathematician. I don't mean the last statement in a tautological way, but realize that a mathematical proof, as published in a mathematical journal, is something of a rhetorical artifact; i.e., it is a proof because a body of mathematicians agree that it is a proof. Ideally, the arguments in the proof could all be reduced to symbolic logic, but this is not how it is done in practice. The utter failure of computer-generated proofs to do valuable mathematics provides some evidence for this.
I get into the mind set by doing proofs and having them accepted by other mathematicians. I agree with the others that "practice" is essential. You don't do proofs unless you try, try, and try. Often the light dawns slowly.
The best resources are, of course, other mathematicians, and reading proofs. There are very few, if any, who can do true mathematical proofs without being part of the mathematical community.
恐怕“实践”确实是这里最好的答案。
它与编程非常相似:一旦掌握了它的窍门,您就会发现能够特别好的解决问题的模式,并且您可以创建以前从未实现过的新颖系统的高级设计图。然而,新手程序员并不了解模式:他们不断地编写代码,直到他们意外地发现了一些似乎“有效”的解决方案。
当你需要证明一个问题时,你通常可以识别属性(“我是否有一组不同的对象?”,“我是否生成排列?”,“我是否希望最小化/最大化某些值?”等) )。迟早,证明会聚集成模糊相似的组,用于解决一个问题的技术可以很容易地应用于新的变体。
推荐阅读:
I'm afraid that "practice" really is the best answer here.
Its very similar to programming: once you get the hang of it, you find patterns which solve problems particularly well, and you can create a picture of the high-level design of novel systems which you've never implemented before. However, neophyte programmers aren't aware of patterns: they hack away at code until they accidentally stumble on some solution which appears to "work".
When you're given a problem to prove, you can usually identify properties ("Do I have a set of distinct objects?", "Am I generating permutations?", "Am I looking to minimize/maximize some value?", etc). Sooner or later, proofs will clump together into vaguely similar group, where techniques used to solve one problem can easily apply to novel variations.
Recommended reading:
我不知道。可能就像你擅长作曲一样。
当我试图证明某件事时,我并没有遵循某种固定的策略,我只是思考问题。然后[未定义的时间]之后,我的大脑返回一个结果,我跳起来把它写下来。
但练习肯定有帮助。当我开始尝试证明极其简单的陈述(例如德摩根定律)时,我完全绝望了。所以我坐下来,在给我们的工作表上做了五十个左右的可选示例问题。现在证明一些事情感觉很自然。
I have no idea. Probably the same way you get good at composing music.
When I try to prove something I'm not following some fixed strategy, I just think about the problem. Then [undefined amount of time] later, my mind returns a result and I jump up to write it down.
But practicing definitely helps. When I started trying to prove extremely simple statements, like DeMorgan's laws, I was completely hopeless. So I sat down and did the fifty or so optional example problems on a worksheet we were given. Now it feels natural to prove something.
实践和研究非常有意义,同意。我发现一些有用的技巧:
Practice and study makes perfect sense, agreed. Some tricks, that I found useful: