Trains to and from the airport are frequent (usually 6 per hour during the day, no trains between 2am-4am) and take around 45 Minutes.
If your sons enjoyed castles there are several opportunities: Nymphenburg Palace is a cute baroque royal residence, nearby Blutenburg Castle is a gothic affair, the Residenz is fine if they don't mind it being a museum, and in the suburb of Oberschleissheim there are 3 baroque palaces to visit. The English Garden might be of interest (especially in summer), as is the Hofgarten and to some extent the Olympiapark (kids usually like to get on the Olympiaturm, a high observation tower).
As for restaurants: Most will be able to serve you a decent Schnitzel dish which should work quite well for kids (in fact you will get special kid's dishes at almost every restaurant...). If all fails there are quite a number of American-style fast food chains around...