CalculiX  2.13
A Free Software Three-Dimensional Structural Finite Element Program
writeinput.f File Reference

Go to the source code of this file.

Functions/Subroutines

subroutine writeinput (inpc, ipoinp, inp, nline, ninp, ipoinpc)
 

Function/Subroutine Documentation

◆ writeinput()

subroutine writeinput ( character*1, dimension(*)  inpc,
integer, dimension(2,nentries)  ipoinp,
integer, dimension(3,ninp)  inp,
integer  nline,
integer  ninp,
integer, dimension(0:*)  ipoinpc 
)
19 !
20  implicit none
21 !
22  integer nentries
23  parameter(nentries=17)
24 !
25  character*1 inpc(*)
26  character*20 nameref(nentries)
27 !
28  integer nline,i,j,ninp,ipoinp(2,nentries),inp(3,ninp),
29  & ipoinpc(0:*)
30 !
31  data nameref /'RESTART,READ','NODE','USERELEMENT','ELEMENT',
32  & 'NSET',
33  & 'ELSET','SURFACE','TRANSFORM','MATERIAL',
34  & 'ORIENTATION','TIE','SURFACEINTERACTION',
35  & 'INITIALCONDITIONS','AMPLITUDE',
36  & 'CONTACTPAIR','COUPLING','REST'/
37 !
38  open(16,file='input.inpc',status='unknown',err=161)
39  do i=1,nline
40  write(16,'(1x,i6,1x,1320a1)') i,
41  & (inpc(j),j=ipoinpc(i-1)+1,ipoinpc(i))
42  enddo
43  close(16)
44 !
45  open(16,file='input.ipoinp',status='unknown',err=162)
46  do i=1,nentries
47  write(16,'(1x,a20,1x,i6,1x,i6)') nameref(i),(ipoinp(j,i),j=1,2)
48  enddo
49  close(16)
50 !
51  open(16,file='input.inp',status='unknown',err=163)
52  do i=1,ninp
53  write(16,'(1x,i3,1x,i6,1x,i6,1x,i6)') i,(inp(j,i),j=1,3)
54  enddo
55  close(16)
56 !
57  return
58 !
59  161 write(*,*) '*ERROR in writeinput: could not open file input.inpc'
60  call exit(201)
61 !
62  162 write(*,*)
63  & '*ERROR in writeinput: could not open file input.ipoinp'
64  call exit(201)
65 !
66  163 write(*,*) '*ERROR in writeinput: could not open file input.inp'
67  call exit(201)
Hosted by OpenAircraft.com, (Michigan UAV, LLC)