public double Function(double z) { double norm = z; if (norm >= sigma) return 0; norm = norm / sigma; double a = c2dPI * System.Math.Acos(-norm); double b = c2dPI * norm; double c = 1.0 - norm * norm; return a - b * System.Math.Sqrt(c); }