The route is surprisingly Z-shaped mostly due to geography, since the Ardennes lie on the direct line. Also the development of the rail network in either country took no account of the other country.
That's further north than the direct line - I know I have fond memories of hitchhiking Brussels->Aachen with my girlfriend in the 1970s. Direct Paris/Berlin train needs to go along the Sedan/Bastogne axis that is not very flat.
Trains somehow go from Aachen to Brussels. Ardennes is hardly an obstacle.