OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
inelt.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!|| inelts ../starter/source/interfaces/inter3d1/inelt.F
25!||--- called by ------------------------------------------------------
26!|| i1chk3 ../starter/source/interfaces/inter3d1/i1chk3.f
27!|| i21els3 ../starter/source/interfaces/inter3d1/i21els3.F
28!|| i2_surfi ../starter/source/interfaces/inter3d1/i2_surfi.F90
29!|| i2chk3 ../starter/source/interfaces/inter3d1/i2chk3.F
30!|| i3sti3 ../starter/source/interfaces/inter3d1/i3sti3.F
31!|| i7sti3 ../starter/source/interfaces/inter3d1/i7sti3.F
32!|| i9sti3 ../starter/source/interfaces/int09/i9sti3.F
33!||--- calls -----------------------------------------------------
34!|| norma1 ../starter/source/interfaces/inter3d1/norma1.F
35!||====================================================================
36 SUBROUTINE inelts(X ,IRECT ,IXS ,NINT ,NEL ,
37 . I ,AREA ,NOINT ,IR ,SURF_ELTYP,
38 . SURF_ELEM)
39C-----------------------------------------------
40C I m p l i c i t T y p e s
41C-----------------------------------------------
42#include "implicit_f.inc"
43C-----------------------------------------------
44C C o m m o n B l o c k s
45C-----------------------------------------------
46C-----------------------------------------------
47C D u m m y A r g u m e n t s
48C-----------------------------------------------
49 INTEGER NINT, NEL, I, NOINT,IR,SURF_ELTYP(*),SURF_ELEM(*)
50C REAL
52 . area
53 INTEGER IRECT(4,*), IXS(NIXS,*)
54C REAL
56 . x(3,*)
57C-----------------------------------------------
58C L o c a l V a r i a b l e s
59C-----------------------------------------------
60 INTEGER IY(4), N, JJ, II, K, NN, KK, IC, IAD,
61 . NUSER, NUSERM
62C REAL
64 . n1, n2, n3, dds
65 my_real :: xx1(4), xx2(4),xx3(4),xs1,ys1,zs1,xc,yc,zc
66C-----------------------------------------------
67C E x t e r n a l F u n c t i o n s
68C-----------------------------------------------
69C
70 ic =0
71 nel=0
72 IF (i <= 0) RETURN
73 IF (surf_eltyp(i) /= 1) RETURN
74C
75 nel=surf_elem(i)
76C-----------------------------------------------
77C VERIFICATION DE L'ORIENTATION DES SEGMENTS
78C-----------------------------------------------
79 xs1=0.
80 ys1=0.
81 zs1=0.
82 DO 100 jj=1,4
83 nn=irect(jj,i)
84 iy(jj)=nn
85 xx1(jj)=x(1,nn)
86 xx2(jj)=x(2,nn)
87 xx3(jj)=x(3,nn)
88 xs1=xs1+.25*x(1,nn)
89 ys1=ys1+.25*x(2,nn)
90 100 zs1=zs1+.25*x(3,nn)
91C
92 CALL norma1(n1,n2,n3,area,xx1,xx2,xx3)
93 xc=0.
94 yc=0.
95 zc=0.
96 DO 110 k=1,8
97 kk=ixs(k+1,nel)
98 xc=xc+x(1,kk)
99 yc=yc+x(2,kk)
100 zc=zc+x(3,kk)
101 110 CONTINUE
102 xc=xc*one_over_8
103 yc=yc*one_over_8
104 zc=zc*one_over_8
105 IF(ir/=0) RETURN
106 IF(ic>=2)RETURN
107 dds=n1*(xc-xs1)+n2*(yc-ys1)+n3*(zc-zs1)
108 IF(dds<0) RETURN
109 IF(iy(3)==iy(4)) THEN
110 irect(1,i)=iy(2)
111 irect(2,i)=iy(1)
112 ELSE
113 DO 120 kk=1,4
114 120 irect(kk,i)=iy(4-kk+1)
115 ENDIF
116 RETURN
117C
118 END
119!||====================================================================
120!|| ineltc ../starter/source/interfaces/inter3d1/inelt.F
121!||--- called by ------------------------------------------------------
122!|| i1chk3 ../starter/source/interfaces/inter3d1/i1chk3.F
123!|| i20sti3 ../starter/source/interfaces/inter3d1/i20sti3.F
124!|| i21els3 ../starter/source/interfaces/inter3d1/i21els3.F
125!|| i24gapm ../starter/source/interfaces/inter3d1/i24sti3.F
126!|| i2_surfi ../starter/source/interfaces/inter3d1/i2_surfi.F90
127!|| i2chk3 ../starter/source/interfaces/inter3d1/i2chk3.F
128!|| i3sti3 ../starter/source/interfaces/inter3d1/i3sti3.F
129!|| i7sti3 ../starter/source/interfaces/inter3d1/i7sti3.F
130!||====================================================================
131 SUBROUTINE ineltc(NELC ,NELTG ,IS ,SURF_ELTYP, SURF_ELEM)
132C-----------------------------------------------
133C I m p l i c i t T y p e s
134C-----------------------------------------------
135#include "implicit_f.inc"
136C-----------------------------------------------
137C D u m m y A r g u m e n t s
138C-----------------------------------------------
139 INTEGER NELC, IS, NELTG,SURF_ELTYP(*),SURF_ELEM(*)
140C-----------------------------------------------
141C L o c a l V a r i a b l e s
142C-----------------------------------------------
143 INTEGER ELTYP
144C-----------------------------------------------
145 nelc=0
146 neltg=0
147
148 IF (is <= 0) RETURN
149 eltyp = surf_eltyp(is)
150 IF (eltyp == 3) THEN
151 nelc = surf_elem(is)
152 ELSEIF (eltyp == 7) THEN
153 neltg = surf_elem(is)
154 ENDIF
155!---
156 RETURN
157 END
158!||====================================================================
159!|| i20nelts ../starter/source/interfaces/inter3d1/inelt.F
160!||--- called by ------------------------------------------------------
161!|| i20sti3 ../starter/source/interfaces/inter3d1/i20sti3.F
162!||--- calls -----------------------------------------------------
163!|| norma1 ../starter/source/interfaces/inter3d1/norma1.f
164!||====================================================================
165 SUBROUTINE i20nelts(X ,IRECT ,IXS ,NINT ,NEL ,
166 . I ,AREA ,NOINT ,IR ,SURF_ELTYP,
167 . SURF_ELEM)
168C-----------------------------------------------
169C I m p l i c i t T y p e s
170C-----------------------------------------------
171#include "implicit_f.inc"
172C-----------------------------------------------
173C C o m m o n B l o c k s
174C-----------------------------------------------
175C-----------------------------------------------
176C D u m m y A r g u m e n t s
177C-----------------------------------------------
178 INTEGER NINT, NEL, I, NOINT,IR,SURF_ELTYP(*),SURF_ELEM(*)
179C REAL
180 my_real
181 . AREA
182 INTEGER IRECT(4), IXS(NIXS,*)
183C REAL
184 my_real
185 . x(3,*)
186C-----------------------------------------------
187C L o c a l V a r i a b l e s
188C-----------------------------------------------
189 INTEGER IY(4), N, JJ, II, K, NN, KK, IC, IAD,
190 . NUSER, NUSERM
191C REAL
192 my_real
193 . n1, n2, n3, dds
194 my_real xx1(4), xx2(4),xx3(4),xs1,ys1,zs1,xc,yc,zc
195C-----------------------------------------------
196C E x t e r n a l F u n c t i o n s
197C-----------------------------------------------
198C
199 ic =0
200 nel=0
201
202 IF (i <= 0) RETURN
203 IF (surf_eltyp(i) /= 1) RETURN
204C
205 nel=surf_elem(i)
206C-----------------------------------------------
207C VERIFICATION DE L'ORIENTATION DES SEGMENTS
208C-----------------------------------------------
209 xs1=0.
210 ys1=0.
211 zs1=0.
212 DO 100 jj=1,4
213 nn=irect(jj)
214 iy(jj)=nn
215 xx1(jj)=x(1,nn)
216 xx2(jj)=x(2,nn)
217 xx3(jj)=x(3,nn)
218 xs1=xs1+.25*x(1,nn)
219 ys1=ys1+.25*x(2,nn)
220 100 zs1=zs1+.25*x(3,nn)
221C
222 CALL norma1(n1,n2,n3,area,xx1,xx2,xx3)
223 xc=0.
224 yc=0.
225 zc=0.
226 DO 110 k=1,8
227 kk=ixs(k+1,nel)
228 xc=xc+x(1,kk)
229 yc=yc+x(2,kk)
230 zc=zc+x(3,kk)
231 110 CONTINUE
232 xc=xc*one_over_8
233 yc=yc*one_over_8
234 zc=zc*one_over_8
235 IF(ir/=0) RETURN
236 IF(ic>=2)RETURN
237 dds=n1*(xc-xs1)+n2*(yc-ys1)+n3*(zc-zs1)
238 IF(dds<0) RETURN
239 IF(iy(3)==iy(4)) THEN
240 irect(1)=iy(2)
241 irect(2)=iy(1)
242 ELSE
243 DO 120 kk=1,4
244 120 irect(kk)=iy(4-kk+1)
245 ENDIF
246 RETURN
247C
248 END
249!||====================================================================
250!|| ineltigeo ../starter/source/interfaces/inter3d1/inelt.f
251!||--- called by ------------------------------------------------------
252!|| i7sti3 ../starter/source/interfaces/inter3d1/i7sti3.F
253!||--- calls -----------------------------------------------------
254!|| norma1 ../starter/source/interfaces/inter3d1/norma1.F
255!||====================================================================
256 SUBROUTINE ineltigeo(XE ,IRECT ,IXS ,NINT ,NELIG3D ,
257 . I ,AREA ,NOINT ,IR ,SURF_ELTYP_IGE,
258 . IXIG3D ,KXIG3D ,IGEO ,SURF_ELEM_IGE)
259C-----------------------------------------------
260C I m p l i c i t T y p e s
261C-----------------------------------------------
262#include "implicit_f.inc"
263C-----------------------------------------------
264C C o m m o n B l o c k s
265C-----------------------------------------------
266#include "param_c.inc"
267C-----------------------------------------------
268C D u m m y A r g u m e n t s
269C-----------------------------------------------
270 INTEGER NINT, NELIG3D, I, NOINT,IR
271C REAL
272 my_real
273 . AREA
274 INTEGER IRECT(4,*), IXS(NIXS,*),SURF_ELTYP_IGE(*),
275 . SURF_ELEM_IGE(*),KXIG3D(NIXIG3D,*),IGEO(NPROPGI,*),
276 . ixig3d(*)
277C REAL
278 my_real
279 . xe(3,*)
280C-----------------------------------------------
281C L o c a l V a r i a b l e s
282C-----------------------------------------------
283 INTEGER IY(4), N, JJ, II, K, NN, KK, IC, IAD,
284 . nuser, nuserm, coin_ige(8), px, py, pz, ipid
285C REAL
286 my_real
287 . n1, n2, n3, dds
288 my_real :: xx1(4), xx2(4),xx3(4),xc,yc,zc,xs1,ys1,zs1
289C-----------------------------------------------
290C E x t e r n a l F u n c t i o n s
291C-----------------------------------------------
292C
293 ic =0
294 nelig3d=0
295 IF (surf_eltyp_ige(i) /= 101) RETURN
296C
297 nelig3d=surf_elem_ige(i)
298
299C-----------------------------------------------
300C VERIFICATION DE L'ORIENTATION DES SEGMENTS
301C-----------------------------------------------
302 xs1=0.
303 ys1=0.
304 zs1=0.
305 DO jj=1,4
306 nn=irect(jj,i)
307 iy(jj)=nn
308 xx1(jj)=xe(1,nn)
309 xx2(jj)=xe(2,nn)
310 xx3(jj)=xe(3,nn)
311 xs1=xs1+.25*xe(1,nn)
312 ys1=ys1+.25*xe(2,nn)
313 zs1=zs1+.25*xe(3,nn)
314 ENDDO
315C
316 CALL norma1(n1,n2,n3,area,xx1,xx2,xx3)
317 xc=0.
318 yc=0.
319 zc=0.
320
321 ipid = kxig3d(2,nelig3d)
322 px = igeo(41,ipid)-1
323 py = igeo(42,ipid)-1
324 pz = igeo(43,ipid)-1
325 coin_ige(1) = (px+1)*py+1
326 coin_ige(2) = (px+1)*(py+1)
327 coin_ige(3) = px+1
328 coin_ige(4) = 1
329 coin_ige(5) = (px+1)*(py+1)*pz+(px+1)*py+1
330 coin_ige(6) = (px+1)*(py+1)*(pz+1)
331 coin_ige(7) = (px+1)*(py+1)*pz+px+1
332 coin_ige(8) = (px+1)*(py+1)*pz+1
333
334 DO k=1,8
335 xc=xc+xe(1,ixig3d(kxig3d(4,nelig3d)+coin_ige(k)-1))
336 yc=yc+xe(2,ixig3d(kxig3d(4,nelig3d)+coin_ige(k)-1))
337 zc=zc+xe(3,ixig3d(kxig3d(4,nelig3d)+coin_ige(k)-1))
338 ENDDO
339 xc=xc*one_over_8
340 yc=yc*one_over_8
341 zc=zc*one_over_8
342 IF(ir/=0) RETURN
343 IF(ic>=2)RETURN
344 dds=n1*(xc-xs1)+n2*(yc-ys1)+n3*(zc-zs1)
345 IF(dds<0) RETURN
346 DO kk=1,4
347 irect(kk,i)=iy(4-kk+1)
348 ENDDO
349 RETURN
350C
351 END
352
#define my_real
Definition cppsort.cpp:32
subroutine area(d1, x, x2, y, y2, eint, stif0)
subroutine i1chk3(x, irect, ixs, nrt, ixc, nint, nsn, nsv, noint, ixtg, geo, pm, knod2els, knod2elc, knod2eltg, nod2els, nod2elc, nod2eltg, igrsurf, thk, nty, ixs10, ixs16, ixs20, id, titr, igeo, pm_stack, iworksh)
Definition i1chk3.F:44
subroutine i20nelts(x, irect, ixs, nint, nel, i, area, noint, ir, surf_eltyp, surf_elem)
Definition inelt.F:168
subroutine inelts(x, irect, ixs, nint, nel, i, area, noint, ir, surf_eltyp, surf_elem)
Definition inelt.F:39
subroutine ineltigeo(xe, irect, ixs, nint, nelig3d, i, area, noint, ir, surf_eltyp_ige, ixig3d, kxig3d, igeo, surf_elem_ige)
Definition inelt.F:259
subroutine ineltc(nelc, neltg, is, surf_eltyp, surf_elem)
Definition inelt.F:132
subroutine norma1(n1, n2, n3, area, xx1, xx2, xx3)
Definition norma1.F:38
program starter
Definition starter.F:39