OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
hm_read_refsta.F File Reference
#include "implicit_f.inc"
#include "units_c.inc"
#include "scr17_c.inc"
#include "scr03_c.inc"
#include "scr15_c.inc"

Go to the source code of this file.

Functions/Subroutines

subroutine hm_read_refsta (lsubmodel, xrfile)

Function/Subroutine Documentation

◆ hm_read_refsta()

subroutine hm_read_refsta ( type(submodel_data), dimension(*), intent(in) lsubmodel,
character (len=ncharline), intent(inout) xrfile )

Definition at line 41 of file hm_read_refsta.F.

42C============================================================================
43C M o d u l e s
44C-----------------------------------------------
45 USE unitab_mod
46 USE message_mod
47 USE submodel_mod
49 USE refsta_mod
52C-----------------------------------------------
53C I m p l i c i t T y p e s
54C-----------------------------------------------
55#include "implicit_f.inc"
56C-----------------------------------------------
57C C o m m o n B l o c k s
58C-----------------------------------------------
59#include "units_c.inc"
60#include "scr17_c.inc"
61#include "scr03_c.inc"
62#include "scr15_c.inc"
63C-----------------------------------------------
64C D u m m y A r g u m e n t s
65C-----------------------------------------------
66 TYPE(SUBMODEL_DATA),INTENT(IN)::LSUBMODEL(*)
67 CHARACTER (LEN=ncharline), INTENT(INOUT) :: XRFILE
68C-----------------------------------------------
69C L o c a l V a r i a b l e s
70C-----------------------------------------------
71 CHARACTER(LEN=NCHARLINE) :: TMP_NAME
72 INTEGER LEN_TMP_NAME,J, I, LEN_
73 LOGICAL IS_AVAILABLE, IS_ENCRYPTED
74C-----------------------------------------------
75C S o u r c e L i n e s
76C-----------------------------------------------
77 is_encrypted = .false.
78 is_available = .false.
79
80 CALL hm_option_count('/REFSTA',irefsta)
81 IF(irefsta == 0) RETURN
82 CALL hm_option_start('/REFSTA')
83 CALL hm_option_read_key(lsubmodel)
84 CALL hm_option_is_encrypted(is_encrypted)
85
86 rs0_fmt=0
87 nitrs=0
88 xrfile(1:ncharline)=' '
89 CALL hm_get_string('filename',xrfile,ncharline,is_available)
90 CALL hm_get_intv('nitrs',nitrs,is_available,lsubmodel)
91 CALL hm_get_intv('refsta_fileformat',rs0_fmt,is_available,lsubmodel)
92
93 IF (nitrs == 0) nitrs=100
94 len_ = len_trim(xrfile)
95 IF(len_ > 0 )xrfile(len_+1:ncharline) = ' '
96 !
97 IF (xrfile==' ') THEN
98 xrfile=rootnam(1:rootlen)//'RS0'
99 ELSE
100 j=0
101 DO i=1,ncharline
102 IF(xrfile(i:i)/=' ')THEN
103 j=j+1
104 xrfile(j:j) = xrfile(i:i)
105 ENDIF
106 ENDDO
107 DO i=j+1,ncharline
108 xrfile(i:i) = ' '
109 ENDDO
110 ENDIF
111 refsta_filename = xrfile
112 tmp_name=infile_name(1:infile_name_len)//xrfile(1:len_trim(xrfile))
113 len_tmp_name = infile_name_len+len_trim(xrfile)
114 OPEN(unit=iin6,file=tmp_name(1:len_tmp_name),access='SEQUENTIAL',form='FORMATTED',status='OLD',err=111)
115
116C-----------------------------------------------
117 RETURN
118
119C-----------------------------------------------
120 111 CONTINUE
121 CALL ancmsg(msgid=517,
122 . msgtype=msgerror,
123 . anmode=aninfo,
124 . c1=xrfile)
125C-----------------------------------------------
126 RETURN
subroutine hm_get_intv(name, ival, is_available, lsubmodel)
subroutine hm_get_string(name, sval, size, is_available)
subroutine hm_option_count(entity_type, hm_option_number)
subroutine hm_option_is_encrypted(is_encrypted)
subroutine hm_option_start(entity_type)
integer infile_name_len
character(len=infile_char_len) infile_name
integer, parameter ncharline
integer rs0_fmt
Definition refsta_mod.F:38
character(len=ncharline) refsta_filename
Definition refsta_mod.F:36
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