compute AVP