Invoice calculation adapted to new requirements