# New Package: Matroids

**URL:** https://discourse.julialang.org/t/new-package-matroids/125716
**Category:** Package Announcements
**Tags:** optimization, linear-algebra, graph-theory, matroid
**Created:** [February 10, 2025, 1:25am UTC](https://discourse.julialang.org/t/new-package-matroids/125716 "2025-02-10T01:25:48Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![scheinerman](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/scheinerman/32/35303_2.png) [@scheinerman](https://discourse.julialang.org/u/scheinerman)
#### Post date: [February 10, 2025, 1:25am UTC](https://discourse.julialang.org/t/new-package-matroids/125716/1 "2025-02-10T01:25:48Z")

</div>

I am pleased to announce the creation of a [Matroids](https://github.com/scheinerman/Matroids.jl) module for Julia.

Matroids provide an abstract notion of linear independence, and may be considered a generalization of matrices and graphs. Roughly speaking, they are the setting in which the greedy algorithm works. Much more information in the [documentation](https://docs.juliahub.com/General/Matroids/stable/). [Be sure to skip past the 0.0.x versions of the documentation.]

A few details:

- Our implementation of matroids is based on rank functions as it is infeasible to store all the independent sets, or even just the bases, of modest size matroids.
- This module provides many basic methods (deletion, contraction, dual, closure, etc.). More needs to be done.
- Matroid ground sets are always of the form `{1,2,...,m}` and in that way are compatible with the [Julia Graphs](https://juliagraphs.org/Graphs.jl/stable/) ecosystem.

I hope there are a few people who find this useful 🙂 .
