OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
accele.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!|| accele ../engine/source/assembly/accele.F
25!||--- called by ------------------------------------------------------
26!|| resol ../engine/source/engine/resol.F
27!||====================================================================
28 SUBROUTINE accele(
29 1 A ,AR ,V ,MS ,IN ,
30 2 SIZE_NALE ,NALE ,MS_2D ,
31 3 SIZE_NPBY, NPBY )
32C-----------------------------------------------------------------------
33C I m p l i c i t T y p e s
34C-----------------------------------------------
35#include "implicit_f.inc"
36C-----------------------------------------------
37C C o m m o n B l o c k s
38C-----------------------------------------------
39#include "com01_c.inc"
40#include "com04_c.inc"
41#include "inter22.inc"
42#include "param_c.inc"
43C-----------------------------------------------
44C D u m m y A r g u m e n t s
45C-----------------------------------------------
46 INTEGER, INTENT(IN) :: SIZE_NALE !< size of NALE array
47 INTEGER, INTENT(IN) :: SIZE_NPBY !< 2nd dimension of NPBY array
48 INTEGER, DIMENSION(SIZE_NALE), INTENT(IN) :: NALE !< array of ALE node (1 if the node is related to ALE computation
49 INTEGER, DIMENSION(NNPBY,SIZE_NPBY), INTENT(IN) :: NPBY !< rigid body array
50 my_real, DIMENSION(3,NUMNOD), INTENT(INOUT) :: a,v,ar !< acceleration, velocity and angular acceleration
51 my_real, DIMENSION(NUMNOD), INTENT(INOUT) :: ms,in,ms_2d !< mass and inertia
52C-----------------------------------------------
53C L o c a l V a r i a b l e s
54C-----------------------------------------------
55 INTEGER :: N,I,MSR
56 my_real :: RTMP
57C-----------------------------------------------
58C S o u r c e L i n e s
59C-----------------------------------------------
60
61 !------------------------------------------------!
62 ! acceleration computation
63 !------------------------------------------------!
64 IF(n2d == 0) THEN
65!$OMP DO SCHEDULE(guided)
66 DO n=1,numnod
67 IF(ms(n)>zero) THEN
68 rtmp = one / ms(n)
69 a(1,n) = a(1,n) * rtmp
70 a(2,n) = a(2,n) * rtmp
71 a(3,n) = a(3,n) * rtmp
72 ELSE
73 a(1,n) = zero
74 a(2,n) = zero
75 a(3,n) = zero
76 IF(nmult/=0) THEN
77 v(1,n) = zero
78 v(2,n) = zero
79 v(3,n) = zero
80 ENDIF
81 ENDIF
82 ENDDO
83!$OMP END DO
84 ELSE
85 DO i=1,nrbody
86 msr = npby(1,i)
87 IF(msr>0) THEN
88 ms(msr) = ms_2d(msr)
89 ENDIF
90 ENDDO
91!$OMP DO SCHEDULE(guided)
92 DO n=1,numnod
93 IF(ms(n)>zero) THEN
94 rtmp = one / ms(n)
95 a(1,n) = a(1,n) * rtmp
96 a(2,n) = a(2,n) * rtmp
97 a(3,n) = a(3,n) * rtmp
98 ELSE
99 a(1,n) = zero
100 a(2,n) = zero
101 a(3,n) = zero
102 IF(nmult/=0) THEN
103 v(1,n) = zero
104 v(2,n) = zero
105 v(3,n) = zero
106 ENDIF
107 ENDIF
108 ENDDO
109!$OMP END DO
110 ENDIF
111
112 !------------------------------------------------!
113 ! angular acceleration computation
114 !------------------------------------------------!
115 IF (iroddl/=0) THEN
116!$OMP DO SCHEDULE(guided)
117 DO n=1,numnod
118 IF(in(n)>zero) THEN
119 rtmp = one / in(n)
120 ar(1,n) = ar(1,n) * rtmp
121 ar(2,n) = ar(2,n) * rtmp
122 ar(3,n) = ar(3,n) * rtmp
123 ELSE
124 ar(1,n) = zero
125 ar(2,n) = zero
126 ar(3,n) = zero
127 ENDIF
128 ENDDO
129!$OMP END DO
130 ENDIF
131
132 !------------------------------------------------!
133 ! FVM DOES NOT NEED ACCEL AND VEL !
134 !------------------------------------------------!
135 IF(int22>0)THEN
136!$OMP DO SCHEDULE(guided)
137 DO n=1,numnod
138 IF(nale(n)/=0)THEN
139 a( 1:3,n) = zero
140 ar(1:3,n) = zero
141 ms(n) = zero
142 ENDIF
143 ENDDO
144!$OMP END DO
145 ENDIF
146 !------------------------------------------------!
147
148 RETURN
149 END SUBROUTINE accele
subroutine accele(a, ar, v, ms, in, size_nale, nale, ms_2d, size_npby, npby)
Definition accele.F:32
#define my_real
Definition cppsort.cpp:32