This method returns a string which can be recognized as a matroid in the Sage matroids package.
Currently this function is purely for demonstrative purposes, using lowercase alphabet letters for the ground set (thus limited to matroids on <= 26 elements), and using a basis description.
The inverse functionality is provided by the function fromSageMatroid.
i1 : V = specificMatroid "vamos" o1 = a matroid of rank 4 on 8 elements o1 : Matroid |
i2 : s = toSageMatroid V o2 = Matroid(groundset = 'abcdefgh', bases = ['abce','abde','acde','bcde','abcf','abdf','acdf','bcdf','abef','acef', 'bdef','cdef','abcg','abdg','acdg','bcdg','abeg','aceg','bceg','adeg', 'bdeg','cdeg','abfg','acfg','bcfg','adfg','bdfg','cdfg','aefg','befg', 'cefg','defg','abch','abdh','acdh','bcdh','abeh','aceh','bceh','adeh', 'bdeh','cdeh','abfh','acfh','bcfh','adfh','bdfh','cdfh','aefh','befh', 'cefh','defh','abgh','acgh','bdgh','cdgh','aegh','begh','cegh','degh', 'afgh','bfgh','cfgh','dfgh','efgh']) |
i3 : class s o3 = String o3 : Type |
i4 : fromSageMatroid s === V o4 = true |
The object toSageMatroid is a method function.