function f(x: real): real; begin if x < -1.0 then Result:= Pi / (4 * x) else if (x >= -1.0) and (x <= 1.0) Result:= arccos(x) Result:= Pi * x / 4; end;