Fairycakes69's return rail fare is for off-peak travel, leaving Ayr after 0930 weekdays (or any time at the weekend). Earlier weekday travel costs £31.60 return.
Sometimes you can do the journey by simply changing at Glasgow Central but most services require you to transfer from Glasgow Central to Glasgow Queen Street.
Milligans Coach Travel has a few day trips to Edinburgh but it's unlikely that any will meet your needs. I'll post the link though, as there might be something in their programme which is of interest to your family:
http://www.milligansc...6151Milligans2012.pdf
Ayr Tourist Information Centre, on Sandgate, will know about any other coach trips. Phone 01292 288688.
I can recommend the haggis, neeps and tatties served at The Standing order ;-)
http://www.jdwethersp...nding-order-edinburgh
TripAdvisor lists 1160 restaurants in Edinburgh, ranked in order here:
http://www.tripadviso...inburgh_Scotland.html
Here are the ten best cheap places to eat in Edinburgh, according to The Guardian:
http://www.guardian.c...restaurants-edinburgh
And here are some more suggestions (ranked in order) from the excellent Urbanspoon website:
http://www.urbanspoon...burgh/Cheap-Eats.html
Chris