Category Archives: math

Species definition clarification and exercises

[This is the fourth in a series of posts about combinatorial species. Previous posts: And now, back to your regularly scheduled combinatorial species; Decomposing data structures; Combinatorial species definition.] In my previous post I neglected to mention something quite crucial, … Continue reading

Posted in math, species | Tagged , , , | 3 Comments

Combinatorial species definition

Continuing from my previous post, recall that the goal of species is to have a unified theory of containers with labeled1 locations. So, how do we actually specify such things (leaving aside for the moment the question of how we … Continue reading

Posted in math, species | Tagged , , , , | 7 Comments

foldr is made of monoids

> import Data.Monoid In his recent blog post What is foldr made of?, Tom Ellis made the clever observation that foldr is equivalent in power to the combination of map and compose, where > compose :: [a -> a] -> … Continue reading

Posted in haskell, math | Tagged , , , , | 15 Comments

Decomposing data structures

So, what are combinatorial species? As a very weak first approximation, you can think of them as a generalization of algebraic data types.1 That doesn’t really say much about what they are, but at least it does explain why programmers … Continue reading

Posted in math, species | Tagged , , , | 9 Comments

And now, back to your regularly scheduled combinatorial species

I’ve already mentioned this to people here and there, but haven’t yet announced it publically, so here it is: Stephanie Weirich and I have been awarded a grant from the NSF to study the intersection of combinatorial species and (functional) … Continue reading

Posted in combinatorics, math, writing | Tagged , | 10 Comments

Generating plane tilings with diagrams

I’ve finally set up a diagrams-contrib package to serve as a home for user contributions to the diagrams project—generation of specialized diagrams, fun or instructive examples, half-baked ideas, stuff which is not sufficiently polished or general to go in the … Continue reading

Posted in diagrams, haskell, math, projects | Tagged , , | 3 Comments

Themes on Streams, Part II

In a previous post I claimed that comonad structures on R -> a are in one-to-one correspondence with monoid structures on R. In this post and the next I’ll justify that claim. Characterizing comonads on R -> a Suppose we … Continue reading

Posted in haskell, math | Tagged , , , , | 2 Comments

Themes on Streams

> {-# LANGUAGE DeriveFunctor, FlexibleInstances #-} Recall that a stream is a countably infinite sequence of values: > data Stream a = a :> Stream a > deriving (Functor, Show) > > sHead (a :> _) = a > sTail … Continue reading

Posted in haskell, math | Tagged , , , , , | 3 Comments

Math.OEIS needs a new maintainer

Summary: the OEIS has switched servers and the oeis package needs updating to match, so I’m looking for someone to take over development. All the rest is padding in the form of entertaining stories. Recently, Michael Snoyman’s wonderful packdeps tool … Continue reading

Posted in haskell, math, projects | Tagged , , , , | 4 Comments

Things I have learned about vector spaces

Work on the diagrams library is coming along rather nicely. I’ll have more to say about it soon, but for now here are two things I have learned recently: Normals transform as the inverse transpose (see Subject 5.27). Be very … Continue reading

Posted in math, projects | Tagged , , , , , , , | 4 Comments