File:FacIteT.jpg

From TORI
Jump to navigation Jump to search

Original file(2,093 × 2,093 pixels, file size: 795 KB, MIME type: image/jpeg)

Iterations of function Factorial;

$y=\mathrm{Factorial}^n(x)$

is plotted versus $x$ for various values of $n$.

The iterates are implemented through the SuperFactorial SuFac and AbelFactorial AuFac,

$ \mathrm{Factorial}^n(x)=\mathrm{SuFac}\Big(x+\mathrm{AuFac}(x)\Big)$

C++ generator of curves

// Files fac.cin, facp.cin, afacc.cin, SuFac.cin, AuFac.cin and ado.cin // should be loaded to the working directory in order to compile the code below.

#include<math.h> 
#include<stdio.h>
#include<stdlib.h>
#define DB double
#define DO(x,y) for(x=0;x<y;x++)
using namespace std;
#include <complex>
typedef complex<double> z_type;
#define Re(x) x.real()
#define Im(x) x.imag()
#define I z_type(0.,1.)
#include "ado.cin"
//DB B=2.;
//DB F(DB z) { return exp( exp( log(B)*z));}
//DB G(DB z) { return log( log(z) )/log(B);}
#include "fac.cin"
#include "facp.cin"
#include "afacc.cin"
#include "SuFac.cin"
#include "AuFac.cin"
main(){ int m,n; double x,y,t; FILE *o;
o=fopen("FacIte.eps","w"); ado(o,1020,1020);
fprintf(o,"1 1 translate 100 100 scale\n");
#define M(x,y) fprintf(o,"%6.3f %6.3f M\n",0.+x,0.+y);
#define L(x,y) fprintf(o,"%6.3f %6.3f L\n",0.+x,0.+y);
for(m=0;m<11;m++) {M(m,0)L(m,10)}
for(m=0;m<11;m++) {M(0,m)L(10,m)}
fprintf(o,"2 setlinecap .01 W S\n");
DO(m,402){x=0.001+.01*m; y=Re(fac(x)); if(m==0)M(x,y) else L(x,y); if(y>10.1) break;}
DO(m,402){x=0.001+.01*m; y=Re(fac(fac(x))); if(m==0)M(x,y) else L(x,y); if(y>10.1) break;}
fprintf(o,"1 setlinecap 1 setlinejoin .04 W 0 1 0 RGB S\n");
DO(m,1002){x=.88+.01*m; y=Re(afacc(x)); if(m==0)M(x,y) else L(x,y);} fprintf(o,"1 setlinecap 1 setlinejoin .03 W 1 0 1 RGB S\n");
DO(m,1002){x=.95+.01*m; y=Re(afacc(afacc(x))); if(m==0)M(x,y) else L(x,y);} fprintf(o,"1 setlinecap 1 setlinejoin .03 W 1 0 1 RGB S\n");
for(n=-20;n<21;n++){t=.1*n; DO(m,182){x=2.+.05*(m); y=Re(SuFac(t+AuFac(z_type(x,1.e-16)))); if(m==0)M(x,y)else L(x,y); if(x>10.1||y>10.1)break;} }
fprintf(o,"1 setlinecap 1 setlinejoin .01 W 0 0 0 RGB S\n");
fprintf(o,"showpage\n%c%cTrailer",'%','%'); fclose(o);
     system("epstopdf FacIte.eps");    
     system(    "open FacIte.pdf");
     getchar(); system("killall Preview");
}

Latex Generator of labels

% %<br> % file IterPowPlot.pdf should be generated with the code above in order to compile the Latex document below. %<br> % Copyleft 2012 by Dmitrii Kouznetsov <br> % <poem><nomathjax><nowki> \documentclass[12pt]{article} % <br> \usepackage{geometry} % <br> \usepackage{graphicx} % <br> \usepackage{rotating} % <br> \paperwidth 1008pt % <br> \paperheight 1008pt % <br> \topmargin -94pt % <br> \oddsidemargin -81pt % <br> \textwidth 1100pt % <br> \textheight 1100pt % <br> \pagestyle {empty} % <br> \newcommand \sx {\scalebox} % <br> \newcommand \rot {\begin{rotate}} % <br> \newcommand \ero {\end{rotate}} % <br> \newcommand \ing {\includegraphics} % <br> \parindent 0pt% <br> \pagestyle{empty} % <br> \begin{document} % <br> \begin{picture}(1002,1002) % <br> %\put(10,10){\ing{IterPowPlot}} % <br> \put(10,10){\ing{FacIte}} % <br> %\put(11,976){\sx{4}{$y\!=\!\mathrm{pow}_2^c(x)$}} % <br> \put(13,991){\sx{4.4}{$y$}}% \!=\!\mathrm{Factorial}^n(x)$}} % <br> \put(13,898){\sx{4}{$9$}} % <br> \put(13,798){\sx{4}{$8$}} % <br> \put(13,698){\sx{4}{$7$}} % <br> \put(13,598){\sx{4}{$6$}} % <br> \put(13,498){\sx{4}{$5$}} % <br> \put(13,398){\sx{4}{$4$}} % <br> \put(13,298){\sx{4}{$3$}} % <br> \put(13,198){\sx{4}{$2$}} % <br> \put(13,098){\sx{4}{$1$}} % <br> % <br> \put(100,16){\sx{4}{$1$}} % <br> \put(200,16){\sx{4}{$2$}} % <br> \put(301,16){\sx{4}{$3$}} % <br> \put(401,16){\sx{4}{$4$}} % <br> \put(502,16){\sx{4}{$5$}} % <br> \put(602,16){\sx{4}{$6$}} % <br> \put(703,16){\sx{4}{$7$}} % <br> \put(803,16){\sx{4}{$8$}} % <br> \put(903,16){\sx{4}{$9$}} % <br> \put(990,16){\sx{4}{$x$}} % <br> % <br> \put(258,920){\sx{3.6}{\rot{88}$n\!=\!2$\ero}} % <br> \put(355,921){\sx{3.6}{\rot{85}$n\!=\!1$\ero}} % <br> \put(342,791){\sx{2.9}{\rot{84}$y\!=\!x!$\ero}} % <br> \put(441,890){\sx{3.6}{\rot{79}$n\!=\!0.6$\ero}} % <br> \put(473,890){\sx{3.6}{\rot{74}$n\!=\!0.5$\ero}} % <br> \put(530,894){\sx{3.6}{\rot{70}$n\!=\!0.4$\ero}} % <br> \put(598,894){\sx{3.6}{\rot{69}$n\!=\!0.3$\ero}} % <br> \put(674,898){\sx{3.6}{\rot{62}$n\!=\!0.2$\ero}} % <br> \put(792,910){\sx{3.6}{\rot{54}$n\!=\!0.1$\ero}} % <br> % <br> \put(928,932){\sx{3.6}{\rot{45}$n\!=\!0$\ero}} % <br> \put(738,722){\sx{3.6}{\rot{45}$y\!=\!x$\ero}} % <br> % <br> \put(888,744){\sx{3.6}{\rot{36}$n\!=\!-0.1$\ero}} % <br> \put(877,634){\sx{3.6}{\rot{28}$n\!=\!-0.2$\ero}} % <br> \put(871,560){\sx{3.6}{\rot{20}$n\!=\!-0.3$\ero}} % <br> \put(866,504){\sx{3.6}{\rot{16}$n\!=\!-0.4$\ero}} % <br> \put(866,456){\sx{3.6}{\rot{14}$n\!=\!-0.5$\ero}} % <br> \put(862,411){\sx{3.6}{\rot{10}$n\!=\!-0.6$\ero}} % <br> % <br> \put(889,328){\sx{3.6}{\rot{5}$n\!=\!-1$\ero}} % <br> \put(886,230){\sx{3.6}{\rot{1}$n\!=\!-2$\ero}} % <br> \end{picture} % <br> \end{document} % <br> </nomathjax></poem>

File history

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

Date/TimeThumbnailDimensionsUserComment
current17:50, 20 June 2013Thumbnail for version as of 17:50, 20 June 20132,093 × 2,093 (795 KB)Maintenance script (talk | contribs)Importing image file

The following page uses this file:

Metadata