On 30 jun, 22:45, Ryan Hinton <iob...@email.com> wrote:
> Thanks for the reply!  That's a perfect example of what I am doing
> now.  Can I go one level higher and define my generating function as a
> product of terms *while leaving the actual degrees, coefficients, and
> even the number of dimensions symbolic*.  

I don't know any direct way, but I can suggest:

* Use symbolic variables for the exponents. I understand you need a
potentially infinite number, but maybe you can achieve your goals with
a big finite number, or maybe you can create more variables on the fly
as needed.

* Write some python classes. This could just be a neat way to hide the
creation of variables as they are needed, but with a little more
work...

* Look at sage-combinat. Their Word object behaves in some aspects as
you describe. This could give you inspiration, or maybe something
more:

sage: f = lambda n : add(Integer(n).digits(2)) % 2
sage: Word(f)
word: 0110100110010110100101100110100110010110...

* Wait for someone more inspired to reply.

Good luck!

-- 
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to