File:EulerPhi.svg

Page contents not supported in other languages.
This is a file from the Wikimedia Commons
From Simple English Wikipedia, the free encyclopedia

Original file(SVG file, nominally 731 × 551 pixels, file size: 232 KB)

Summary

Description
English: Plot of the first 1000 values of the en:Euler's totient function. Svg version of Image:EulerPhi.PNG
Italiano: I primi 1000 valori della it:Funzione φ di Eulero. Versione svg di Image:EulerPhi.PNG.
Date
Source Own work
 
This W3C-unspecified plot was created with Matplotlib.
Author Pietro Battiston (it:User:Toobaz)
Other versions Image:EulerPhi.PNG

Created with the following script, ran in "ipython -pylab":

xlabel('n')
ylabel('$\phi(n)$')
plot([fi(i) for i in range(1,1000)], 'b.')

"fi" is the Euler φ, defined for instance as:

def fattorizza(n):
    c = 0
    f = {}
    for i in xrange( 2, int(sqrt(n))+1 ):
        if not n%i:
            f[i] = 1
            n /= i
        while not n%i:
            f[i] += 1
            vn = n
            n /= i
        if n == 1:
            return f
    f[n] = 1
    return f

def fi(n):
    if n == 1:
        return 1
    fi = 1
    f = fattorizza(n)
    for p in f:
        k = f[p]
        fi *= (p-1)*p**(k-1)
    return fi

Licensing

I, the copyright holder of this work, hereby publish it under the following licenses:
GNU head Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled GNU Free Documentation License.
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International, 3.0 Unported, 2.5 Generic, 2.0 Generic and 1.0 Generic 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.
You may select the license of your choice.

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts

24 May 2009

image/svg+xml

File history

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

Date/TimeThumbnailDimensionsUserComment
current16:07, 17 May 2012Thumbnail for version as of 16:07, 17 May 2012731 × 551 (232 KB)ItzuvitReverted to version as of 09:29, 16 March 2010
12:22, 13 May 2012Thumbnail for version as of 12:22, 13 May 20121,200 × 1,200 (51 KB)AntonsusiValid code; taking exactly one pixel for one scale unit; easier code.
09:29, 16 March 2010Thumbnail for version as of 09:29, 16 March 2010731 × 551 (232 KB)ToobazFixed the decomposition into primes: (x)range doesn't contain extrema.
14:29, 24 May 2009Thumbnail for version as of 14:29, 24 May 2009731 × 551 (231 KB)Toobaz{{Information |Description={{en|1=Plot of the first 1000 values of the en:Euler's totient function. Svg version of Image:EulerPhi.PNG }} {{it|1=I primi 1000 valori della it:Funzione φ di Eulero. Versione svg di Image:EulerPhi.PNG.}} |

The following page uses this file:

Global file usage

The following other wikis use this file:

Metadata