Integral of Cos Square D