SetPartitions() used to create sets of sets (as of, say January 2013).  
That seems to be broken as most common methods on sets will fail (but not 
all).  Any ideas on a simple fix or a good workaround (or an indication of 
what I am doing wrong)?  I can use the standard_form() method to get a list 
of lists, which I can convert back to sets of sets, but that is very 
unnatural (and the reordering will mean lots of needless editing of a very 
long string of doctests).  

Thanks in advance for any ideas.  I can make a trac ticket if that is 
called for.

Rob

sage: S = SetPartitions([1,2,3,4], [2,2]).list()
sage: S
[{{1, 2}, {3, 4}}, {{1, 3}, {2, 4}}, {{1, 4}, {2, 3}}]

sage: S[0].cardinality()
2

sage: S[0].intersection(S[1])
AttributeError: 'SetPartitions_setparts_with_category.element_class' object 
has no attribute 'intersection'

sage: Set(S[0])
TypeError: Element has no defined underlying set

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to