improved numerical integration attempt, added Mathematica script generator to evaluate the many integration conditions