may be an outlet pipe or hose dumping water over the side?
If it was a periscope I would expect water to be thrown forward as well as sideways.
I have seen images from a perisope between a frigate propellors but I don't think a skipper would risk his boat that close to the bow.
Not sure what the underwater speed of the sub is but the carrier seems to be cracking on.