C Chuong trinh con trong bo chuong trinh C phan tich phan biet (phan lop) SUBROUTINE DMATX(K,M,N,X,XBAR,D,CMEAN) dimension N(1),X(1),XBAR(1),D(1),CMEAN(1) MM=M*M do 100 i=1,MM 100 D(i)=0 N4=0 L=0 LM=0 do 160 NG=1,K N1=N(NG) FN=N1 do 130 j=1,M LM=LM+1 XBAR(LM)=0 do 120 i=1,N1 L=L+1 120 XBAR(LM)=XBAR(LM)+X(L) 130 XBAR(LM)=XBAR(LM)/FN LMEAN=LM-M do 150 i=1,N1 LL=N4+i-N1 do 140 j=1,M LL=LL+N1 N2=LMEAN+j 140 CMEAN(j)=X(LL)-XBAR(N2) LL=0 do 150 j=1,M do 150 jj=1,M LL=LL+1 150 D(LL)=D(LL)+CMEAN(J)*CMEAN(JJ) 160 N4=N4+N1*M LL=-K DO 170 I=1,K 170 LL=LL+N(I) FN=LL do 180 I=1,MM 180 D(I)=D(I)/FN RETURN END