Created
April 10, 2014 05:49
-
-
Save crowding/10345922 to your computer and use it in GitHub Desktop.
Draw the logistic map in J, annotated.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'dot;color black' plot (; 50&}.@:((**(1-]))^:(i. 200)&0.25)) 2.4 ([+-~*((%~i.)100)) 4 | |
NB. 100 numbers in [0,1) ^^^^^^^^^ | |
NB. rescaled to ^^^^^ | |
NB. 100 numbers in [2.4,4) ^^^ ^ | |
NB. makes "x", ^^^^^^^^^^^^^^^^^^^^^^^^ | |
NB. ^^^^^^^^^ function y -> y * (1-y)*x | |
NB. ^^^^^^^^^^ applied 200 times | |
NB. ^^^^^ starting with y=0.25 | |
NB. ^^^^^^^ then dropping first 50 iterations | |
NB. ^ put original "x" alongside result | |
NB.^^^^^^^^^^^^^^^^^^^ and plot points | |
NB. (%~i.)&100 | |
NB. 2.4 ([+-~*((%~i.)&:100)) 4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment