Hi André,
Hmmm... as far as I know, Guide's method for computing this is
almost exactly the same as in Brad Schaefer's article. (I made a
small alteration to allow the moon to contribute some light when it's
partly below the horizon.) The source code is available at
http://www.projectpluto.com/source.htm#astrocalc
Look in 'vislimit.cpp'. (This can be compiled as C or C++ code.)
This code is used for the limiting visual magnitudes shown in Quick
Info, and also for computing the realistic sky shading shown when
you use Display... Background... Realistic.
It's a little puzzling to me that Guide and Schaefer's code would
disagree.
-- Bill