58 TYPE(t_region
),
INTENT(INOUT),
TARGET :: region
64 CHARACTER(CHRLEN) :: rcsidentstring
66 INTEGER :: thermalmodel, icont, ncont, npcls
70 INTEGER,
POINTER,
DIMENSION(:) :: pcvplagmass
71 INTEGER,
POINTER,
DIMENSION(:,:) :: paiv
73 REAL(RFREAL) :: accell, diaml, heatcapl, mixtvolr, onethird,
pi, &
74 prlam, psil, relvelmagl, reltemp, reyl, taulr
76 REAL(RFREAL),
DIMENSION(3) :: relvel
77 REAL(RFREAL),
POINTER,
DIMENSION(:) :: pspcheat
78 REAL(RFREAL),
POINTER,
DIMENSION(:,:) :: pcv, pdv, ptv
80 TYPE(t_plag) ,
POINTER :: pplag
86 '$RCSfile: INRT_CalcHeatTransferNonBurn.F90,v $ $Revision: 1.3 $'
88 global => region%global
91 'INRT_CalcHeatTransferNonBurn.F90' )
101 ilev = region%currLevel
102 IF (global%plagUsed) npcls = region%levels(ilev)%plag%nPcls
105 IF (global%plagUsed) npcls = region%plag%nPcls
108 IF (npcls < 1) go to 999
112 onethird = 1.0_rfreal/3.0_rfreal
116 ncont = region%plagInput%nCont
117 thermalmodel = region%inrtInput%inrts(inrt_type_htransnb)%switches( &
118 inrt_swi_htransnb_model)
123 pplag => region%levels(ilev)%plag
134 pcvplagmass => pplag%cvPlagMass
135 pspcheat => region%plagInput%spht
141 IF (paiv(aiv_plag_burnstat,ipcls) /= inrt_burnstat_off) cycle
143 diaml = pdv(dv_plag_diam,ipcls)
145 heatcapl =
sum( pcv(pcvplagmass(:),ipcls) * pspcheat(:) )
149 taulr = 2.0_rfreal*
pi*ptv(tv_plag_tcolmixt,ipcls) * diaml/heatcapl
151 reltemp = pdv(dv_plag_tempmixt,ipcls)-pdv(dv_plag_temp,ipcls)
153 SELECT CASE (thermalmodel)
155 CASE (inrt_htransnb_model_stokes)
159 CASE (inrt_htransnb_model_rm)
161 relvel(1) = pdv(dv_plag_uvelmixt,ipcls)-pdv(dv_plag_uvel,ipcls)
162 relvel(2) = pdv(dv_plag_vvelmixt,ipcls)-pdv(dv_plag_vvel,ipcls)
163 relvel(3) = pdv(dv_plag_wvelmixt,ipcls)-pdv(dv_plag_wvel,ipcls)
165 relvelmagl =
sqrt( relvel(1)*relvel(1)+ &
166 relvel(2)*relvel(2)+ &
167 relvel(3)*relvel(3) )
169 reyl = diaml * relvelmagl * pdv(dv_plag_densmixt,ipcls) / &
170 ptv(tv_plag_muelmixt,ipcls)
172 psil = 1.0_rfreal + 0.3_rfreal* (reyl**0.5_rfreal) *(prlam**onethird)
175 CALL
errorstop( global,err_reached_default,__line__ )
179 accell = psil*reltemp*taulr
184 pplag%inrtSources(inrt_htransnb_l_ener_g,ipcls) = - heatcapl*accell
Tfloat sum() const
Return the sum of all the pixel values in an image.
subroutine registerfunction(global, funName, fileName)
subroutine inrt_calcheattransfernonburn(region)
subroutine errorstop(global, errorCode, errorLine, addMessage)
subroutine deregisterfunction(global)