12 ms·
An Intuitive Guide to Linear Algebra (2012)
- the_watcher 7y agoI remember taking Advanced Algebra Honors in 10th grade. It was basically Algebra II with a few (seemingly teacher-selected based on the experience of students who had a different teacher) advanced topics thrown in. One of them was matrices, and I was completely stumped by them. I now encounter them all the time, and wish I'd been able to wrap my head around them when I was younger.
- marcuskaz 7y ago20+ years ago I combined learning JavaScript and Linear Algebra https://mkaz.blog/math/javascript-linear-algebra-calculator/ https://mkaz.blog/math/javascript-linear-algebra-calculator/
- PNWChris 7y agoOP Here: I just wanted to give some context to how I found this page, and why I thought it would be good to post. I may be putting myself on the spot here: I never took a linear algebra course in undergrad. It was a heavily encouraged option, of course, but I felt I understood the basic rules enough to not really need formal study. I opted to study other areas, partially motivated by a fear I wouldn't do well and would hurt my GPA (my god was I vain, I feel I could do so much more studying full-time with my current world-view). As time has gone on, and ML and quantum computing have simply blown up since I graduated in 2014, I quickly realized the magnitude of my mistake. I have frantically self-studied for years to try to make up the gaps in my mathematical understanding, and linear algebra has come up time and time again. I can do the processes, but they never clicked, I had no intuition. I want to help others in my position cut to the chase, and study the highest yield, most intuition giving resources. I actually developed the mental model shared in this guide on my own, and was positively delighted to find to this while thinking over a comment I was drafting on here. This page lays things out so clearly. The component steps are intuitive and I can commit them to memory/recall what they mean without needing to dig up my notes to self! === I find this page gives an excellent foundation, and goes great with these resources: * A web site which clearly shows how to do matrix multiplication in a way that's easy to recall, it makes the procedure like riding a bike: http://matrixmultiplication.xyz/ http://matrixmultiplication.xyz/ Huge thanks to Jeremy Howard of fast.ai for mentioning this in one of his lectures, this tool is how I finally got matrix multiplication to click * A paper named "An Introduction to Quantum Computing" (bear with me, it's superbly well written and very approachable): https://arxiv.org/abs/0708.0261 https://arxiv.org/abs/0708.0261 Page 3 of that paper lays out matrix multiplication (e.g.: applying a "transformation matrix" in the spatial parlance of 3blue1brown's videos) as a traversal of a directed graph. A very useful understanding, and shows how generalizable the tools of linear algebra really are in my opinion. * The essence of linear algebra, by 3blue1brown (fantastic for a geometric/"transformation of space" view of linear alg): https://www.youtube.com/playlist?list=PLZHQObOWTQDPD3MizzM2xVFitgF8hE_ab https://www.youtube.com/playlist?list=PLZHQObOWTQDPD3MizzM2x...
- dang 7y agoA thread from 2015: https://news.ycombinator.com/item?id=8920638 https://news.ycombinator.com/item?id=8920638 Discussed at the time: https://news.ycombinator.com/item?id=4633662 https://news.ycombinator.com/item?id=4633662
- bgroat 7y agoI love betterexplained. Does this guy have a patreon?
- wodenokoto 7y agoHe has a business that sells courses and books right on the homepage.
- RickS 7y agoAlready this is so helpful, as someone with only a partial high school math background. The visual "pouring" analogy alone made it worth the read.
- vecter 7y agoThis is ok but nothing is as intuitive as 3B1B's series on YouTube that has been posted hundreds of times on HN [0]. Linear algebra is really about linear transformations of vector spaces, which is not captured in this blog post. [0] https://www.youtube.com/watch?v=fNk_zzaMoSs https://www.youtube.com/watch?v=fNk_zzaMoSs
- foxx-boxx 7y agoOften these articles are written by students who either failed their exam or scared to fail it. People who actually know the subject get paid either for lectures or for real work.
- sandov 7y agoPlaylist link: https://www.youtube.com/playlist?list=PLZHQObOWTQDPD3MizzM2xVFitgF8hE_ab https://www.youtube.com/playlist?list=PLZHQObOWTQDPD3MizzM2x...
- OrwellianChild 7y ago3B1B does great work explaining these concepts, but I can't help but ask "why not both?" when it comes to explaining these concepts. Turns out, linear algebra is great for working with matrices, vector space, approximating non-linear systems, and more... Let's embrace multiple ways of teaching it and gaining intuitions rather than keeping score, eh?
- nightcracker 7y ago> Linear algebra is really about linear transformations of vector spaces, which is not captured in this blog post. I... disagree. Some of linear algebra is about that. And it's probably a good way to view it that way when learning. But some of my current work (coding theory) involves linear algebra over finite fields. We use results from linear algebra, and interpret our problem using matrices, but really at no point are we viewing what we're doing as transforming a vector space, we're just solving equations with unknowns.
- xscott 7y agoI think this is spot on. Depending on what you're doing, a matrix can be: - A linear transformation - A basis set of column vectors - A set of equations (rows) to be solved - (your example: parity equations for coding theory) - The covariance of elements in a vector space - The Hessian of a function for numerical optimization - The adjacency representation of a graph - Just a 2D image (compression algorithms) ... (I'm sure there are plenty of others) For some of these, the matrix is really just a high dimensional number. You (rarely?) never think of covariance in a Kalman filter as a linear transform, but you still need to take its Eigen vectors if you want to draw ellipses.
- adamnemecek 7y agoIf this interests you, you should check out the bivector community https://bivector.net/ https://bivector.net/. Join the discord https://discord.gg/vGY6pPk https://discord.gg/vGY6pPk. Check out a demo https://observablehq.com/@enkimute/animated-orbits https://observablehq.com/@enkimute/animated-orbits Also at the end of February, there is geometric algebra event in Belgium. https://bivector.net/game2020.html https://bivector.net/game2020.html All the big names in the field will be there.
- formalsystem 7y agoViewing Linear Algebra as the study of linear operators instead of matrices makes everything so much simpler. Of course AB != BA Composition makes sense Inverse makes sense This is the book that helped me get it http://linear.axler.net/ http://linear.axler.net/
- mathnovice 7y agoI'm reading Strang's linear algebra book and he teaches it in terms of combining columns and rows which I think is a lot clearer than explaining it in terms of linear equations.
- swiley 7y agoI really like "matrices are the coordinate form of linear transforms." In the LA class I took the professor made a pretty big deal out of that, first by defining "lexicographic matrix basis" so he could write out matrices as vectors and then talking about mapping between the three different ideas. There's still stuff he said that I'm unpacking today... that was a dense class.
- zelly 7y agoThis is a great book. I also recommend Halmos "Finite Dimensional Vector Spaces". The typical way linear algebra is introduced does not present a matrix as a linear transformation first and foremost.
- sushisource 7y agoI love explainers like this, but it frankly makes me a little angry that the vast majority of the math teachers I had in highschool and college taught in the awful way described in the setup to the piece. Why is that? Has anyone studied it, or is there even a solid anecdotal explanation? The best one I can imagine is many of these professors simply don't care much for teaching and are more focused on their research, which is still infuriating but at least an explanation. I ended up with an undergrad in applied math, though I'm a software engineer now. I like math, but I feel like I never got to be all that great at it. I suspect I would've enjoyed it more and achieved more with explanations like these.
- addicted 7y agoHow much of this explainer however seems better to us precisely because of the more comprehensive knowledge and understanding we already have? For example the author uses the word function liberally in the explanation. However, when studying functions in school in math it was super complicated for me. It was only after I started programming, learning the programming language meaning of function, and then when I was reintroduced to mathematical functions through functional programming that I truly grasped mathematical functions and all the stuff I was taught in school. I’m not arguing that school level math does not need to be improved. I just think we should be cautious that because an explanation that seems intuitive to us now after having gained a complete introduction to all math concepts as well as programming (esp on HN) may not necessarily be as intuitive when students who are only exposed to a very small subset of mathematical concepts encounter them.
- swiley 7y agoAs someone who learned to program before taking any interesting math I was always so confused by the amount of early math classes spent explaining function notation. It wasn't until I tried teaching people that I realized how odd the notation can seem.
- kevstev 7y agoyou should be happy someone explained it to you- I feel that notation was overlooked tremendously in my math education- I actually just brought this up in a thread yesterday. It was like "oh, we have this dx now... k."
- alacombe 7y agoSpeaking for Linear Algebra, I learnt more reading for a few hours the appendix of "The Design of Rijndael: AES - The Advanced Encryption Standard" than I did in 6 months of theoretical university teaching full of useless technical terms and solutions in search of problems...
- JadeNB 7y ago> solutions in search of problems... This sounds like it was meant to be pejorative, but it's what (applied) linear algebra, and applied mathematics more generally, is. Anyone can learn about a certain mathematical topic upon realising it's the one relevant to the problem they're facing—and learn it way more quickly, due to motivation and focus, than they would in a general-purpose course on the topic; the art is in recognising what mathematics is relevant, and you can't do that if you've never heard of it before. Having a library of (conceptual, not cookbook) solution hooks on which to hang your problems is how you get to be good at using mathematics.
- alacombe 7y agoOf course it was meant to be pejorative and that pretty much summarize my experience through university. In this particular case, the teacher wasn't giving a rat arse about his class and was merely there for the safe job, pension, sprinkles by some "research". Anyhow, I disagree with that top-down approach, which seems to be very... European. I much prefer to follow a more logical path where the problem preclude the introduction to the solution.
- JadeNB 7y ago> Anyhow, I disagree with that top-down approach, which seems to be very... European. I much prefer to follow a more logical path where the problem preclude the introduction to the solution. I agree that it's easier to learn that way, but it's not much use when solving real-world problems; you can learn the techniques relevant to the solution once you know what they are, but, if you haven't met them before, you won't recognise that they're the right ones.
- dundercoder 7y agoDoes something like this exist for differential equations?
- sci_c0 7y agoMay be this can help you: https://www.youtube.com/playlist?list=PLZHQObOWTQDNPOjrT6KVlfJuKtYTftqH6 https://www.youtube.com/playlist?list=PLZHQObOWTQDNPOjrT6KVl... This is 3Blue1Brown's video series on Differential Equations. Do support him on Patreon if this really helps you.
- adamcharnock 7y agoI... I still really struggle with this. I'm a smart person, I've got a bachelors of engineering, I've been a professional software developer for around 14 years now, and I've built a house. But there is something about degree-level maths and beyond that I find deeply unintuitive in a way that software development isn't. Through comments here I found 3blue1brown's (clearly much loved) videos. By the third video I was shouting, "why for the love of god would we be doing this"? Based on this reaction I suspect that the content neither has intrinsic appeal to me, nor does it have obvious use in my work, projects, or life. Pre-degree maths though, I love. My A-level maths really changed how I saw the world, and I make use of it reasonably often (well, often enough to not forget it). I think I'm writing this here because most other commenters seem to really grasp this subject, or feel that they grasp it better having seen these videos. I'm honestly happy for you. However, if anyone is reading this who doesn't feel like that, then know you're not alone :-)
- amelius 7y agoTry Gilbert Strang's course at MIT, it's publicly available in video format, and starts from basic principles.
- dragontamer 7y agoThe problem with Linear Algebra specifically, is that it can be viewed from many different perspectives. The article here focuses on an "operational" perspective, how the numbers get added or multiplied together to turn into other numbers. However, Linear Algebra is also useful in geometry, and other situations. This "intuitive guide" to linear algebra sets you up very nicely for figuring out how to add and multiply matricies together. But it doesn't give you any intuition about a rotation (aka quaternions) in 3d space, for example. A lot of math books make the mistake of trying to teach all the perspectives at the same time, instead of focusing on just one viewpoint until the student gains mastery. A Quaternion is "just" a 4x4 matrix that represents rotation in 3-dimension space. Because you only move 3-ways rotationally (yaw, pitch, and roll), you're "underconstrained" with regards to the 4x4 matrix. Etc. etc. A lot of geometry intuition needs to be built here to really understand Quaternion... and none of that geometry is explored in the blogpost. Which is fine. Focus is good. But when people approach Linear Algebra, its important to know that its "so useful" that there are too many ways of looking at Linear Algebra... too many different, yet equivalent, understandings of the subject.
- nearlynameless 7y agoWhile this explanation is certainly much clearer than what I remember of high school maths, I still have a pretty tough time following the formula examples. When I see A(x) = ax, I'm not entirely sure how to read it. Is A meant to be a function that accepts x? If so, why is the equivalent expression a * x? Is it supposed to be implied that function A also has some hidden value "a" that is going to be multiplied by the supplied value? Is this notation specific to multiplication, to this expression, or what? Positing that something is 'intuitive' when it depends so much on additional contextual knowledge seems ever so slightly disingenuous as best, and slightly harmful at worst; it can make the reader feel as though they must be dumb for not understanding this 'intuitive' material. I do acknowledge that this is linear algebra, and if one doesn't have a really solid grasp of notation of regular algebra it is likely to go over their heads, but the practical explanations (such as the slope rise/run example) are quite clear and relatively simple to follow; it follows that a simple explanation of the notation might be helpful too.
- kdtop 7y agoI agree that this was a bit confusing. Higher up in the article, it shows that a linear function is one that doesn't change when scaled: F(a * x) = a * F(x) This is showing the relationship between two uses of the same function. Then, further along, we find: "So, what types of functions are actually linear? Plain-old scaling by a constant, or functions that look like: F(x)=ax In our roof example, a=1/3" I think in this second situation, F(x)=ax is not a relationship but rather a DEFINITION of the function F(x). In programming terms: function F(x: real) : real; begin Result := x * (1/3); end;
- rustybolt 7y agoThe particular example might be confusing because the same letter is used twice with different capitalization. There is no direct relation between them. > Is A meant to be a function that accepts x? Yes. > If so, why is the equivalent expression a * x? Because that how A(x) is defined. >Is it supposed to be implied that function A also has some hidden value "a" that is going to be multiplied by the supplied value? Yes, it's an unspecified constant (a, b, c... are used to denote constants by convention), so you can really calculate A(x) for supplied values of x yet until the constant 'a' is specified. > Is this notation specific to multiplication, to this expression, or what? No. Functions might be defined using any expression. For example A(x) = b^x is a valid function as well (again, we have an unspecified constant). Just don't expect to encounter it in an introductory course in linear algebra (since it would deal mostly with linear functions).
- andrepd 7y agoGoes to show how different people have different tastes. I find this type of exposition very confusing and very unenlightening. Give me a Landau-style "minimalistic"/"focused" explanation any day. Not to mention, it tries so hard to simplify things to a simple analogy (the spreadsheet thing) that it ends up being plain misleading. In other words: "Make things as simple as then can be, but no simpler."
- id_ris 7y agoI recently finished going through MIT OCW's linear algebra class from Gilbert Strang. Without the struggle of doing the assignments, reading the text, and watching the lectures, I don't think I would have ever learned the content. While content like this and that from 3blue1brown are commendable and useful, it simply would not have lodged the ideas into my head. Now that the ideas of things like vector spaces, norms, orthogonality, rank, basis, etc are nearly second nature, the concepts are useful as I study other branches of math which would feel impenetrable otherwise. YMMV, and if you can learn from condensed materials go for it, but I might be too dumb for it work lol. I think the real benefit accrues to the author who had to work out how to teach these concepts to others.
- dfabulich 7y ago> While content like this and that from 3blue1brown are commendable and useful, it simply would not have lodged the ideas into my head. I'm not sure I understand your point. Are you just saying that this blog post isn't an adequate substitute for taking a course in linear algebra? (Of course it isn't. But who said it was?)
- abdullahkhalids 7y agoUnfortunately, for a lot of people, including undergraduates, the dopamine hit they get from watching a video or passively reading a textbook makes them believe that these are adequate substitutes for doing thousands of exercises. In my university, undergraduates have admitted that they have done fewer than 50 questions throughout the entirety of my math course. Their grades obviously reflect that, but they will do the same next semester.
- mattkrause 7y agoCan I press you to explain what you think dopamine is/does? I'm curious because I'm a neuroscientist who occasionally works on dopaminergic stuff and "passively reading a textbook" is so far from the canonical examples we use for dopamine activity, but the idea of dopamine/dopamine 'hits' has taken on a life of its own that seems quite different from the neurotransmitter.
- bobblywobbles 7y agoThank you for writing this up, or reposting. I agree that it is better to understand math, and computer science, intuitively first. Learning the basics instead of learning how to think in them forces memorization and is frankly in a time gone by. If only I could've been taught this way when I was younger, then I'd actually be any good at any advanced math.
- photon_lines 7y agoThis is a nice resource - I wrote one myself as well which is mostly based on the series by 3Blue1Brown, as well as other resources which I found useful and which used a visual approach to introducing linear algebra. You can find my guide here: https://github.com/photonlines/Intuitive-Overview-of-Linear-Algebra-Fundamentals/blob/master/PDF/An%20Intuitive%20Overview%20of%20Linear%20Algebra%20Fundamentals.pdf https://github.com/photonlines/Intuitive-Overview-of-Linear-...
- sci_c0 7y agohttp://immersivemath.com/ila/index.html http://immersivemath.com/ila/index.html An interactive Linear Algebra course to complement the article.
- diffeomorphism 7y agoThis seems to be "what are matrices and how do you work with them" and not linear algebra. I mean that can be useful sometimes but seems more like something you would teach in a numerics course instead. Actually, I think this way of explaining and motivating things (linear map==matrix) will get really, really confusing once you try to understand changes of bases or eigenvalue decomposition. A linear map is something that takes vectors and spits out vectors while preserving the vector structure (i.e. addition and scalar multiplication on the input give you addition and scalar multiplication of the output).
- rayalez 7y agoAre there resources like this for Calculus/Prob/Stats?
- ukj 7y agoThe only way to test if you've 'understood' something is to apply it to real-world problems. If it works - then you understood it. If it doesn't - then you didn't. "Understanding" without way of external verification seems no different to dopamine-chasing. Measuring on output and all that...
- matteuan 7y agoThe only way to test is if you talk with an expert and he says you have understood. There are many things in linear algebra that you can use in practice even when you didn't really understand them. This is the reason why self-studying certain topics is very hard, you still need (good) teachers to give you constant feedback.
- ukj 7y agoThat seems like a verbalistic notion of 'understanding'. How do I falsify the expert's claims about my understanding?