On Feb 10, 11:16 am, Simon King <simon.k...@nuigalway.ie> wrote:
> sage: f = y(n+2) - y(n+1) - y(n)

ahh ... ok. now i get it ^^
When I look into sympy/solvers/recurr.py right the first thing rsolve
does is to compute lhs - rhs. So, f = y(n) == y(n-1) - y(n-2) *should*
work. But it doesn't, because that equation doesn't get transformed
into a sympy Equality (just a "bool").

This works:

sage: f = Equality(y(n), y(n-1) + y(n-2))
sage: rsolve(f, y(n))
C0*(1/2 + 5**(1/2)/2)**n + C1*(1/2 - 5**(1/2)/2)**n

I'm +1 for introducing rsolve in sage (and yes, more namespace
pollution, but we have to think about all the newcomers who expect
some easy functions to work just out of the box, integrate, diff,
etc...)

H

-- 
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