The Royal Navy flagship will be returning to Portsmouth following a diplomatic visit to Germany.