Prediction of critical transitions of ternary mixtures containing ammonia and n-alkanes