PROGRAM BT5_3 PARAMETER (NMAX=100,MMAX=6) DIMENSION X(NMAX*MMAX) DIMENSION R(MMAX*MMAX),RC(MMAX*MMAX) CHARACTER VARNAME(6)*2 DATA VARNAME /'X1','X2','X3','Y1','Y2','Y3'/ DATA ALFA /0.05/ OPEN(1,FILE='C:\MASTER\G_TR\BAITAP~1\NEW\BANG2.TXT') READ(1,*) READ(1,*) READ(1,*) N,M DO I=1,N L=(M-1)*N+I READ(1,*) TMP, (X(J),J=I,L,N) ENDDO CALL CORRE(X,N,M,R) 300 FORMAT('KHOANG UOC LUONG CUA R(',A2,'-',A2,')=(', & F7.4,';',F7.4')') DO J=1,M-1 DO K=(J-1)*M+J+1, J*M CALL ULKHOANGR(R(K),ALFA,N,R1,R2) L=MOD(K,M) IF (L.EQ.0) L=6 WRITE(*,'(" R(",A2,"-",A2,")=",F7.4)') & VARNAME(J),VARNAME(L), R(K) WRITE(*,300) VARNAME(J),VARNAME(L), R1,R2 ENDDO ENDDO END !++++++++++++++++++++++ SUBROUTINE ULKHOANGR(R,ALFA,N,R1,R2) ! CHUONG TRINH NAY TINH UOC LUONG KHOANG CUA HE SO TUONG QUAN ! (R1, R2) ==> R1