OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
write_debug.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 When compiled with -DDEBUG_RST
24C calls to WRITE_I_C in other parts of the code will be replace by
25C WRITE_I_C_DEBUG
26C Same for WRITE_DB
27C This allows to use the option -flush_rst_to_txt at the starter
28
29!||====================================================================
30!|| write_i_c_debug ../starter/source/output/tools/write_debug.F
31!||--- calls -----------------------------------------------------
32!|| fretitl2 ../starter/source/starter/freform.f
33!||--- uses -----------------------------------------------------
34!||====================================================================
35 SUBROUTINE write_i_c_debug(A,N,SA)
37! Do not replace IMPLICIT NONE by an include here
38 IMPLICIT NONE
39#include "debug_rst.inc"
40 INTEGER :: A(N),N
41 CHARACTER(len=*) :: SA
42 CHARACTER(LEN=NCHARTITLE) :: TITR
43 INTEGER :: I,IT,J
44 INTEGER :: NT
45#if defined(_OPENMP)
46 INTEGER OMP_GET_THREAD_NUM
47 EXTERNAL omp_get_thread_num
48 nt = omp_get_thread_num()
49#else
50 nt=1
51#endif
52 IF(flush_rst_to_txt) THEN
53 titr(1:nchartitle) = " "
54 IF(n==ceiling(dble(nchartitle)/3.0d0)) THEN
55 CALL fretitl2(titr,a,ceiling(dble(nchartitle)/3.0d0))
56 WRITE(777+nt,*) trim(sa),' '
57 j = 1
58 DO i = 1,n
59 WRITE(777+nt,*) a(i),titr(j:j+2)
60 j = j + 3
61 ENDDO
62 ELSE
63 WRITE(777+nt,*) trim(sa),' '
64 DO i = 1,n
65 WRITE(777+nt,*) a(i)
66 ENDDO
67 ENDIF
68 ENDIF
69
70 CALL write_i_c(a,n)
71
72
73 END SUBROUTINE
74
75!||====================================================================
76!|| write_db_debug ../starter/source/output/tools/write_debug.F
77!||--- calls -----------------------------------------------------
78!||====================================================================
79 SUBROUTINE write_db_debug(A,N,SA)
80! Do not replace IMPLICIT NONE by an include here
81 IMPLICIT NONE
82#include "debug_rst.inc"
83 INTEGER :: N
84 DOUBLE PRECISION :: A(N)
85 CHARACTER(len=*) :: SA
86 INTEGER :: I,NT
87#if defined(_OPENMP)
88 INTEGER OMP_GET_THREAD_NUM
89 EXTERNAL omp_get_thread_num
90 nt = omp_get_thread_num()
91#else
92 nt=1
93#endif
94
95
96 IF(flush_rst_to_txt) THEN
97 WRITE(777+nt,*) trim(sa),' '
98 DO i = 1,n
99 WRITE(777+nt,'(E10.4,2X,Z20)') a(i),a(i)
100 ENDDO
101 ENDIF
102 CALL write_db(a,n)
103
104 END SUBROUTINE
105
106
107
subroutine freform(irunn, irfl, irfe, h3d_data, flag_cst_ams, dynain_data, sensors, dt, output, glob_therm)
Definition freform.F:88
integer, parameter nchartitle
subroutine fretitl2(titr, iasc, l)
Definition freform.F:804
program starter
Definition starter.F:39
subroutine write_db(a, n)
Definition write_db.F:140
subroutine write_i_c_debug(a, n, sa)
Definition write_debug.F:36
subroutine write_db_debug(a, n, sa)
Definition write_debug.F:80
void write_i_c(int *w, int *len)