Added functions for double integrals