OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
q4coor2.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!|| q4rcoor2 ../starter/source/elements/solid_2d/quad4/q4coor2.F
25!||--- called by ------------------------------------------------------
26!|| q4init2 ../starter/source/elements/solid_2d/quad4/q4init2.F
27!||====================================================================
28 SUBROUTINE q4rcoor2(X,IXQ,NGL ,MXT ,
29 . PID, IX1, IX2, IX3, IX4,
30 . Y1, Y2, Y3, Y4,
31 . Z1, Z2, Z3, Z4,YAVG,Y234,Y124,
32 . SY, SZ, TY, TZ, E1Y, E1Z , E2Y, E2Z)
33C-----------------------------------------------
34C I m p l i c i t T y p e s
35C-----------------------------------------------
36#include "implicit_f.inc"
37C-----------------------------------------------
38C G l o b a l P a r a m e t e r s
39C-----------------------------------------------
40#include "mvsiz_p.inc"
41C-----------------------------------------------
42C C o m m o n B l o c k s
43C-----------------------------------------------
44#include "vect01_c.inc"
45C-----------------------------------------------
46C D u m m y A r g u m e n t s
47C-----------------------------------------------
48 INTEGER IXQ(NIXQ,*), NGL(*), MXT(*), PID(*)
49 INTEGER IX1(*), IX2(*), IX3(*), IX4(*)
50 my_real
51 . X(3,*),E1Y(*),E1Z(*),E2Y(*),E2Z(*)
52 my_real
53 . y1(*), y2(*), y3(*), y4(*),
54 . z1(*), z2(*), z3(*), z4(*),yavg(*),y234(*),y124(*)
55C-----------------------------------------------
56C L o c a l V a r i a b l e s
57C-----------------------------------------------
58 INTEGER I
59 my_real
60 . SY(MVSIZ) ,SZ(MVSIZ) ,
61 . TY(MVSIZ) ,TZ(MVSIZ), SUMA,CT,CS
62C--------------------------------------------------
63C CONNECTIVITES ET MATERIEL
64C--------------------------------------------------
65 DO i=lft,llt
66 mxt(i)=ixq(1,i)
67 ix1(i)=ixq(2,i)
68 ix2(i)=ixq(3,i)
69 ix3(i)=ixq(4,i)
70 ix4(i)=ixq(5,i)
71 pid(i)=ixq(6,i)
72 ngl(i)=ixq(nixq,i)
73 END DO
74C
75C----------------------------
76C COORDONNEES NOEUDS |
77C----------------------------
78 DO i=lft,llt
79 y1(i)=x(2,ix1(i))
80 z1(i)=x(3,ix1(i))
81 y2(i)=x(2,ix2(i))
82 z2(i)=x(3,ix2(i))
83 y3(i)=x(2,ix3(i))
84 z3(i)=x(3,ix3(i))
85 y4(i)=x(2,ix4(i))
86 z4(i)=x(3,ix4(i))
87 END DO
88 DO i=lft,llt
89 yavg(i) = fourth*(y1(i)+y2(i)+y3(i)+y4(i))
90 y234(i)=y2(i)+y3(i)+y4(i)
91 y124(i)=y1(i)+y2(i)+y4(i)
92 END DO
93C---------------------------------------
94C REPERE LOCAL (ISOPARAMETRIQUE)
95C---------------------------------------
96 DO i=lft,llt
97 sy(i)=half*(y2(i)+y3(i)-y1(i)-y4(i))
98 sz(i)=half*(z2(i)+z3(i)-z1(i)-z4(i))
99 ty(i)=half*(y3(i)+y4(i)-y1(i)-y2(i))
100 tz(i)=half*(z3(i)+z4(i)-z1(i)-z2(i))
101 END DO
102C-----------
103C REPERE CONVECTE ORTHOGONALISE
104C full integ: Same than the shell
105C-----------
106 DO i=lft,llt
107 ct = ty(i)*ty(i)+tz(i)*tz(i)
108 cs = sy(i)*sy(i)+sz(i)*sz(i)
109 IF(cs /= zero) THEN
110 suma = sqrt(ct/max(em20,cs))
111 e1y(i) = sy(i)*suma + tz(i)
112 e1z(i) = sz(i)*suma - ty(i)
113 ELSEIF(ct /= zero)THEN
114 suma = sqrt(cs/max(em20,ct))
115 e1y(i) = sy(i) + tz(i)*suma
116 e1z(i) = sz(i) - ty(i)*suma
117 END IF
118 suma=sqrt(e1y(i)**2+e1z(i)**2)
119 suma=one/max(suma,em20)
120 e1y(i)=e1y(i)*suma
121 e1z(i)=e1z(i)*suma
122 e2y(i)=-e1z(i)
123 e2z(i)= e1y(i)
124 ENDDO
125c
126 RETURN
127 END
#define max(a, b)
Definition macros.h:21
subroutine q4rcoor2(x, ixq, ngl, mxt, pid, ix1, ix2, ix3, ix4, y1, y2, y3, y4, z1, z2, z3, z4, yavg, y234, y124, sy, sz, ty, tz, e1y, e1z, e2y, e2z)
Definition q4coor2.F:33