| Home | Trees | Indices | Help |
|
|---|
|
|
Mathematical Sets and Power Sets
| Classes | |
|
MathSet Mathematical set, allows unhashable elements. |
|
|
SubSet Subset of selected MathSet, or other Iterable. |
|
|
CartesianProduct List of MathSets, with Cartesian semantics. |
|
|
PowerSet Efficiently store power set of a mathematical set. |
|
|
TypedDict dict subclass where values can be constrained by key. |
|
| Functions | |||
| bool |
|
||
|
|
||
|
|||
|
|||
|
|||
| Variables | |
logger = logging.getLogger(__name__)
|
|
__package__ =
|
|
| Function Details |
Compare list contents, ignoring ordering. Hashability of elements not assumed, incurring O(N**2) See Also
|
Return unique elements. NoteAlways returning a list for consistency was tempting, however this defeats the purpose of creating this function to achieve brevity elsewhere in the code.
|
powerset([1,2,3]) --> () (1,) (2,) (3,) (1,2) (1,3) (2,3) (1,2,3) From http://docs.python.org/2/library/itertools.html, also in https://pypi.python.org/pypi/more-itertools |
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Sat Nov 19 00:11:17 2016 | http://epydoc.sourceforge.net |