File:CircleMapOrbitDiag.png

From Wikiversity
Jump to navigation Jump to search

Original file(9,600 × 5,400 pixels, file size: 5.57 MB, MIME type: image/png)

This is a file from the Wikimedia Commons. The description on its description page there is shown below.

Commons is a freely licensed media file repository. You can help.

Summary

Description
English: Produced by the following Python code adapted from Wikipedia article Logistic map:
import numpy as np
import math
import matplotlib.pyplot as plt

# - Described at: https://mathworld.wolfram.com/CircleMap.html
#   - Both the formula and modulo 1 trace to the above.
# - Described https://en.wikipedia.org/wiki/Arnold_tongue
#   - The above uses "+ K/2*pi" while MathWorld uses "- K/2*pi"
#   - The choice of omega = 1/3 traces to the above.
#   - The choice of kInterval of (0, 4 * math.pi) traces to the above, except that we start at -2
#     to get a more complete picture.
#   - Issue: the choice of omega and kInterval trace only to Wikipedia, not to other source.
# - The choice of starting at 0.5 is not based on anything; it is a guess taken over
#   from the logistic map.

preset = 1

saveFigure = True
markerSize = 0.001
markerStyle = "," # . - point; , - pixel
if preset == 1:
  kInterval = (-2, 4 * math.pi)
  kResolution = 0.002
  mapIterationCount = 1000
  lastMapIterationCountToPlot = 1000
  startingIterationValue = 0.5
  yLim = (-0.1, 1.1)
  omega = 1.0/3.0
  fileName = "CircleMapOrbitDiag.png"

lims = np.zeros(mapIterationCount)

fig, biax = plt.subplots()
fig.set_size_inches(16, 9)

itemCount = 0
for K in np.arange(kInterval[0], kInterval[1], kResolution):
  itemCount += 1
  lims[0] = startingIterationValue
  for i in xrange(mapIterationCount - 1):
    lims[i + 1] = (lims[i] + omega + K / (2 * math.pi) * math.sin(2 * math.pi * lims[i])) % 1
  if itemCount % 1000 == 0:
    print("Parameter values processed:", itemCount)

  biax.plot([K] * lastMapIterationCountToPlot,
            lims[(mapIterationCount - lastMapIterationCountToPlot):], "b.",
            markersize=markerSize,
            marker=markerStyle)

biax.set(xlabel="K", ylabel="x",
         title="Circle map - (x + omega - K / (2 * pi) * sin(2 * pi * x)) mod 1 - bifurcation diagram/orbit diagram" + "\n" +
               "K resolution: " + str(kResolution) +
               ", iteration count: " + str(mapIterationCount) +
               ", last values to plot count: " + str(lastMapIterationCountToPlot) +
               (", omega: %.3f" % omega))
               
biax.set_ylim(yLim[0], yLim[1])
if saveFigure:
  plt.savefig(fileName, dpi=600)
else:
  plt.show()
Date
Source Own work
Author Dan Polansky

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution
This file is licensed under the Creative Commons Attribution 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.

Captions

An orbit diagram of the circle map

Items portrayed in this file

depicts

9 February 2024

image/png

2821d8df634acf8d113977aa5efb5edf6698a6a0

5,844,130 byte

5,400 pixel

9,600 pixel

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current08:20, 9 February 2024Thumbnail for version as of 08:20, 9 February 20249,600 × 5,400 (5.57 MB)Dan PolanskyUploaded own work with UploadWizard

The following page uses this file:

Metadata