Numerical integration (C, C++, Qt)