OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
fxgrvcor.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!|| fxgrvcor ../engine/source/constraints/fxbody/fxgrvcor.F
25!||--- called by ------------------------------------------------------
26!|| resol ../engine/source/engine/resol.F
27!||--- calls -----------------------------------------------------
28!|| finter ../engine/source/tools/curve/finter.F
29!||--- uses -----------------------------------------------------
30!|| finter_mixed_mod ../engine/source/tools/finter_mixed.F90
31!|| python_funct_mod ../common_source/modules/python_mod.F90
32!||====================================================================
33 SUBROUTINE fxgrvcor(FXBIPM, FXBGRVI , A , IGRV, AGRV,
34 . NPC , TF , MS , V , SKEW,
35 . FXBGRW, IAD_ELEM, FR_ELEM, WFEXT,python)
36 use python_funct_mod, only : python_
37 use finter_mixed_mod, only : finter_mixed
38C-----------------------------------------------
39C I m p l i c i t T y p e s
40C-----------------------------------------------
41#include "implicit_f.inc"
42C-----------------------------------------------
43C C o m m o n B l o c k s
44C-----------------------------------------------
45#include "com04_c.inc"
46#include "com06_c.inc"
47#include "com08_c.inc"
48#include "param_c.inc"
49#include "fxbcom.inc"
50#include "com01_c.inc"
51C-----------------------------------------------
52C D u m m y A r g u m e n t s
53C-----------------------------------------------
54 INTEGER FXBIPM(NBIPM,*), FXBGRVI(*), IGRV(NIGRV,*), NPC(*), IAD_ELEM(2,*), FR_ELEM(*)
55 my_real A(3,*), AGRV(LFACGRV,*), TF(*), MS(*), V(3,*), SKEW(LSKEW,*), FXBGRW(*)
56 DOUBLE PRECISION, INTENT(INOUT) :: WFEXT
57 TYPE(python_), intent(inout) :: python
58C-----------------------------------------------
59C L o c a l V a r i a b l e s
60C-----------------------------------------------
61 INTEGER NFX, NLG, AGRVI, IADG, IG, NL, NNO, ISK, N2, N1, IFUNC,
62 . I, K1, K2, K3, IAGRV(NUMNOD), J, JJ
63 my_real
64 . fi0, fi, dydx, wfextt, vv
65 my_real finter
66 EXTERNAL finter
67C
68 DO i=1,numnod
69 iagrv(i)=1
70 ENDDO
71 IF (nspmd>1) THEN
72 DO i=1,nspmd
73 DO j=iad_elem(1,i),iad_elem(1,i+1)-1
74 jj=fr_elem(j)
75 iagrv(jj)=iagrv(jj)+1
76 ENDDO
77 ENDDO
78 ENDIF
79C
80 wfextt=zero
81 DO nfx=1,nfxbody
82 nlg=fxbipm(25,nfx)
83 agrvi=fxbipm(26,nfx)
84 iadg=0
85 DO ig=1,nlg
86 nl=fxbgrvi(agrvi+iadg)
87 nno=fxbgrvi(agrvi+iadg+1)
88 isk=igrv(2,nl)/10
89 n2=igrv(2,nl)-10*isk
90 ifunc=igrv(3,nl)
91 IF (ifunc > 0) THEN
92 fi0=agrv(1,nl)*finter_mixed(python,nfunct,ifunc,(tt-dt1)*agrv(2,nl),npc,tf)
93 fi =agrv(1,nl)*finter_mixed(python,nfunct,ifunc,tt*agrv(2,nl),npc,tf)
94 ELSE
95 fi0= agrv(1,nl)
96 fi = agrv(1,nl)
97 ENDIF
98 IF (isk<=1) THEN
99 DO i=1,nno
100 n1=fxbgrvi(agrvi+iadg+i+1)
101 a(n2,n1)=a(n2,n1)-fi
102 wfextt=wfextt+half*(fi0+fi)*ms(n1)*v(n2,n1)*dt1
103 . /iagrv(n1)
104 ENDDO
105 ELSE
106 k1=3*n2-2
107 k2=3*n2-1
108 k3=3*n2
109 DO i=1,nno
110 n1=fxbgrvi(agrvi+iadg+i+1)
111 vv = skew(k1,isk)*v(1,n1)+skew(k2,isk)*v(2,n1)+
112 . skew(k3,isk)*v(3,n1)
113 a(1,n1)=a(1,n1)-skew(k1,isk)*fi
114 a(2,n1)=a(2,n1)-skew(k2,isk)*fi
115 a(3,n1)=a(3,n1)-skew(k3,isk)*fi
116 wfextt=wfextt+half*(fi0+fi)*ms(n1)*vv*dt1/iagrv(n1)
117 ENDDO
118 ENDIF
119 iadg=iadg+2+nno
120 ENDDO
121 wfext=wfext-wfextt+fxbgrw(nfx)
122 ENDDO
123C
124 RETURN
125 END
126
subroutine fxgrvcor(fxbipm, fxbgrvi, a, igrv, agrv, npc, tf, ms, v, skew, fxbgrw, iad_elem, fr_elem, wfext, python)
Definition fxgrvcor.F:36