15 int bin = int(enu/0.05);
40 double syst = randomN*((scaled_pos/
fCV[ptype][
ntype][
bin])-1);
43 if(scaled_pos == 0) weight = 1;
46 else if(noNeg ==
true){
47 double syst = randomN*( (2 - (scaled_pos/
fCV[ptype][
ntype][
bin])) - 1);
50 if(scaled_pos == 0) weight = 1;
54 double syst = randomN*((scaled_neg/
fCV[ptype][
ntype][
bin])-1);
57 if(scaled_neg == 0) weight = 1;
61 if(fabs(
fCV[ptype][ntype][bin]) < 1.e-12) weight = 1;
63 if(weight < 0) weight = 1;
64 if(weight > 30) weight = 30;
69 if( (ntype == 0 || ntype == 1) && ptype == 1) weight = 1;
70 if( (ntype == 1 || ntype == 3) && ptype == 3) weight = 1;
EventWeightParameterSet fParameterSet
constexpr details::BinObj< T > bin(T value)
Returns a wrapper to print the specified data in binary format.
double UnisimWeightCalc(double enu, int ptype, int ntype, double randomN, bool noNeg)
bool isfinite(Vector const &v)
Returns whether all components of the vector are finite.
std::string fName
Name of the parameter set.
BEGIN_PROLOG could also be cout