OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
read_pcyl.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!|| read_pcyl ../engine/source/output/restart/read_pcyl.F
25!||--- called by ------------------------------------------------------
26!|| rdresb ../engine/source/output/restart/rdresb.F
27!||--- calls -----------------------------------------------------
28!|| read_db ../common_source/tools/input_output/read_db.F
29!|| read_i_c ../common_source/tools/input_output/write_routtines.c
30!||--- uses -----------------------------------------------------
31!|| loads_mod ../common_source/modules/loads/loads_mod.F90
32!||====================================================================
33 SUBROUTINE read_pcyl(LOADS)
34C-----------------------------------------------
35C M o d u l e s
36C-----------------------------------------------
37 USE loads_mod
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 "units_c.inc"
47#include "tabsiz_c.inc"
48C-----------------------------------------------
49C D u m m y A r g u m e n t s
50C-----------------------------------------------
51 TYPE (LOADS_) :: LOADS
52C-----------------------------------------------
53C L o c a l V a r i a b l e s
54C-----------------------------------------------
55 INTEGER :: I,J,NSEG,LLINT,IAD,NLOAD_CYL
56 INTEGER :: MY_SIZE
57 INTEGER ,DIMENSION(:) ,ALLOCATABLE :: ITMP
58 my_real, DIMENSION(3) :: rtmp
59C-----------------------------------------------
60c -> PCYL_ID
61c -> NSEG
62c -> SEGNOD(NSEG,4) (N1,N2,NB3,N4) by segment
63c -> FRAME_ID
64c -> SENS_ID
65c -> TABLE_ID
66c -> XSCALE_R
67c -> XSCALE_T
68c -> YSCALE_P
69c=======================================================================
70 nload_cyl = loads%NLOAD_CYL
71 ALLOCATE(loads%LOAD_CYL(nload_cyl))
72c
73 DO i=1,nload_cyl
74 CALL read_i_c(nseg,1)
75 llint = 4 + nseg*4
76 ALLOCATE (itmp(llint))
77 CALL read_i_c(itmp,llint)
78
79 loads%LOAD_CYL(i)%ID = itmp(1)
80 loads%LOAD_CYL(i)%ISENS = itmp(2)
81 loads%LOAD_CYL(i)%ITABLE = itmp(3)
82 loads%LOAD_CYL(i)%IFRAME = itmp(4)
83c
84 ALLOCATE(loads%LOAD_CYL(i)%SEGNOD(nseg,4))
85 iad = 4
86 loads%LOAD_CYL(i)%NSEG = nseg
87 DO j=1,nseg
88 loads%LOAD_CYL(i)%SEGNOD(j,1) = itmp(iad+1)
89 loads%LOAD_CYL(i)%SEGNOD(j,2) = itmp(iad+2)
90 loads%LOAD_CYL(i)%SEGNOD(j,3) = itmp(iad+3)
91 loads%LOAD_CYL(i)%SEGNOD(j,4) = itmp(iad+4)
92 iad = iad + 4
93 END DO
94c
95 CALL read_db(rtmp,3)
96 loads%LOAD_CYL(i)%XSCALE_R = rtmp(1)
97 loads%LOAD_CYL(i)%XSCALE_T = rtmp(2)
98 loads%LOAD_CYL(i)%YSCALE = rtmp(3)
99
100 ! ---------------
101 ! load/pcyl option : adress of FSKY array
102 my_size = loads%LOAD_CYL(i)%NSEG
103 ALLOCATE(loads%LOAD_CYL(i)%SEGMENT_ADRESS(4,my_size))
104 CALL read_i_c(loads%LOAD_CYL(i)%SEGMENT_ADRESS,4*my_size)
105 ! ---------------
106c
107 DEALLOCATE(itmp)
108 ENDDO
109c-----------
110 RETURN
111 END
#define my_real
Definition cppsort.cpp:32
subroutine read_db(a, n)
Definition read_db.F:88
subroutine read_pcyl(loads)
Definition read_pcyl.F:34
void read_i_c(int *w, int *len)