first working version to compute the efficiencies from tuple