GithubHelp home page GithubHelp logo

category-theory's Introduction

Category Theory

I'm learning category theory by trying to explain it. This is a work in progress. Please open an issue or fork and submit a pull request if you find a mistake.

What is category theory, and how do I use it?

Category theory is a mathematical language that formalizes the notion of process. Anytime you want to talk about processes with input and output, category theory will be useful.

A category $C$ consists of:

  1. a collection of objects denoted $\text{Ob}(C)$. If $X$ is an object of $C$, then write $X \in C$.
  2. for every pair of of objects $(X, Y)$, a set of processes (or usually "morphisms") $\text{Proc}(X, Y)$ that transform $X$ into $Y$. If $f \in \text{Proc}(X, Y)$, then write $f : X \to Y$;

with the following rules that ensure processes actually behave like processes with objects as inputs and outputs:

  • for processes $f : X \to Y$ and $g : Y \to Z$, there is a process $gf : X \to Z$ (read "$g$ after $f$" or "g composed with f"),
  • for every object $X$, there is a process that does nothing $1_X : X \to X$ called the identity of $X$ such that $f = f 1_X$ and $f = 1_Y f$ for any process $f : X \to Y$,
  • $hgf = (hg)f = h(gf)$ if the objects of inputs and outputs are compatible.

Processes are prevalent. When programmers program, physicists do physics, and mathematicians do math, they are trying to describe or engineer processes.

You can use category theory to talk about other mathematical languages and dig up relationships between them. You can even use categories to talk about categories.

My goal here is to show you how to use category theory, so let's start with some examples.

category-theory's People

Contributors

lukeburns avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.