Re: Unexpected brainmalfunction [was: Unexpected result with RSolve?]

*To*: mathgroup at smc.vnet.net*Subject*: [mg33671] Re: [mg33661] Unexpected brainmalfunction [was: Unexpected result with RSolve?]*From*: Fernando Rinaldi <fernando.rinaldi at e-technik.uni-ulm.de>*Date*: Sat, 6 Apr 2002 00:48:45 -0500 (EST)*References*: <a8g3e2$b3i$1@smc.vnet.net> <200204050040.TAA16630@smc.vnet.net>*Sender*: owner-wri-mathgroup at wolfram.com

wouter.van.den.broeck at vub.ac.be wrote: > Thanks to all who pointed out the flaw in my deductive thinking ;) > > wouter > > On Wed, 3 Apr 2002 23:32:18 +0000 (UTC), > wouter.van.den.broeck at vub.ac.be wrote: > > >Hey, > > > >There's probably a sound solution, but i'm struggling to grab it: > > > >RSolve[{a[n + 1] == n a[n], a[0] == 1}, a[n], n] > > > >returns: > >{{a[n] -> 0}} > > > >where, i believe it 'should' return > >{{a[n] -> (n-1)!}} > > > >Anyone care to give me some directions as to why this 'unexpected' > >result? > > > >(note: I started of with the standard textbook example: > >RSolve[{a[n] == n a[n-1], a[0] == 1}, a[n], n] > >which returns > >{{a[n] -> n!}} > >so there's no need to correct me in this direction, I just explored a > >bit, and wonder why i'm getting that result with the variation above) > > > >TIA > > > >wouter vdb > > > > > > Mathematica is pretty right.....sure! you wrote: RSolve[{a[n + 1] == n a[n], a[0] == 1}, a[n], n] so for n=0 you start with: a[1]=0 a[0]; so a[1]=0 a[2]=1 a[1] and so a[2]=0 going on a[n]=0 probably you wanted to write this: RSolve[{a[n ] == (n - 1) a[n-1], a[1] == 1}, a[n], n] for getting {{a[n] -> (-1+n)!}} everything is working bye

**References**:**Unexpected brainmalfunction [was: Unexpected result with RSolve?]***From:*wouter.van.den.broeck@vub.ac.be