matroid-0.0.0: matroid (combinatorial pre-geometries) library
Copyright(c) Immanuel Albrecht 2020-202x
LicenseBSD-3
Maintainermail@immanuel-albrecht.de
Stabilityexperimental
PortabilityPOSIX
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Matroid.Typeclass.Defaults

Description

This module provides default implementations for the members of the Matroid typeclass.

Synopsis

Documentation

rk Source #

Arguments

:: (Set a -> Set a)

basis filter of the matroid

-> Set a

set of matroid elements

-> Int 

returns the rank of the set, wrt. to the given basis filter

indep Source #

Arguments

:: (Set a -> Int)

the rank function of the matroid

-> Set a

set of matroid elements

-> Bool 

tests whether a given set is independent

basis Source #

Arguments

:: Ord a 
=> (Set a -> Bool)

the independence test of the matroid

-> Set a

set of matroid elements

-> Set a 

obtains an independent subset with maximal cardinality

cl Source #

Arguments

:: Ord a 
=> (Set a -> Int)

the rank function of the matroid

-> Set a

the groundset of the matroid

-> Set a

set of matroid elements

-> Set a 

computes the closure of a given set

loops Source #

Arguments

:: (Set a -> Set a)

the closure operator of the matroid

-> Set a 

returns the loops in the matroid

coRk Source #

Arguments

:: Ord a 
=> (Set a -> Int)

the rank function of the matroid

-> Set a

the ground set of the matroid

-> Set a

set of matroid elements

-> Int 

rank function of the dual matroid

coloops Source #

Arguments

:: Ord a 
=> (Set a -> Int)

the rank function of the matroid

-> Set a

the ground set of the matroid

-> Set a 

returns the coloops in the matroid