11 ms·
Why There Is No Hitchhiker’s Guide to Mathematics for Programmers
- Ended 11y agoI hate how programming is so inconsistent. I mean, in vim I press 'w' to move one word, whereas in Notepad I press Ctrl-Right. They're not even close! I hate it when I use someone else's editor and I have to re-learn all the commands. I wish programmers could standardise this stuff. Maybe there could be a committee whose job it is to standardise editor commands, then we could program in any editor without having to worry about it. [I'm joking of course, but only half-joking. There's a serious point to be made, which is that mathematics exists completely independently of notation. When mathematicians don't care about notation, it's because they care about the actual mathematics instead. The reason mathematics notation is non-standardised is because standardising it wouldn't really help mathematicians that much. Unfortunately this means that non-mathematicians who use mathematics suffer.]
- skybrian 11y agoWell sure, mathematicians are so nutty about notation, it's amazing any mathematics gets done at all. Not at all convinced it's a feature. More like an unfortunate side-effect of tradition.
- michael_fine 11y agoI'm sure mathematicians would say the same thing about programmers and their verbosity.
- duaneb 11y agoYou think english would be much better? It's trading one symbol for another. It's complex reasoning no matter what.
- TheCowboy 11y agoI don't think the choice is between pure English and what we have now. It's easy to just stick with the traditional notation(s) of every subject, but there could be some cases where an attempt to refactor some notations might be of benefit. I usually like to criticize the combined use of i and j. Their use in pseudocode for analyzing loops also just aids confusion. I've helped some people by telling them to go through examples and change one of the variables into something more readable, and then it clicks for them.
- GFK_of_xmaspast 11y ago"Writing everything out in prose" is the way it used to be back in the long-ago days. Modern notation is far superior.
- kmm 11y agoThat really surprises me. I've never found mathematical notation to be anything than very useful and terse. Can you make it any more clear what bothers you? It has always been very clear for me, and I'm not sure what could be improved. I'd think any attempt to make it less ambiguous or more expressive would eventually devolve in something very similar to what we have now, because of our compulsion to simplify repeated tasks (eg Einstein notation, bra-ket etc..)
- mrob 11y ago>Can you make it any more clear what bothers you? A few things that spring to mind: dx/dy notation, and especially manipulating it like it's a real fraction. Implicit multiplication, which forces use of single character variable names, which forces use of weird fonts and greek letters. Writing sin^2(x) for (sin(x))^2 Writing sin^-1(x) for arcsin(x) (especially bad because it conflicts with sin^2(x)) The base for log(x) is ambiguous. Writing |x| for abs(x) (abs() is obviously a function, it shouldn't have special notation) Calling abs "modulus" And the names "imaginary number" and "complex number" seem almost deliberately designed to intimidate outsiders. IMO they should be called "oscillating numbers" and "rotating numbers".
- Maken 11y ago>Writing |x| for abs(x) (abs() is obviously a function, it shouldn't have special notation) >Calling abs "modulus" Both of those are because the absolute value of a number is the norm of the one-dimensional space.
- mrob 11y agoI've been successfully using abs() for a very long time, and I have no idea what "the norm of the one-dimensional space" is. If the notation requires understanding something of so little practical relevance to make sense then it's bad notation.
- schoen 11y agoIt's a generalization, and it makes sense as one: https://en.wikipedia.org/wiki/Norm_%28mathematics%29 https://en.wikipedia.org/wiki/Norm_%28mathematics%29 It allows you to think about |x| when x is a vector (or even other kinds of objects!) rather than just a real number. This kind of generalization can be a really powerful thing about mathematics, making existing insights more broadly applicable.
- Animats 11y ago"In mathematics there is no unified documentation, just a collective understanding, scattered references, and spoken folk lore. You’re lucky if a textbook has a table of notation in the appendix. You are expected to derive the finer details and catch the errors yourself." This has always bugged me. Andrew Ng's notation for machine learning sometimes uses superscripts as indices, and sometimes as exponents. In the same formula. Years ago, when I was working on a physics engine for animation, I was struggling through a 2-volume treatise on nonlinear differential equations. One formula in Volume 2 had a symbol I didn't understand, and couldn't find in the text. I eventually found it defined in the first volume, about 500 pages back. Steven Wolfram was annoyed by that, and he created Mathematica partly to define an unambiguous notation for much of mathematics. This is a fixable problem. By now we should have programs which read mathematical papers and textbooks, and check that all symbols are defined and unambiguous. There would be style sheets for different branches of mathematics. When reading a paper processed through such a system, you would be able to see the expanded, unambiguous form of a formula, and the definitions of all the standard operators and symbols. This might not be possible for truly cutting-edge mathematics where the conventions haven't settled yet, but that's a small fraction of what's published.
- bsilvereagle 11y ago> Andrew Ng's notation for machine learning sometimes uses superscripts as indices, and sometimes as exponents. In the same formula. I've never read Ng's work, but typically upper and lower indices is a sign of a summation. It's known as "Einstein Summation Notation". At first glance it seems obtuse, but when you start doing covariant/contravariant derivatives on tensors, the notation makes things much easier.
- OscarCunningham 11y agoIn a general relativity lecture I once saw an expression where indices were being used to mean three different things. As a power, to denote the components of a vector and as an index over some other indexing set. Of course it was perfectly readable because there are implicit conventions about what kind of letters you can use for each of these things, and because the formula would only make sense if you read it a certain way.
- GFK_of_xmaspast 11y agoI think one thing that you have to remember is, ISO standards aside, mathematical notation isn't a fixed thing but a living tradition that evolves over time.
- klibertp 11y agoWhich is totally true for programming languages, yet they somehow manage to have standards, all the undefined behaviour of C be damned. How come it's not the case for mathematics? Maths notation has very many problems, most of which stem from the fact that its syntax isn't formally specified. I have no idea why would mathematicians want to continue using this informally specified, ambiguous notation when there are alternatives.
- serge2k 11y agobecause we know how to read and don't care what a bunch of outsiders think.
- klibertp 11y agoYeah, that's exactly my suspicion! I'm just happy it's not true for Computer Science and programming. Whatever you want to say about a social side of programming, there's no denying it that outsiders and beginners are warmly welcomed in the community. We create and provide for free tutorials and guides for beginners, we design languages to be as easy for people to understand as possible (we don't exactly know what makes languages easy to understand, but we at least try!), we create tools for visualisation and summarizing code, and so on. Similar activities seem to be unpopular with mathematicians. I can't help but feel mathematicians are just a bunch of elitist pricks, who know they are on their way out and who try to build artificial barriers for entry into their field to make themselves needed for a bit longer. It's actually natural, most people will fight to retain their status (and jobs). It reminds me of "refucktoring", writing convoluted, unreadable code just to make sure nobody, else than you, can work with it. Such programmers are shunned in our community, yet they are heroes in mathematics. Oh well, as an "outsider" it's not my problem.
- 11y ago
- OscarCunningham 11y agoI feel a need to stand up for mathematics notation. The main complaint seems to be that it is too minimalist, using the minimal number of symbols (or less) to be unambiguous. But mathematics notation needs to be extremely succinct because the notation is not just for reading. When you're working something out you often need to write pages and pages of formulae and diagrams by hand. So using a notation more verbose than absolutely necessary would be unnecessarily painful. Programming is different because you can use a text editor with copy, paste, autocomplete etc. But I imagine that if I wasn't allowed to use any of those then my variable names would shrink down to one letter when I was programming too. Also, I think that making formulas smaller makes it easier for the eye to see the whole formula together. This makes it easier to quickly understand the meaning of the formula, at least once you've got used to the notation for that particular area of mathematics.
- warfangle 11y agoGoing through Calc III for the first time. I can't imagine how many more trees I would destroy if I had to write out double integrals longhand. Not to mention, it would make it a lot harder to reason about everything going on... When I first started in my adult adventure in math (never doing well with it academically, I started on pre-calc with Khan Academy about a year and a half ago; I'm now working through multivariable calculus on MIT OCW), I used scratch mode in emacs because hey, I'm right there on the computer. I gave up and started using graph paper as my scratch pretty quickly :) I can't imagine trying to actually _do_ math with something "descriptive" like LaTeX. Math, from what I've come to realize, is less about describing how to compute something and more about describing something in such a way that it can be manipulated in order to reveal something new. And that's why the obtuse iconography is popular in math, and why the obtuse iconography of APL never became truly mainstream in programming.
- skybrian 11y agoYes, that's the tradition part. I certainly don't object to using whatever notation you like when you're at a whiteboard or scribbling on paper. But math papers are carefully formatted and published using LaTEX, not by taking pictures of whiteboards. This isn't because it's easiest. It's supposedly to benefit the reader, and yet fails in practice. It seems like coming up with a format that at least allows definitions and usages to be hyperlinked might be pretty nice, instead of a format whose primary benefit is looking pretty when you print it on paper.
- bitwize 11y agoMath notation is for pencil and paper what Unix commands are for typed input: terse, dense, intended to be easy for insiders to write and read at the expense of outsider accessibility. It does the job it's supposed to do. You wouldn't plow through a mathematical paper like a Twilight novel. You're supposed to slow down, consider each symbol in relation to all the others, and from that build a picture in your head of the mathematical object being described.
- skybrian 11y agoWell yes, I agree, nobody expects to be able to skim. But I don't think Unix commands are a particularly great example for your side. They are nice for interactive work but terrible for maintenance. Nobody wants to read a thousand-line shell script.
- kaitai 11y agoSounds like a really good analogy, in fact :)
- sklogic 11y agoThere is One Book to rule them all (sorry, could not find a link to the original 1973 edition): http://www.amazon.co.uk/Mathematical-Handbook-Scientists-Engineers-Definitions/dp/0486411478 http://www.amazon.co.uk/Mathematical-Handbook-Scientists-Eng...
- deleted 11y ago[deleted]
- DrScump 11y agoA Hitchhiker’s Guide to Mathematics would probably just be the number 42 over and over again.
- ccvannorman 11y agoWith alternating pages printed "What is 6 x 7"
- DrScump 11y agoNo! Remember the book: "What do you get if you multiply six by nine?"
- colejohnson66 11y agoAnd because everything is base 10, 6 times 9 is 42. In base "A", it's 54, but we're using base 10, not base "A"
- jaybosamiya 11y agoAll bases are base 10
- delinka 11y ago"Doing mathematics" and "using math in my code" are so far apart. In my programs that Really Utilize Math, I'm taking advantage of some existing mathematical concept, but I'm not advancing the state of the art in mathematics. However, the few times I've really wanted to delve into math and really understand the concepts underpinning that formula I'm using, I need a machine to iterate on. My computer isn't ideal because the software that's available is too expensive for 'hobby' use; there's no library that lets me use code in a language I know to manipulate symbols and equations. The TI series of calculators are not ideal because A) they're intentionally crippled (to prevent student cheating) and B) they have a bit of learning curve to them when you don't use them regularly. Can I get a touch-device app for mathematical symbol/equation manipulation? That'd be ideal.
- adenadel 11y agoYou might be interested in Sage. It's free and open source and allows you to use Python syntax. http://www.sagemath.org/ http://www.sagemath.org/ https://cloud.sagemath.com/ https://cloud.sagemath.com/
- ryanmonroe 11y agoThere's always the Wolfram Alpha app. Or if you want something offline, you could use SymPy (though obviously this isn't a touch-device app). I use Wolfram Alpha on my iPhone pretty much every day for simple matrix calculations, derivatives, integrals, and summations and it works very well.
- iheartmemcache 11y agohttp://detexify.kirelabs.org/classify.html http://detexify.kirelabs.org/classify.html that will yield a TeX symbol which can trivially be transformed into something acceptable into most of the engines (e.g. Sage, Octave, etc) for evaluation. It's not "evaluate definite integral (0,5] for .." but it'll get you half the way there. PS. Cheating on TI's is trivial. If you're a math professor, adopt a no graphing calculator rule. (You can still cheat on your standard secretary's 20$ calculator, especially in the age of low-power Cortex M0+'s, but it's somewhat less trivial. I'd imagine memorizing 5 or 6 rules on taking the derivative would be easier for someone capable of doing that. (Though if those tools had been around when I was in uni, I might have just done it for the sake of doing it.))
- contingencies 11y agoJust yesterday I found myself reverse engineering checksum algorithms in various domestic bank account systems about the world. https://github.com/globalcitizen/php-iban/issues/39 https://github.com/globalcitizen/php-iban/issues/39 I went for an explanation of some of the newer ones I hadn't heard of before (Damm) and it was painful. (The code was only a few lines, though!) While some algorithms had a pre-existing implementation, wiser than rewriting I simply nabbed them and evaluated. Most of the implementations were unreadable/undocumented and of dubious origin, many of the implementations claiming to provide the same algorithm delivered different results. Some of these work for some countries, some for others. No idea where the differences lie and not enough interest to bother finding out. Then of course there's the origin of these 'standards', ISO, who insist on charging 88CHF for a 5 page document, thus we can't actually read the damn standard. I would up porting a family of algorithms from Java using code generation. Why we don't yet have a library delivering smackdown-documented functions in arbitrary languages for named algorithms escapes me...
- joolze 11y agohttp://www.amazon.com/Numerical-Recipes-Scientific-Computing-Second/dp/0521431085/ref=sr_1_4?ie=UTF8&qid=1455840459&sr=8-4&keywords=numerical+recipes http://www.amazon.com/Numerical-Recipes-Scientific-Computing... This or a variation is on almost every physicist's shelf I know...
- Silhouette 11y agoThis or a variation is on almost every physicist's shelf I know... Unfortunately, that is a significant part of the problem. Numerical Recipes was an OK book for its time, and certainly a popular one given the limited material available in the field. However, neither the recipes themselves nor the book's general presentation are ideal today, and in many cases, someone interested in implementing robust, efficient algorithms for various mathematical constructs would do better now to read other sources. For example, substantial linear algebra computations are probably going to use some variation of BLAS/LAPACK today. There is also a lot of background material available about the algorithms used within these libraries and the underlying mathematical foundations, for those who need to implement something a little different or who are simply curious. In most fields, and excluding those who are actually writing this kind of mathematical library, a programmer will do better to use the tools that are already freely available today rather than trying to implement their own code based on ideas from Numerical Recipes.
- bigger_cheese 11y agoI'm an Engineer I have NR sitting on my desk shelf I refer to it often. A lot of my peers use it as well. NR is hugely helpful. One example a few years ago I needed to implement technique from a math paper in some C code. The paper included such classic math terms like "Tridiagonal Matrix" and "Cholesky Decomposition" I'm sure they mean a lot to someone with a math background but baffled me at the time. It wasn't until I pulled out my handy copy of NR I was able to even slightly wrap my head around just what the hell a "Cholesky Decomposition" even was. Let alone how I would code it. And even then I had to dredge up my old Linear Algebra textbook from Uni to re familiarise myself with basic Matrix operations. The code I wrote ended up being full of comments like this: "/* Newton's method to compute positive root f(p)^2 = (u^T)(Q^T)(D^2)Qu and F(dF/dp) = (u^T)(Q^T)(D^2)Q(du/dp) */ " Which is basically me trying to wrap my head around just what the hell the mathematical paper is talking about whilst writing the algorithm programatically. Even now opening the .C file some years later it took me a few minutes to make sense of that comment I had to realise that U^T was shorthand for transpose of Matrix U. Numerical techniques are hugely complicated especially when you don't deal with them every day I have yet to find a book better than NR at breaking them down and presenting them in a way someone like me (with Science/Eng background) can understand them. I'll gladly take any recommendations you have for updated references. As far as I know NR and the GSL (GNU scientific library) documentation are considered the gold standard by all my peers.
- gtrubetskoy 11y agoApplied science, i.e. taking something from text book abstract and general to something specific is always extremely difficult. It's one thing to read about a nuclear reaction but a whole different thing to actually set one off. To implement something you need to have a level of understanding of it that is way deeper than what is required to get a passing grade in your math class. The problem isn't mathematical notation or the programming language (I am quite competent in and have no quarrel with either). I recently set out to implement Triple Exponential Smoothing (aka Holt-Winters method), but I didn't want to use someone else's code, I wanted to understand the algorithm so that I knew enough to compare various implementations and/or write my own. It took _months_. There is a lot of material on the subject, but it all disagrees ever so slightly on one thing or another, or skips over something essential. I don't think anyone or anything is to blame for this - that's just life. You can read about it here, btw: http://grisha.org/blog/2016/01/29/triple-exponential-smoothing-forecasting/ http://grisha.org/blog/2016/01/29/triple-exponential-smoothi...
- obelisk_ 11y agoInteresting read. Thank you for sharing.
- j2kun 11y ago> There is a lot of material on the subject, but it all disagrees ever so slightly on one thing or another, or skips over something essential. I don't think anyone or anything is to blame for this - that's just life. Isn't this precisely what you said wasn't the problem? The resources out there all differ slightly on one thing or another. I suppose you mean small semantic differences? I think when I wrote this article originally I intended superficial semantic differences in the math to count as well as notational differences. Doing math for too long has made me think of these as the same thing, since the true underlying insight doesn't depend on either.
- gtrubetskoy 11y agoYes, every text used its own conventions for variable names, different words to say the same thing, etc, but no, that wasn't a problem (for me at least). I think the point I was trying to make (not so well) is that perhaps it's not that programmers do not like math, but rather that when you learn to view everything through a programmer's eyes, i.e. "how am I going to actually build this damn thing", you tend to get very wary of abstract or generic approaches which is what scientific books are made of. For example, if I were given a book with a chapter on Holt-Winters and told that there'd be a quiz later, I could have "mastered" it in a night probably. But when I had to write the code to actually do that, I'd find out that this book does not mention how you come up with initial values, while wikipedia does, wikipedia cites this NIST publication, but who wrote that and is it any good? Then I came across a 2014 paper that says that the forecast can be improved with a slight change in one of the formulas, only when I tried it, my results were worse; no book mentioned how to find best alpha, beta and gamma, because for that you need some kind of a gradient descent or nelder-mead method, and on and on. _That's_ what took months (and it was challenging and fun too), and I think we agree that there isn't a solution to this, it's a dilemma, not a problem. (As someone once said - avoid trying to solve dilemmas and avoid managing problems).
- ludamad 11y agoThe opinions of what the subscript could mean are very coloured by Python :P Didn't mention the fact that this could be a type, etc
- adrusi 11y agoI think a big barrier to understanding math for a lot of people, and definitely for me, is names. Things get named for people instead of what they are: "the Kronecker delta function". You came up with some genius model and proved it, and after all that work you decided that your name and some greek letter are what people need to think of when they hear about it and not anything about what it is? Fuck you Kronecker! The problem extends beyond mathematics, to essentially everything except programming. And in fairness out of all the fields with shitty names, mathematics has the best excuse: unlike the natural sciences and engineering, math is completely abstract. But programming is also pretty abstract, and yet we don't call stacks Hawk-elbower's double-u structure! No, we notice a semantic similarity between our abstract concept and something more familiar, and we come up with a monosyllabic, five-letter word that conveys a lot of information about the construct to someone completely uninitiated. This both makes it more approachable and easier to learn, serving as a mnemonic device. And once you've internalized it it makes no difference whatsoever. I hear people whine that naming abstract concepts after concrete objects will only give people a harder time thinking abstractly. Bullshit, I say: have you ever heard of a novice programmer thinking that stacks are only good for representing stacks of paper or dictionaries for looking up definitions of human words. I understand that naming things nicely in math is harder than in programming, and that in some more cutting-edge branches there might simply be no good analogies to draw, but I don't think it's impossible for more mundane topics. Math professors teach by drawing analogies and thinking of applications all the time. In any case we can do a lot better than "Kronecker's delta function".
- jandrese 11y agoI've always been annoyed that mathematicians are stuck on one letter variable names. Worse, when they ran out of letters instead of rethinking the policy and considering descriptive variable names they instead decided to use foreign alphabets instead. Regular mathematical notation is like what you would get when you run a program through one of those obfuscators that blows away all of the comments and whitespace, reduces variables down to a single letter, and renames all of the functions to single letters. But we can't change it because it would confuse all of the existing mathematicians who spent years memorizing all of the quirks of the system.
- 11y ago
- alfiedotwtf 11y agoThere's "The Hitchhiker's Guide to Calculus" by Spivak, and it's actually a really easy read while giving you an excellent mental model of Calculus.
- deleted 11y ago[deleted]
- deleted 11y ago[deleted]
- hydandata 11y agoI love programming, but never got the hang of Mathematics due to various reasons. Failed a big project as a solo programmer long time ago, when I was 17, because I could not create the necessary mathematical model and no help was available, with everything else completed, infrastructure, web site/interface database etc. Soon afterwards set off on a different career path, but always kept an intimate relationship with programming, doing some both at work and for fun at home. Recently, after watching R.W. Hamming lectures and reading his book "Art of Doing Science and Engineering" [1] [2] decided that I would try learning mathematics again. I found it really hard to do. There are so many implicit assumptions, so much ground that is not covered. I was about to give up again, when I found a book [3] by retired computer science professor, who seemed to have written it specifically for me! it really felt that way. Now I recommend it to almost everyone, especially tech-savvy people. I am no longer afraid of mathematics, with the help of this book, and great advice by Hamming, I am finally "getting it". If you find learning new programming languages easy, but struggle with mathematics, check it out! The book is not aimed at teaching you mathematics, rather, it teaches you those missing pieces, that almost every other book either assumes you already know, or describes vaguely and badly, gives you context and valuable advice. To me it almost feels like it is teaching you a functional programming language. A strange and very flexible programming language, with its warts and all. You learn the language, and then you can go on to explore programs written in it, algorithms, data structures whatnot. My ultimate goal is to, at least, learn enough so that I can really understand books by Hamming, especially "Methods of Mathematics Applied to Calculus, Probability, and Statistics" [4]. And, of course, to do interesting projects along the way, now that I am starting to understand some of the research papers. [1] http://worrydream.com/refs/Hamming-TheArtOfDoingScienceAndEngineering.pdf http://worrydream.com/refs/Hamming-TheArtOfDoingScienceAndEn... [2] https://www.youtube.com/watch?v=AD4b-52jtos&list=PL2FF649D0C4407B30 https://www.youtube.com/watch?v=AD4b-52jtos&list=PL2FF649D0C... [3] http://www.amazon.com/The-Language-Mathematics-Utilizing-Practice/dp/0470878894 http://www.amazon.com/The-Language-Mathematics-Utilizing-Pra... [4] http://www.amazon.com/Methods-Mathematics-Calculus-Probability-Statistics/dp/0486439453 http://www.amazon.com/Methods-Mathematics-Calculus-Probabili...
- Jugurtha 11y agoI think this goes beyond programmers and those who want to learn "Mathematics": it can be frustrating to talk with someone who confuses equivalence and implication in everyday conversations; this inability to use proper, basic, logic seems to be too widespread. I can relate to the funny part on notation. I've been fortunate enough to have an older sister who's Algebraist and I remember when I was in primary school and I'd have a question, she'd explain on paper using different symbols than the ones I was using just to make sure I wasn't a slave of notation. She insisted I had to think in an "abstract" way (that's precisely the word she used) and not be tied by what the letters are called, and only look at the relations between them and context. This one piece of advice served me well. It's also funny the author mentions Fermat's Last Theorem because the first time I had heard of it, it was still called "Conjecture de Fermat" and I had read a piece on "Science & Vie" on Andrew Wiles' proof and the fact there still was work to be done to see whether it was correct or not. I was 7 at the time and it seemed strange and amazing how something that can be stated in terms deceivingly simple even I could think I understood, can be so difficult to prove. I've studied Electronics Engineering in college and we had really cool Maths courses (again, in the spirit of different notation, I noticed a peculiarity: in the U.S., the term "Calculus" is used, whilst we used "Analysis", "Introduction to Mathematical Analysis", "Differential Analysis", etc. Perhaps the influence of French and Soviet Mathematicians who taught at my University. The books are also either Smirnov, Demidovich, Pontryagin, Piskunov, or Dieudonné, so the style taught is kind of different). I digress. For me, it doesn't matter. I love Mathematics. Not the way many people say they love it. It is something on my top list of things to do and I am self studying currently. Why? First, emotional reason: in retrospect, the happiest years of college where in the "Common Core" (two years of core knowledge (mainly Physics and Maths) every Engineering student goes through before choosing a specialty (except Computer Science students, they only do freshman and then CS). Maths (and Physics) bring me happiness in a way that is hard to describe. The second reason is practical: when my Maths skills were somewhat sharp, I had no problem understanding other things, because I had the necessary tools to strip down the things and go at it where it was called for (for example, modulation with a transistor and using Taylor series for the current). I then turned utterly incompetent and let everything rust and I'm paying the price right now. I have graduated but the blade is dull and I can't live with myself like that. I've come a long way, especially because I was clueless in time management and focusing my efforts and getting things done and I had to learn how to mitigate my proclivity to be all over the place. The one sure thing is that I'll never let go. I may not become a great mathematician, but every day I am less incompetent than the day before it. The point is, as in everything else: people don't learn because they lack the drive to do so, face the reality of sucking, learning the basics and fighting that embarrassing feeling of the inner voice that says "shouldn't you already know that stuff?".
- mamcx 11y agoI read a lot of papers about programming recently, and the weird kind of math people use there is a huge barrier. So, no even math related to programming is readable by programmers!
- awalGarg 11y agoWith a program, you can always write test cases and run them to ensure they all pass. If your tests are solid and plentiful, the computer will catch your mistakes and you can go fix them. There is no corresponding “proof checker” for mathematics. There is no compiler to tell you that it’s nonsensical to construct the set of all sets, or that it’s a type error to quotient a set by something that’s not an equivalence relation. This is something that I have been noticing for quite a while. As I got out of high-school and self discovered programming - something that I gradually realized is that programmers have an infrastructure of tooling setup to help themselves. They made their things to help themselves. Compiler compilers (and cross-compilers!) simply blew my mind away. I joined college after a gap of an year, and as I faced Physics and Mathematics again, that feeling strengthened. I now sometimes think of a very strict compiler for mathematics that catches errors from the math lingua. Could possibly be extended to Physics too. Don't even know if that is feasibly possible, but I find the idea intriguing.
- jandrese 11y agoThis is what Mathematica is supposed to do. I'm not sure if I would call it a resounding success however.
- irremediable 11y ago> I now sometimes think of a very strict compiler for mathematics that catches errors from the math lingua. Is that what Coq (https://en.wikipedia.org/wiki/Coq https://en.wikipedia.org/wiki/Coq) is?
- Joof 11y agoCoq is either too immature or too strict. Writing a proof in coq is far too difficult for what it does. I agree that we need a proof 'compiler' though.
- irremediable 11y agoThanks for the insight on this, by the way; I'm more of an applied math person, so I have no firsthand experience of things like computer-verified proofs, Coq, etc. What do you think are the specific ways in which a proof compiler would be different?
- 2sk21 11y agoThe difference is this: When I write code that has an error, I usually get either a compile or run time error. Not so with math!
- auggierose 11y agoThat's possible with math too!
- Smaug123 11y agoOne can, however, catch some of these with unit tests, in maths just as well as in code. The unit tests for maths are tiny, trivial cases of the main theorem. For instance, if I wrote down Fermat's Last Theorem as "x^n + y^n = z^n has no solutions for n > 1", I would run my unit tests by checking the boundary case n=2, and discovering the easy counterexample of (3,4,5).
- atemerev 11y agoAll right, so this article can be probably condensed to these two points: 1. "Mathematics is hard and inconsistent, but so is programming". Well, yes, but this is exactly the problem! I pity poor souls who started their journey into programming with, say, C++ — the champion of consistency and elegancy. But there are other ways and other languages. And, with some effort, it _is_ possible to provide gentle introduction into programming world. The same should apply for mathematics. 2. "You can't learn mathematics on your own, but it's the same with programming". And here I deeply disagree. Programming as activity is _the_ perfect learning environment. Find some coding sample, compile and run it (or paste to REPL), see if it gets you the same result. Try to change some variables in the code, see how behaviour changes. Can you run it without this function? What this method does? (A quick look to the documentation reveals everything, including additional arguments to try). You can tinker and hack and play and learn with every language and environment out there, it's like a perfect experimental setup where experiments are cheap, and everything is perfectly reproducible, at least on your own machine. ;) With math, there are no docs, no playground, no explanations, no nothing. Either you are the part of mathematical community and can hope for explanations and knowledge transfer, or you are not. In programmers parlance, it's like being the part of a huge legacy project with long compile times and cryptic documentation, where the only way you can learn is ask your senior colleagues questions like "what this class is doing?" and get answers like "oh, we are not doing _that_ anymore, this is an artefact from like 15 years ago, still widely referred in the docs, though. Here is the right way instead". Sounds familiar? This is why learning math is way harder than it should be.
- choosername 11y ago> With math, there are no docs, no playground, no explanations, no nothing. Either you are the part of mathematical community and can hope for explanations and knowledge transfer, or you are not what's the difference to CS here, where did you get that coding sample you mentioned? The playground is your mind, pebbles or pen and paper, maths are a projection of the real world. Mathematics is not inconsistent. Isn't this the premisses of rigor? Math has mathematical consistency and that's not the same as literal consistency, but maybe that's a problem in semiotics and language. The language and the literature is inconsistent.