OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
thpinit.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!|| thpinit ../starter/source/output/th/thpinit.F
25!||--- called by ------------------------------------------------------
26!|| lectur ../starter/source/starter/lectur.F
27!||--- calls -----------------------------------------------------
28!|| nlocal ../starter/source/spmd/node/ddtools.F
29!||====================================================================
30 SUBROUTINE thpinit(
31 1 ITHGRP,ITHBUF,IPARG ,DD_IAD,IXRI,
32 2 IFLAG ,NTHGRP2)
33C----------------------------------------------
34C INITIALISATION DU BUFFER TH (PROC SPMD)
35C----------------------------------------------
36C-----------------------------------------------
37C M o d u l e s
38C-----------------------------------------------
39C-----------------------------------------------
40C I m p l i c i t T y p e s
41C-----------------------------------------------
42#include "implicit_f.inc"
43C-----------------------------------------------
44C C o m m o n B l o c k s
45C-----------------------------------------------
46#include "com01_c.inc"
47#include "param_c.inc"
48C-----------------------------------------------
49C D u m m y A r g u m e n t s
50C-----------------------------------------------
51 INTEGER :: ITHGRP(NITHGR,*),ITHBUF(*),IPARG(NPARG,*),DD_IAD(NSPMD+1,*), IXRI(4,*),IFLAG, NTHGRP2
52C-----------------------------------------------
53C F u n c t i o n
54C-----------------------------------------------
55 INTEGER NLOCAL
56 EXTERNAL NLOCAL
57C-----------------------------------------------
58C L o c a l V a r i a b l e s
59C-----------------------------------------------
60 INTEGER :: P,NT,NG,I,K,NNE,IAD,ITYP,IH,NFT,ITY,NEL,N1,N2
61C-----------------------------------------------
62 IF(iflag==0) THEN
63C
64C Initialisation de nft0 = nft
65C
66 DO ng = 1, ngroup
67 iparg(31,ng) = iparg(3,ng)
68 ENDDO
69 ENDIF
70C
71C Mise a jour de PROC dans ITHBUF en fonction de la domdec
72C
73 IF (nspmd>1) THEN
74C traitement de p1 a pmaxporc-1 (p0 par defaut)
75 DO nt = 1, nthgrp2
76 ityp=ithgrp(2,nt)
77 nne =ithgrp(4,nt)
78 iad =ithgrp(5,nt)
79 IF((ityp >= 1 .AND. ityp <= 7) .OR. ityp == 50 .OR. ityp == 51 .OR. ityp == 100)THEN
80 DO ih = 1, nne
81 k = ithbuf(iad-1+ih)
82 DO ng = 1, ngroup
83 ity = iparg(5,ng)
84 IF(ity==ityp) THEN
85 nel = iparg(2,ng)
86 nft = iparg(3,ng)
87 p = iparg(32,ng)
88 IF (k>nft.AND.k<=nft+nel) THEN
89 ithbuf(iad+nne-1+ih) = p
90 ENDIF
91 ENDIF
92 ENDDO
93 ENDDO
94 ELSEIF (ityp==0) THEN
95c DO IH = 1, NNE
96c K = ITHBUF(IAD-1+IH)
97c DO P = 1, NSPMD
98c IF(MOD(FRONT(K,P),10)==1) THEN
99c ITHBUF(IAD+NNE-1+IH) = P-1
100c GOTO 209
101c ENDIF
102c ENDDO
103c 209 CONTINUE
104c ENDDO
105 ELSEIF (ityp==109) THEN
106 DO ih = 1, nne
107 k = ithbuf(iad-1+ih)
108 n1 = ixri(2,k)
109 n2 = ixri(3,k)
110 DO p = 1, nspmd
111 IF(nlocal(n1,p)==1.AND.
112 . nlocal(n2,p)==1) THEN
113 ithbuf(iad+nne-1+ih) = p
114 GOTO 109
115 ENDIF
116 ENDDO
117 109 CONTINUE
118 ENDDO
119 ENDIF
120 ENDDO
121 ENDIF
122C
123 RETURN
124 END
subroutine thpinit(ithgrp, ithbuf, iparg, dd_iad, ixri, iflag, nthgrp2)
Definition thpinit.F:33