Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
tutorial:apps_matroid [2009/11/03 12:59] – Links to tutorial:graph_tutorial changed to tutorial:apps_graph sherrmann | user_guide:tutorials:apps_matroid [2019/02/04 22:55] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Short Introduction to New Application '' | + | {{page>.: |
- | + | ||
- | The application '' | + | |
- | + | ||
- | To make '' | + | |
- | + | ||
- | ===== Constructing a Simple Matroid and Playing Around ===== | + | |
- | + | ||
- | This is how to produce a matroid from a vector configuration. | + | |
- | + | ||
- | < | + | |
- | matroid > $M=new Matroid(POINTS=> | + | |
- | </ | + | |
- | + | ||
- | If '' | + | |
- | + | ||
- | < | + | |
- | polytope > $M=new matroid:: | + | |
- | </ | + | |
- | + | ||
- | Output of basic statistics. | + | |
- | < | + | |
- | matroid > print $M-> | + | |
- | 3 4 3 | + | |
- | </ | + | |
- | + | ||
- | The '' | + | |
- | + | ||
- | < | + | |
- | matroid > print $M-> | + | |
- | {0 1 2} | + | |
- | {0 2 3} | + | |
- | {1 2 3} | + | |
- | </code> | + | |
- | + | ||
- | Similarly you can compute the circuits and cocircuits. | + | |
- | + | ||
- | < | + | |
- | matroid > print $M-> | + | |
- | {0 1 3} | + | |
- | + | ||
- | matroid > print $M-> | + | |
- | {2} | + | |
- | {0 1} | + | |
- | {0 3} | + | |
- | {1 3} | + | |
- | </ | + | |
- | + | ||
- | ===== Matroid Polytopes ===== | + | |
- | + | ||
- | You can construct a polytope from the bases of a matroid as the convex hull of the characteristic vectors of the bases. | + | |
- | + | ||
- | < | + | |
- | matroid > print $M-> | + | |
- | 1 1 1 1 0 | + | |
- | 1 1 0 1 1 | + | |
- | 1 0 1 1 1 | + | |
- | + | ||
- | matroid > print $M-> | + | |
- | 3 3 | + | |
- | </ | + | |
- | + | ||
- | ===== Other Constructions ===== | + | |
- | + | ||
- | The vertices of a polytope give rise to a matroid. | + | |
- | + | ||
- | < | + | |
- | matroid > $C=new Matroid(POINTS=> | + | |
- | + | ||
- | matroid > print $C-> | + | |
- | 58 | + | |
- | </ | + | |
- | + | ||
- | The system also allows you to construct a matroid from a graph. | + | |
- | + | ||
- | < | + | |
- | matroid > $G=matroid_from_graph(polytope:: | + | |
- | + | ||
- | matroid > print $G-> | + | |
- | 792 | + | |
- | </ | + | |