OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
sgetdir3.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!|| sgetdir3 ../engine/source/elements/thickshell/solidec/sgetdir3.F
25!||--- called by ------------------------------------------------------
26!|| s6cforc3 ../engine/source/elements/thickshell/solide6c/s6cforc3.F
27!|| scforc3 ../engine/source/elements/thickshell/solidec/scforc3.F
28!||====================================================================
29 SUBROUTINE sgetdir3(NEL,RX, RY, RZ, TX, TY, TZ,
30 . E1X,E1Y,E1Z,E2X,E2Y,E2Z,DIR,DIRB,IREP)
31C-----------------------------------------------
32C I m p l i c i t T y p e s
33C-----------------------------------------------
34#include "implicit_f.inc"
35C-----------------------------------------------
36C G l o b a l P a r a m e t e r s
37C-----------------------------------------------
38#include "mvsiz_p.inc"
39C-----------------------------------------------
40C D u m m y A r g u m e n t s
41C-----------------------------------------------
42 INTEGER :: NEL,IREP
43C
45 . rx(*),ry(*),rz(*),tx(*),ty(*),tz(*),dir(nel,6),dirb(mvsiz,2),
46 . e1x(*),e1y(*),e1z(*),e2x(*),e2y(*),e2z(*)
47C-----------------------------------------------
48C L o c a l V a r i a b l e s
49C-----------------------------------------------
50 INTEGER I
51C
52 my_real
53 . v1,v2,v3,vr,vs,aa,bb,suma
54C-----------------------------------------------
55 IF (irep == 0) THEN
56 DO i=1,nel
57 dirb(i,1) = dir(i,1)
58 dirb(i,2) = dir(i,2)
59 ENDDO
60 ELSE
61 DO i=1,nel
62 aa = dir(i,1)
63 bb = dir(i,2)
64 v1 = aa*tx(i) + bb*rx(i)
65 v2 = aa*ty(i) + bb*ry(i)
66 v3 = aa*tz(i) + bb*rz(i)
67 vr=v1*e1x(i)+v2*e1y(i)+v3*e1z(i)
68 vs=v1*e2x(i)+v2*e2y(i)+v3*e2z(i)
69 suma=sqrt(vr*vr + vs*vs)
70 suma=one/max(em20,suma)
71 dirb(i,1) = vr*suma
72 dirb(i,2) = vs*suma
73 ENDDO
74 ENDIF
75C-----------
76 RETURN
77 END
#define my_real
Definition cppsort.cpp:32
#define max(a, b)
Definition macros.h:21
subroutine sgetdir3(nel, rx, ry, rz, tx, ty, tz, e1x, e1y, e1z, e2x, e2y, e2z, dir, dirb, irep)
Definition sgetdir3.F:31