The relationship between programming and mathematics

In fact, computer science programming. Many people have the wrong view that computer science is a branch of mathematics, mathematics is the foundation of computer science, mathematics, computer science is more profound than science. These people think that just have to learn mathematics, not to mention all the programming things, but this is not true.

Basic math is not computer science

In fact, the fact is this:

1. Computer Science, but it was not mathematics, it is merely borrowed very small, very basic math, high school math is easier than that. The so-called higher mathematics, basic computer science do not have access inside.

2. The computer is more fundamental than the mathematical tools like pen and paper. The computer can be used to solve problems of mathematics, can also be used to solve the problem is not mathematics, such as engineering problems, the problem of art, economic issues, social issues and so on.

3. Computer science is completely independent discipline. Studied mathematics and physics, and not a substitute for learning computer science. You have to learn for computer science, are likely to become a good programmer.

4. mathematician language used, compared to common programming languages ​​(such as C ++, Java), in fact, is very backward and poor design. The so-called mathematical beauty, in fact, most arrogant.

5.99% of mathematicians write decent code.

Mathematics is abnormal bad language

This is not alarmist. If you studied in depth theoretical programming language, you will find those symbols actually used by mathematicians, but is a very bad programming language. Some mathematical theory is useful, however, the house used to describe the mathematical language used in these theories, but it is complex, the lack of consistency, the combination of (composability), simplicity, usability. This is why most people see math headache. It's not that they are not smart enough, but the design language of mathematics problems. As people learn mathematics, in fact, only a small part of the essence of time thinking about it, but most of the time to toss it in the syntax.

For a very simple example. If you say x -1 represents the power of -1 (the inverse of x) x, then f -1 What does that mean? -1 th, f is the reciprocal of f? Do the math teachers of doctrine and excuses to deceive you, they always tell you: you should remember these! But you thought about it: why x -1 represents -1 x to the power, and f -1 is obviously exactly the same form, but it is represented an inverse function of the function f. One is exponentiation, one inverse function, less wind horse, but written in a way. Such language designed to confuse unbearable, but pleased with the convention as an excuse.

If you look at some more math book, you will find this is just tip of the iceberg language of mathematics hundreds of years of accumulated dross. Book by a variety of mathematical and superscripts, subscripts superscript in parentheses, x, y, z, a, b, c, f, g, h, various writhing Greek letter, Heber by letters ...... italic, bold, curlicue, double shadow body ...... with different fonts to represent different "types." Many meanings of the symbols, which are not the same in different sub-areas. Some people in a math class, in the end did not understand what is the meaning of those symbols.

Many people feel difficult to learn calculus, in fact, the problem is not them, but in Leibniz (Leibniz). Leibniz designed to describe the language of calculus (∫, dx, dy, ...), from the perspective of modern language design point of view, in fact, very bad, can be said to be a mess. I can not blame Leibniz, after all he is a man hundreds of years ago, he did not know much of what we now know. However, the design of the ancients, now is not considered to improve, but as a dogma taught to students, it is a lazy.

Unlike mathematical language programming language, its long history, it has not been systematic, thoughtful, unified design. The emergence of various mathematical symbols, often in the history of a mathematician one day some strange symbols readily draw on the blackboard, saying it represents, what it represents, ...... then settle down. Many mathematicians only care about their own piece of narrow sub-areas, just as his theory to design a set of symbols, completely regardless of whether these symbols with other sub-areas in conflict. This is why the different sub-areas of mathematics to write the same symbol, but can represent a completely different meaning. In this sense, the language of mathematics with Perl (a very bad programming language) is somewhat similar. The Perl functions necessary for all kinds of people, indiscriminately added to the language inside, causing unbearable complicated language, and even the creator of Perl himself can not understand all its features.

Mathematical proof, in fact, not very strict language used - strange symbols, plus vague, misunderstood human language. If you know what a Curry-Howard Correspondence will understand that every mathematical proof are nothing but a piece of code. The same theorem, can have many different versions of the proof (the code). Some of these proved short elegant, but some length and complexity, like noodles, like going around and could not understand. You often see inside mathematical proof "Undefined variable", prove that the logic also contains a variety of tacit knowledge, thinking jump, very difficult to understand. Many mathematical proof, from the viewpoint of the program point of view, even the compiler will not pass, never mind run.

Mathematicians often do not care about elegance to prove. They think if they can prove a theorem, you tube my simple proof Jane, let it not easy to understand. The more you read, the more I feel inscrutable! This trend to the programming time on the show the drawbacks. Mathematicians write code, the code is often overlooked elegance, simplicity, modularity important factor, readability, performance, data structures, etc., that the results can be calculated as long as the code on the line. They like the code as proof, one-time thing, so their code often can not meet the stringent requirements of the actual project.

Programming is an art

From the above, you may already know, ordinary programmers programming language, even if the C ++ language so many problems, in fact, many mathematicians have also been smarter than the language used. A branch of computer science is not mathematics, it is largely better than math, higher than mathematics. Some basic mathematical theory can be used in computer science, mathematical science is not yet part of the computer. In the language of mathematics with too much dross left over from history, it is actually Buddha across the river mud, unable to help themselves, it does not solve the practical problems encountered in programming.

Programming is really an art, because it is consistent with the various features of art. Art can use the tools provided by science, but it is not part of science, and its status is not less than science. And all the arts, science and programming to solve the problem can not be solved, to meet the new needs of people, open up a new world. So, dear programmers, do as they do not understand a lot of worry about the math. Mathematics does not help you write good programs, but who can write a good program, but it can better understand mathematics. I suggest that you first learn programming, then go to math.

 

"Previously very good, I want less, went to bed early, like to laugh, but also somehow suddenly live a scribble."

Guess you like

Origin www.cnblogs.com/yanggb/p/11818582.html