Skip to content

extend ROOT::VecOps::DeltaR

Afiq Aizuddin Anuar requested to merge vec_sca_dR_take_2 into HHbbtautau_dev

consider a situation where one is interested in the dRs of jets wrt a single reference point say the higgs at gen level.

this is an example where we want a ROOT::VecOps::DeltaR(eta1, eta2, phi1, phi2) to be able to also take ROOT::VecOps::DeltaR(vector, scalar, vector, scalar) and vice versa, instead of just ROOT::VecOps::DeltaR(vector, ..., vector) and ROOT::VecOps::DeltaR(scalar, ..., scalar).

not available in the root version we used, and last I checked, also in master.

no reason why, as ROOT::VecOps::DeltaPhi(phi1, phi2) etc already supports mixed vec/sca args. so we extend it by ourselves.

numbers_like(...) is a bonus ala numpy's zeros_like, but with arbitrary numbers. used by e.g. utilsrdf.py's define_if_valid().

Merge request reports