OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
accele.F File Reference
#include "implicit_f.inc"
#include "com01_c.inc"
#include "com04_c.inc"
#include "inter22.inc"
#include "param_c.inc"

Go to the source code of this file.

Functions/Subroutines

subroutine accele (a, ar, v, ms, in, size_nale, nale, ms_2d, size_npby, npby)

Function/Subroutine Documentation

◆ accele()

subroutine accele ( intent(inout) a,
intent(inout) ar,
intent(inout) v,
intent(inout) ms,
intent(inout) in,
integer, intent(in) size_nale,
integer, dimension(size_nale), intent(in) nale,
intent(inout) ms_2d,
integer, intent(in) size_npby,
integer, dimension(nnpby,size_npby), intent(in) npby )
Parameters
[in]size_nalesize of NALE array
[in]size_npby2nd dimension of NPBY array
[in]nalearray of ALE node (1 if the node is related to ALE computation
[in]npbyrigid body array

Definition at line 28 of file accele.F.

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
#define my_real
Definition cppsort.cpp:32