This is a file from the Wikimedia Commons

File:Golden mean.png

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

Original file(1,000 × 1,000 pixels, file size: 30 KB, MIME type: image/png)

Summary

Description
English: Approximation of golden mean by finite continued fractions :
Date
Source Own work
Author Adam majewski

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 3.0 Unported 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

/* 
golden ratio conjugate 
= ((sqrt(5)-1)/2 = 0.618033988749895
It is approximated by finite continued  fractions :

[0;1,1,1,....]



*/

kill(all);

iMax : 10;



/* continuead fraction - goldem mean */
f(i_Max):=
(
[a,i],
i:1,
a:[0,1,1],
while i<i_Max do 
(a:endcons(1,a),
 i:i+1),
float(cfdisrep(a))
)$



/* save the values to 2 lists */
xx:makelist (1, i, 1, 1); /* list of positive integers  */
yy:makelist (f(1), i, 1, 1); /* list of cf  */

for i:2 thru iMax step 1 do 
(  
   xx:cons(i,xx), 
   y:float(f(i)),
   yy:cons(y,yy)

);

load(draw);
draw2d(
   file_name = "golden_mean",
   terminal  = 'png,
  
  
   dimensions  = [1000,1000],
   title= "Finite continued fraction aproximation for golden mean",
   key = "n-fraction",
   xlabel     = "n",
   ylabel     = "n-continued fractions",
   point_type    = filled_circle,
   point_size    = 1.0,
   points_joined = true,

   color         = red,
   points(xx,yy),
   color = blue,
   key = "golden mean",
   explicit((sqrt(5)-1)/2,x,1,iMax)

  );

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts

21 October 2011

image/png

File history

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

Date/TimeThumbnailDimensionsUserComment
current18:34, 21 October 2011Thumbnail for version as of 18:34, 21 October 20111,000 × 1,000 (30 KB)Soul windsurfer

Global file usage

The following other wikis use this file: