Gas bremsstrahlung from electron storage rings: A Monte Carlo evaluation and some useful formulae