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

Go to the source code of this file.

Functions/Subroutines

subroutine frictions (inpc, textpart, elcon, nelcon, imat, ntmat_, ncmat_, irstrt, istep, istat, n, iline, ipol, inl, ipoinp, inp, ipoinpc, nstate_, ichangefriction, mortar)
 

Function/Subroutine Documentation

◆ frictions()

subroutine frictions ( character*1, dimension(*)  inpc,
character*132, dimension(16)  textpart,
real*8, dimension(0:ncmat_,ntmat_,*)  elcon,
integer, dimension(2,*)  nelcon,
integer  imat,
integer  ntmat_,
integer  ncmat_,
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  nstate_,
integer  ichangefriction,
integer  mortar 
)
22 !
23 ! reading the input deck: *FRICTION
24 !
25  implicit none
26 !
27  character*1 inpc(*)
28  character*132 textpart(16)
29 !
30  integer nelcon(2,*),imat,ntmat_,istep,istat,ipoinpc(0:*),
31  & n,key,i,ncmat_,irstrt,iline,ipol,inl,ipoinp(2,*),inp(3,*),
32  & nstate_,ichangefriction,mortar
33 !
34  real*8 elcon(0:ncmat_,ntmat_,*)
35 !
36  if((istep.gt.0).and.(irstrt.ge.0).and.(ichangefriction.eq.0)) then
37  write(*,*) '*ERROR reading *FRICTION:'
38  write(*,*) ' *FRICTION should be placed'
39  write(*,*) ' before all step definitions'
40  call exit(201)
41  endif
42 !
43  if(imat.eq.0) then
44  write(*,*) '*ERROR reading *FRICTION:'
45  write(*,*) ' *FRICTION should be preceded'
46  write(*,*) ' by a *SURFACE INTERACTION card'
47  call exit(201)
48  endif
49 !
50  nstate_=max(nstate_,9)
51 !
52 c if(nelcon(1,imat).gt.0) nelcon(1,imat)=max(nelcon(1,imat),7)
53 !
54 ! "8" is for Mortar contact
55 !
56  if(nelcon(1,imat).ne.-51) nelcon(1,imat)=max(nelcon(1,imat),8)
57  nelcon(2,imat)=1
58 !
59 ! no temperature dependence allowed; last line is decisive
60 !
61  do
62  call getnewline(inpc,textpart,istat,n,key,iline,ipol,inl,
63  & ipoinp,inp,ipoinpc)
64  if((istat.lt.0).or.(key.eq.1)) return
65  do i=1,3
66  read(textpart(i)(1:20),'(f20.0)',iostat=istat)
67  & elcon(5+i,1,imat)
68  if(istat.gt.0) call inputerror(inpc,ipoinpc,iline,
69  &"*FRICTION%")
70  enddo
71  if(elcon(6,1,imat).le.0.d0) then
72  write(*,*) '*ERROR reading *FRICTION: friction coefficient'
73  write(*,*) ' must be strictly positive'
74  call inputerror(inpc,ipoinpc,iline,
75  &"*FRICTION%")
76  call exit(201)
77  endif
78  if(elcon(7,1,imat).le.0.d0) then
79  write(*,*) '*ERROR reading *FRICTION: stick slope'
80  write(*,*) ' must be strictly positive'
81  call inputerror(inpc,ipoinpc,iline,
82  &"*FRICTION%")
83  call exit(201)
84  endif
85  elcon(0,1,imat)=0.d0
86  enddo
87 !
88  return
#define max(a, b)
Definition: cascade.c:32
subroutine getnewline(inpc, textpart, istat, n, key, iline, ipol, inl, ipoinp, inp, ipoinpc)
Definition: getnewline.f:21
subroutine inputerror(inpc, ipoinpc, iline, text)
Definition: inputerror.f:20
Hosted by OpenAircraft.com, (Michigan UAV, LLC)