.


:




:

































 

 

 

 





Delphi. 2.4.5 . Delphi. .

 

. .

Z(x,y), . X0Y, Z.

Z(x,y) . , .3.26, 3.30, . , Z=Zc, Z(x,y) Z=Zc.

R . :

x2 + y2 + z2=R2

Z, x, y:

 

(3.47)

 

 

+ , . 0 R. .3.31.

 

. .

1. (3.47) .

2. Z(x,y), , .1.

 


. (Z>0) -1≤ x ≤ 1, -1≤ y ≤1. , X0Y, .3.32.

N×M, N X, M - Y. . X Y , :

hx=2/N, hy=2/M.

N=M, .

:

xj= 1+jhx, j=0,..,N

yi= 1+ihy, i=0,..,M

 

, Z (3.47). :

(3.48)

 

Z {Zi,j}, i=0,..,M, j=0,..,N

 

.

Program Polusfera;

Const M=50; N=50;//

Var I,j: integer;

Z: array[1..M,1..N] of real; // - Z

x,y,hx,hy: real;

Flt: file of real; //

begin

Assign(Flt, F:\temp\Tmas.dat); //

Rewrite(Flt); //

hx:=2/N; hy:=2/M; // X Y

// Z

for i:=1 to M do

begin

y:=-1+hy*I;

for j:=1 to N do

begin

x:=-1+hx*j;

Z[I,j]:=sqrt(2-x*x-y*y)

end

end;

//

for i:=1 to M do

for j:=1 to N do write(Flt, Z[I,j]);

close(Flt);

Writeln( )

end.

. , , 2.2.4 . , .

, , . , , :

Var <>: file of < >.

Flt, :

Var Flt: file of real;

write(< >, < >)

:

Read((< >, < >)

, .

 





:


: 2015-11-23; !; : 2456 |


:

:

- , - .
==> ...

1313 - | 1250 -


© 2015-2024 lektsii.org - -

: 0.015 .