arrow arrow , "Q" "n"



<<     >>

.

N i

Q i

N i

Q i

N i

Q i

N i

Q i

N i

Q i

0,03

0,19

0,39

0,59

0,79

0,89

1,13

1,09

1,43

1,23

0,09

0,28

0,48

0,66

0,87

0,94

1,19

1,12

1,49

1,26

0,15

0,35

0,56

0,72

0,94

0,98

1,25

1,15

1,55

1,29

0,22

0,43

0,64

0,78

1,01

1,02

1,31

1,18

1,61

1,32

0,31

0,52

0,72

0,84

1,07

1,06

1,37

1,21

1,66

1,34

.4. .

:

Qi -

(Qi) -

.5. .

:

Qi -

(Qi) -

QBASIC

QBASIC. (1), , . -. (1) (2).

1

1

2

QBASIC

OPEN " .bas" FOR OUTPUT AS #2

'

CLS : n = 25

DIM N(n), Q(n), T(n), QT1(n), QT2(n), Z(n)

DATA 0.03, 0.09, 0.15, 0.22, 0.31

DATA 0.39, 0.48, 0.56, 0.64, 0.72

DATA 0.79, 0.87, 0.94, 1.01, 1.07

DATA 1.13, 1.19, 1.25, 1.31, 1.37

DATA 1.43, 1.49, 1.55, 1.61, 1.66

DATA 0.19, 0.28, 0.35, 0.43, 0.52

DATA 0.59, 0.66, 0.72, 0.78, 0.84

DATA 0.89, 0.94, 0.98, 1.02, 1.06

DATA 1.09, 1.12, 1.15, 1.18, 1.21

DATA 1.23, 1.26, 1.29, 1.32, 1.34

'

FOR I = 1 TO n: READ N(I): NEXT I

FOR I = 1 TO n: READ Q(I)

'

SN1 = SN1 + N(I): SN2 = SN2 + N(I) ^ 2

SQ1 = SQ1 + Q(I): SN1Q1 = SN1Q1 + N(I) * Q(I)

T(I) = LOG(N(I)): Z(I) = LOG(Q(I))

ST1 = ST1 + T(I): ST2 = ST2 + T(I) ^ 2

SZ1 = SZ1 + Z(I): ST1Z1 = ST1Z1 + T(I) * Z(I)

NEXT I

'

A1 = (SQ1 - SN1Q1 * SN1 / SN2) / (n - SN1 ^ 2 / SN2)

A2 = (SQ1 - A1 * n) / SN1

'

B = (SZ1 - ST1Z1 * ST1 / ST2) / (n - ST1 ^ 2 / ST2)

A11 = EXP(B)

A22 = (SZ1 - A11 * n) / ST1

'

NC = SN1 / n: QC = SQ1 / n

FOR I = 1 TO n

S1 = S1 + (N(I) - NC) * (Q(I) - QC)

S2 = S2 + (N(I) - NC) ^ 2: S3 = S3 + (Q(I) - QC) ^ 2

QT1(I) = A1 + A2 * N(I)

QT2(I) = A11 * N(I) ^ A22

NEXT I

R = S1 / (SQR(S2) * SQR(S3))

'

FOR I = 1 TO n

M1 = M1 + (QT1(I) - Q(I)) ^ 2

M2 = M2 + (QT2(I) - Q(I)) ^ 2

V1 = V1 + (QT1(I) - QC) ^ 2

V2 = V2 + (QT2(I) - QC) ^ 2

NEXT I

'

F1 = M1 + V1

F2 = M2 + V2

R1 = 1 - (M1 / F1)

R2 = 1 - (M2 / F2)

'

PRINT #2, " "

PRINT #2,

PRINT #2, " "

PRINT #2, "R="; R

PRINT #2,

PRINT #2, " "

PRINT #2, "A1="; A1; " A2="; A2

PRINT #2,

PRINT #2, " CT "

PRINT #2, "A11="; A11; " A22="; A22

PRINT #2,

PRINT #2, " "

PRINT #2, " "

PRINT #2,

PRINT #2, "R1="; R1; "R2="; R2

PRINT #2

PRINT #2, -99-1 ..

R= .988714

A1= .3000169 A2= .67114

CT

A11= 1.006743 A22= 0.51921

R1= .9775556 R2= .99568867

-99-1 ..

,

NC, QC - N Q .

QT1 - (1).

QT2 - (3).

A1, A2 - (1) .

A11, A22 - (3).

R - .

M1 - QT1 .

M2 - QT2 .

V1 - QT1 .

V2 - QT2 .

F1, F2- .

R1 - QT1.

R2 - QT2.

 
<<     >>