Storing a group in a computer I would like to write a program (in C++) that can handle groups. The use shall be solving equations in groups. What's a good idea to store a group?
My plan was:


*

*If the group has a generating system, it is enough to store the generators

*Otherwise, try something implicit (for example, let $(\mathbb{R},+)$ be approximated by all floats, or: this group can be constructed from that group by whatever)


Are there better alternatives to store groups?

It might be helpful to look at what is done in an open-source computer algebra system, such as GAP.  As far as I know, it deals mainly with finitely generated groups, but they must have some way of dealing with some non-finitely-generated groups.  For example, commutator subgroups of f.g. groups aren't always f.g., and I think GAP can still work with them.  
