29 #ifndef G4NeutronHPFastLegendre_h
30 #define G4NeutronHPFastLegendre_h 1
106 for(i=0;i<31;i++) theNbin[i]=1+200*(i+1);
117 if(l>30)
return regularIntegrate(l,costh);
121 y1 = integral[l][
bin];
122 y2 = integral[l][bin+1];
124 return Interpolate(bin, l, y1, y2, costh);
129 if(l>30)
return regularEvaluate(l,costh);
132 if(bin != theNbin[l]-1)
136 y2 =
value[l][bin+1];
137 result = Interpolate(bin, l, y1, y2, costh);
148 G4double regularEvaluate(
int l ,
double x );
149 G4double regularIntegrate(
int l ,
double x );
155 bin =
G4int( (theNbin[l]-1)*(costh+1)/2. );
156 if(bin == theNbin[l]-1) bin--;
163 G4int half = (theNbin[l]-1)/2;
166 x1mx2 = 1./
G4double( (theNbin[l]-1)/2 );
168 slope = (y2-
y1)/x1mx2;