German lender Deutsche Bank reported a surprise surge in profits for the second quarter of 2017, beating market estimates and doubling its pre-tax profit figure from last year.