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

Go to the source code of this file.

Functions/Subroutines

subroutine materials (inpc, textpart, matname, nmat, nmat_, irstrt, istep, istat, n, iline, ipol, inl, ipoinp, inp, ipoinpc, imat)
 

Function/Subroutine Documentation

◆ materials()

subroutine materials ( character*1, dimension(*)  inpc,
character*132, dimension(16)  textpart,
character*80, dimension(*)  matname,
integer  nmat,
integer  nmat_,
integer  irstrt,
integer  istep,
integer  istat,
integer  n,
integer  iline,
integer  ipol,
integer  inl,
integer, dimension(2,*)  ipoinp,
integer, dimension(3,*)  inp,
integer, dimension(0:*)  ipoinpc,
integer  imat 
)
22 !
23 ! reading the input deck: *MATERIAL
24 !
25  implicit none
26 !
27  character*1 inpc(*)
28  character*80 matname(*)
29  character*132 textpart(16)
30 !
31  integer nmat,nmat_,istep,istat,n,key,i,irstrt,iline,ipol,inl,
32  & ipoinp(2,*),inp(3,*),ipoinpc(0:*),imat
33 !
34  if((istep.gt.0).and.(irstrt.ge.0)) then
35  write(*,*)
36  & '*ERROR reading *MATERIAL: *MATERIAL should be placed'
37  write(*,*) ' before all step definitions'
38  call exit(201)
39  endif
40 !
41  nmat=nmat+1
42  if(nmat.gt.nmat_) then
43  write(*,*) '*ERROR reading *MATERIAL: increase nmat_'
44  call exit(201)
45  endif
46 !
47  imat=nmat
48 !
49  do i=2,n
50  if(textpart(i)(1:5).eq.'NAME=') then
51  matname(nmat)=textpart(i)(6:85)
52  if(textpart(i)(86:86).ne.' ') then
53  write(*,*)
54  & '*ERROR reading *MATERIAL: material name too long'
55  write(*,*) ' (more than 80 characters)'
56  write(*,*) ' material name:',textpart(i)(1:132)
57  call exit(201)
58  endif
59  exit
60  else
61  write(*,*)
62  & '*WARNING reading *MATERIAL: parameter not recognized:'
63  write(*,*) ' ',
64  & textpart(i)(1:index(textpart(i),' ')-1)
65  call inputwarning(inpc,ipoinpc,iline,
66  &"*MATERIAL%")
67  endif
68  enddo
69 !
70  call getnewline(inpc,textpart,istat,n,key,iline,ipol,inl,
71  & ipoinp,inp,ipoinpc)
72 !
73  return
subroutine inputwarning(inpc, ipoinpc, iline, text)
Definition: inputwarning.f:20
subroutine getnewline(inpc, textpart, istat, n, key, iline, ipol, inl, ipoinp, inp, ipoinpc)
Definition: getnewline.f:21
Hosted by OpenAircraft.com, (Michigan UAV, LLC)