Problem with scalar transport at inlets
Posted: Wed Oct 12, 2016 5:07 pm
C_S version is 4.0
Dear team,
First of all, thanks for your work. I used C_S for several years and I'm always pleased to work with your new releases.
I currently work with a scalar transport equation that represents a concentration in particles (lets say that unit is part/m3). The basic system is just a closed box with one inlet and one outlet.
I define a value (dirichlet bc) for this scalar at a velocity inlet and then check what is the quantity (number of particles) released in the domain during an unsteady job. For this, I used something like:
in cs_user_extra_operations.f90.
Unfortunately, I don't get the right result. This is easy to check with a constant timestep since the dispersion timerate (in part/s) is just :
S_inlet*u_inlet*C_scal
where:
S_inlet is the surface of the inlet (m2)
u_inlet is the velocity at inlet (m/s)
C_scal is the value of scalar at inlet (part/m3)
In the past (C_S v2.0), I fixed this problem by modifying covofi.f90 (suppress viscosity at inlets) with :
Could you please :
- tell me if you have reproduced the problem
- help me to get the same kind of correction for scalar viscosity at inlets (in covofi) since I'm not yet familiar with the new architecture of C_S last releases?
Thank you for your feedback.
Dear team,
First of all, thanks for your work. I used C_S for several years and I'm always pleased to work with your new releases.
I currently work with a scalar transport equation that represents a concentration in particles (lets say that unit is part/m3). The basic system is just a closed box with one inlet and one outlet.
I define a value (dirichlet bc) for this scalar at a velocity inlet and then check what is the quantity (number of particles) released in the domain during an unsteady job. For this, I used something like:
Code: Select all
integration = 0.d0
call field_get_val_s(ivarfl(isca(1)), cvar_scal)
do iel = 1, ncel
integration = integration + cvar_scal(iel)*volume(iel)
enddo
Unfortunately, I don't get the right result. This is easy to check with a constant timestep since the dispersion timerate (in part/s) is just :
S_inlet*u_inlet*C_scal
where:
S_inlet is the surface of the inlet (m2)
u_inlet is the velocity at inlet (m/s)
C_scal is the value of scalar at inlet (part/m3)
In the past (C_S v2.0), I fixed this problem by modifying covofi.f90 (suppress viscosity at inlets) with :
Code: Select all
do ifac = 1, nfabor
iel = ifabor(ifac)
if(ipcvsl.eq.0)then
viscb(ifac) = visls0(iscal)*ra(isrfbn-1+ifac)/ra(idistb-1+ifac)
else
viscb(ifac) = propce(iel,ipcvsl)*ra(isrfbn-1+ifac)/ra(idistb-1+ifac)
end if
enddo
- tell me if you have reproduced the problem
- help me to get the same kind of correction for scalar viscosity at inlets (in covofi) since I'm not yet familiar with the new architecture of C_S last releases?
Thank you for your feedback.