fix of an accidentally carried out wrong cleanup.
This commit is contained in:
20
src/external/libBNMR/TBNMR.cpp
vendored
20
src/external/libBNMR/TBNMR.cpp
vendored
@ -73,21 +73,13 @@ double SExpRlx::operator()(double x, const vector<double> &par) const {
|
|||||||
// par[1] is the relaxation rate
|
// par[1] is the relaxation rate
|
||||||
// par[2] is the exponent
|
// par[2] is the exponent
|
||||||
|
|
||||||
double y;
|
if ( x >= 0 && x <= par[0] ) {
|
||||||
|
sexp1.SetParameters(x, par[1], par[2],tau_Li);
|
||||||
|
return sexp1.Integral(0.0,x)/(1-exp(-x/tau_Li))/tau_Li;
|
||||||
if ( x >= 0 && x <= par[0] ) {
|
|
||||||
TF1 sexp("sexp", "exp(-([0]-x)/[3])*exp(-pow(([1]*([0]-x)),[2]))", 0.0, 10000.0);
|
|
||||||
sexp.SetParameters(x, par[1], par[2],tau_Li);
|
|
||||||
sexp.SetNpx(1000);
|
|
||||||
y=sexp.Integral(0.0,x)/(1-exp(-x/tau_Li))/tau_Li;
|
|
||||||
} else if ( x > par[0] ) {
|
} else if ( x > par[0] ) {
|
||||||
TF1 sexp("sexp", "exp(-([3]-x)/[4])*exp(-pow(([1]*([0]-x)),[2]))", 0.0, 10000.0);
|
sexp2.SetParameters(x, par[1], par[2], par[0],tau_Li);
|
||||||
sexp.SetParameters(x, par[1], par[2], par[0],tau_Li);
|
return sexp2.Integral(0.0,par[0])/(1-exp(-par[0]/tau_Li))/tau_Li;
|
||||||
sexp.SetNpx(1000);
|
|
||||||
y=sexp.Integral(0.0,par[0])/(1-exp(-x/tau_Li))/tau_Li;
|
|
||||||
} else {
|
|
||||||
y = 0;
|
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user