Skip to content

Define what should be the rapidity result if `e()<0`

As of now the eta() of FourVector is defined as

    double rap() const {
      if ( e() == 0.0 ) return 0.0;
      if ( e() == fabs(pz()) ) return std::copysign(HUGE_VAL, pz());
      return 0.5*std::log( (e() + pz()) / (e() - pz()) );
    }

And in case e()<0, it is possible to get NaN as a result.