OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
r2r_prelec_name.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!|| r2r_prelec_name ../starter/source/coupling/rad2rad/r2r_prelec_name.F
25!||--- called by ------------------------------------------------------
26!|| r2r_fork ../starter/source/coupling/rad2rad/r2r_fork.F
27!||--- calls -----------------------------------------------------
28!|| ancmsg ../starter/source/output/message/message.F
29!|| hm_get_intv ../starter/source/devtools/hm_reader/hm_get_intv.F
30!|| hm_option_read_key ../starter/source/devtools/hm_reader/hm_option_read_key.F
31!|| hm_option_start ../starter/source/devtools/hm_reader/hm_option_start.f
32!||--- uses -----------------------------------------------------
33!|| hm_option_read_mod ../starter/share/modules1/hm_option_read_mod.F
34!|| message_mod ../starter/share/message_module/message_mod.F
35!|| r2r_mod ../starter/share/modules1/r2r_mod.F
36!|| restmod ../starter/share/modules1/restart_mod.F
37!|| submodel_mod ../starter/share/modules1/submodel_mod.F
38!||====================================================================
39 SUBROUTINE r2r_prelec_name(KDOM,LSUBMODEL)
40C-----------------------------------------------
41C M o d u l e s
42C-----------------------------------------------
43 USE message_mod
44 USE restmod
45 USE r2r_mod
46 USE submodel_mod
49C-----------------------------------------------
50C I m p l i c i t T y p e s
51C-----------------------------------------------
52#include "implicit_f.inc"
53C-----------------------------------------------
54C C o m m o n B l o c k s
55C-----------------------------------------------
56#include "r2r_c.inc"
57C-----------------------------------------------
58C D u m m y A r g u m e n t s
59C-----------------------------------------------
60 INTEGER KDOM
61 TYPE(submodel_data),INTENT(IN)::LSUBMODEL(*)
62C-----------------------------------------------
63C L o c a l V a r i a b l e s
64C-----------------------------------------------
65 INTEGER I,NUSER,N,RLEN,STAT,DEB,K,FLAG_FMT,ID,NEL
66 CHARACTER(LEN=NCHARKEY)::KEY
67 CHARACTER(LEN=NCHARTITLE)::LOCNAME,TITR
68 LOGICAL IS_AVAILABLE
69C=======================================================================
70C
71 is_available = .false.
72 CALL hm_option_start('/SUBDOMAIN')
73 nb_part_sub = 0
74C
75 IF (ipid==0) THEN
76C--------------------------------------------------------------------C
77C------Prereading of domain names --> Child process -----------------C
78C--------------------------------------------------------------------C
79
80 flag_fmt = 0
81
82 DO n=1,nsubdom
83C
84 CALL hm_option_read_key(lsubmodel,
85 . option_id = id,
86 . option_titr = titr,
87 . keyword2 = key)
88C---
89 IF(n == kdom)THEN
90 dom_name = ''//trim(titr)
91 ENDIF
92C----- Computation of total number of parts
93 CALL hm_get_intv('idsmax',nel,is_available,lsubmodel)
94 nb_part_sub = nb_part_sub + nel
95 END DO
96
97 ELSE
98C--------------------------------------------------------------------C
99C------Prereading of domain names --> father process ----------------C
100C--------------------------------------------------------------------C
101
102 n = 0
103 deb = 1
104
105C DO WHILE(N < NSUBDOM)
106 DO n=1,nsubdom
107C---
108C
109 CALL hm_option_read_key(lsubmodel,
110 . option_id = id,
111 . option_titr = titr,
112 . keyword2 = key)
113
114 locname = ''//trim(titr)
115 rlen = len_trim(locname)
116 dom_name(deb:deb+rlen-1)=locname(1:rlen)
117 isubdom(7,n)=rlen
118 isubdom(8,n)=deb
119 deb=deb+rlen
120C----- Computation of total number of parts
121 CALL hm_get_intv('idsmax',nel,is_available,lsubmodel)
122 nb_part_sub = nb_part_sub + nel
123C
124 END DO
125
126C------Check of domain names ----------------C
127
128 DO n=1,nsubdom
129 DO k=n+1,nsubdom
130 IF (isubdom(7,n)==isubdom(7,k)) THEN
131 rlen = isubdom(7,n)
132 key(1:rlen)=dom_name(isubdom(8,n):isubdom(8,n)+rlen-1)
133 titr(1:rlen)=dom_name(isubdom(8,k):isubdom(8,k)+rlen-1)
134 IF (key(1:rlen) == titr(1:rlen)) THEN
135 CALL ancmsg(msgid=826,
136 . msgtype=msgerror,
137 . anmode=aninfo,i1=isubdom(1,n),
138 . c1=key(1:rlen))
139 ierr=ierr+1
140 ENDIF
141 ENDIF
142 ENDDO
143 ENDDO
144
145 ENDIF
146
147 RETURN
148
149 END SUBROUTINE r2r_prelec_name
150
subroutine hm_get_intv(name, ival, is_available, lsubmodel)
subroutine hm_option_start(entity_type)
integer, parameter nchartitle
integer, parameter ncharkey
integer, dimension(:,:), allocatable isubdom
Definition r2r_mod.F:144
subroutine r2r_prelec_name(kdom, lsubmodel)
subroutine ancmsg(msgid, msgtype, anmode, i1, i2, i3, i4, i5, i6, i7, i8, i9, i10, i11, i12, i13, i14, i15, i16, i17, i18, i19, i20, r1, r2, r3, r4, r5, r6, r7, r8, r9, c1, c2, c3, c4, c5, c6, c7, c8, c9, prmode)
Definition message.F:889
program starter
Definition starter.F:39