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

Go to the source code of this file.

Functions/Subroutines

subroutine flowresult (ntg, itg, cam, vold, v, nload, sideload, nelemload, xloadact, nactdog, network, mi, ne, ipkon, lakon, kon)
 

Function/Subroutine Documentation

◆ flowresult()

subroutine flowresult ( integer  ntg,
integer, dimension(*)  itg,
real*8, dimension(5)  cam,
real*8, dimension(0:mi(2),*)  vold,
real*8, dimension(0:mi(2),*)  v,
integer  nload,
character*20, dimension(*)  sideload,
integer, dimension(2,*)  nelemload,
real*8, dimension(2,*)  xloadact,
integer, dimension(0:3,*)  nactdog,
integer  network,
integer, dimension(*)  mi,
integer  ne,
integer, dimension(*)  ipkon,
character*8, dimension(*)  lakon,
integer, dimension(*)  kon 
)
21 !
22  implicit none
23 !
24  character*8 lakon(*),lakonl
25  character*20 sideload(*)
26 !
27  integer i,j,nload,node,ntg,itg(*),nelemload(2,*),kon(*),
28  & nactdog(0:3,*),network,mi(*),ne,indexe,ipkon(*),
29  & node1,node2,node3
30 !
31  real*8 cam(5),vold(0:mi(2),*),v(0:mi(2),*),xloadact(2,*)
32 !
33 ! calculating the change of gas temperature: is taken
34 ! into account in the global convergence for purely
35 ! thermal networks (reason: for purely thermal networks
36 ! the network solution is not iterated to speed up
37 ! the calculation)
38 !
39  if(network.le.1) then
40  do i=1,ntg
41  node=itg(i)
42  if(nactdog(0,node).eq.0) cycle
43  if(dabs(vold(0,node)-v(0,node)).gt.cam(2)) then
44  cam(2)=dabs(vold(0,node)-v(0,node))
45  cam(5)=node+0.5d0
46  endif
47  enddo
48  endif
49 !
50 ! replacing vold by v (including the static temperature for
51 ! gases and the critical depth for liquid channels)
52 !
53  do i=1,ntg
54  node=itg(i)
55  do j=0,3
56  vold(j,node)=v(j,node)
57  enddo
58  enddo
59 !
60 ! determining all inflowing mass flow in the end nodes and
61 ! assigning it to the end nodes
62 !
63  do i=1,ne
64 !
65  if(ipkon(i).lt.0) cycle
66  lakonl=lakon(i)
67  if(lakonl(1:1).ne.'D') cycle
68  if(lakonl(1:7).eq.'DCOUP3D') cycle
69 !
70  indexe=ipkon(i)
71  if(kon(indexe+1).ne.0) then
72  node1=kon(indexe+1)
73  vold(1,node1)=0.d0
74  endif
75  if(kon(indexe+3).ne.0) then
76  node3=kon(indexe+3)
77  vold(1,node3)=0.d0
78  endif
79  enddo
80 !
81  do i=1,ne
82 !
83  if(ipkon(i).lt.0) cycle
84  lakonl=lakon(i)
85  if(lakonl(1:1).ne.'D') cycle
86  if(lakonl(1:7).eq.'DCOUP3D') cycle
87 !
88  indexe=ipkon(i)
89  node2=kon(indexe+2)
90  if(kon(indexe+1).ne.0) then
91  node1=kon(indexe+1)
92 c if(vold(1,node2).gt.0.d0)
93 c & vold(1,node1)=vold(1,node1)+vold(1,node2)
94  if(vold(1,node2).lt.0.d0)
95  & vold(1,node1)=vold(1,node1)-vold(1,node2)
96  endif
97  if(kon(indexe+3).ne.0) then
98  node3=kon(indexe+3)
99 c if(vold(1,node2).lt.0.d0)
100 c & vold(1,node3)=vold(1,node3)-vold(1,node2)
101  if(vold(1,node2).gt.0.d0)
102  & vold(1,node3)=vold(1,node3)+vold(1,node2)
103  endif
104  enddo
105 !
106 ! updating the film boundary conditions
107 !
108  do i=1,nload
109  if(sideload(i)(3:4).eq.'FC') then
110  node=nelemload(2,i)
111  xloadact(2,i)=vold(0,node)
112  endif
113  enddo
114 !
115 ! updating the pressure boundary conditions
116 !
117  do i=1,nload
118  if(sideload(i)(3:4).eq.'NP') then
119  node=nelemload(2,i)
120  xloadact(1,i)=vold(2,node)
121  endif
122  enddo
123 !
124  return
Hosted by OpenAircraft.com, (Michigan UAV, LLC)