CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Pre-Processing (https://www.cfd-online.com/Forums/openfoam-pre-processing/)
-   -   Channel flow with heat flux (https://www.cfd-online.com/Forums/openfoam-pre-processing/141307-channel-flow-heat-flux.html)

Cara Gao September 4, 2014 12:58

Channel flow with heat flux
 
Hi, openformers,

I am working on a case about channel turbulent flow with fixed heat flux into it, but I didn't find any similar case in the tutorial. I want to set the heat flux directly instead of setting a temperature gradient. Anyone have any suggestion?? An example case will be very helpful!

Thanks,
Best,
Fei

GDTech September 5, 2014 09:17

Hi,

I think this boundary condition should do the job : turbulentHeatFluxTemperature

Code:

myPatch
{
        type            turbulentHeatFluxTemperature;
        heatSource      flux; // flux [W/m2] or power [W] 
        q              uniform 10; // [W/m2] or [W]       
        alphaEff        alphaEff;       
        value          uniform 300;
}

Best regards,
Laurent.

Cara Gao September 8, 2014 15:08

Thanks, Laurent. I also found one quite similar to the one you suggested.
type compressible::turbulentHeatFluxTemperature;
heatSource flux; // power [W]; flux [W/m2]
q uniform 2000; // heat power or flux
kappaName kappa;
kappa fluidThermo;
I tried to use this boundary condition in the T file in a tutorial case called buoyantCavity. And I change the closed system to a open system with an inlet and outlet. However, I got the error message,

#0 Foam::error::printStack(Foam::Ostream&) at ??:?
#1 Foam::sigFpe::sigHandler(int) at ??:?
#2 in "/lib/x86_64-linux-gnu/libc.so.6"
#3 Foam::GAMGSolver::scale(Foam::Field<double>&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, Foam::Field<double> const&, unsigned char) const at ??:?
#4 Foam::GAMGSolver::Vcycle(Foam::PtrList<Foam::lduMa trix::smoother> const&, Foam::Field<double>&, Foam::Field<double> const&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::PtrList<Foam::Field<double> >&, Foam::PtrList<Foam::Field<double> >&, unsigned char) const at ??:?
#5 Foam::GAMGSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ??:?
#6 Foam::fvMatrix<double>::solveSegregated(Foam::dict ionary const&) at ??:?
#7 Foam::fvMatrix<double>::solve(Foam::dictionary const&) at ??:?
#8
at ??:?
#9
at ??:?
#10 __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#11
at ??:?
Floating point exception (core dumped)

It looks like meaningless to me.

Is there any former who knows how to solve for such error message?

Best,
Cara

jherb September 28, 2014 08:11

This error message means that there was a floating point exception (division by 0?) in the GAMG solver. You did not post the full log file so it is not clear which equation failed? p? So very likely you boundary conditions are set up wrong.

Cara Gao September 28, 2014 18:52

Hi, Joachim,
Indeed, you are right. The boundary condition is not right.

Thanks,
Cara


All times are GMT -4. The time now is 00:21.