OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
s4alesfem.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!|| s4alesfem ../engine/source/elements/solid/solide4_sfem/s4alesfem.f
25!||--- called by ------------------------------------------------------
26!|| alemain ../engine/source/ale/alemain.F
27!||--- calls -----------------------------------------------------
28!|| foat_to_6_float ../engine/source/system/parit.F
29!|| initbuf ../engine/share/resol/initbuf.F
30!|| s4volnod3 ../engine/source/elements/solid/solide4_sfem/s4volnod3.F
31!|| spmd_exch_vol ../engine/source/mpi/nodes/spmd_exch_vol.F
32!||--- uses -----------------------------------------------------
33!|| elbufdef_mod ../common_source/modules/mat_elem/elbufdef_mod.F90
34!|| initbuf_mod ../engine/share/resol/initbuf.F
35!||====================================================================
36 SUBROUTINE s4alesfem(IPARG,IXS,X,ELBUF_TAB,SFEM_NODVAR, S_SFEM_NODVAR,PM,
37 . IAD_ELEM,FR_ELEM)
38C-----------------------------------------------
39C M o d u l e s
40C-----------------------------------------------
41 USE initbuf_mod
42 USE elbufdef_mod
43C-----------------------------------------------
44C I m p l i c i t T y p e s
45C-----------------------------------------------
46#include "implicit_f.inc"
47C-----------------------------------------------
48C G l o b a l P a r a m e t e r s
49C-----------------------------------------------
50#include "mvsiz_p.inc"
51#include "param_c.inc"
52C-----------------------------------------------
53C C o m m o n B l o c k s
54C-----------------------------------------------
55#include "com01_c.inc"
56#include "com04_c.inc"
57#include "vect01_c.inc"
58C-----------------------------------------------
59C D u m m y A r g u m e n t s
60C-----------------------------------------------
61 INTEGER,INTENT(IN) :: S_SFEM_NODVAR
62 INTEGER IXS(NIXS,*),IPARG(NPARG,*),IAD_ELEM(2,*),FR_ELEM(*)
63 my_real x(*),sfem_nodvar(s_sfem_nodvar),pm(npropm,*)
64 TYPE (ELBUF_STRUCT_), TARGET, DIMENSION(NGROUP) :: ELBUF_TAB
65C-----------------------------------------------
66C L o c a l V a r i a b l e s
67C-----------------------------------------------
68 INTEGER NG, I, J, I1, I2, I3, I4, K, LENR,NEL
69 INTEGER NC1(MVSIZ),NC2(MVSIZ),NC3(MVSIZ),NC4(MVSIZ)
70 INTEGER MAT(MVSIZ)
71 my_real mass(mvsiz)
72
73 DOUBLE PRECISION VARNOD6(6,2*NUMNOD), MASS6(6,MVSIZ)
74C
75 TYPE(g_bufel_) ,POINTER :: GBUF
76C
77 sfem_nodvar(1:2*numnod) = zero
78 varnod6(1:6,1:2*numnod) = zero
79 mass(1:mvsiz) = zero
80 mass6(1:6,1:mvsiz) = zero
81C----------------------------------------------------
82C COMPUTE NODAL VOLUME & MASS FOR ALL TETRAHEDRON
83C----------------------------------------------------
84C Boucle parallele dynamique SMP
85C
86 DO ng = 1,ngroup
87 IF(iparg(8, ng)==1) cycle
88 IF(iparg(28,ng)/=4) cycle
89 CALL initbuf(iparg ,ng ,
90 2 mtn ,llt ,nft ,iad ,ity ,
91 3 npt ,jale ,ismstr ,jeul ,jtur ,
92 4 jthe ,jlag ,jmult ,jhbe ,jivf ,
93 5 nvaux ,jpor ,jcvt ,jclose ,jplasol ,
94 6 irep ,iint ,igtyp ,israt ,isrot ,
95 7 icsen ,isorth ,isorthg ,ifailure,jsms )
96C
97 IF(jeul == 1) cycle
98 IF(jlag == 1) cycle
99 IF(isrot <= 2) cycle
100 lft=1
101 nel = llt
102C
103 DO i=lft,llt
104 j=i+nft
105 mat(i)=ixs(1,j)
106 nc1(i)=ixs(2,j)
107 nc2(i)=ixs(4,j)
108 nc3(i)=ixs(7,j)
109 nc4(i)=ixs(6,j)
110 ENDDO
111C
112 gbuf => elbuf_tab(ng)%GBUF
113 IF(isrot == 3) THEN
114 CALL s4volnod3(
115 1 varnod6, x, nc1, nc2,
116 2 nc3, nc4, gbuf%OFF, gbuf%SMSTR,
117 3 nel, ismstr)
118 DO i=lft,llt
119 mass(i)=gbuf%RHO(i)/pm(1,mat(i))
120 ENDDO
121 !Parith-On treatment
122 CALL foat_to_6_float(lft ,llt ,mass ,mass6 )
123 DO i=lft,llt
124 i1=nc1(i)+numnod
125 i2=nc2(i)+numnod
126 i3=nc3(i)+numnod
127 i4=nc4(i)+numnod
128 !Parith-On treatment
129 DO k=1,6
130 varnod6(k,i1) = varnod6(k,i1) + mass6(k,i)
131 varnod6(k,i2) = varnod6(k,i2) + mass6(k,i)
132 varnod6(k,i3) = varnod6(k,i3) + mass6(k,i)
133 varnod6(k,i4) = varnod6(k,i4) + mass6(k,i)
134 ENDDO
135 ENDDO
136 ENDIF !ISROT=3
137
138 ENDDO !DO=1,NG
139
140c EXCHANGE
141 IF(nspmd > 1)THEN
142 lenr = 2*(iad_elem(1,nspmd+1)-iad_elem(1,1))
143 CALL spmd_exch_vol(varnod6(1,1),varnod6(1,numnod+1),iad_elem,
144 . fr_elem, lenr )
145 ENDIF
146
147C Routine assembly PARITH/ON
148 DO i=1,numnod
149
150 j=i+numnod
151 DO k=1,6
152 !VOLNOD
153 sfem_nodvar(i) = sfem_nodvar(i) + varnod6(k,i)
154 !SFEM_NODVAR
155 sfem_nodvar(i+numnod) = sfem_nodvar(i+numnod) + varnod6(k,i+numnod)
156 ENDDO
157
158 !RHO0/RHO -> SFEM_NODVAR
159 IF(sfem_nodvar(j) /= 0)THEN
160 sfem_nodvar(i)=sfem_nodvar(i)/sfem_nodvar(j)
161 ENDIF
162 ENDDO
163C
164 RETURN
165 END
#define my_real
Definition cppsort.cpp:32
subroutine initbuf(iparg, ng, mtn, llt, nft, iad, ity, npt, jale, ismstr, jeul, jtur, jthe, jlag, jmult, jhbe, jivf, mid, jpor, jcvt, jclose, jpla, irep, iint, igtyp, israt, isrot, icsen, isorth, isorthg, ifailure, jsms)
Definition initbuf.F:261
subroutine foat_to_6_float(jft, jlt, f, f6)
Definition parit.F:225
subroutine s4alesfem(iparg, ixs, x, elbuf_tab, sfem_nodvar, s_sfem_nodvar, pm, iad_elem, fr_elem)
Definition s4alesfem.F:38
subroutine s4volnod3(volnod6, x, nc1, nc2, nc3, nc4, offg, xdp, nel, ismstr)
Definition s4volnod3.F:35
subroutine spmd_exch_vol(volnod6, varnod6, iad_elem, fr_elem, lenr)