Commit d87dc771 authored by Elia Merzari's avatar Elia Merzari
Browse files

Adding computation of average temperature

parent 97c4f143
......@@ -58,6 +58,10 @@ c-----------------------------------------------------------------------
include 'SIZE'
include 'TOTAL'
common/test_passing/ flux_moose, temp_nek
real sint, sint1, sarea, sarea1, wtmp
integer e, f
n1=nelt*lx1*ly1*lz1
n2=nelt*lx2*ly2*lz2
......@@ -71,10 +75,30 @@ c-----------------------------------------------------------------------
tmax=glmax(t,n1)
ifflow=.false.
sint1=0.0
sarea1=0.0
do e=1,lelt
do f=1,6
call surface_int(sint,sarea,t,e,f)
if (cbc(f,e,1).eq.'W ') then
sint1=sint1+sint
sarea1=sarea1+sarea
endif
enddo
enddo
call gop(sint1,wtmp,'+ ',1)
call gop(sarea1,wtmp,'+ ',1)
temp_nek=sint1/sarea1
if (nid.eq.0) then
write(6,*)"*** Pressure: ",pmin," - ",pmax
write(6,*)"*** Velocity: ",wmin," - ",wmax
c write(6,*)"*** Pressure: ",pmin," - ",pmax
c write(6,*)"*** Velocity: ",wmin," - ",wmax
write(6,*)"*** Temperature: ",tmin," - ",tmax
write(6,*)"*** Av. Temperature: ",temp_nek
endif
return
......@@ -84,6 +108,8 @@ c-----------------------------------------------------------------------
include 'SIZE'
include 'TOTAL'
include 'NEKUSE'
common/test_passing/ flux_moose, temp_nek
integer e,ieg
real ucx, ucy, ucz, ucy_e, yy
......@@ -99,7 +125,7 @@ c-----------------------------------------------------------------------
uy = 0.0
uz = 1.0
temp = 0.0
flux = 1.0
flux = 1.0 !flux_moose
return
end
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment