OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
phasekinetic2.F File Reference
#include "implicit_f.inc"

Go to the source code of this file.

Functions/Subroutines

subroutine phasekinetic2 (nel0, time, tempel, tempo, tempmin, ae1, ae3, bs, ms, fcfer, fcper, fcbai, fgrain, frac1, frac2, frac3, frac4, frac5, x2, x3, x4, x5, gfac_f, phi_f, psi_f, cr_f, cf, gfac_p, phi_p, psi_p, cr_p, cp, gfac_b, phi_b, psi_b, cr_b, cb, phi_m, psi_m, n_m, fgfer, fgper, fgbai, qr2, qr3, qr4, kper, kbain, alpha, xeq2, xeq4, xgama, totfrac, timestep, nicool, index, theaccfact)

Function/Subroutine Documentation

◆ phasekinetic2()

subroutine phasekinetic2 ( integer nel0,
time,
tempel,
tempo,
tempmin,
ae1,
ae3,
bs,
ms,
fcfer,
fcper,
fcbai,
fgrain,
frac1,
frac2,
frac3,
frac4,
frac5,
x2,
x3,
x4,
x5,
gfac_f,
phi_f,
psi_f,
cr_f,
cf,
gfac_p,
phi_p,
psi_p,
cr_p,
cp,
gfac_b,
phi_b,
psi_b,
cr_b,
cb,
phi_m,
psi_m,
n_m,
fgfer,
fgper,
fgbai,
qr2,
qr3,
qr4,
kper,
kbain,
alpha,
xeq2,
xeq4,
xgama,
totfrac,
timestep,
integer nicool,
integer, dimension(nicool) index,
intent(in) theaccfact )

Definition at line 29 of file phasekinetic2.F.

35
36#include "implicit_f.inc"
37C-----------------------------------------------
38C I N P U T A r g u m e n t s
39C-----------------------------------------------
40 INTEGER NEL0,NICOOL,INDEX(NICOOL)
41 my_real ,intent(in) :: theaccfact
43 . tempel(nel0),tempo(nel0),tempmin(nel0),timestep
45 . time,alpha,tref,ae1,ae3,bs,ms,gsize,nu,fcfer,fcper,fcbai,
46 . fgrain,qr2,qr3,qr4,kper,kbain,xeq2,xeq4,yx,
47 . gfac_f,phi_f,psi_f,cr_f,cf,gfac_p,phi_p,psi_p,cr_p,cp,
48 . gfac_b,phi_b,psi_b,cr_b,cb,phi_m,psi_m,n_m,fgfer,fgper,fgbai
49C-----------------------------------------------
51 . frac1(nel0),frac2(nel0),frac3(nel0),frac4(nel0),frac5(nel0)
53 . x2(nel0),x3(nel0),x4(nel0),x5(nel0),totfrac(nel0),xgama(nel0)
55 . ftemp,ux,vx,udot,vdot,f,const,fdot,x2old(nel0),
56 . x3old(nel0),x4old(nel0),x5old(nel0),gx,gdot,dti,term1,term2 ,term3
57 INTEGER I,K,J
58C-----------------------------------------------
59 ! SUM OF FRAC1+FRAC2+FRAC3+FRAC4+FRAC5=1--------
60 dti= one/max(timestep*theaccfact,em10)
61 DO j=1,nicool ! NEL0
62
63 i=index(j)
64 ! CHECK TEMPERATURE FOR CORRESPONDING PHASE CHANGE
65 IF(totfrac(i)<one.AND.tempel(i)<tempmin(i))THEN
66 IF (tempel(i)<ae3)THEN
67 IF(tempel(i)>ae1)THEN
68 IF(x2(i)<0.999)THEN
69 ! FERRITE FORMATION X2
70 !X2OLD(I)= FRAC2(I)/XEQ2
71 x2old(i)=x2(i)
72 IF(x2(i)==zero)x2(i)=em10
73 ftemp = exp(-qr2/tempel(i))*abs(tempel(i)-ae3)**3
74 const = ftemp * fgfer * cf
75 DO k=1,4
76 ux = x2(i) **(phi_f*(one-x2(i)))
77 vx = (one-x2(i))**(psi_f*x2(i))
78 gx = exp(cr_f *x2(i)*x2(i))
79 IF (gx<zero) gx=one
80 f =(x2(i)-x2old(i))*dti - const * ux*vx /gx
81 udot = phi_f* ux * ((one-x2(i))/max(em10,x2(i))-log(max(em10,x2(i))))
82 vdot = psi_f* vx * (log(one-x2(i))-x2(i)/(one-x2(i)))
83 gdot = two * cr_f * x2(i) * gx
84 fdot = dti-const*((udot*vx+vdot*ux)*gx-ux*vx*gdot)/gx/gx
85 x2(i)= max(em20,x2(i)-f/fdot)
86 ENDDO
87 frac2(i)=x2(i)*xeq2
88 frac1(i)=one-frac2(i)-frac3(i)-frac4(i)-frac5(i)
89 ENDIF
90c---------------------------------
91 ELSEIF(tempel(i)>bs)THEN
92
93 IF(x3(i)<0.999)THEN
94 ! PEARLITE X3
95 x3old(i)= x3(i) !FRAC3(I)/(ONE-XEQ2) !!
96 IF(x3(i)==zero)x3(i)=em10
97 ftemp=6.17*exp(-qr3/tempel(i))*abs(tempel(i)-ae1)**3
98 const=ftemp* fgper *cp !!! adjusted
99 DO k=1,4
100 ux = x3(i) **(phi_p*(one-x3(i)))
101 vx = (one-x3(i))**(psi_p*x3(i))
102 gx = exp(cr_p *x3(i)*x3(i))
103 IF (gx<zero) gx=one
104 f =(x3(i)-x3old(i))*dti - const * ux*vx /gx
105 udot = phi_p* ux * ((one-x3(i))/max(em10,x3(i))-log(max(em10,x3(i))))
106 vdot = psi_p* vx * (log(one-x3(i))-x3(i)/(one-x3(i)))
107 gdot = two * cr_p * x3(i) * gx
108 fdot = dti-const*((udot*vx+vdot*ux)*gx-ux*vx*gdot)/gx/gx
109 x3(i)= max(em20,x3(i)-f/fdot)
110 ENDDO
111c FRAC3(I)=X3(I)*(ONE-X2(I))
112 frac3(i)=x3(i)*(one-xeq2)
113 frac1(i)=one-frac2(i)-frac3(i)-frac4(i)-frac5(i)
114 ! CHECK IF FERRITE FORMATION
115 ENDIF
116c---------------------------------
117 ELSEIF(tempel(i)>ms)THEN
118 IF(x4(i)<0.999)THEN
119 ! BAINITE FORMATION
120 x4old(i) = x4(i)
121 IF(x4(i) == zero) x4(i) = x3(i)
122 ! INITIALISE AU TAUX DE PERLITE
123 ftemp=exp(-qr4/tempel(i)) *(tempel(i)-bs)**2
124 const=ftemp* fgbai *cb
125 DO k=1,4
126 ux = x4(i) **(phi_b*(one-x4(i)))
127 vx = (one-x4(i))**(psi_b*x4(i))
128 gx = exp(cr_b *x4(i)*x4(i))
129 IF (gx<zero) gx=one
130 f =(x4(i)-x4old(i))*dti - const * ux*vx /gx
131 udot = phi_b* ux * ( (one-x4(i))/max(em10,x4(i))-log(max(em10,x4(i))) )
132 vdot = psi_b* vx * (log(one-x4(i))-x4(i)/(one-x4(i)))
133 gdot = two * cr_b * x4(i) * gx
134 fdot = dti-const*((udot*vx+vdot*ux)*gx-ux*vx*gdot)/gx/gx
135 x4(i)= max(em20,x4(i)-f/fdot)
136 ENDDO
137 frac4(i)=x4(i)*(one-x2(i))
138 frac1(i)=one-frac2(i)-frac3(i)-frac4(i)-frac5(i)
139 ENDIF
140
141 ELSE
142 ! MARTENSITE FORMATION X5
143 IF (frac5(i)==zero)xgama(i)= frac1(i)
144 x5old(i) = x5(i)
145 term1 = alpha*(ms-tempel(i))**n_m
146 term2 = max(em20,x5(i)) ** phi_m
147 IF(psi_m >=zero) THEN
148 term3 = (one - x5(i)) ** psi_m
149 ELSE
150 term3 = (one - x5(i)) ** (psi_m*two -xgama(i) )
151 ENDIF
152 x5(i) = x5old(i) + (term1 * term2 *term3)*(tempo(i)-tempel(i))
153 frac5(i)=x5(i)*xgama(i)
154 frac1(i)=one-frac2(i)-frac3(i)-frac4(i)-frac5(i)
155 ENDIF
156
157
158 ENDIF
159 ENDIF
160 ENDDO
161
162 RETURN
#define my_real
Definition cppsort.cpp:32
#define alpha
Definition eval.h:35
#define max(a, b)
Definition macros.h:21