Difference between revisions of "File:Sufact.png"

From TORI
Jump to navigation Jump to search
(Importing image file)
 
 
Line 1: Line 1:
  +
[[Explicit plot]] of functions [[Factorial]] and [[SuFac]]:
Importing image file
 
  +
  +
$y=x! ~$ and $~y=\mathrm{SuFac}(x)$ versus $x$.
  +
  +
This is adaptation of Figure 8.4 from the Russian book "Superfunctions" ([[Суперфункции]], in Russian)
  +
<ref>
  +
https://www.morebooks.de/store/ru/book/Суперфункции/isbn/978-3-659-56202-0 <br>
  +
http://www.ils.uec.ac.jp/~dima/BOOK/202.pdf<br>
  +
http://mizugadro.mydns.jp/BOOK/202.pdf
  +
Д.Кузнецов. Суперфункции. [[Lambert Academic Publishing]], 2014.
  +
</ref>.
  +
  +
==[[C++]] generator of curves==
  +
Files [[ado.cin]], [[fac.cin]], [[sufac.cin]] should be loaded in ordert o compile the code below
  +
  +
<poem><nomathjax><nowiki>
  +
#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 std::complex<double> z_type;
  +
#define Re(x) x.real()
  +
#define Im(x) x.imag()
  +
#define I z_type(0.,1.)
  +
#include "ado.cin"
  +
#include "fac.cin"
  +
#include "sufac.cin"
  +
// #include "superfactorial.cin"
  +
//#include "doya.cin"
  +
//DB Shoko(DB x) { return log(1.+exp(x)*(M_E-1.)); }
  +
  +
int main(){ int m,n; double x,y; FILE *o;
  +
//o=fopen("SuperFacPlot.eps","w"); ado(o,802,1010);
  +
o=fopen("superfacplo.eps","w"); ado(o,802,1010);
  +
fprintf(o,"401 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=-4;m<5;m++) {M(m,0)L(m,10)}
  +
for(m=0;m<11;m++) {M(-4,m)L(4,m)}
  +
fprintf(o,"2 setlinecap .01 W S\n 1 setlinecap 1 setlinejoin\n");
  +
for(m=0;m<42;m++){x=-.5+.1*m; y=Re(fac(x)); if(m==0)M(x,y) else L(x,y);} fprintf(o,".04 W .7 0 0 RGB S\n");
  +
for(m=0;m<54;m++){x=-4+.1*m; y=Re(superfac(x));if(m==0)M(x,y) else L(x,y);} fprintf(o,".04 W 0 0 .7 RGB S\n");
  +
fprintf(o,"showpage\n%c%cTrailer",'%','%'); fclose(o);
  +
system("epstopdf superfacplo.eps");
  +
system( "open superfacplo.pdf");
  +
getchar(); system("killall Preview");//for mac
  +
}
  +
</nowiki></nomathjax></poem>
  +
  +
==[[Latex]] generator of labels==
  +
  +
<poem><nomathjax><nowiki>
  +
\documentclass[12pt]{article}
  +
\paperwidth 808pt
  +
\paperheight 1056pt
  +
\textwidth 1800pt
  +
\textheight 1800pt
  +
\topmargin -108pt
  +
\oddsidemargin -72pt
  +
\parindent 0pt
  +
\pagestyle{empty}
  +
\usepackage {graphics}
  +
\usepackage{rotating}
  +
\newcommand \rot {\begin{rotate}}
  +
\newcommand \ero {\end{rotate}}
  +
\newcommand \ing {\includegraphics}
  +
\newcommand \sx {\scalebox}
  +
\begin{document}
  +
\begin{picture}(602,1010)
  +
%\put(0,0){\includegraphics{SuperFacPlot}}
  +
\put(0,0){\includegraphics{superfacplo}}
  +
\put(372,978){\sx{4.5}{$y$}}
  +
\put(372,890){\sx{4.5}{$9$}}
  +
\put(372,790){\sx{4.5}{$8$}}
  +
\put(372,690){\sx{4.5}{$7$}}
  +
\put(372,590){\sx{4.5}{$6$}}
  +
\put(372,490){\sx{4.5}{$5$}}
  +
\put(372,390){\sx{4.5}{$4$}}
  +
\put(372,290){\sx{4.5}{$3$}}
  +
\put(372,190){\sx{4.5}{$2$}}
  +
\put(372,90){\sx{4.5}{$1$}}
  +
\put( 066,-42){\sx{4.5}{$-\!3$}}
  +
\put(166,-42){\sx{4.5}{$-\!2$}}
  +
\put(266,-42){\sx{4.5}{$-\!1$}}
  +
\put(391,-42){\sx{4.5}{$0$}}
  +
\put(491,-42){\sx{4.5}{$1$}}
  +
\put(591,-42){\sx{4.5}{$2$}}
  +
\put(691,-42){\sx{4.5}{$3$}}
  +
\put(777,-42){\sx{4.5}{$x$}}
  +
%\put(532,440){\sx{5}{\rot{83}$y\!=\!\mathrm{SuperFactorial}(x)$\ero}}
  +
\put(532,440){\sx{5}{\rot{83}$y\!=\!\mathrm{SuFac}(x)$\ero}}
  +
%\put(660,450){\sx{4}{\rot{83}$y\!=\!\mathrm{Factorial}(x)$\ero}} %
  +
\put(740,500){\sx{5}{\rot{83}$y\!=\!\mathrm{Factorial}(x)$\ero}}
  +
\end{picture}
  +
\end{document}
  +
</nowiki></nomathjax></poem>
  +
  +
==References==
  +
  +
<references/>
  +
  +
[[Category:Factorial]]
  +
[[Category:SuFac]]
  +
[[Category:Superfunction]]
  +
[[Category:Explicit plot]]
  +
[[Category:Book]]
  +
[[Category:BookPlot]]
  +
[[Category:C++]]
  +
[[Category:Latex]]

Latest revision as of 08:53, 1 December 2018

Explicit plot of functions Factorial and SuFac:

$y=x! ~$ and $~y=\mathrm{SuFac}(x)$ versus $x$.

This is adaptation of Figure 8.4 from the Russian book "Superfunctions" (Суперфункции, in Russian) [1].

C++ generator of curves

Files ado.cin, fac.cin, sufac.cin should be loaded in ordert o 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 std::complex<double> z_type;
#define Re(x) x.real()
#define Im(x) x.imag()
#define I z_type(0.,1.)
#include "ado.cin"
#include "fac.cin"
#include "sufac.cin"
// #include "superfactorial.cin"
 //#include "doya.cin"
 //DB Shoko(DB x) { return log(1.+exp(x)*(M_E-1.)); }

int main(){ int m,n; double x,y; FILE *o;
//o=fopen("SuperFacPlot.eps","w"); ado(o,802,1010);
o=fopen("superfacplo.eps","w"); ado(o,802,1010);
fprintf(o,"401 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=-4;m<5;m++) {M(m,0)L(m,10)}
for(m=0;m<11;m++) {M(-4,m)L(4,m)}
fprintf(o,"2 setlinecap .01 W S\n 1 setlinecap 1 setlinejoin\n");
for(m=0;m<42;m++){x=-.5+.1*m; y=Re(fac(x)); if(m==0)M(x,y) else L(x,y);} fprintf(o,".04 W .7 0 0 RGB S\n");
for(m=0;m<54;m++){x=-4+.1*m; y=Re(superfac(x));if(m==0)M(x,y) else L(x,y);} fprintf(o,".04 W 0 0 .7 RGB S\n");
fprintf(o,"showpage\n%c%cTrailer",'%','%'); fclose(o);
    system("epstopdf superfacplo.eps");
    system( "open superfacplo.pdf");
    getchar(); system("killall Preview");//for mac
}

Latex generator of labels


\documentclass[12pt]{article}
\paperwidth 808pt
\paperheight 1056pt
\textwidth 1800pt
\textheight 1800pt
\topmargin -108pt
\oddsidemargin -72pt
\parindent 0pt
\pagestyle{empty}
\usepackage {graphics}
\usepackage{rotating}
\newcommand \rot {\begin{rotate}}
\newcommand \ero {\end{rotate}}
\newcommand \ing {\includegraphics}
\newcommand \sx {\scalebox}
\begin{document}
\begin{picture}(602,1010)
%\put(0,0){\includegraphics{SuperFacPlot}}
\put(0,0){\includegraphics{superfacplo}}
\put(372,978){\sx{4.5}{$y$}}
\put(372,890){\sx{4.5}{$9$}}
\put(372,790){\sx{4.5}{$8$}}
\put(372,690){\sx{4.5}{$7$}}
\put(372,590){\sx{4.5}{$6$}}
\put(372,490){\sx{4.5}{$5$}}
\put(372,390){\sx{4.5}{$4$}}
\put(372,290){\sx{4.5}{$3$}}
\put(372,190){\sx{4.5}{$2$}}
\put(372,90){\sx{4.5}{$1$}}
\put( 066,-42){\sx{4.5}{$-\!3$}}
\put(166,-42){\sx{4.5}{$-\!2$}}
\put(266,-42){\sx{4.5}{$-\!1$}}
\put(391,-42){\sx{4.5}{$0$}}
\put(491,-42){\sx{4.5}{$1$}}
\put(591,-42){\sx{4.5}{$2$}}
\put(691,-42){\sx{4.5}{$3$}}
\put(777,-42){\sx{4.5}{$x$}}
%\put(532,440){\sx{5}{\rot{83}$y\!=\!\mathrm{SuperFactorial}(x)$\ero}}
\put(532,440){\sx{5}{\rot{83}$y\!=\!\mathrm{SuFac}(x)$\ero}}
%\put(660,450){\sx{4}{\rot{83}$y\!=\!\mathrm{Factorial}(x)$\ero}} %
\put(740,500){\sx{5}{\rot{83}$y\!=\!\mathrm{Factorial}(x)$\ero}}
\end{picture}
\end{document}

References

File history

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

Date/TimeThumbnailDimensionsUserComment
current06:14, 1 December 2018Thumbnail for version as of 06:14, 1 December 20181,677 × 2,191 (224 KB)Maintenance script (talk | contribs)Importing image file

The following page uses this file:

Metadata