OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
w_secbuf.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/.
23C
24!||====================================================================
25!|| w_secbuf ../starter/source/restart/ddsplit/w_secbuf.F
26!||--- called by ------------------------------------------------------
27!|| ddsplit ../starter/source/restart/ddsplit/ddsplit.F
28!||--- calls -----------------------------------------------------
29!|| nlocal ../starter/source/spmd/node/ddtools.F
30!||====================================================================
31 SUBROUTINE w_secbuf(SECBUF ,LSECBUF_L, NSTRF, PROC,
32 2 LEN_AM )
33C-----------------------------------------------
34C M o d u l e s
35C-----------------------------------------------
36
37C-----------------------------------------------
38C I m p l i c i t T y p e s
39C-----------------------------------------------
40#include "implicit_f.inc"
41C-----------------------------------------------
42C C o m m o n B l o c k s
43C-----------------------------------------------
44#include "com04_c.inc"
45C-----------------------------------------------
46C D u m m y A r g u m e n t s
47C-----------------------------------------------
48 INTEGER PROC, LSECBUF_L, LEN_AM,
49 . nstrf(*)
51 . secbuf(*)
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 NNOD_S, NNOD_S_L, TYP_S, NSINT_S,
61 . n, ip, j, k0, k2, kr_l, kr, k
63 . secbuf_l(lsecbuf_l)
64C
65 kr_l = 0
66 kr = 0
67C header commun
68 DO j = 1, 10
69 secbuf_l(kr_l+j) = secbuf(kr+j)
70 END DO
71 kr_l = kr_l + 10
72 kr = kr + 10
73C
74 k0 = nstrf(25)
75 DO n = 1, nsect
76 typ_s = nstrf(k0)
77 nnod_s = nstrf(k0+6)
78 nsint_s = nstrf(k0+14)
79 k2=k0+30+nsint_s
80C noeuds locaux
81 nnod_s_l = 0
82 DO j = 1, nnod_s
83 k = nstrf(k2 + j -1)
84 IF(nlocal(k,proc+1)==1)THEN
85 nnod_s_l = nnod_s_l + 1
86 END IF
87 END DO
88 DO j = 1, 10
89 secbuf_l(kr_l+j) = secbuf(kr+j)
90 END DO
91 kr_l = kr_l + 10
92 kr = kr + 10
93 IF(typ_s>=100) THEN
94 DO j = 1, 12*nnod_s_l
95 secbuf_l(kr_l+j) = zero
96 END DO
97 kr_l = kr_l + 12*nnod_s_l
98 kr = kr + 12*nnod_s
99 END IF
100 IF(typ_s>=101) THEN
101 DO j = 1, 12*nnod_s_l
102 secbuf_l(kr_l+j) = zero
103 END DO
104 kr_l = kr_l + 12*nnod_s_l
105 kr = kr + 12*nnod_s
106 END IF
107 IF(typ_s>=102) THEN
108 DO j = 1, 6*nnod_s_l
109 secbuf_l(kr_l+j) = zero
110 END DO
111 kr_l = kr_l + 6*nnod_s_l
112 kr = kr + 6*nnod_s
113 END IF
114 k0 = nstrf(k0+24)
115 ENDDO
116C
117 CALL write_db(secbuf_l,lsecbuf_l)
118 len_am = len_am + lsecbuf_l
119 if(lsecbuf_l/=kr_l)print*,'error secbuf',lsecbuf_l,kr_l,nnod_s_l
120C
121 RETURN
122 END
#define my_real
Definition cppsort.cpp:32
subroutine w_secbuf(secbuf, lsecbuf_l, nstrf, proc, len_am)
Definition w_secbuf.F:33
subroutine write_db(a, n)
Definition write_db.F:140