add gamma and logA