fix bug for transfer and calculate