Form calculation is not calculating the values properly