50 nR_E1= nR_M1= nR_E2=0;
51 np_E1= np_M1= np_E2=0;
55 E1_normFac=-1; M1_normFac=-1; E2_normFac=-1;
56 NormEmin=0; NormEmax=6;
85 IsDone=TakePSFFromInputFile(inputfname);
90 if(defaultinputfname!=0){
91 IsDone=TakePSFFromInputFile(defaultinputfname);
96 snprintf(fname,500,
"%s/PSF/PSF_param.dat",dirname);
97 IsDone=TakePSFFromDetailedParFile(fname);
102 snprintf(fname,500,
"%s/PSF/CRP_IAEA_SMLO_E1_v01.dat",dirname);
103 IsDone=TakePSFFromIAEA01(fname);
104 if(IsDone){
return 0;}
107 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
111 snprintf(fname,500,
"%s/PSF/gdr-parameters&errors-exp-MLO.dat",dirname);
112 IsDone=TakePSFFromRIPL01(fname);
113 if(IsDone){
return 0;}
116 snprintf(fname,500,
"%s/PSF/gdr-parameters-theor.dat",dirname);
117 IsDone=TakePSFFromRIPL02(fname);
118 if(IsDone){
return 0;}
126 G4double a=28.69,b=21.731,c=0.0285,d=1.267;
128 E_E1[nR_E1]=a*std::pow(A_Int,-1./3.)+b*std::pow(A_Int,-1./6.);
129 G_E1[nR_E1]=c*std::pow(E_E1[nR_E1],1.9);
130 s_E1[nR_E1]=120/3.141592*d*(A_Int-Z_Int)*Z_Int/(
G4double)A_Int/G_E1[nR_E1];
132 GenerateM1AndE2FromE1();
137void G4NuDEXPSF::GenerateM1AndE2FromE1(){
141 E_M1[nR_M1]=41*std::pow(A_Int,-1./3.);
150 s_M1[0]=fE1/0.0588/std::pow(A_Int,0.878)/fM1;
155 E_E2[nR_E2]=63*std::pow(A_Int,-1./3.);
156 G_E2[nR_E2]=6.11-0.021*A_Int;
157 s_E2[nR_E2]=0.00014*Z_Int*Z_Int*E_E2[nR_E2]/std::pow(A_Int,1./3)/G_E2[nR_E2];
163G4bool G4NuDEXPSF::TakePSFFromRIPL02(
const char* fname){
167 std::ifstream in(fname);
170 for(
G4int i=0;i<4;i++){in.ignore(10000,
'\n');}
172 if(aZ==Z_Int && aA==A_Int){
176 in>>E_E1[0]>>G_E1[0]>>E_E1[1]>>G_E1[1];
177 PSFType_E1[0]=2; PSFType_E1[1]=2;
179 G4double a=28.69,b=21.731,c=0.0285,d=1.267;
180 G4double E_E1_0=a*std::pow(A_Int,-1./3.)+b*std::pow(A_Int,-1./6.);
181 G4double G_E1_0=c*std::pow(E_E1_0,1.9);
184 s_E1[1]=2.*s_E1_0/3.;
188 in.ignore(10000,
'\n');
191 if(result){GenerateM1AndE2FromE1();}
197G4bool G4NuDEXPSF::TakePSFFromRIPL01(
const char* fname){
201 std::ifstream in(fname);
204 for(
G4int i=0;i<7;i++){in.ignore(10000,
'\n');}
206 if(aZ==Z_Int && aA==A_Int){
210 in>>E_E1[nR_E1]>>s_E1[nR_E1]>>G_E1[nR_E1];
214 in>>E_E1[nR_E1]>>dum>>G_E1[nR_E1];
216 s_E1[nR_E1]=std::atof(dum);
222 in.ignore(10000,
'\n');
225 if(result){GenerateM1AndE2FromE1();}
231G4bool G4NuDEXPSF::TakePSFFromIAEA01(
const char* fname){
237 std::ifstream in(fname);
239 if(aZ==Z_Int && aA==A_Int){
242 in>>dum>>dum>>E_E1[nR_E1]>>dum>>dum>>G_E1[nR_E1]>>dum>>dum>>s_E1[nR_E1];
243 PSFType_E1[nR_E1]=11;
246 if(std::string(dum)==std::string(
"beta=")){
250 else if(std::string(dum)==std::string(
"Er2")){
251 in>>dum>>E_E1[nR_E1]>>dum>>dum>>G_E1[nR_E1]>>dum>>dum>>s_E1[nR_E1]>>dum>>beta;
252 PSFType_E1[nR_E1]=11;
257 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
261 in.ignore(10000,
'\n');
272 E_M1[nR_M1]=18.0*std::pow(A_Int,-1./6.);
274 s_M1[nR_M1]=0.03*std::pow(A_Int,5./6.);
278 E_M1[nR_M1]=5.0*std::pow(A_Int,-1./10.);
280 s_M1[nR_M1]=0.02*std::fabs(beta)*std::pow(A_Int,9./10.);
283 PSFType_M1[nR_M1]=21;
284 E_M1[nR_M1]=0.4035*std::exp(-6.0*std::fabs(beta));
293 E_E2[nR_E2]=63*std::pow(A_Int,-1./3.);
294 G_E2[nR_E2]=6.11-0.021*A_Int;
295 s_E2[nR_E2]=0.00014*Z_Int*Z_Int*E_E2[nR_E2]/std::pow(A_Int,1./3)/G_E2[nR_E2];
305G4bool G4NuDEXPSF::TakePSFFromInputFile(
const char* fname){
309 std::ifstream in(fname);
311 if(word[0]==
'#'){in.ignore(10000,
'\n');}
312 if(std::string(word)==std::string(
"END")){
break;}
313 if(std::string(word)==std::string(
"PSF")){
316 for(
G4int i=0;i<nR_E1;i++){
317 in>>PSFType_E1[i]>>E_E1[i]>>G_E1[i]>>s_E1[i];
318 if(PSFType_E1[i]==7){in>>p1_E1[i];}
319 if(PSFType_E1[i]==8){in>>p1_E1[i]>>p2_E1[i];}
320 if(PSFType_E1[i]==9){in>>p1_E1[i]>>p2_E1[i];}
321 if(PSFType_E1[i]==10){in>>p1_E1[i]>>p2_E1[i]>>p3_E1[i];}
322 if(PSFType_E1[i]==40 || PSFType_E1[i]==41){
323 if(x_E1!=0){
NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");}
326 for(
G4int j=0;j<np_E1;j++){in>>x_E1[j]>>y_E1[j];}
331 for(
G4int i=0;i<nR_M1;i++){
332 in>>PSFType_M1[i]>>E_M1[i]>>G_M1[i]>>s_M1[i];
333 if(PSFType_M1[i]==7){in>>p1_M1[i];}
334 if(PSFType_M1[i]==8){in>>p1_M1[i]>>p2_M1[i];}
335 if(PSFType_M1[i]==9){in>>p1_M1[i]>>p2_M1[i];}
336 if(PSFType_M1[i]==10){in>>p1_M1[i]>>p2_M1[i]>>p3_M1[i];}
337 if(PSFType_M1[i]==40 || PSFType_M1[i]==41){
338 if(x_M1!=0){
NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");}
341 for(
G4int j=0;j<np_M1;j++){in>>x_M1[j]>>y_M1[j];}
346 for(
G4int i=0;i<nR_E2;i++){
347 in>>PSFType_E2[i]>>E_E2[i]>>G_E2[i]>>s_E2[i];
348 if(PSFType_E2[i]==7){in>>p1_E2[i];}
349 if(PSFType_E2[i]==8){in>>p1_E2[i]>>p2_E2[i];}
350 if(PSFType_E2[i]==9){in>>p1_E2[i]>>p2_E2[i];}
351 if(PSFType_E2[i]==10){in>>p1_E2[i]>>p2_E2[i]>>p3_E2[i];}
352 if(PSFType_E2[i]==40 || PSFType_E2[i]==41){
353 if(x_E2!=0){
NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");}
356 for(
G4int j=0;j<np_E2;j++){in>>x_E2[j]>>y_E2[j];}
370void G4NuDEXPSF::Renormalize(){
372 G4int npIntegral=1000;
374 G4double binWidth=(NormEmax-NormEmin)/npIntegral;
379 for(
G4int i=0;i<npIntegral;i++){
380 x_eval=NormEmin+binWidth*(i+0.5);
381 y_eval=
GetE1(x_eval,NormEmax);
385 ScaleFactor_E1=E1_normFac/Integral;
391 for(
G4int i=0;i<npIntegral;i++){
392 x_eval=NormEmin+binWidth*(i+0.5);
393 y_eval=
GetM1(x_eval,NormEmax);
397 ScaleFactor_M1=M1_normFac/Integral;
404 for(
G4int i=0;i<npIntegral;i++){
405 x_eval=NormEmin+binWidth*(i+0.5);
406 y_eval=
GetE2(x_eval,NormEmax);
410 ScaleFactor_E2=E2_normFac/Integral;
418G4bool G4NuDEXPSF::TakePSFFromDetailedParFile(
const char* fname){
422 std::ifstream in(fname);
424 if(aZ==Z_Int && aA==A_Int){
427 for(
G4int i=0;i<nR_E1;i++){
428 in>>PSFType_E1[i]>>E_E1[i]>>G_E1[i]>>s_E1[i];
429 if(PSFType_E1[i]==7){in>>p1_E1[i];}
430 if(PSFType_E1[i]==8){in>>p1_E1[i]>>p2_E1[i];}
431 if(PSFType_E1[i]==9){in>>p1_E1[i]>>p2_E1[i];}
432 if(PSFType_E1[i]==10){in>>p1_E1[i]>>p2_E1[i]>>p3_E1[i];}
435 for(
G4int i=0;i<nR_M1;i++){
436 in>>PSFType_M1[i]>>E_M1[i]>>G_M1[i]>>s_M1[i];
437 if(PSFType_M1[i]==7){in>>p1_M1[i];}
438 if(PSFType_M1[i]==8){in>>p1_M1[i]>>p2_M1[i];}
439 if(PSFType_M1[i]==9){in>>p1_M1[i]>>p2_M1[i];}
440 if(PSFType_M1[i]==10){in>>p1_M1[i]>>p2_M1[i]>>p3_M1[i];}
443 for(
G4int i=0;i<nR_E2;i++){
444 in>>PSFType_E2[i]>>E_E2[i]>>G_E2[i]>>s_E2[i];
445 if(PSFType_E2[i]==7){in>>p1_E2[i];}
446 if(PSFType_E2[i]==8){in>>p1_E2[i]>>p2_E2[i];}
447 if(PSFType_E2[i]==9){in>>p1_E2[i]>>p2_E2[i];}
448 if(PSFType_E2[i]==10){in>>p1_E2[i]>>p2_E2[i]>>p3_E2[i];}
452 in.ignore(10000,
'\n');
466 for(
G4int i=0;i<nR_E1;i++){
467 if(PSFType_E1[i]==0){
468 result+=8.674E-8*SLO(Eg,E_E1[i],G_E1[i],s_E1[i]);
470 else if(PSFType_E1[i]==1){
471 result+=8.674E-8*EGLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy);
473 else if(PSFType_E1[i]==2){
474 result+=8.674E-8*SMLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy);
476 else if(PSFType_E1[i]==3){
477 result+=8.674E-8*GLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy);
479 else if(PSFType_E1[i]==4){
480 result+=8.674E-8*MGLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy);
482 else if(PSFType_E1[i]==5){
483 result+=8.674E-8*KMF(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy);
485 else if(PSFType_E1[i]==6){
486 result+=8.674E-8*GH(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy);
488 else if(PSFType_E1[i]==7){
489 result+=8.674E-8*MEGLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy,p1_E1[i],p1_E1[i]);
491 else if(PSFType_E1[i]==8){
492 result+=8.674E-8*MEGLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy,p1_E1[i],p2_E1[i]);
494 else if(PSFType_E1[i]==9){
495 result+=8.674E-8*MEGLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy,p1_E1[i],p1_E1[i],p2_E1[i]);
497 else if(PSFType_E1[i]==10){
498 result+=8.674E-8*MEGLO(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy,p1_E1[i],p2_E1[i],p3_E1[i]);
500 else if(PSFType_E1[i]==11){
501 result+=8.674E-8*SMLO_v2(Eg,E_E1[i],G_E1[i],s_E1[i],ExcitationEnergy);
503 else if(PSFType_E1[i]==20){
504 result+=8.674E-8*Gauss(Eg,E_E1[i],G_E1[i],s_E1[i]);
506 else if(PSFType_E1[i]==21){
507 result+=8.674E-8*Expo(Eg,E_E1[i],G_E1[i]);
509 else if(PSFType_E1[i]==40){
510 result+=EvaluateFunction(Eg,np_E1,x_E1,y_E1);
512 else if(PSFType_E1[i]==41){
513 result+=std::pow(10.,EvaluateFunction(Eg,np_E1,x_E1,y_E1));
516 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
521 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
524 return result*ScaleFactor_E1;
530 for(
G4int i=0;i<nR_M1;i++){
531 if(PSFType_M1[i]==0){
532 result+=8.674E-8*SLO(Eg,E_M1[i],G_M1[i],s_M1[i]);
534 else if(PSFType_M1[i]==1){
535 result+=8.674E-8*EGLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy);
537 else if(PSFType_M1[i]==2){
538 result+=8.674E-8*SMLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy);
540 else if(PSFType_M1[i]==3){
541 result+=8.674E-8*GLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy);
543 else if(PSFType_M1[i]==4){
544 result+=8.674E-8*MGLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy);
546 else if(PSFType_M1[i]==5){
547 result+=8.674E-8*KMF(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy);
549 else if(PSFType_M1[i]==6){
550 result+=8.674E-8*GH(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy);
552 else if(PSFType_M1[i]==7){
553 result+=8.674E-8*MEGLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy,p1_M1[i],p1_M1[i]);
555 else if(PSFType_M1[i]==8){
556 result+=8.674E-8*MEGLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy,p1_M1[i],p2_M1[i]);
558 else if(PSFType_M1[i]==9){
559 result+=8.674E-8*MEGLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy,p1_M1[i],p1_M1[i],p2_M1[i]);
561 else if(PSFType_M1[i]==10){
562 result+=8.674E-8*MEGLO(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy,p1_M1[i],p2_M1[i],p3_M1[i]);
564 else if(PSFType_M1[i]==11){
565 result+=8.674E-8*SMLO_v2(Eg,E_M1[i],G_M1[i],s_M1[i],ExcitationEnergy);
567 else if(PSFType_M1[i]==20){
568 result+=8.674E-8*Gauss(Eg,E_M1[i],G_M1[i],s_M1[i]);
570 else if(PSFType_M1[i]==21){
571 result+=8.674E-8*Expo(Eg,E_M1[i],G_M1[i]);
573 else if(PSFType_M1[i]==40){
574 result+=EvaluateFunction(Eg,np_M1,x_M1,y_M1);
576 else if(PSFType_M1[i]==41){
577 result+=std::pow(10.,EvaluateFunction(Eg,np_M1,x_M1,y_M1));
580 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
585 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
588 return result*ScaleFactor_M1;
594 for(
G4int i=0;i<nR_E2;i++){
595 if(PSFType_E2[i]==0){
596 result+=5.22E-8*SLO(Eg,E_E2[i],G_E2[i],s_E2[i]);
598 else if(PSFType_E2[i]==1){
599 result+=5.22E-8*EGLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy);
601 else if(PSFType_E2[i]==2){
602 result+=5.22E-8*SMLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy);
604 else if(PSFType_E2[i]==3){
605 result+=5.22E-8*GLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy);
607 else if(PSFType_E2[i]==4){
608 result+=5.22E-8*MGLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy);
610 else if(PSFType_E2[i]==5){
611 result+=5.22E-8*KMF(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy);
613 else if(PSFType_E2[i]==6){
614 result+=5.22E-8*GH(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy);
616 else if(PSFType_E2[i]==7){
617 result+=5.22E-8*MEGLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy,p1_E2[i],p1_E2[i]);
619 else if(PSFType_E2[i]==8){
620 result+=5.22E-8*MEGLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy,p1_E2[i],p2_E2[i]);
622 else if(PSFType_E2[i]==9){
623 result+=5.22E-8*MEGLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy,p1_E2[i],p1_E2[i],p2_E2[i]);
625 else if(PSFType_E2[i]==10){
626 result+=5.22E-8*MEGLO(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy,p1_E2[i],p2_E2[i],p3_E2[i]);
628 else if(PSFType_E2[i]==11){
629 result+=5.22E-8*SMLO_v2(Eg,E_E2[i],G_E2[i],s_E2[i],ExcitationEnergy);
631 else if(PSFType_E2[i]==20){
632 result+=5.22E-8*Gauss(Eg,E_E2[i],G_E2[i],s_E2[i]);
634 else if(PSFType_E2[i]==21){
635 result+=5.22E-8*Expo(Eg,E_E2[i],G_E2[i]);
637 else if(PSFType_E2[i]==40){
638 result+=EvaluateFunction(Eg,np_E2,x_E2,y_E2);
640 else if(PSFType_E2[i]==41){
641 result+=std::pow(10.,EvaluateFunction(Eg,np_E2,x_E2,y_E2));
644 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
649 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
652 return result*ScaleFactor_E2;
665 return sr*Gr*Eg*Gr/((Eg*Eg-Er*Er)*(Eg*Eg-Er*Er)+Eg*Eg*Gr*Gr);
674 Tf=theLD->GetNucleusTemperature(ExcitationEnergy-Eg);
676 G4double Gc=Gr/Er/Er*(Eg*Eg+4*3.141592*3.141592*Tf*Tf);
678 if(Eg==Er){
return 0;}
680 return 0.7*Er*Gr*sr*Gc/((Eg*Eg-Er*Er)*(Eg*Eg-Er*Er));
686 G4double result=EGLO_GLO_MGLO(Eg,Er,Gr,sr,ExcitationEnergy,0);
693 G4double result=EGLO_GLO_MGLO(Eg,Er,Gr,sr,ExcitationEnergy,1);
700 G4double result=EGLO_GLO_MGLO(Eg,Er,Gr,sr,ExcitationEnergy,2);
710 Tf=theLD->GetNucleusTemperature(ExcitationEnergy-Eg);
713 G4double Gamma_h=0.63*Gr/Eg/Er*(Eg*Eg+4*3.141592*3.141592*Tf*Tf);
715 return sr*Gr*Eg*Gamma_h/((Eg*Eg-Er*Er)*(Eg*Eg-Er*Er)+Eg*Eg*Gr*Gamma_h);
723 Tf=theLD->GetNucleusTemperature(ExcitationEnergy-Eg);
727 G4double Gk_Eg=Gr/Er*ExcitationEnergy;
729 return Lambda*sr*Gr*Eg*Gk_Eg/((Eg*Eg-Er*Er)*(Eg*Eg-Er*Er)+Eg*Eg*Gk_Eg*Gk_Eg);
736 if(Eg<ExcitationEnergy){
737 Tf=std::sqrt((ExcitationEnergy-Eg)/(A_Int/10.));
742 G4double Gk_Eg=Gr/Er*(Eg+4*3.141592*3.141592*Tf*Tf/Er);
744 return Lambda*sig_trk*2./3.141592*sr*Eg*Gk_Eg/((Eg*Eg-Er*Er)*(Eg*Eg-Er*Er)+Eg*Eg*Gk_Eg*Gk_Eg);
750 return Area*(1./(sigma*std::sqrt(2.*3.141592)))*std::exp(-0.5*std::pow((Eg-Er)/sigma,2.));
756 return C*std::exp(-eta*Eg);
770 Tf=theLD->GetNucleusTemperature(ExcitationEnergy-Eg);
773 G4double Gk_Eg=Gamma_k(Eg,Er,Gr,Tf,k_param1);
775 G4double Gk_0=Gamma_k(0,Er,Gr,Tf,k_param2);
777 return sr*Gr*(Eg*Gk_Eg/((Eg*Eg-Er*Er)*(Eg*Eg-Er*Er)+Eg*Eg*Gk_Eg*Gk_Eg)+0.7*Gk_0/Er/Er/Er);
790 Ti=theLD->GetNucleusTemperature(ExcitationEnergy);
791 Tf=theLD->GetNucleusTemperature(ExcitationEnergy-Eg);
799 k_param=1+0.09*(A_Int-148)*(A_Int-148)*std::exp(-0.18*(A_Int-148));
803 result=FlexibleGLOType(Eg,Er,Gr,sr,Tf,k_param,Ti,k_param);
806 result=FlexibleGLOType(Eg,Er,Gr,sr,Tf,1,Ti,1);
809 result=FlexibleGLOType(Eg,Er,Gr,sr,Tf,k_param,Ti,1);
812 NuDEXException(__FILE__,std::to_string(__LINE__).c_str(),
"##### Error in NuDEX #####");
821 G4double Gk_Eg=Gamma_k(Eg,Er,Gr,Temp1,k_param1);
823 G4double Gk_0=Gamma_k(0,Er,Gr,Temp1,k_param2);
825 return sr*Gr*(Eg*Gk_Eg/((Eg*Eg-Er*Er)*(Eg*Eg-Er*Er)+Eg*Eg*Gk_Eg*Gk_Eg)+0.7*Gk_0/Er/Er/Er);
835 Chi=k_param+(1-k_param)*(Eg-eps0_param)/(Er-eps0_param);
838 G4double Gamma_k=C_coll*(Eg*Eg+4*3.141592*3.141592*Temp*Temp);
854 out<<
" ###################################################################################### "<<std::endl;
855 out<<
" PSF_PARAMS"<<std::endl;
856 out<<
" E1: nRes = "<<nR_E1<<std::endl;
857 for(
G4int i=0;i<nR_E1;i++){
858 out<<
" "<<PSFType_E1[i]<<
" "<<E_E1[i]<<
" "<<G_E1[i]<<
" "<<s_E1[i]<<std::endl;
859 if(PSFType_E1[i]==7){out<<
" "<<p1_E1[i]<<std::endl;}
860 if(PSFType_E1[i]==8){out<<
" "<<p1_E1[i]<<
" "<<p2_E1[i]<<std::endl;}
861 if(PSFType_E1[i]==9){out<<
" "<<p1_E1[i]<<
" "<<p2_E1[i]<<std::endl;}
862 if(PSFType_E1[i]==10){out<<
" "<<p1_E1[i]<<
" "<<p2_E1[i]<<
" "<<p3_E1[i]<<std::endl;}
863 if(PSFType_E1[i]==40 || PSFType_E1[i]==41){out<<np_E1;
for(
G4int j=0;j<np_E1;j++){out<<
" "<<x_E1[j]<<
" "<<y_E1[j];} out<<std::endl;}
865 out<<
" M1: nRes = "<<nR_M1<<std::endl;
866 for(
G4int i=0;i<nR_M1;i++){
867 out<<
" "<<PSFType_M1[i]<<
" "<<E_M1[i]<<
" "<<G_M1[i]<<
" "<<s_M1[i]<<std::endl;
868 if(PSFType_M1[i]==7){out<<
" "<<p1_M1[i]<<std::endl;}
869 if(PSFType_M1[i]==8){out<<
" "<<p1_M1[i]<<
" "<<p2_M1[i]<<std::endl;}
870 if(PSFType_M1[i]==9){out<<
" "<<p1_M1[i]<<
" "<<p2_M1[i]<<std::endl;}
871 if(PSFType_M1[i]==10){out<<
" "<<p1_M1[i]<<
" "<<p2_M1[i]<<
" "<<p3_M1[i]<<std::endl;}
872 if(PSFType_M1[i]==40 || PSFType_M1[i]==41){out<<np_M1;
for(
G4int j=0;j<np_M1;j++){out<<
" "<<x_M1[j]<<
" "<<y_M1[j];} out<<std::endl;}
874 out<<
" E2: nRes = "<<nR_E2<<std::endl;
875 for(
G4int i=0;i<nR_E2;i++){
876 out<<
" "<<PSFType_E2[i]<<
" "<<E_E2[i]<<
" "<<G_E2[i]<<
" "<<s_E2[i]<<std::endl;
877 if(PSFType_E2[i]==7){out<<
" "<<p1_E2[i]<<std::endl;}
878 if(PSFType_E2[i]==8){out<<
" "<<p1_E2[i]<<
" "<<p2_E2[i]<<std::endl;}
879 if(PSFType_E2[i]==9){out<<
" "<<p1_E2[i]<<
" "<<p2_E2[i]<<std::endl;}
880 if(PSFType_E2[i]==10){out<<
" "<<p1_E2[i]<<
" "<<p2_E2[i]<<
" "<<p3_E2[i]<<std::endl;}
881 if(PSFType_E2[i]==40 || PSFType_E2[i]==41){out<<np_E2;
for(
G4int j=0;j<np_E2;j++){out<<
" "<<x_E2[j]<<
" "<<y_E2[j];} out<<std::endl;}
883 out<<
" ###################################################################################### "<<std::endl;
890 out<<
" PSF"<<std::endl;
891 G4long oldprc = out.precision(15);
892 out<<nR_E1<<std::endl;
893 for(
G4int i=0;i<nR_E1;i++){
894 out<<
" "<<PSFType_E1[i]<<
" "<<E_E1[i]<<
" "<<G_E1[i]<<
" "<<s_E1[i];
895 if(PSFType_E1[i]==7){out<<
" "<<p1_E1[i];}
896 if(PSFType_E1[i]==8){out<<
" "<<p1_E1[i]<<
" "<<p2_E1[i];}
897 if(PSFType_E1[i]==9){out<<
" "<<p1_E1[i]<<
" "<<p2_E1[i];}
898 if(PSFType_E1[i]==10){out<<
" "<<p1_E1[i]<<
" "<<p2_E1[i]<<
" "<<p3_E1[i];}
899 if(PSFType_E1[i]==40 || PSFType_E1[i]==41){out<<np_E1;
for(
G4int j=0;j<np_E1;j++){out<<
" "<<x_E1[j]<<
" "<<y_E1[j];} }
902 out<<nR_M1<<std::endl;
903 for(
G4int i=0;i<nR_M1;i++){
904 out<<
" "<<PSFType_M1[i]<<
" "<<E_M1[i]<<
" "<<G_M1[i]<<
" "<<s_M1[i];
905 if(PSFType_M1[i]==7){out<<
" "<<p1_M1[i];}
906 if(PSFType_M1[i]==8){out<<
" "<<p1_M1[i]<<
" "<<p2_M1[i];}
907 if(PSFType_M1[i]==9){out<<
" "<<p1_M1[i]<<
" "<<p2_M1[i];}
908 if(PSFType_M1[i]==10){out<<
" "<<p1_M1[i]<<
" "<<p2_M1[i]<<
" "<<p3_M1[i];}
909 if(PSFType_M1[i]==40 || PSFType_M1[i]==41){out<<np_M1;
for(
G4int j=0;j<np_M1;j++){out<<
" "<<x_M1[j]<<
" "<<y_M1[j];}}
912 out<<nR_E2<<std::endl;
913 for(
G4int i=0;i<nR_E2;i++){
914 out<<
" "<<PSFType_E2[i]<<
" "<<E_E2[i]<<
" "<<G_E2[i]<<
" "<<s_E2[i];
915 if(PSFType_E2[i]==7){out<<
" "<<p1_E2[i];}
916 if(PSFType_E2[i]==8){out<<
" "<<p1_E2[i]<<
" "<<p2_E2[i];}
917 if(PSFType_E2[i]==9){out<<
" "<<p1_E2[i]<<
" "<<p2_E2[i];}
918 if(PSFType_E2[i]==10){out<<
" "<<p1_E2[i]<<
" "<<p2_E2[i]<<
" "<<p3_E2[i];}
919 if(PSFType_E2[i]==40 || PSFType_E2[i]==41){out<<np_E2;
for(
G4int j=0;j<np_E2;j++){out<<
" "<<x_E2[j]<<
" "<<y_E2[j];}}
922 out.precision(oldprc);
927 if(xval<x[0]){
return y[0];}
928 if(xval>x[np-1]){
return y[np-1];}
932 for(
G4int i=1;i<np;i++){
939 m=(y[i_eval]-y[i_eval-1])/(x[i_eval]-x[i_eval-1]);
940 b=y[i_eval]-m*x[i_eval];
G4double C(G4double temp)
void NuDEXException(const char *originOfException, const char *exceptionCode, const char *description)
G4double GetM1(G4double Eg, G4double ExcitationEnergy)
G4double GetE2(G4double Eg, G4double ExcitationEnergy)
void PrintPSFParameters(std::ostream &out)
G4int Init(const char *dirname, G4NuDEXLevelDensity *aLD, const char *inputfname=0, const char *defaultinputfname=0, G4int PSFflag=0)
G4NuDEXPSF(G4int aZ, G4int aA)
G4double GetE1(G4double Eg, G4double ExcitationEnergy)
void PrintPSFParametersInInputFileFormat(std::ostream &out)