Well, one difference could be that it doesn't actually store the whole
permutation when it's not necessary.  This could be useful for groups
of very large order.

For example, the other day, I was trying to figure out a way to
generate a random permutation of order roughly 2**32 (what I was
trying to do was randomize some Python hashes).  There is the function
random_permutation, but this generates the whole permutation, which
would take up way too much space.  What I would rather have is some
lazy evaluation, where it generates unknown permutations "on the fly".
 This could be easily implemented as a dictionary.

Aaron Meurer

On Tue, Mar 20, 2012 at 11:05 PM, Saptarshi Mandal
<[email protected]> wrote:
> Sounds good. I am just not sure if *implementing* a pure abstract
> group class is the best way to go. From an implementation perspective,
> it would be very convenient if the abstract group class encapsulates
> the permutation group class. Implementing any other concrete group
> will then require one to a) inherit the abstract class, b) map the
> group operation to an appropriate permutation group operation and c)
> construct an isomorphism from the concrete group to the permutation
> group. This way we can reuse all the algorithms that have been
> implemented for permutation groups. This strategy is useful for
> implementation because perm group algorithms are the simplest to
> implement.
>
> I have not looked at the source code of GAP but I think the abstract
> groups that GAP allows you to create are really permutation groups
> masquerading as abstract groups. I could be hopelessly wrong though.
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sympy" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/sympy?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sympy?hl=en.

Reply via email to