77
78
79
84 USE matparam_def_mod
85 USE sensor_mod
86 USE law19_upd_mod , ONLY : law19_upd
87 USE law81_upd_mod , ONLY : law81_upd
88 USE law87_upd_mod , ONLY : law87_upd
89 USE law129_upd_mod , ONLY : law129_upd
90 USE law133_upd_mod , ONLY : law133_upd
91 USE law163_upd_mod , ONLY : law163_upd
92 USE law190_upd_mod , ONLY : law190_upd
93 USE visc_param_mod
95 USE eosfun_usr2sys_mod , ONLY : eosfun_usr2sys
96
97
98
99#include "implicit_f.inc"
100
101
102
103#include "units_c.inc"
104#include "param_c.inc"
105#include "scr17_c.inc"
106#include "scr19_c.inc"
107#include "com04_c.inc"
108#include "tabsiz_c.inc"
109
110
111
112 INTEGER NPC(SNPC), FUNC_ID(NFUNCT)
113 INTEGER, DIMENSION(NPROPMI,NUMMAT) ,INTENT(INOUT) :: IPM
114 my_real pm(npropm,nummat), pld(stf),bufmat(sbufmat)
115 TARGET ipm,bufmat
116 TYPE(MLAW_TAG_), TARGET, DIMENSION(NUMMAT) :: MLAW_TAG
117 TYPE(TTABLE), DIMENSION(NTABLE) ,INTENT(INOUT) :: TABLE
118 TYPE (NLOCAL_STR_) :: NLOC_DMG
119 TYPE (SENSORS_) ,INTENT(IN) :: SENSORS
120 TYPE(MATPARAM_STRUCT_) ,DIMENSION(NUMMAT), INTENT(INOUT) ,TARGET :: MAT_PARAM
121
122
123
124 INTEGER IMAT,ILAW,IRUP,MAT_ID,IADD,IFC,FLAG_HE,NFUNC,NFUNCL,NUMTABL,
125 . NPARAM,NUPARF,NFAIL,IR,FLAG_FIT,IFAILG,
126 . NPRONY,J,ITYPE_VISC,FORM
128 INTEGER, DIMENSION(NUMMAT) :: MULLINS,GURSON
129 INTEGER, DIMENSION(MAXTAB) :: TABLE_ID
130 INTEGER, DIMENSION(:), POINTER :: IFUNC,ITABLE
131 my_real,
DIMENSION(:),
POINTER :: uparam,uparf
132 TYPE(MLAW_TAG_), POINTER :: MTAG
133 CHARACTER(LEN=NCHARTITLE)::TITR, TITLE
134 TYPE(MATPARAM_STRUCT_) , POINTER :: MATPARAM
135 TYPE (VISC_PARAM_) , POINTER :: VISC
136 INTEGER :: NFUNC_EOS
137
138
139
140 mullins(1:nummat) = 0
141 gurson(1:nummat) = 0
142 DO imat=1,nummat
143 ilaw = mat_param(imat)%ILAW
144 nfail = mat_param(imat)%NFAIL
145 IF (nfail > 0) THEN
146 mtag => mlaw_tag(imat)
147 DO ir = 1,nfail
148 irup = mat_param(imat)%FAIL(ir)%IRUPT
149 IF (irup == 33 .AND. ilaw /=100 .AND. ilaw /=95 .AND. ilaw/=92) THEN
150 CALL ancmsg(msgid=1769, msgtype=msgerror, anmode=aninfo_blind_1,
151 . i1=imat,
152 . i2=ilaw)
153 ENDIF
154 IF (irup == 33 .AND. (ilaw ==100 .OR. ilaw ==95 .OR. ilaw==92)) THEN
155 mullins(imat) = ir
156 ELSEIF (irup == 35 .and. ilaw==104) THEN
157 IF (gurson(imat) == 0) THEN
158 gurson(imat) = ir
159 ELSE
160
161 CALL ancmsg(msgid=1650,msgtype=msgerror,
162 . anmode=aninfo_blind_1,i1=imat)
163 ENDIF
164 ELSE IF (irup == 14) THEN
165 mtag%G_DMG = 1
166 ELSE IF (irup == 28) THEN
167 mtag%G_DMG = 2
168
169 ELSE IF (irup == 10 .OR. irup == 11 .OR. irup == 13 .OR. irup == 30 .OR.
170 . irup == 41 .OR. irup == 42 .OR. irup == 44 .OR. irup == 45 .OR.
171 . irup == 46 .OR. irup == 47 .OR. irup == 50 .OR. irup == 51) THEN
172 mtag%L_DMGSCL = 1
173 mtag%G_DMGSCL = 1
174
175 ELSE IF (irup == 48) THEN
176 mtag%G_DMGSCL = 6
177 mtag%L_DMGSCL = 6
178 ENDIF
179 ENDDO
180 ENDIF
181 ENDDO
182
183
184
185 DO imat=1,nummat
186
187 mat_id = mat_param(imat)%MAT_ID
188 ilaw = mat_param(imat)%ILAW
189
190
191 nfunc_eos = mat_param(imat)%EOS%NFUNC
192 IF(nfunc_eos > 0)THEN
193 title = mat_param(imat)%EOS%title
194 CALL eosfun_usr2sys(title,mat_id,nfunc_eos,mat_param(imat)%EOS%FUNC,func_id, nfunct )
195 ENDIF
196
197
198 IF (ilaw < 29.and.ilaw/=19.or.ilaw==32.or.ilaw==43.or.ilaw==49.or.ilaw==52.or.
199 . ilaw==57.or.ilaw==59.or.ilaw==60.or.ilaw==65.or.ilaw==75.or.
200 . ilaw==78 ) cycle
201
202 CALL fretitl2(titr,ipm(npropmi-ltitr+1,imat),ltitr)
203
204 iadd =
max(1,ipm(7,imat))
205 nparam =
min(ipm(9,imat),sbufmat)
206 uparam => bufmat(iadd:iadd+nparam-1)
207
208 itype_visc = mat_param(imat)%IVISC
209 gama_inf = one
210 IF (itype_visc == 2) THEN
211 visc => mat_param(imat)%VISC
212 nprony = visc%IPARAM(1)
213 form = visc%IPARAM(2)
214 IF(form == 1) THEN
215 gama_inf = one
216 DO j=1,nprony
217 gama_inf = gama_inf - visc%UPARAM(j)
218 ENDDO
219 gama_inf =
max(em20, gama_inf)
220 ENDIF
221 ENDIF
222 gama_inf =
min(gama_inf, one)
223
224
225
226
227
228 nfunc = ipm(10 ,imat)
229 numtabl = ipm(226,imat)
230 ifunc => ipm(10+1:10+nfunc,imat)
231 itable => ipm(226+1:226+numtabl,imat)
232
233 IF (nfunc > 0) THEN
235 ENDIF
236
237 IF (ilaw /= 73 .and. ilaw /= 74 .and. ilaw /= 80) THEN
238 IF (numtabl > 0 ) THEN
239 table_id(1:numtabl) = ipm(226+1:226+numtabl,imat)
241 ENDIF
242 ENDIF
243
244
245 SELECT CASE (ilaw)
246
247 CASE (19)
248 CALL law19_upd(mat_param(imat),sensors)
249
250 CASE (36)
251 mtag => mlaw_tag(imat)
252 CALL law36_upd(iout ,titr ,mat_id ,nparam,uparam ,
253 . nfunc ,ifunc ,func_id,npc ,pld ,
254 . mtag ,nfunct )
255
256 CASE (42)
257 CALL law42_upd(mat_param(imat),iout,titr,mat_id,pm(1,imat),gama_inf)
258
259 CASE (58)
260 nfuncl = ipm(6,imat)
261 ifunc => ipm(10+1:10+nfunc+nfuncl,imat)
262 CALL law58_upd(mat_param(imat),titr,npc,pld,
263 . nfunc,nfuncl,ifunc,mat_id,func_id,
264 . pm(1,imat),sensors)
265
266 CASE (62)
267 CALL law62_upd(iout,titr,mat_id,nparam,uparam, pm(1,imat),gama_inf)
268
269 CASE (69)
270 CALL law69_upd(iout, titr , mat_id, uparam, nfunc,nfunct,
271 . ifunc, func_id , npc , pld ,
272 . pm(1,imat),ipm(1,imat),gama_inf)
273
274
275 CASE (70)
276
277 CALL law70_upd(mat_param(imat) ,titr ,mat_id ,nparam ,uparam ,
278 . nfunc ,ifunc ,npc ,pld ,iout ,
279 . nfunct ,func_id ,npropm ,pm(1,imat))
280
281 CASE (76)
282 CALL law76_upd(iout ,titr ,mat_id ,nparam ,mat_param(imat) ,
283 . uparam ,numtabl ,itable ,table ,nfunc ,
284 . ifunc ,npc ,pld )
285
286
287 CASE (77)
288 CALL law77_upd(titr ,mat_id ,nparam ,mat_param(imat) ,
289 . uparam ,nfunc ,ifunc ,npc ,pld )
290
291
292 CASE (81)
293 CALL law81_upd(mat_param(imat) ,nfunc ,ifunc ,npc ,snpc ,
294 . pld ,stf ,pm(1,imat),npropm,iout ,
295 . mat_id ,titr )
296
297
298 CASE (87)
299 flag_fit = mat_param(imat)%IPARAM(3)
300 IF (flag_fit == 1) THEN
301 CALL law87_upd(iout ,titr ,mat_id ,mat_param(imat) )
302 ENDIF
303
304 CASE (90)
305
307 . ipm(1,imat),func_id,npc,pld,pm(1,imat),
308 . nfunct)
309
310 CASE (92)
311
312
313 uparam(13) = mullins(imat)
314 ifc = ipm(11,imat)
315 IF (ifc > 0) THEN
316 CALL law92_upd(iout ,titr ,mat_id ,uparam ,nfunc ,nfunct,
317 . ifunc ,func_id ,npc ,pld ,pm(1,imat),ipm(1,imat))
318 ENDIF
319
320 CASE (95)
321 uparam(21) = mullins(imat)
322
323 CASE (100)
324
325 flag_he = uparam(2)
326 uparam(3) = mullins(imat)
327 IF (flag_he == 2 )THEN
328 ifc = ipm(11,imat)
329 IF( ifc /=0 ) THEN
331 . ifunc, func_id , npc , pld , pm(1,imat))
332 ENDIF
333 ELSEIF(flag_he == 13 )THEN
335 . ifunc, func_id , npc , pld , pm(1,imat))
336 ENDIF
337
338 CASE (104)
339
340 ir = gurson(imat)
341 IF (ir > 0) THEN
342 ifailg = 1
343 nuparf = mat_param(imat)%FAIL(ir)%NUPARAM
344 uparf => mat_param(imat)%FAIL(ir)%UPARAM(1:nuparf)
345
346 CALL law104_upd(ifailg ,nparam,nuparf,uparam,uparf ,
347 . nloc_dmg,imat ,mlaw_tag(imat),ipm ,
348 . mat_param(imat))
349 ENDIF
350
351 CASE (108)
353 . nfunc,ifunc,mat_id,func_id,
354 . pm(1,imat))
355
356 CASE (109)
357 IF (mat_param(imat)%NLOC > 0) THEN
358 mlaw_tag(imat)%NUVAR = 1
359 ENDIF
360
361 CASE (111)
362
363
364 ifc = ipm(11,imat)
365 IF (ifc > 0) THEN
366 CALL law111_upd(iout ,titr ,mat_id ,uparam ,nfunc ,
367 . ifunc ,func_id ,npc ,pld ,pm(1,imat),ipm(1,imat))
368 ENDIF
369
370 CASE (112)
372 . numtabl,itable,table,mat_id)
373
374 CASE (113)
376 . nfunc,ifunc,mat_id,func_id,
377 . pm(1,imat))
378
379
380 CASE (114)
382 . nfunc,ifunc,mat_id,func_id,
383 . pm(1,imat))
384
385 CASE (119)
386 CALL law119_upd(nparam ,numtabl ,itable ,table ,table_id,
387 . uparam,pm(1,imat),titr ,mat_id )
388
389 CASE (120)
390 CALL law120_upd(nparam ,numtabl ,itable ,table ,uparam)
391
392 CASE (129)
393 CALL law129_upd(mat_param(imat),sensors)
394
395 CASE (133)
396 CALL law133_upd(mat_param(imat),pm(1,imat),npropm)
397
398 CASE (158)
399 nfuncl = ipm(6,imat)
400 ifunc => ipm(10+1:10+nfunc+nfuncl,imat)
402 . nfunc,nfuncl,ifunc,mat_id,func_id,
403 . pm(1,imat),sensors)
404
405 CASE (163)
406 CALL law163_upd(mat_param(imat),pm(1,imat),npropm)
407
408 CASE (190)
409 CALL law190_upd(mat_param(imat) ,numtabl ,itable ,table ,pm(1,imat),
410 . npropm, ntable)
411
412
413 END SELECT
414 pm(107,imat) = two*
max(pm(32,imat),pm(100,imat))
415 IF (ilaw==62) pm(107,imat) = hundred*pm(107,imat)
416
417 ENDDO ! imat=1,nummat
418
419 RETURN
subroutine law100_upd_ab(iout, titr, mat_id, uparam, nfunc, ifunc, func_id, npc, pld, pm)
subroutine law100_upd_nht(iout, titr, mat_id, uparam, nfunc, ifunc, func_id, npc, pld, pm)
subroutine law104_upd(ifailg, nuparam, nuparf, uparam, uparf, nloc_dmg, imat, mlaw_tag, ipm, matparam)
subroutine law108_upd(iout, titr, uparam, npc, pld, nfunc, ifunc, mat_id, func_id, pm)
subroutine law111_upd(iout, titr, mat_id, uparam, nfunc, ifunc, func_id, npc, pld, pm, ipm)
subroutine law112_upd(titr, uparam, npc, pld, numtabl, itable, table, mat_id)
subroutine law113_upd(iout, titr, uparam, npc, pld, nfunc, ifunc, mat_id, func_id, pm)
subroutine law114_upd(iout, titr, uparam, npc, pld, nfunc, ifunc, mat_id, func_id, pm)
subroutine law119_upd(nuparam, numtabl, itable, table, table_id, uparam, pm, titr, mat_id)
subroutine law120_upd(nuparam, numtabl, itable, table, uparam)
subroutine law158_upd(mat_param, titr, npc, pld, nfunc, nfunl, ifunc, mat_id, func_id, pm, sensors)
subroutine law36_upd(iout, titr, mat_id, nuparam, uparam, nfunc, ifunc, func_id, npc, pld, mtag, nfunct)
subroutine law42_upd(mat_param, iout, titr, mat_id, pm, gama_inf)
subroutine law58_upd(mat_param, titr, npc, pld, nfunc, nfunl, ifunc, mat_id, func_id, pm, sensors)
subroutine law62_upd(iout, titr, mat_id, nuparam, uparam, pm, gama_inf)
subroutine law69_upd(iout, titr, mat_id, uparam, nfunc, nfunct, ifunc, func_id, npc, pld, pm, ipm, gama_inf)
subroutine law70_upd(mat_param, titr, mat_id, nuparam, uparam, nfunc, ifunc, npc, pld, iout, nfunct, func_id, npropm, pm)
subroutine law76_upd(iout, titr, mat_id, nuparam, matparam, uparam, numtabl, itable, table, nfunc, ifunc, npc, pld)
subroutine law77_upd(titr, mat_id, nuparam, mat_param, uparam, nfunc, ifunc, npc, pld)
subroutine law90_upd(iout, titr, mat_id, uparam, ipm, func_id, npc, pld, pm, nfunct)
subroutine law92_upd(iout, titr, mat_id, uparam, nfunc, nfunct, ifunc, func_id, npc, pld, pm, ipm)
subroutine matfun_usr2sys(titr, mat_id, nfunc, ifunc, func_id)
subroutine mattab_usr2sys(titr, mat_id, ntable, table, ntabl, itable)
integer, parameter nchartitle
subroutine ancmsg(msgid, msgtype, anmode, i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12, i13, i14, i15, i16, i17, i18, i19, i20, r1, r2, r3, r4, r5, r6, r7, r8, r9, c1, c2, c3, c4, c5, c6, c7, c8, c9, prmode)