OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
hm_read_fail_fabric.F
Go to the documentation of this file.
1Copyright> OpenRadioss
2Copyright> Copyright (C) 1986-2025 Altair Engineering Inc.
3Copyright>
4Copyright> This program is free software: you can redistribute it and/or modify
5Copyright> it under the terms of the GNU Affero General Public License as published by
6Copyright> the Free Software Foundation, either version 3 of the License, or
7Copyright> (at your option) any later version.
8Copyright>
9Copyright> This program is distributed in the hope that it will be useful,
10Copyright> but WITHOUT ANY WARRANTY; without even the implied warranty of
11Copyright> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12Copyright> GNU Affero General Public License for more details.
13Copyright>
14Copyright> You should have received a copy of the GNU Affero General Public License
15Copyright> along with this program. If not, see <https://www.gnu.org/licenses/>.
16Copyright>
17Copyright>
18Copyright> Commercial Alternative: Altair Radioss Software
19Copyright>
20Copyright> As an alternative to this open-source version, Altair also offers Altair Radioss
21Copyright> software under a commercial license. Contact Altair to discuss further if the
22Copyright> commercial version may interest you: https://www.altair.com/radioss/.
23!||====================================================================
24!|| hm_read_fail_fabric ../starter/source/materials/fail/fabric/hm_read_fail_fabric.F
25!||--- called by ------------------------------------------------------
26!|| hm_read_fail ../starter/source/materials/fail/hm_read_fail.F
27!||--- calls -----------------------------------------------------
28!|| ancmsg ../starter/source/output/message/message.F
29!|| hm_get_floatv ../starter/source/devtools/hm_reader/hm_get_floatv.F
30!|| hm_get_intv ../starter/source/devtools/hm_reader/hm_get_intv.F
31!|| hm_option_is_encrypted ../starter/source/devtools/hm_reader/hm_option_is_encrypted.F
32!||--- uses -----------------------------------------------------
33!|| hm_option_read_mod ../starter/share/modules1/hm_option_read_mod.F
34!|| message_mod ../starter/share/message_module/message_mod.F
35!|| submodel_mod ../starter/share/modules1/submodel_mod.F
36!||====================================================================
37 SUBROUTINE hm_read_fail_fabric(FAIL ,
38 . MAT_ID ,FAIL_ID ,IRUPT ,UNIT_ID ,
39 . LSUBMODEL,UNITAB )
40C-----------------------------------------------
41C ROUTINE DESCRIPTION :
42C ===================
43C READ ANISOTROPIC FABRIC FAILURE MODEL
44C-----------------------------------------------
45C M o d u l e s
46C-----------------------------------------------
47 USE fail_param_mod
48 USE unitab_mod
49 USE message_mod
50 USE submodel_mod
52C-----------------------------------------------
53C I m p l i c i t T y p e s
54C-----------------------------------------------
55#include "implicit_f.inc"
56C-----------------------------------------------
57C C o m m o n B l o c k s
58C-----------------------------------------------
59#include "units_c.inc"
60C-----------------------------------------------
61C D u m m y A r g u m e n t s
62C-----------------------------------------------
63 INTEGER ,INTENT(IN) :: FAIL_ID ! failure model ID
64 INTEGER ,INTENT(IN) :: MAT_ID ! material law ID
65 INTEGER ,INTENT(IN) :: IRUPT ! failure model number
66 INTEGER ,INTENT(IN) :: UNIT_ID !
67 TYPE (UNIT_TYPE_) ,INTENT(IN) :: UNITAB ! table of input units
68 TYPE (SUBMODEL_DATA),INTENT(IN) :: LSUBMODEL(*) ! submodel table
69 TYPE (FAIL_PARAM_) ,INTENT(INOUT) :: FAIL ! failure model data structure
70C-----------------------------------------------
71C L o c a l V a r i a b l e s
72C-----------------------------------------------
73 INTEGER :: IRFUN,NDIR
74 my_real :: EPSF1,EPSR1,EPSF2,EPSR2,FAC_T
75 LOGICAL :: IS_AVAILABLE,IS_ENCRYPTED
76C=======================================================================
77 is_encrypted = .false.
78 is_available = .false.
79c
80 IF (unit_id > 0) THEN
81 fac_t = unitab%FAC_T(unit_id)
82 ELSE
83 fac_t = one
84 ENDIF
85C--------------------------------------------------
86C check crypting
87C--------------------------------------------------
88c
89 CALL hm_option_is_encrypted(is_encrypted)
90c
91C--------------------------------------------------
92C Read DATA
93C--------------------------------------------------
94 CALL hm_get_floatv ('Epsilon_f1' ,epsf1 ,is_available,lsubmodel,unitab)
95 CALL hm_get_floatv ('Epsilon_r1' ,epsr1 ,is_available,lsubmodel,unitab)
96 CALL hm_get_floatv ('Epsilon_f2' ,epsf2 ,is_available,lsubmodel,unitab)
97 CALL hm_get_floatv ('Epsilon_r2' ,epsr2 ,is_available,lsubmodel,unitab)
98 CALL hm_get_intv ('NDIR' ,ndir ,is_available,lsubmodel)
99c
100 CALL hm_get_intv ('fct_ID' ,irfun ,is_available,lsubmodel)
101c--------------------------------------------------
102c Default values
103c--------------------------------------------------
104 IF (epsf1 <= zero) epsf1 = ep20
105 IF (epsr1 <= zero) epsr1 = ep20*two
106 IF (epsf2 <= zero) epsf2 = ep20
107 IF (epsr2 <= zero) epsr2 = ep20*two
108 IF (ndir == 0) ndir = 2
109 ndir = min(ndir,2)
110 ndir = max(ndir,1)
111c
112 IF (epsf1 > epsr1 .or. epsf2 > epsr2) THEN
113 CALL ancmsg(msgid=617,
114 . msgtype=msgerror,
115 . anmode=aninfo_blind_1,
116 . i1=mat_id)
117 ENDIF
118c--------------------------------------------------
119 fail%KEYWORD = 'FABRIC'
120 fail%IRUPT = irupt
121 fail%FAIL_ID = fail_id
122 fail%NUPARAM = 6
123 fail%NIPARAM = 0
124 fail%NUVAR = 2
125 fail%NFUNC = 1
126 fail%NTABLE = 0
127 fail%NMOD = 0
128c
129 ALLOCATE (fail%UPARAM(fail%NUPARAM))
130 ALLOCATE (fail%IPARAM(fail%NIPARAM))
131 ALLOCATE (fail%IFUNC (fail%NFUNC))
132 ALLOCATE (fail%TABLE (fail%NTABLE))
133
134 fail%IFUNC(1) = irfun
135c
136 fail%UPARAM(1) = epsf1
137 fail%UPARAM(2) = epsr1
138 fail%UPARAM(3) = epsf2
139 fail%UPARAM(4) = epsr2
140 fail%UPARAM(5) = fac_t ! abscissa unit scaling factor (strain rate)
141 fail%UPARAM(6) = ndir
142c-----------------------------------------------------
143 IF (is_encrypted)THEN
144 WRITE(iout, 1000)
145 ELSE
146 WRITE(iout, 1100) epsf1,epsr1,epsf2,epsr2,ndir,irfun
147 ENDIF
148c-----------
149 RETURN
150c--------------------------------------------------
151 1000 FORMAT(
152 & 5x,' CRYPTED DATA IN FAILURE MODEL '/,
153 & 5x,' ----------------------------- '/)
154 1100 FORMAT(
155 & 5x,' ANISOTROPIC FABRIC FAILURE MODEL ',/
156 & 5x,' ------------------------ ',/
157 & 5x,'FAILURE TENSION STRAIN DIRECTION 1 . . =',e12.4/
158 & 5x,'RUPTURE TENSION STRAIN DIRECTION 1 . . =',e12.4/
159 & 5x,'FAILURE TENSION STRAIN DIRECTION 2 . . =',e12.4/
160 & 5x,'RUPTURE TENSION STRAIN DIRECTION 2 . . =',e12.4/
161 & 5x,'NUMBER OF BROKEN DIR. FOR EL. DELETION =',i10/
162 & 5x,'STRAIN RATE SCALING FUNCTION . . . . . =',i10)
163c--------------------------------------------------
164 END
subroutine hm_get_floatv(name, rval, is_available, lsubmodel, unitab)
subroutine hm_get_intv(name, ival, is_available, lsubmodel)
subroutine hm_option_is_encrypted(is_encrypted)
subroutine hm_read_fail_fabric(fail, mat_id, fail_id, irupt, unit_id, lsubmodel, unitab)
#define min(a, b)
Definition macros.h:20
#define max(a, b)
Definition macros.h:21
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)
Definition message.F:889