OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
fail_energy_s.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/.
23C new (energy failure model)
24!||====================================================================
25!|| fail_energy_s ../engine/source/materials/fail/energy/fail_energy_s.F
26!||--- called by ------------------------------------------------------
27!|| mmain ../engine/source/materials/mat_share/mmain.F90
28!|| mulaw ../engine/source/materials/mat_share/mulaw.F90
29!|| mulaw8 ../engine/source/materials/mat_share/mulaw8.F90
30!|| usermat_solid ../engine/source/materials/mat_share/usermat_solid.F
31!||--- calls -----------------------------------------------------
32!|| finter ../engine/source/tools/curve/finter.f
33!||====================================================================
34 SUBROUTINE fail_energy_s(
35 1 NEL ,NUPARAM ,NUVAR ,NFUNC ,IFUNC ,NPF ,
36 2 TF ,TIME ,TIMESTEP ,UPARAM ,NGL ,EPSP ,
37 3 UVAR ,OFF ,DFMAX ,TDELE ,DMGSCL ,
38 4 SIGNXX ,SIGNYY ,SIGNZZ ,SIGNXY ,SIGNYZ ,SIGNZX ,
39 5 DEPSXX ,DEPSYY ,DEPSZZ ,DEPSXY ,DEPSYZ ,DEPSZX )
40C-----------------------------------------------
41C I m p l i c i t T y p e s
42C-----------------------------------------------
43#include "implicit_f.inc"
44C---------+---------+---+---+--------------------------------------------
45C VAR | SIZE |TYP| RW| DEFINITION
46C---------+---------+---+---+--------------------------------------------
47C NEL | 1 | I | R | SIZE OF THE ELEMENT GROUP NEL
48C NUPARAM | 1 | I | R | SIZE OF THE USER PARAMETER ARRAY
49C NUVAR | 1 | I | R | NUMBER OF FAILURE ELEMENT VARIABLES
50C---------+---------+---+---+--------------------------------------------
51C MFUNC | 1 | I | R | NUMBER FUNCTION USED FOR THIS USER LAW not used
52C KFUNC | NFUNC | I | R | FUNCTION INDEX not used
53C NPF | * | I | R | FUNCTION ARRAY
54C TF | * | F | R | FUNCTION ARRAY
55C---------+---------+---+---+--------------------------------------------
56C TIME | 1 | F | R | CURRENT TIME
57C TIMESTEP| 1 | F | R | CURRENT TIME STEP
58C UPARAM | NUPARAM | F | R | USER FAILURE PARAMETER ARRAY
59C---------+---------+---+---+--------------------------------------------
60C SIGNXX | NEL | F | W | NEW ELASTO PLASTIC STRESS XX
61C SIGNYY | NEL | F | W | NEW ELASTO PLASTIC STRESS YY
62C ... | | | |
63C ... | | | |
64C---------+---------+---+---+--------------------------------------------
65C UVAR |NEL*NUVAR| F |R/W| USER ELEMENT VARIABLE ARRAY
66C OFF | NEL | F |R/W| DELETED ELEMENT FLAG (=1. ON, =0. OFF)
67C---------+---------+---+---+--------------------------------------------
68#include "mvsiz_p.inc"
69#include "scr17_c.inc"
70#include "units_c.inc"
71#include "comlock.inc"
72#include "param_c.inc"
73#include "impl1_c.inc"
74C-----------------------------------------------
75C I N P U T A r g u m e n t s
76C-----------------------------------------------
77 INTEGER, INTENT(IN) :: NEL,NUPARAM,NUVAR
78 INTEGER, DIMENSION(NEL), INTENT(IN) :: NGL
79 my_real, INTENT(IN) :: TIME,TIMESTEP
80 my_real, DIMENSION(NUPARAM), INTENT(IN) :: UPARAM
81 my_real, DIMENSION(NEL), INTENT(IN) :: SIGNXX,SIGNYY,SIGNZZ,
82 . signxy,signyz,signzx,depsxx,depsyy,depszz,depsxy,depsyz,
83 . depszx,epsp
84C-----------------------------------------------
85C I N P U T O U T P U T A r g u m e n t s
86C-----------------------------------------------
87 my_real, DIMENSION(NEL), INTENT(INOUT) :: off,dfmax,dmgscl,tdele
88 my_real, DIMENSION(NEL,NUVAR), INTENT(INOUT) :: uvar
89C-----------------------------------------------
90C VARIABLES FOR FUNCTION INTERPOLATION
91C-----------------------------------------------
92 INTEGER NPF(*), NFUNC, IFUNC(NFUNC)
93 my_real finter ,tf(*)
94 EXTERNAL finter
95C Y = FINTER(IFUNC(J),X,NPF,TF,DYDX)
96C Y : y = f(x)
97C X : x
98C DYDX : f'(x) = dy/dx
99C IFUNC(J): FUNCTION INDEX
100C J : FIRST(J=1), SECOND(J=2) .. FUNCTION USED FOR THIS LAW
101C NPF,TF : FUNCTION PARAMETER
102C-----------------------------------------------
103C L o c a l V a r i a b l e s
104C-----------------------------------------------
105 INTEGER I,J,IDEL,IDEV,IFLAG(MVSIZ),INDX(MVSIZ),IADBUF,NINDX,
106 . NINDEX,INDEX(MVSIZ),IR,IFAIL,JJ,
107 . ISOLID
108 my_real
109 . E1,E2,E3,E4,E5,E6,RFAC,E42,E52,E62,C,D, EPST,EPST2,
110 . r1,r2,y,yp,dav,dydx,ie_sp,p,scale,cc
111 my_real
112 . eps_max(mvsiz),damage(mvsiz),epsf1(mvsiz),epsf2(mvsiz),
113 . rief1,rief2,xfac
114C--------------------------------------------------------------
115 rief1 = uparam(1)
116 rief2 = uparam(2)
117 xfac = uparam(4)
118 !ISOLID = INT(UPARAM(4))
119 DO i=1,nel
120 damage(i) = zero
121 uvar(i,1) = uvar(i,1) + signxx(i)*depsxx(i) +
122 . signyy(i)*depsyy(i) +
123 . signzz(i)*depszz(i) +
124 . signxy(i)*depsxy(i) +
125 . signyz(i)*depsyz(i) +
126 . signzx(i)*depszx(i)
127 ENDDO
128C-----------------------------------------------
129 DO i=1,nel
130 IF(off(i)<em01) off(i)=zero
131 IF(off(i)<one) off(i)=off(i)*four_over_5
132 END DO
133CC
134 nindx=0
135 DO i=1,nel
136 rfac = one
137 IF(ifunc(1)/=0)THEN
138 rfac=finter(ifunc(1),epsp(i)*xfac,npf,tf,dydx)
139 rfac = max(rfac,em20)
140 ENDIF
141 IF(off(i)==one)THEN
142 ie_sp = uvar(i,1)
143 r1 = rief1*rfac
144 r2 = rief2*rfac
145 IF(ie_sp>r1.AND.r1<r2) THEN
146 damage(i)= (ie_sp-r1)/(r2-r1)
147 damage(i)= min(one,damage(i))
148 ENDIF
149 dfmax(i) = max(dfmax(i),damage(i))
150 IF(ie_sp>r2) THEN
151 damage(i)= one
152 off(i)=four_over_5
153 nindx=nindx+1
154 indx(nindx)=i
155 tdele(i) = time
156 ENDIF
157 ENDIF
158 ENDDO
159c
160 IF(nindx>0.AND.imconv==1)THEN
161 DO j=1,nindx
162#include "lockon.inc"
163 WRITE(iout, 1000) ngl(indx(j))
164 WRITE(istdo,1100) ngl(indx(j)),time
165#include "lockoff.inc"
166 END DO
167 END IF
168 DO i=1,nel
169 dmgscl(i) = one - dfmax(i)
170 ENDDO
171C-----------------------------------------------
172 1000 FORMAT(1x,'DELETE SOLID ELEMENT NUMBER ',i10)
173 1100 FORMAT(1x,'DELETE SOLID ELEMENT NUMBER ',i10,
174 . ' AT TIME :',1pe20.13)
175CC
176 RETURN
177 END
subroutine fail_energy_s(nel, nuparam, nuvar, nfunc, ifunc, npf, tf, time, timestep, uparam, ngl, epsp, uvar, off, dfmax, tdele, dmgscl, signxx, signyy, signzz, signxy, signyz, signzx, depsxx, depsyy, depszz, depsxy, depsyz, depszx)
#define min(a, b)
Definition macros.h:20
#define max(a, b)
Definition macros.h:21