.


           


{ }

Procedure ReIection(n : longint; p, PP, eps : real; var e : real);

var

x : real;

begin

x := 0;

repeat

x := x + eps

until

FF(x) >= PP;

e := x*sqrt(p*(1 - p)/n)

end;

{ - }

Program Task3;

uses WinCrt;

var

n : longint;

e, eps, p, pp : real;

{----------------------------------------------------------------------------------------}

{ 頠 }

{ 0 x. - }

Function FF(x : real) : real;

var

n : integer;

u, I : real;

begin

if

x >= 5

then

FF := 1

else if x <= -5

then

FF := -1

else

begin

u := x;

n := 0;

I := 0;

repeat

I := I + u;

n := n + 1;

u := -u*(x*x*(2*n - 1)/(2*n*(2*n + 1)))

until

abs(u) < 0.00001;

FF := 2*I/sqrt(2*Pi)

end

end;

{----------------------------------------------------------------------------------------}

{ (ReIection) }

{ }

Procedure ReIection(n : longint; p, PP, eps : real; var e : real);

var

x : real;

begin

x := 0;

repeat

x := x + eps

until

FF(x) >= PP;