OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
get_file_name_info.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!|| get_file_name_info ../engine/source/system/get_file_name_info.f
25!||--- called by ------------------------------------------------------
26!|| radioss2 ../engine/source/engine/radioss2.F
27!||--- calls -----------------------------------------------------
28!|| arret ../engine/source/system/arret.F
29!|| phelpinfo ../engine/source/engine/execargcheck.F
30!||====================================================================
31 SUBROUTINE get_file_name_info(INPUT,LENI,
32 * ROOTNAME,LENR,
33 * RUNN,FVERS)
34C-----------------------------------------------
35C I m p l i c i t T y p e s
36C-----------------------------------------------
37#include "implicit_f.inc"
38C-----------------------------------------------
39C D u m m y A r g u m e n t s
40C-----------------------------------------------
41 CHARACTER INPUT*256
42 CHARACTER ROOTNAME*80
43 INTEGER LENI,LENR,RUNN,FVERS
44C-----------------------------------------------
45C L o c a l V a r i a b l e s
46C-----------------------------------------------
47 INTEGER ERR,FST,LST,V4RNUM,rd
48 CHARACTER ARUN*4,EXT*4,EXT3*3,V4LETTER,V5LETTER
49C-----------------------------------------------
50 IF (input=='CHECK_DATA')THEN
51 lenr = 0
52 runn = 0
53 RETURN
54 ENDIF
55
56 IF (leni < 4) GOTO 1000
57
58
59 WRITE(ext,'(A)') input(leni-3:leni)
60 IF ( lle(ext,'.rad') .AND. lge(ext,'.rad')) THEN
61 IF (leni < 10 ) GOTO 1000
62C Run number
63 READ(input(leni-7:leni-4),fmt='(I4)',err=1000) runn
64C Rootname
65 WRITE(rootname,fmt='(A)',err=1000) input(1:leni-9)
66 lenr=len_trim(rootname)
67C Dataset letter
68 WRITE(v5letter,'(A)') input(leni-8:leni-8)
69 IF ( v5letter=='_') THEN
70 fvers = 5
71 ELSE
72 GOTO 1000
73 ENDIF
74 ELSE
75C Run number
76 READ(input(leni-1:leni),fmt='(I2)',err=1000) runn
77C Rootname
78 WRITE(rootname,fmt='(A)',err=1000) input(1:leni-3)
79 lenr=len_trim(rootname)
80C Dataset letter
81 WRITE(v4letter,'(A)') input(leni-2:leni-2)
82 IF ( v4letter=='D') THEN
83 fvers=4
84 ELSE
85 GOTO 1000
86 ENDIF
87
88 ENDIF
89
90
91 RETURN
92
93 1000 CONTINUE
94 CALL phelpinfo(3,input,leni)
95 CALL arret(7)
96 END
subroutine get_file_name_info(input, leni, rootname, lenr, runn, fvers)
subroutine phelpinfo()
subroutine arret(nn)
Definition arret.F:87