This is a file from the Wikimedia Commons

File:Lyapunov exponent of real quadratic map with exponential transformation on the real axis.png

From Wikibooks, open books for an open world
Jump to navigation Jump to search

Original file(1,799 × 2,462 pixels, file size: 263 KB, MIME type: image/png)

Summary

Description
English: Lyapunov exponent of real quadratic map with exponential transformation on the real axis
Date
Source Own work : based on the code by Mario Rodriguez Riotorto[1] using Maxima CAS and draw package ( also by Mario Rodriguez Riotorto )
Author Adam majewski
Other versions

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 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.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.


Maxima CAS src code

/*
batch file for Maxima CAS program
save it as a file with mac extension and open in Maxima 
It creates l6.svg file in the directory path ( see below)
change the path directory if you save mac file in the different location 

https://commons.wikimedia.org/wiki/File:Lyapunov_exponent_of_real_quadratic_map.png

http://fy.chalmers.se/~f99krgu/CompBioA/CompBioLecture2.pdf

log(c - cf)

log(-c_f) = 0.3372970313844768
log(0.25-c_f) = 0.5014751574920848

---------------
Transform is c←ec+c0 with c0=−1.401155189092051.

https://fractalforums.org/fractal-image-gallery/18/feigenbaum-stretch/2112
--------------


*/
kill(all);
remvalue(all);


/* real quadratic  diagram based on the code by Mario Rodriguez Riotorto using Maxima CAS draw packag  */



pts:[]; /* points of the orbit */

ls:[];
kMax1:200;
kMax2:500;
cF:-1.4011551890; /* The Feigenbaum Point of period doubling cascade */ 

cMax:  0.25;
xMax : log(cMax - cF); /* from c to x  */


/* width of component is about 1.5 */
NoOfComponents : 8 ; /*  (xMax-xMin)/1.5; */
xMin : xMax - NoOfComponents*1.5; /* from NoOfComponents to x  */
cMin: cF +exp(xMin); /* from x to c = -1.3996312;  */


 
n:500;
dx:(xMax-xMin)/n;


/* ------------- compute -----------------------------------*/

for x:xMin while x <= xMax step dx do 
    (
    
       c: cF + exp(x),
       z: 0.0,
       l:0, /* Lyapunov exponent */
       for k:1 thru kMax1 do 
         (    
           z: z * z+c, /* to remove points from image compute and do not draw it */
           l:l+log(abs(2*z))
         ),
       
        for k:1 thru kMax2  do 
          ( 
           z:  z * z+c, /* compute and draw it */
           pts: cons([x,z], pts),/* save points to draw it later */
	   l:l+log(abs(2*z))	
          ),
       ls:cons([x,l/(kMax1+kMax2)],ls)   /* save points to draw it later */         
                   
    ); 


/* =================  draw ======================================*/

 path:"~/maxima/batch/logistic/log/m2/"$ /* result of pwd; to save image in the same directory as mac file  */
 FileName:concat("n_",string(NoOfComponents), "_", string(n),"_", string(kMax1),"_",string(kMax2))$ /* without extension which is the terminal name */

load(draw);

 
 draw(
  terminal  = 'svg,
  file_name = concat(path,FileName),
  dimensions=[1900,2600], /*  y = x*rows  */
  
  
  
  gr2d(
  	title      = "Bifurcation diagram, z[i+1] = z[i]*z[i] +c",
  	font_size = 30,
  	font = "Liberation Sans", /* https://commons.wikimedia.org/wiki/Help:SVG#Font_substitution_and_fallback_fonts */
    	points_joined =false,
   	xlabel     = "log(c - cF)",
        ylabel     = "z ",
        point_type = filled_circle,
        point_size = 0.2,
        color = black,
        points(pts) 
   ),

  gr2d(
  	title = " Lyapunov exponent ",
  	font_size = 30,
  	font = "Liberation Sans", /* https://commons.wikimedia.org/wiki/Help:SVG#Font_substitution_and_fallback_fonts */
   	points_joined =true,
    	yaxis       = true,
   	xaxis 	= true,
   	xlabel     = "log(c - cF)",
   	ylabel     = " lyapunov exponent ",
   	yrange = [-0.5,0.1],
   	color         = red,
   	point_size    = 0.5,
   	point_type = filled_circle,
   	points(ls))

 );
 
 

Image Mafic / Bash src code

 convert n_8_500_200_500.svg n.png
  1. how to make multiplots with the draw package by Mario Rodríguez Riotorto

Captions

Lyapunov exponent of real quadratic map with exponential transformation on the real axis

28 September 2019

File history

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

Date/TimeThumbnailDimensionsUserComment
current05:01, 29 September 2019Thumbnail for version as of 05:01, 29 September 20191,799 × 2,462 (263 KB)Soul windsurferUser created page with UploadWizard

Metadata