[sage-support] recurrence relation

2011-04-17 Thread raman
Hello Dears could you please tell me how I can write the recurrence relation by sage? for example p(n)=2p(n-1)+p(n-2) where p(0)=1 and p(1)=3 -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to

Re: [sage-support] recurrence relation

2011-04-17 Thread amaseam
2011/4/17 raman raman.kurdi2...@gmail.com: Hello Dears could you please tell me how I can write the recurrence relation by sage? for example p(n)=2p(n-1)+p(n-2) where p(0)=1 and p(1)=3 you could do this: def p(n): if n == 0: return 1 if n == 1: return 3 l = (1,3) for i in

[sage-support] recurrence relation for a system of simultaneous equations

2007-09-28 Thread David Stahl
I have a system of polynomial equations with rational coefficients and I have one rational solution. I am trying to find a recurrence relation that will allow me to generate additional rational solutions. The equations are: A6x0^2+A5x1^2+A4x2^2+A3x0x1+A2x0x2+A1x1x2+A0=0 (a)