No shear wall

Questions and remarks about code_saturne usage
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
CTrinca
Posts: 32
Joined: Mon Mar 30, 2015 9:19 am

No shear wall

Post by CTrinca »

Hello everyone,

I need to impose a "no-shear wall" boundary condition with uniform temperature in a test simulation. I have found a ready-made recipe for it in the user manual (for version 4, in the notes at page 74), which I implemented as follows in cs_user_boundary_conditions:

Code: Select all

if (constant_temperature_applied) then
    boundaryselection = constant_T_boundaries
    allocate(lstelt(nfabor))
    call getfbr(boundaryselection, nlelt, lstelt)

    do ilelt = 1, nlelt
        ifac = lstelt(ilelt)
        iel = ifabor(ifac)
        itypfb(ifac) = isymet
        icodcl(ifac,isca(iscalt)) = 1
        rcodcl(ifac,isca(iscalt),1) = T_boundary
    end do
 
end if


where constant_T_boundaries and T_boundary are defined in cs_user_modules.
That does not seem to work: if I plot the boundary temperature field on that boundary surface, I get a very patchy distribution, as shown in the picture attached (it is supposed to be 30 C everywhere).
Can you spot any problem in my code?
Thanks in advance and regards,

Cosimo
Attachments
boundary_T.png
Yvan Fournier
Posts: 4080
Joined: Mon Feb 20, 2012 3:25 pm

Re: No shear wall

Post by Yvan Fournier »

Hello,

How regular is your mesh ?

How does the temperature field look in a cut plane through the domain ? How does the fow field compare ?

Regards,

Yvan
CTrinca
Posts: 32
Joined: Mon Mar 30, 2015 9:19 am

Re: No shear wall

Post by CTrinca »

Hello Yvan,

The calculation itself is very unstable, but I thought that it could be either independent or even caused by the boundary problem. But that is because I assumed that imposing a Dirichlet boundary condition would force the boundary temperature to the chosen value no matter what happens in the bulk, contrary to what I see here. Is that wrong, and if so, why?
Thanks as always for your answer.
Regards,

Cosimo
Yvan Fournier
Posts: 4080
Joined: Mon Feb 20, 2012 3:25 pm

Re: No shear wall

Post by Yvan Fournier »

Hello,

If you force a Dirichlet value, you should get that exact value on the boundary, though this is first converted to a flux, and retrieving the boundary value requires postprocessing using t* and t+ wall values.

Do you use the standard postprocessing at the boundary ? Could you plot the temperature on a plae through the domain ?

Regards,

Yvan
CTrinca
Posts: 32
Joined: Mon Mar 30, 2015 9:19 am

Re: No shear wall

Post by CTrinca »

Hello,

The boundary temperature I plotted is that output by the calculation, with the postprocessing activated in the GUI in Surface solution control. I attached the temperature field on a mid plane. As you see it is rather irregular, and also the time evolution at my monitoring points is unstable. The flow field has a very similar pattern.
You also asked about my mesh: it is pretty regular, my domain is just an annulus meshed with hexahedra. The preprocessor does not find any bad cell.
Thanks again for your support,

Cosimo
Attachments
sliceT.png
Yvan Fournier
Posts: 4080
Joined: Mon Feb 20, 2012 3:25 pm

Re: No shear wall

Post by Yvan Fournier »

Hello,

I'm not quite sure whether the wall temperature postprocessing also works correctly for symmetry BC's, so could you ?

1) test your case using wall laws to see if the postprocessed wall temperature has the same irreguliar behavior or gives you the prescribed value ?

2) if this is not the case, post your case here, with a small version if the mesh if possible.

Best regards,

Yvan
Post Reply