Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Solve two variable recursive equation in Mathematica, is that possible?

I tried to use RSolve to solve a two variable recursive equation in Mathematica, but it simply repeats what I type.

Is it possible to solve two variable recursive equations in Mathematica?

like image 397
Ang Avatar asked Jan 18 '26 09:01

Ang


2 Answers

Perhaps you should include the equation in your question, as it is possible you are simply using RSolve incorrectly.

Mathematica can solve some two-variable recurrence equations, but not all.

Sometimes the free package Guess.m can solve what RSolve cannot. (You must request access to the file; contact information is on that page.)

like image 159
Mr.Wizard Avatar answered Jan 19 '26 23:01

Mr.Wizard


I discovered RecurrenceTable[] today while trying to plot the Logistic map. It gives a table of values, symbolic if you like, given a set of recurrence relations and initial conditions. Oh, and it's really fast.

For example,

logisticMap[r_,x0_,maxn_]:=RecurrenceTable[{x[n+1]==r x[n](1-x[n]),x[0]==x0},x,{n,0,nmax}]; Manipulate[ListPlot[Transpose[{Range[0,maxn],logisticMap[r,x0,maxn]}],PlotRange->{0,1}],{{r,3.485},0,4},{{x0,0.432},0,1},{{maxn,500},10,1000,1}]

Logistic Map Example

The documentation for RecurrenceTable gives examples for two-variable relations.

like image 38
JxB Avatar answered Jan 19 '26 23:01

JxB