new implementation of arb_exp()