I am making a normal distribution calculator in PHP, but I can't figure out how to calculate the integral of a function using PHP. I've searched the web and stackoverflow, but I can't find anything on the topic. The closest I've come is via php.net where someone referrers to the Composite Simpson's Rule to get an approximation, but I would like to get a precise result and not just an approximation.
Is there any commonly know way to achieve my goal, that I am missing, and if there are several which would be the best for calculating normal distribution?