File:Norifit76fragment.jpg

From TORI
Revision as of 08:44, 1 December 2018 by Maintenance script (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Original file(967 × 448 pixels, file size: 155 KB, MIME type: image/jpeg)

Fragment from image http://mizugadro.mydns.jp/t/index.php/File:Norifit76plot.jpg

Analysis of the approximation of nori function through function korifit76,

nori$(x)=\, $kori$(x)^2\approx\, $korifit76$(x)^2$

The free agreements are shown:

$\mathrm{A}(x)= - \lg\! \Big( \big|\mathrm{korifit76}(x)^2-\mathrm{nori}(x)\big|\Big)$

$\mathrm{B}(x)= - \lg\! \Big( \big|\mathrm{korifit76}(x)-\mathrm{kori}(x)\big| \Big)$

$\displaystyle \mathrm{C}(x)= - \lg \left(\frac {\big|\mathrm{korifit76}(x)-\mathrm{kori}(x)\big|}{\big|\mathrm{korifit76}(x)\big| + \big|\mathrm{kori}(x)\big|}\,\right)$

where functions nori and kori are evaluated through the straightforward definitions using the C++ built-in Bessel function double j0(double ).

kori$(x) =\,$mori$\big(\sqrt{x}\big)$ $\,= \displaystyle \frac{ J_0\big(L_1 \sqrt{x} \big)}{1-x}$

where $L_n =\,$BesselJZero$[0,n]~$ is $n$th zero of function BesselJ0.

For reference, at the bottom, functions nori and kori, scaled with factor 10, are shown with green and red curves.

The additional vertical grid lines show abscissas $\displaystyle M_n=\left(\frac{L_n}{L_1}\right)^2~ $ for $~n=2\,..\,5$

korifit76

Function korifit76 is defined in the following way:

$\mathrm{kori76fit}= \displaystyle \prod_{n=2}^7\! \left(1-\frac{L_1^2}{L_n^2}x\right)~ \frac{1+\sum_{n=1}^6 a_n x^n}{1+\sum_{n=1}^6 b_n x^n} $

where $L_n=\mathrm{BesselJZero}[0,n]$ and coefficients $a$ and $b$ are:

$\begin{array}{l} a_1=-0.04844698269548584 \\ a_2= 0.0010028289633265202 \\ a_3= -0.000011428855401098336\\ a_4= 7.61813379974462\times 10^{-8}\\ a_5= -2.8376606186641804\!\times\! 10^{-10}~\\ a_6= 4.651275051439759\times 10^{-13} \end{array}$ $\begin{array}{l} b_1= 0.03223483760044156\\ b_2= 0.0004974915308429358\\ b_3= 4.7768603073237505\times 10^{-6}\\ b_4= 3.071615607112112\times 10^{-8}\\ b_5= 1.292095753771865\times 10^{-10}\\ b_6= 2.925186494186955\times 10^{-13} \end{array} $

C++ generator of curves


#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.)
#define M(x,y) fprintf(o,"%6.4lf %6.4lf M\n",0.+x,0.+y);
#define L(x,y) fprintf(o,"%6.4lf %6.4lf L\n",0.+x,0.+y);

#include "korifit76.cin"
#include "ado.cin"

DB L1=2.404825557695773;
DB L2=5.5200781102863115;
DB L3=8.653727912911013;
DB L4=11.791534439014281;
DB L5=14.930917708487787;
DB L6=18.071063967910924;
DB L7=21.21163662987926;
DB L8=24.352471530749302;

DB LN[9]={ 0., 2.404825557695773, 5.5200781102863115,
 8.653727912911013,11.791534439014281,14.930917708487787,
18.071063967910924,21.21163662987926, 24.352471530749302};

int main(){int m,n,i; double x,y,z,t,u; FILE *o;

o=fopen("norifit76plo.eps","w");
ado(o,520,220);
fprintf(o,"10 10 translate 10 10 scale 2 setlinecap 1 setlinejoin\n");

for(m=0;m<51;m+=1) {M(m,0)L(m,15)}
for(n=0;n<16;n+=1){M(0,n)L(50,n)}
fprintf(o,"0.04 W S\n");

for(m=2;m<6;m++){ x=LN[m]/LN[1]; x*=x; M(x,0)L(x,20) }
fprintf(o,"0.03 W 1 0 1 RGB S\n");

for(n=1;n<5001;n+=5){ x=.01*n;
        y=j0(L1*sqrt(x))/(1.-x); y*=y;
        z=Re(korifit76(x)); z*=z;
        t=y-z;
        u=-log(fabs(t))/log(10);
        printf("%6.2lf %19.16lf %19.16lf %19.16lf %8.2lf\n",x,y,z,t,u);
        if(n==1) M(x,u) else if(u>0 && u <20)L(x,u)
}
fprintf(o,"0 .7 0 RGB .1 W S\n");

for(n=1;n<5001;n+=5){ x=.01*n;
        y=j0(L1*sqrt(x))/(1.-x);
        z=Re(korifit76(x));
        t=y-z;
        u=-log(fabs(t))/log(10);
        printf("%6.2lf %19.16lf %19.16lf %19.16lf %8.2lf\n",x,y,z,t,u);
        if(n==1) M(x,u) else if(u>0 && u <20)L(x,u)
}
fprintf(o,"1 0 0 RGB .1 W S\n");

for(n=1;n<5001;n+=5){ x=.01*n;
        y=j0(L1*sqrt(x))/(1.-x); y*=y;
        z=Re(korifit76(x)); z*=z;
        t=y-z;
        u=-log(fabs(t)/(fabs(y)+fabs(z)))/log(10);
        printf("%6.2lf %19.16lf %19.16lf %19.16lf %8.2lf\n",x,y,z,t,u);
        if(n==1) M(x,u) else if(u>0 && u <20)L(x,u)
}
fprintf(o,"0 0 0 RGB .1 W S\n");

for(n=1;n<5001;n+=5){ x=.01*n;
        y=j0(L1*sqrt(x))/(1.-x);
        if(n==1) M(x,10*y) else if(y>-1 && y <2)L(x,10*y) }
fprintf(o,"1 0 0 RGB .1 W S\n");

for(n=1;n<5001;n+=5){ x=.01*n;
        y=j0(L1*sqrt(x))/(1.-x); y*=y;
        if(n==1) M(x,10*y) else if(y>-1 && y <2)L(x,10*y) }
fprintf(o,"0 .6 0 RGB .1 W S\n");

fprintf(o,"showpage\n%c%cTrailer\n",'%','%'); fclose(o);
system("epstopdf norifit76plo.eps");
system( "open norifit76plo.pdf");
return 0;}


Latex generator of labels


File history

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

Date/TimeThumbnailDimensionsUserComment
current06:13, 1 December 2018Thumbnail for version as of 06:13, 1 December 2018967 × 448 (155 KB)Maintenance script (talk | contribs)Importing image file

The following 2 pages use this file:

Metadata