Using efficiency curve in outer applications
When an efficiency curve is constructed in HyperLab's detector efficiency analysis module, the fitted orthogonal polynomial is available from the File / Generic info menu item or in efficiency reports. An example polynomial may be the following:
 Eff = exp(-11069.2*0.000654323*T[0] -542.452  *0.00261785*T[1] -83.9643 *0.00614508*T[2] + 56.176  *0.0107488*T[3] -38.0378 *0.0227131*T[4] +  4.23398*0.0361133*T[5] + 2.91758*0.109829*T[6] ) X = -2.92876 +0.485424*log(E_keV) T[0] = 1.0 T[1] =  X -0.279333 T[2] = (X +0.276447 )*T[1] -0.0624734*T[0] T[3] = (X -0.193059 )*T[2] -0.181482 *T[1] T[4] = (X -0.0543797)*T[3] -0.326837 *T[2] T[5] = (X +0.0860381)*T[4] -0.223959 *T[3] T[6] = (X -0.0991865)*T[5] -0.395568 *T[4]
A corresponding c++ calculation function is the following:
 double D4_Eff(double E_keV) { double T[7], X = -2.92876 +0.485424*log(E_keV); T[0] = 1.0; T[1] =  X -0.279333; T[2] = (X +0.276447 )*T[1] -0.0624734*T[0]; T[3] = (X -0.193059 )*T[2] -0.181482 *T[1]; T[4] = (X -0.0543797)*T[3] -0.326837 *T[2]; T[5] = (X +0.0860381)*T[4] -0.223959 *T[3]; T[6] = (X -0.0991865)*T[5] -0.395568 *T[4]; double Eff = exp(  -11069.2*0.000654323*T[0] -542.452*0.00261785*T[1] -83.9643*0.00614508*T[2] +56.176*0.0107488*T[3] -38.0378*0.0227131*T[4] +4.23398*0.0361133*T[5] +2.91758*0.109829*T[6]); return Eff; }
This formula above may be transformed into an identical regular polynomial, which describe the logarithmic of efficiency versus the logarithmic of energy:
 double D4_LogEff_regular(double LogE) {  double LogEff =  71.50855044771767 -117.10105124644454*LogE + 62.00533726638615*pow(LogE,2) - 15.922301170232352*pow(LogE,3) +  2.161709922884965*pow(LogE,4) -  0.1499226396426317*pow(LogE,5) +  0.00419244399979918*pow(LogE,6);  return LogEff; }

Copyright © 1998-2007 by HyperLabs Software Budapest, Hungary