Project Summary

  Analyzed 11 days ago based on code collected 11 days ago.

This module exports one function, equivalence_sets(), which takes a list of sets and returns another list of sets whose contents are transitively grouped from the input sets.

Imagine the input sets to be [ 1, 2 ], [ 3, 4 ], [ 5, 6 ] and [ 1, 3, 7 ]. The returned sets would be [ 1, 2, 3, 4, 7 ] and [ 5, 6 ], because [ 1, 2 ] and [ 3, 4 ] are tied together by [ 1, 3, 7 ], but [ 5, 6 ] stands on its own. So you could say the returned sets represent a kind of transitive union. (Real mathematicians may now flame me about the misuse of terminology.)

Each set is an array reference. The return sets are given as an array in list context, or as a reference to that array in scalar context.

Tags

  perl

Share

In a Nutshell, Algorithm-EquivalenceSets...

 

Activity

30 Day Summary May 9 2013 — Jun 8 2013

12 Month Summary Jun 8 2012 — Jun 8 2013

Community

Ratings

Be the first to rate this project
 
Click to add your rating
 
Review this Project!
 
 
 

Creative Commons License Copyright © 2013 Black Duck Software, Inc. and its contributors, Some Rights Reserved. Unless otherwise marked, this work is licensed under a Creative Commons Attribution 3.0 Unported License . Ohloh ® and the Ohloh logo are trademarks of Black Duck Software, Inc. in the United States and/or other jurisdictions. All other trademarks are the property of their respective holders.