SHGen takes six images from a cube map -- such as what you might render out of Max or Maya -- gives a polar coordinate preview in the center, and transforms it into Spherical Harmonics coefficients.
Spherical Harmonics are used to approximate functions over a sphere, which happens to work out nicely for ambient lighting solutions. Since ambient lighting kind of bounces all over the place and comes from 'everywhere,' it can be represented as intensities over a sphere around an object being lit.
The precision of the approximation depends on how many numbers (the coefficients) you use to drive the harmonic functions. More is better, as usual.
Spherical Harmonics have a few other neat properties in regards to rendering and some nice shortcuts when it comes to doing fast math operations over a sphere. I'd recommend reading some more about them.