OKlibrary  0.2.1.6
IndependentSets.mac
Go to the documentation of this file.
```00001 /* Oliver Kullmann, 9.2.2008 (Swansea) */
00002 /* Copyright 2008, 2009 Oliver Kullmann
00003 This file is part of the OKlibrary. OKlibrary is free software; you can redistribute
00004 it and/or modify it under the terms of the GNU General Public License as published by
00005 the Free Software Foundation and included in this library; either version 3 of the
00006 License, or any later version. */
00007
00022 oklib_include("OKlib/ComputerAlgebra/Hypergraphs/Lisp/Basics.mac")\$
00023 oklib_include("OKlib/ComputerAlgebra/Hypergraphs/Lisp/Transversals/Minimal/RecursiveSplitting.mac")\$
00024 oklib_include("OKlib/ComputerAlgebra/Hypergraphs/Lisp/SetSystems.mac")\$
00025
00026
00027 /* Checking whether I is an independent set for set system S (S may be also
00028    a list of sets).
00029    Note that I doesn't need to be maximal.
00030 */
00031 independentset_p(I,S) := every_s(lambda([H], not subsetp(H,I)), S)\$
00032
00033
00034 /* *************************************************
00035    * The independency hypergraph (of a hypergraph) *
00036    *************************************************
00037 */
00038
00039 /* The hypergraph of maximal independent sets of a hypergraph G, via
00040    hypergraph-transversals: */
00041 /* RENAME: independence_hg_tr */
00042 independence_hyp_tr(G, Tr) := ecomp_hyp(Tr(G))\$
00043 independence_hg_tr(G, Tr) := independence_hyp_tr(G, Tr)\$
00044 /* RENAME: independence_hg_trrs */
00045 independence_hyp_trrs(G) := independence_hyp_tr(G, transversal_hyp_rs)\$
00046 independence_hg_trrs() := independence_hyp_trrs(G)\$
00047
```