Many sources say that a general ceasefire order was issued by Doenitz to German submarines on patrol on May 4, 1945. We know that the German instrument of surrender was signed in the early morning (Europe) on May 7, and took effect late on May 8. Why the submarines have been put out of action 4 days before, especially as they were the only really valuable fighting arm of Nazis by that point?
My guess that it was because of the VLF transmitters guiding and coordinated their actions have been overrun by advancing Allies, like the Goliath transmitter, making communication with submerged boats impossible. But this is just a guess. Does anyone have a better idea? Also, when exactly did the Germans lose their final VLF transmitter, making any coordinated action by the boats impossible?