species-0.4.0.1: Computational combinatorial species

Copyright(c) Brent Yorgey 2010
LicenseBSD-style (see LICENSE)
Maintainerbyorgey@cis.upenn.edu
Stabilityexperimental
Safe HaskellNone
LanguageHaskell2010

Math.Combinatorics.Species.Labeled

Contents

Description

An interpretation of species as exponential generating functions, which count labeled structures.

Synopsis

Documentation

labeled :: EGF -> [Integer] Source #

Extract the coefficients of an exponential generating function as a list of Integers. Since EGF is an instance of Species, the idea is that labeled can be applied directly to an expression of the species DSL. In particular, labeled s !! n is the number of labeled s-structures on an underlying set of size n (note that labeled s is guaranteed to be an infinite list). For example:

> take 10 $ labeled octopi
[0,1,3,14,90,744,7560,91440,1285200,20603520]

gives the number of labeled octopi on 0, 1, 2, 3, ... 9 labels.

labelled :: EGF -> [Integer] Source #

A synonym for labeled, since both spellings are acceptable and it's annoying to have to remember which is correct.

Orphan instances