/***********************************************************/ /* TWO BODY QUANTUM SCATTERING USING PARTIAL WAVE METHOD */ /* FOR CENTRAL POTENTIAL ONLY LI JU. MARCH.28 */ /***********************************************************/ #include #include #include "nr.h" /* The Numerical Recipes Package header */ #define PI 3.141592654 #define INTERGRATION 2E5 #define FNAME "cs.out" /* ouput filename */ #define ANGSTEP (PI/500) /* Finery of cross section output */ double Width,Height,K; /* The Width of the potential barrier */ /* The reduced height of the potential barrier */ /* The incoming wave vector */ double W(float x) { return(10000*exp(-x*x)); } /* Legendre polynomial */ float P(int l,float x) { float i,p0,p1,p2; if (l==0) return(1); if (l==1) return(x); p0 = 1; p1 = x; for (i=1;iWIDTH1)&&FIRST) { X1 = x; Y1 = y2; sphbes (l,X1,&j1,&n1,&a1,&a2); FIRST = 0; } if (x>WIDTH2) { X2 = x; Y2 = y2; sphbes (l,X2,&j2,&n2,&a1,&a2); G = X1*Y2/X2/Y1; printf ("%lf %lf\n",y1,y2); delta[l] = atan((G*j1-j2)/(G*n1-n2)); OK = 0; } k0 = k1; y0 = y1; k1 = k2; y1 = y2; } printf ("Partial wave No.%d intergrated over. delta = %f\n",l,delta[l]); } /* Differential cross section */ for (a1=0;a1