upvar2
C UPVAR2 SOURCE CHAT 05/01/13 03:59:57 5004 C UPVAR2 SOURCE A1 12/01/12 12.15.00 C _____________________________________________________________________ & ALF1,ALF2,NSTRS) IMPLICIT INTEGER(I-N) IMPLICIT REAL *8 (A-H,O-Z) DIMENSION EM(*),EB(*),EPSCRP(*),EPSPLU(*),EPSMIN(*) DIMENSION DIF0(8) DATA X,Y/1.0D-06,0.0D0/ C _____________________________________________________________________ C THIS ROUTINE UPDATES THE INTERNAL VARIABLES C _____________________________________________________________________ C NS = NSTRS/2 DO 10 I=1,NS DIF0(I)=EPSCRP(I)-EPSPLU(I) 10 CONTINUE DO 21 I=1,NS DIF0(I)=EPSCRP(I+NS)-EPSPLU(I+NS) 21 CONTINUE SPLU=PROM1+ ALF1*PROB1 GPLU=PROM2+ ALF2*PROB2 * IF(NS.EQ.2) THEN * P1 =(EPSCRP(1)-EPSPLU(1)) * P2 =(EPSCRP(2)-EPSPLU(2)) * P3 =(EPSCRP(3)-EPSPLU(3)) * P4 =(EPSCRP(4)-EPSPLU(4)) * SPLU= P1*SIG(1)+P2*SIG(2) + ALF1 * (P3*SIG(3)+P4*SIG(4)) * GPLU=(P1*P1+P2*P2+P1*P2) + ALF2 * (P3*P3 +P4*P4+P3*P4) DO 30 I=1,NS DIF0(I)=EPSCRP(I)-EPSMIN(I) 30 CONTINUE DO 40 I=1,NS DIF0(I)=EPSCRP(I+NS)-EPSMIN(I+NS) 40 CONTINUE SMIN=PROM1+ ALF1*PROB1 GMIN=PROM2+ ALF2*PROB2 * P1 =(EPSCRP(1)-EPSMIN(1)) * P2 =(EPSCRP(2)-EPSMIN(2)) * P3 =(EPSCRP(3)-EPSMIN(3)) * P4 =(EPSCRP(4)-EPSMIN(4)) * SMIN= P1*SIG(1)+P2*SIG(2) + ALF1*(P3*SIG(3)+P4*SIG(4)) * GMIN=(P1*P1+P2*P2+P1*P2) + ALF2*(P3*P3+P4*P4+P3*P4) * ELSE * P1 =(EPSCRP(1)-EPSPLU(1))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4*P4+P5*P5+P4*P5+P6*P6/3.0D0) * EPS1=(P1*P1+P2*P2+P1*P2+P3*P3) * EPS2=(P4*P4+P5*P5+P4*P5+P6*P6) * EPSH= EPS1 + ALF2 * EPS2 * ENDIF DO 50 I=1,NS DIF0(I)=EPSCRP(I)-EPSPLU(I) 50 CONTINUE DO 60 I=1,NS DIF0(I)=EPSCRP(I+NS)-EPSPLU(I+NS) 60 CONTINUE EPSH=PROM1+ ALF2*PROB1 EPSH= SQRT(2.D0*EPSH/3.0D0) GO TO 22 20 CONTINUE * IF(NS.EQ.2) THEN * P1 =(EPSCRP(1)-EPSMIN(1)) * P2 =(EPSCRP(2)-EPSMIN(2)) * P3 =(EPSCRP(3)-EPSMIN(3)) * P4 =(EPSCRP(4)-EPSMIN(4)) * EPS1=(P1*P1+P2*P2+P1*P2) * EPS2=(P3*P3+P4*P4+P3*P4) * EPSH= EPS1 + ALF2 * EPS2 * ELSE * P1 =(EPSCRP(1)-EPSMIN(1)) * P2 =(EPSCRP(2)-EPSMIN(2)) * P3 =(EPSCRP(3)-EPSMIN(3)) * P4 =(EPSCRP(4)-EPSMIN(4)) * P5 =(EPSCRP(5)-EPSMIN(5)) * P6 =(EPSCRP(6)-EPSMIN(6)) ** EPS1=(P1*P1+P2*P2+P1*P2+P3*P3/3.0D0) ** EPS2=(P4*P4+P5*P5+P4*P5+P6*P6/3.0D0) * EPS1=(P1*P1+P2*P2+P1*P2+P3*P3) * EPS2=(P4*P4+P5*P5+P4*P5+P6*P6) * EPSH= EPS1 + ALF2 * EPS2 * ENDIF * EPSH= SQRT(EPSH/3.0D0)*2.0D0 DO 51 I=1,NS DIF0(I)=EPSCRP(I)-EPSMIN(I) 51 CONTINUE DO 61 I=1,NS DIF0(I)=EPSCRP(I+NS)-EPSMIN(I+NS) 61 CONTINUE EPSH=PROM1+ ALF2*PROB1 EPSH= SQRT(2.D0*EPSH/3.0D0) 22 CONTINUE M = LL C ---------------------------------------------------------------------- RETURN END
© Cast3M 2003 - Tous droits réservés.
Mentions légales