# Solve the following equation with RSolve and non-autonomous series?

Posted 1 year ago
1320 Views
|
5 Replies
|
3 Total Likes
|
 In this example, RSolve is not giving the result I'd expect (the parenthesis!). Am I missing something? In[452]:= RSolve[{p[t + 1] == ( x[t] p[t] ) / ( 1 + b p[t] ), p[0] == p0}, p[t], t] /. t -> 1 Out[452]= {{p[1] -> p0 / ( 1 + ( b p0 ) / x[0] )}} I am using Mathematica 11.3 on Linux.
5 Replies
Sort By:
Posted 1 year ago
 HiYou have 2 variables p[t] and x[t] then you need a 2 equations to solve.Regards,MI
Posted 1 year ago
 The answer given by RSolve seems wrong to me, unless x[0]=1: Clear[p1, p, p0]; eq = {p[t] == (x[t - 1] p[t - 1])/(1 + b p[t - 1]), p[0] == p0}; sol = RSolveValue[eq, p, t]; p1[0] = p0; p1[t_] := (x[t - 1] p1[t - 1])/(1 + b p1[t - 1]); Simplify[Table[sol[t] == p1[t], {t, 0, 3}]] 
Posted 1 year ago
 I would expect the result to be like this: p1[0] = p0; p1[t_] := (x[t - 1] p1[t - 1])/(1 + b p1[t - 1]); 
 Thanks Gianluca, that's what I mean. From the recursion p[t+1] = ( x[t] p[t] ) / ( 1 + b p[t] ) p[0] = p0 I expect p[1] = ( x[0] p0 ) / ( 1 + b p0 ) but using RSolve I find p[1] = ( x[0] p0 ) / ( x[0] + b p0 )