isConnected M
A matroid M is called connected if for every pair of distinct elements f, g in M, there is a circuit containing both of them. This turns out to be equivalent to saying that there does not exist an element e in M with rank({e}) + rank(M  {e}) = rank(M) (note that <= always holds by submodularity of the rank function).
This method checks connectivity using the first definition above. The second definition generalizes to higher connectivity  cf. is3Connected. In the language of higher connectivity, a matroid is connected (in the sense of the two definitions above) if and only if it is 2connected, i.e. has no 1separation.
To obtain the connected components of a matroid, use components.



