25 std::string shaperType) :
30 std::transform(shaperType.begin(), shaperType.end(),
31 shaperType.begin(), toupper);
32 if (shaperType ==
"UNIPOLAR") {
33 m_type = ShaperType::Unipolar;
35 m_prefactor = exp(m_n);
36 m_transfer_func_sq = (exp(2 * m_n) / pow(2 * m_n, 2 * m_n)) * m_tp *
37 ROOT::Math::tgamma(2 * m_n);
38 }
else if (shaperType ==
"BIPOLAR") {
39 m_type = ShaperType::Bipolar;
40 const double r = m_n - sqrt(m_n);
42 m_prefactor = exp(r) / sqrt(m_n);
43 m_transfer_func_sq = (exp(2 * r) / pow(2 * r, 2 * m_n)) * r * m_tp *
44 ROOT::Math::tgamma(2 * m_n - 1);
46 std::cerr << m_className <<
": Unknown shaper type.\n";