18 ms·
What Is Applied Category Theory? (2018)
- _Microft 6y agoIf the author’s name sounds familiar despite you not being in this field: she is writing the excellent blog at https://www.math3ma.com https://www.math3ma.com and you might know her from there. Articles of this blog are submitted here from time to time.
- creata 6y agoShe also hosted the YouTube math channel PBS Infinite Series. https://www.youtube.com/c/pbsinfiniteseries/featured https://www.youtube.com/c/pbsinfiniteseries/featured
- _Microft 6y agoTwo points to you for nerd-sniping a physicist with the "assassin problem" episode that auto-ran when I followed the link. Have a nice day!
- kbr 6y agoAs a high schooler interested in things that are probably out of my league, I love reading this kind of stuff. The author mentions their unconventional style at the beginning: hyperlinks, color, italics, exclamations, parentheses, side notes, etc. They address your thoughts and craft their explanations around them instead of being terse and optimizing for length. The author's blog [1] has more of this style and has really helped me get deeper into category theory. Without it, I wouldn't have even begun to try and understand things like the Yoneda lemma (which still remains a mystery to me). Does anyone know any other papers or resources with this style? Maybe something like "explorable explanations" [2]? [1] https://www.math3ma.com/ https://www.math3ma.com/ [2] https://explorabl.es/ https://explorabl.es/
- enchiridion 6y agoI don't have any resources to share on this, but I was also interested in this type of thing at your age (still am). If it interests you, never assume something is out of your league. You have time on your side. Sustained effort compounded over time is unreasonably powerful. Keep pushing!
- kbr 6y ago> Sustained effort compounded over time is unreasonably powerful. Thank you, this hits close to home and is great advice, I appreciate it.
- crdrost 6y ago90s-ish videogame lore, “Time is an ally, not an enemy. Patience can sharpen even the smallest of efforts into a weapon that can strike the heart of an empire.” On my cube walls, whenever I get back to my cube: “magic is just cleverly concealed patience.” The approximate η-expansion: you can generally figure out what professional magicians do, you just dismiss it, “I mean of course she coulda known what card I was going to pull if she bought 52 decks of cards and assembled an entire card made out of the Jack of Spades... but that’s expensive and difficult and who would do that.” Penn Jillette puts the same point a different way, saying that he is going to have to perform the same trick over and over again and so it cannot be 99% likely to not injure him, that is far, far too low, he has to be 100% certain his tricks are safe. If he is firing a nail gun at Teller’s neck it must surely be incapable of firing a nail at Teller, and if he waxes on about how much he has memorized the pattern of the nails in the gun then he must be cleverly concealing whatever patience went into making that nail gun and the illusion that it is loaded. But the key is that once you see this one place you see it everywhere. A restaurant works by the same magic. You say what you want and it magically appears before you. How did that happen? Prep work for hours in advance of the meal, so that when the time comes I just need to put tab A in slot B. Like a beef wellington; pre-cooked steak wrapped into a nice little bundle that just needs to be finished in the oven for 20 minutes and sliced. Something to think about next date night—you can impress your date immensely if you make the wellingtons the night before, so that your focus is on your lover and not on your cutting board. You don’t usually think about the prep work that went into the Mother of All Demos, but you should. Sometimes when Alan Kay shows a clip from there, he mentions something like, “you might notice that they get sub-second latency on all these operations, but the terminal was here and the computer was over there so I like to ask students how they got sub-second latency on all these operations, and only one time have I got the right answer, one student said ‘because they wanted sub-second latency?’ and that is absolutely correct, they-goddamn-wanted-subsecond-latency, these things are there for you if you really want them.”
- psychoslave 6y agohttps://betterexplained.com https://betterexplained.com if you haven’t been through it yet. Already often quoted on HN, and some discussions are interesting with the author bringing feedback. https://hn.algolia.com/?q=https%3A%2F%2Fbetterexplained.com https://hn.algolia.com/?q=https%3A%2F%2Fbetterexplained.com
- deleted 6y ago[deleted]
- konamicode 6y agoIf you’re interested in machine learning I can recommend Christopher Olah’s blog: https://colah.github.io/ https://colah.github.io/
- mhh__ 6y agoAlthough they might be very out of your league depending on what your interests are, Anthony Zee has a similar writing style (in print)
- xelxebar 6y agoNot addressing your question, but the Yoneda Lemma is kind of a charlatan. On first reading, it seems magical and deep, but once you grok the proof, it feels like a relatively trivial observation. The whole thing is just about arrow composition! In a way, once you're on the other side, the Yoneda Lemma feels a bit like a checkpoint during the accimatization period where your brain gets used to thinking in categories and commutative diagrams. Not quite sure it's exactly the style you're talking about, but Bartosz Milewski has a nice series of video lectures going all the way from nothing up to Coend stuff. IIRC the series gets to the Yoneda Lemma somewhere in the second series: https://invidious.snopyta.org/channel/UC8BtBl8PNgd3vWKtm2yJ7aA https://invidious.snopyta.org/channel/UC8BtBl8PNgd3vWKtm2yJ7...
- Gormisdomai 6y ago"On first reading, it seems magical and deep, but once you grok the proof, it feels like a relatively trivial observation. The whole thing is just about ____ composition!" I think if you replace _____ with the right word almost every result I've seen in my (albeit somewhat limited) exposure to category theory can be described this way. (not that that detracts from your answer!)
- eli_gottlieb 6y agoWell yeah, because category theory studies composition. That's what it's for. That's why a category is defined the way it is: a bunch of objects, identity arrows from each to itself, and arrows between them, which enjoy an associative composition operator.
- Garlef 6y ago> The whole thing is just about arrow composition! There's much much more to it. For example, a version of the yoneda lemma also holds for metric spaces (instead of a set of arrows between to things, you simply have a number indicating a distance between two things). Here's how I like to think about the yoneda lemma: If you have some kind of objects you want to talk about, one way to do this is by relating these objects to each other. Once you have established such a "method of discourse" (i.e. a way to talk about how your objects relate to each other) the yoneda lemma tells you: 1. You can forget about the inner structure of your objects; Everything is already contained in your "method of discourse". 2. Inversely: The choice of a "method of discourse" severely limits what you can say about your objects. 3. There is no spoon: To understand how you can escape these limitations you need a "method of discourse" for "methods of discourse".
- bmitc 6y agoYou may like the books Conceptual Mathematics: A First Introduction to Categories, Creative Mathematics, Advanced Calculus: A Differential Forms Approach, and Geomtrical Vectors. https://www.amazon.com/dp/052171916X/ https://www.amazon.com/dp/052171916X/ https://www.amazon.com/dp/0883857502/ https://www.amazon.com/dp/0883857502/ https://www.amazon.com/dp/0817637079/ https://www.amazon.com/dp/0817637079/ https://www.amazon.com/dp/0226890481/ https://www.amazon.com/dp/0226890481/
- monktastic1 6y agoNot exactly what you asked for, but this explanation of the Yoneda Lemma is amazing: https://youtu.be/h64yZs8ThtQ https://youtu.be/h64yZs8ThtQ
- neolog 6y ago(2018)
- bschne 6y agoI've never actually gotten around to diving into this topic before, but every time one of Tai-Danae Bradley's publications pops up I am awed by how much care she puts into crafting these from the layout to the illustrations
- bikenaga 6y agoI think she's using the LaTeX package for Edward Tufte's style: https://edwardtufte.github.io/ https://edwardtufte.github.io/ (If you like the design, you'd like Tufte's books.) Anyway, her paper is fun to read and one of the most beautiful papers I've read in terms of layout and design - I like the contrast between the hand-drawn illustrations and the abstract content. It reminds me of Lin Clark's Code Cartoons (https://code-cartoons.com/ https://code-cartoons.com/) .
- gugagore 6y agoThere is an applied category theory course that is currently in the process of wrapping up: https://applied-compositional-thinking.engineering/ https://applied-compositional-thinking.engineering/ The examples in the course offer a complementary entry point to category theory compared to an approach that leverages programmers' knowledge of functional programming. Personally, the more examples the better. I'm grateful to be able to rely on the example of a category as a collection of objects corresponding to types, and arrows between types corresponding to functions with that type signature, and arrow composition corresponding to function composition (and functors, and natural transformations, and ... corresponding to familiar concepts like polymorphic types, and map, and polymorphic functions and ...). I believe that many programmers can [come to] understand this one specific example of category theory objects, even if the words are unfamiliar. And there are so many more examples! There is a great pleasure in formalizing the analogies across different aspects of math and engineering. To get a flavor of and gentle introduction to the analogy-making power of category theory, I recommend this talk by Eugenia Cheng: https://www.youtube.com/watch?v=ho7oagHeqNc https://www.youtube.com/watch?v=ho7oagHeqNc
- wires 6y agoWorth mentioning that we are offering a high-quality (paid) course https://training.statebox.org https://training.statebox.org
- fredgrott 6y agoTo give you an idea of how we are using this pdf.. I am reapplying category theory to use functions in dart-Flutter to avoid using statefull widgets and instead use a reactive function approach to state management. Side benefits is it's easier to explain to beg flutter devs than statefull widgets. Thanks behnamoh for posting this link
- Ceezy 6y agoIf anybody interested the best book to learn the category theory: https://www.maths.ed.ac.uk/~v1ranick/papers/maclanecat.pdf https://www.maths.ed.ac.uk/~v1ranick/papers/maclanecat.pdf
- ectoplasmaboiii 6y agoFor anyone else interested, Tom Leinster (also of Edinburgh Uni) has also written a good short book for beginners: https://www.maths.ed.ac.uk/~tl/bct/ https://www.maths.ed.ac.uk/~tl/bct/ I did his course at uni that used this book as a basis and it was great. Tough, but great.
- jbotz 6y agoWhy do you think this is the best book? And would someone's background, or lack thereof, in other fields of mathematics not have a bearing on that assessment?
- threatofrain 6y agoIf someone lacks interest in math I’m not sure category theory makes sense even in the FOMO way.
- Koshkin 6y agoTo someone who is not interested in math per se but rather in its applications to engineering, category theory, too, has something to offer.
- Ceezy 6y agoCause that's it's reputation in math circles. And recommended by most of my teachers. Also because I used it a lot. You don't need to read it top to bottom. I think people here are interested by monoid and stuff. But to do the monoid part you don't really need category. An Algebra course about monoid is good enough actually.
- bikenaga 6y agoMac Lane was one of the founders of category theory - see for example: "General Theory of Natural Equivalences" - Samuel Eilenberg and Saunders MacLane. Transactions of the American Mathematical Society, Vol. 58, No. 2, (Sep., 1945), pp. 231-294 His "Categorical algebra" paper from 1964 is open-access: https://projecteuclid.org/euclid.bams/1183526392 https://projecteuclid.org/euclid.bams/1183526392 When his book came out it was the standard work for a while. I think some of the terminology he uses is no longer standard, and there are now many very good modern introductions. But his book is still a pretty good read, primarily because he was a wonderful writer with a very distinctive style. That said, the examples (given the time the book was written) are almost exclusively mathematical. The proofs and exercises are usually not difficult, but at a high level of abstraction (not surprisingly).
- newswasboring 6y agoCategory Theory is one of those things which I know are important and has applications in many engineering fields. I also have an intuition that its obviously because things need to flow into each other and composability is how we achieve that. But man, whenever I try to get into this I feel like someone is hitting me on the head with equations.
- user-the-name 6y agoMaybe for a value of "has applications" that doesn't necessarily include anyone actually applying it. As a generalisation, I don't think anyone by people into category theory actually cares about or applies category theory.
- deleted 6y ago[deleted]
- newswasboring 6y agoShouldn't it be easier to explain a general concept than a specific one? The only reason I can think of why this isn't happening is because you need to learn a large amount of information before any of the category theory stuff can be applied in real life. But honestly speaking, that can't be true because languages like Haskell exist and isn't that on the whole programming using category theory? (I am be completely wrong about this). OTOH it can also be just a pedagogy issue. That nobody has figured out how to condense it into an undergraduate level so working engineers can grasp basics.
- seagreen 6y ago> languages like Haskell exist and isn't that on the whole programming using category theory? It's not. However claims like that get thrown around a fair amount so the confusion is understandable. That said, some important Haskell abstractions were designed using category theory. So it can be helpful to know some of the lingo (since it will show up in abstraction names and descriptions). And if you're looking to design the next breakthrough Haskell abstraction it might be extremely helpful, but that's not 99% of programmers. However, the people who can do that are super cool, eg https://www.staff.ncl.ac.uk/andrey.mokhov/selective-functors.pdf https://www.staff.ncl.ac.uk/andrey.mokhov/selective-functors....
- dmch-1 6y agoSamuel Eilenberg, one of the founders of category theory, used to tell to his students "You should have you own category". Meaning, that when you work on category theory you should have in mind applications to something. One of his students used to say "my category is Cat". Cat means the category of categories.
- Upvoter33 6y agoAs an aside, I love the look and feel of this document. It is a beautiful read.
- spinningslate 6y agoI'm not a natural mathematician (emphatically not!) and pretty much every attempt I've made to wrap my head around Category Theory has foundered on an onslaught of formalism by paragraph 2. To be clear, I'm not knoocking that: for those who can and do grok things from that sort of treatment, all power to your elbow (and no small amount of admiration). But it's not how my brain works. I need an intuitive understanding first: exemplars, informal pictures, whatever. I can only start unscrambling the formalism once I have the intuition. The author's introductory blog post is a great example [0]. It's without doubt the best "bootstrap" I've come across - where "best" means "most understanable to me". I really admire people who can take abstract/complex subject matters and lay them out in a clear and accessible way for the layperson. Tai-Danae Bradley definitely fits in that Category (dubious pun intended!). [0]: https://www.math3ma.com/blog/what-is-category-theory-anyway https://www.math3ma.com/blog/what-is-category-theory-anyway EDIT: fixed typo
- lachenmayer 6y agoThe Graphical Linear Algebra[0] series is a fantastic introduction to a really fascinating application of category theory, representing vectors & matrices as flow diagrams (ie. monoidal categories) and deriving useful properties from those. The style is super friendly and builds up intuition slowly, while being completely rigorous. For a great example, check out the "Crema di Mascarpone"[1] chapter which introduces all the tools for writing rigorous mathematical proofs using flow diagrams. [0]: https://graphicallinearalgebra.net/ https://graphicallinearalgebra.net/ [1]: https://graphicallinearalgebra.net/2015/05/06/crema-di-mascarpone-rules-of-the-game-part-2-and-diagrammatic-reasoning/ https://graphicallinearalgebra.net/2015/05/06/crema-di-masca...
- cvxz 6y agoCategory theory has applications to quantum circuit minimisation: https://zxcalculus.com/pyzx.html https://zxcalculus.com/pyzx.html and functional programming.
- johndoe42377 6y agoJust a nice set of ideas to be used for social signalling. In with type systems, a typeclass is all you need. The mantra is "to be an X (being substituted for an X) is to be able to perform (implement) such and such actions (or have this or that biochemical properties). It is that general, that deep, it could be even seen in molecular biology. Category theory, on the other hand, is just a few nested abstract concepts, of which only monoid has some connection to reality, which ends up empty, like most abstract pseudo- philosophical bullshit. And yes, I have watched and read everything by Bartosz. It is empty.
- platz 6y agoThere are a lot of claims made to try to apply CT to programming; I agree most of that effort is overhyped. But CT in general has nothing to do with programming, it's proper role is in pure mathematics
- bordercases 6y agoHi Karma.
- johndoe42377 6y agoThis is the first time someone recognised me. By writing style, I suppose.
- bordercases 6y agoI've read a lot of your work and appreciate it. I don't agree with all of it. But all of it is good. And indeed you have a distinct style.
- myWindoonn 6y agoEvery type theory gives a categorical logic [0]. Category theory is all about describing the structures which definitely exist around mathematical objects even if we don't acknowledge them very often. This isn't social signalling; I'm not posting under my real name and I'm not trying to get accolades. This is mathematics; we teach it to each other. [0] https://mikeshulman.github.io/catlog/catlog.pdf https://mikeshulman.github.io/catlog/catlog.pdf
- carapace 6y agoIn re: CT see also Conal Elliott's "Compiling to categories" http://conal.net/papers/compiling-to-categories/ http://conal.net/papers/compiling-to-categories/ Also, "concatinative" languages like Joy. https://en.wikipedia.org/wiki/Joy_(programming_language) https://en.wikipedia.org/wiki/Joy_(programming_language)
- carapace 6y agoFWIW, here's an example of a simple programming task in Joy, the derivation of the step combinator. It might not make a lot of sense without familiarity with Joy, however, the thing to notice is the smooth algebraic form of programming. Making simple obvious decisions at each point leads to a concise and correct program. That's "the function-level programming style of John Backus's FP." in action. You can do it in Haskell (et. al.) too but I find it much easier in Joy. YMMV. The step combinator accepts a list and a quoted program and runs the program on each item in the list in turn. (Use it to write e.g. sum of list of ints, etc.) [] [P] step ----------------- Empty list, no-op. [X|Xs] [P] step ----------------------- Non-empty list, run P and recur. X P [Xs] [P] step In terms of branch and x: step == [F] x So: [L] [P] step ------------------ [L] [P] [F] x ------------------ [L] [P] [F] F First, get the flag value and roll< it to the top for a branch: F == F′ F″ F′ == [?] dipd roll< [L] [P] [F] F --------------------------- [L] [P] [F′ F″] F′ F″ --------------------------------------- [L] [P] [F′ F″] [?] dipd roll< F″ How that works out: [L] [P] [F] [?] dipd roll< F″ [L] ? [P] [F] roll< F″ [L] b [P] [F] roll< F″ [L] [P] [F] b F″ Now we can write a branch: F″ == [Ff] [Ft] branch [L] [P] [F] b F″ ------------------------------------ [L] [P] [F] b [Ff] [Ft] branch The false case is easy: Ff == pop popop ... [] [P] [F] Ff ... [] [P] [F] pop popop ... [] [P] popop ... The true case is a little more fun: ... [X|Xs] [P] [F] Ft We need to uncons that first term, run a copy of P, and recur (recurse? I think re-curse means to "curse again" so it must be "recur".) Ft == Ft′ Ft″ Ft′ == [uncons] dipd ... [X|Xs] [P] [F] [uncons] dipd Ft″ ... [X|Xs] uncons [P] [F] Ft″ ... X [Xs] [P] [F] Ft″ So now we run a copy of P: ... X [Xs] [P] [F] Ft″ Ft″ == [dup dipd] dip Ft‴ ... X [Xs] [P] [F] Ft″ ... X [Xs] [P] [F] [dup dipd] dip Ft‴ ... X [Xs] [P] dup dipd [F] Ft‴ ... X [Xs] [P] [P] dipd [F] Ft‴ ... X P [Xs] [P] [F] Ft‴ And now all that remains is to recur on F: Ft‴ == x ... X P [Xs] [P] [F] x Collecting the definitions, we have: step == [F] x F == F′ [Ff] [Ft] branch F′ == [?] dipd roll< Ff == pop popop Ft == Ft′ Ft″ x Ft′ == [uncons] dipd Ft″ == [dup dipd] dip