Orthogonal trajectories on Riemannian manifolds and applications to Plane Wave type spacetimes