Function Repository Resource:

ClickRecurrenceMap2D

Source Notebook

Get the orbits of a planar map in an interactive way using a clickable panel

Contributed by: E. Chan-López, Erika Yuridia Flores Chan, Héctor Argote Morales & Víctor Castellanos

ResourceFunction["ClickRecurrenceMap2D"][map,depvars,trange]

gives the orbits corresponding to the recurrence equations represented by map, the dependent variables depvars and a pair trange containing the minimum and maximum number of iterations, with initial conditions determined by clicking within an interactive panel.

Details and Options

The map must be a list of recurrence equations.
The depvars must be a list containing the dependent variables.
The trange must be a list containing the minimum and maximum number of iterations.
ResourceFunction["ClickRecurrenceMap2D"][map,depvars,trange] obtains initial condition data from points the user clicks and plots the corresponding orbits.
ResourceFunction["ClickRecurrenceMap2D"][map,depvars,trange] takes the same options as ListPlot.

Examples

Basic Examples (2) 

Generate some orbits of the Gingerbreadman map:

In[1]:=
Gingerbreadman[{x_[n_], y_[n_]}] := {x[n + 1] == 1 - y[n] + Abs[x[n]],
   y[n + 1] == x[n]}
In[2]:=
X = {x[n], y[n]};

Visualize the orbit by clicking:

In[3]:=
ResourceFunction["ClickRecurrenceMap2D"][
 Gingerbreadman[X], X, {1, 10000}, {PlotStyle -> {{
AbsolutePointSize[1], 
GrayLevel[0]}}, AspectRatio -> 1, PlotHighlighting -> None}]
Out[3]=

Scope (2) 

Gumowski-Mira Attractor (2) 

Generate some orbits of the Gumowski-Mira map:

In[4]:=
f[x_[n_]][a_] := a x[n] + (2 (1 - a) x[n]^2)/(1 + x[n]^2)^2
In[5]:=
GMAttractor[{x_[n_], y_[n_]}][{a_, b_}] := {x[n + 1] == b y[n] + a x[n] + (2 (1 - a) x[n]^2)/(1 + x[n]^2)^2, y[n + 1] == ReplaceAll[
      x[n] -> b y[n] + a x[n] + (2 (1 - a) x[n]^2)/(1 + x[n]^2)^2][
     f[x[n]][a]] - x[n]}
In[6]:=
X = {x[n], y[n]};

Visualize the orbits by clicking:

In[7]:=
ResourceFunction["ClickRecurrenceMap2D"][
 GMAttractor[X][{0.266, 1}], X, {1, 1500}, {PlotStyle -> (PlotStyle -> AbsolutePointSize[1]), AspectRatio -> 1, PlotHighlighting -> None}]
Out[7]=

Publisher

Ramón Eduardo Chan López

Requirements

Wolfram Language 13.0 (December 2021) or above

Version History

  • 2.1.1 – 02 October 2023
  • 2.1.0 – 05 July 2023
  • 2.0.0 – 31 May 2023
  • 1.1.0 – 27 March 2023
  • 1.0.0 – 16 September 2022

Source Metadata

Related Resources

License Information