Must I define something in the controlDict?
|
I changed the fvOptions a little bit and now have this error:
Code:
/*---------------------------------------------------------------------------*\ Code:
heatSource I don't use setFields or something like that, because I want to use all cells. Maybe somebody can help me. |
Hi,
This part explains what OpenFOAM is looking for: Quote:
Regards, Tom |
Thanks for your reply tom.
I changed it in fields. Code:
heatSource Code:
Selecting finite volume options model type scalarCodedSource Code:
Code:
Radiation model not active: radiationProperties not found Regards Chris |
Hello all,
I hope somebody can help me with the scalarCodedSource. I tried many things, but it doesn't work and I can't figure out why. my fvOptions file: Code:
heatSource Code:
Thanks for xour help. Regards, Chris |
Morning all,
i solved the problem with the "primitive entry". Maybe somebody can help me with the code. I need 3 zones in z. The first one should be one face of my mesh and for the other two there should be different values for each cell. Regards Chris |
Hy all,
sorry to bother you, but I have a problem. I only want a zone for a heatSource. So I used topoSetDict and cellSet, but in ParaView the whole mesh is used. Here is my fvOptions: Code:
harmonic Code:
actions Can somebody help me or explain me, why this is the result? regards |
Hy All
Can I select the surfaces of my mesh? Because i want to define a source only on the surface of the mesh. regards, Chris |
Instead of a volumetric heat source, I would rather say that you need a heatflux boundary condition on a surface.
Maybe these two bounday condition on the following link can be of help: https://www.cfd-online.com/Forums/op...tml#post583906 If you use the banana trick on fvOptions for scalarSemiImplctSource Code:
energySource Code:
Selecting finite volume options model type scalarSemiImplicitSource I'm not able to figure it out, how manage it on a boundary surface, maybe my thinking is not correct but: try to think you set only a point, with a volumetric heat source on a surface that is a boundary of your computational domain too; then others points what would be, zeroGradient? ok, but how the heat will be transfered? Because other points has zeroGradient so no heat flux along the surface as well as outside of your domain. So you have a heat flux from your heat point on the surface (that belongs to a volumetric cell) toward the center point of the volumetric cell that it belongs to, but as above you're setting a heat flux, not a heat source. Maybe it works for your purpose. You may even think to use thermaBaffles: https://openfoamwiki.net/index.php/F...hermal_baffles https://openfoam.org/release/2-3-0/thermal/ Hope it helps. Regards. |
How to set "injectionRateSuSp" in "scalarSemiImplicitSource"?
2 Attachment(s)
Dear Foamers,
I read through the thread and a few other webpages, and found the following to options in injectionRateSuSp to create a heat source by fvOption with scalarSemiImplicitSource: injectionRateSuSp { T (0.1 0); //DT = PHI''' / (rho * cp) } or injectionRateSuSp { h (0.1 0); //W absolute, W/m3 specific } I wonder which one to choose for chtMultiRegionFoam? I chose the second one get the computation result as shown in the photo. The case with OpenFOAM 4.0 is also attached. It is a long thin cuboid with heat source of 10W and a flat large cuboid lying above. There is no thermal contact resistance between each other. The solid is located in the middle of a closed (noSlip for U boundary condition) and insulated box (zeroGradient for T). Only a quarter is simulated, thus two faces of the computation domain are symmetry, and the internal temperature and velocity field can be observed. I simulated for two seconds, so that 20J heat was generated. However the increase of the total internal energy of the two solid cuboids increased only 5J (taking the temperature of the solids is uniform at the highest temperature in domain, and the thermal properties are given in the case). I wonder where are the other 75% of energy? Is it due to the symmetry boundary condition that only 25% of the heat was generated? Thank you very much for any help in advance! Sitajeje |
I don't think your problem is due to the b.c. Symmetric simply generates a slip boundary and does not expand the region in any way.
Sent from my HTC One SV using CFD Online Forum mobile app |
Hallo Uwe,
thank you very much for your quick reply! I figured out by trial and error that it is the second option is correct: injectionRateSuSp { h (0.1 0); //W absolute, W/m3 specific } It is true that it is nothing to do with the boundary condition. I made the symmetryPlane as Wall, so that it is a complete insulated box. But the temperature is the same, i.e. only 5J emerges in the solid domain, and 15J was missing. Sorry everyone, It was a wrong estimation of the internal energy. I checked with a simpler geometry, it was correct. Sitajeje |
Hi Sitajeje,
First of all, both implementations should give you the same results since the only difference between them is the comment (the characters behind //), so it has no impact on the calculations. Can you, please, upload your fvSolution specification? Or at least tell us the tolerancies you used for enthalpy for all your regions. Convergence is usually very slow in chtMultiregion* solvers and you would need to set a very low tolerance and let the solver run during several iterations. You can use non ortogonal correctors in order to force the solver to take more iterations. Best regards, Alex |
Alex,
thank you very much for your reply! I tried injectionRateSuSp { T (0.1 0); //DT = PHI''' / (rho * cp) } but there was no heat generated. I checked the solveSolid.H in applications/solvers/heatTransfer/chtMultiRegionFoam/solid, and it is written "fvScalarMatrix hEqn" there. I suppose that is the reason. What is your experience? I used the following: h tolerance 1e-7; relTol 0.1 hFinal tolerance 1e-7; relTol 0; Can you download my file? I uploaded it in my last input. The velocity and temperature didn't need many iterations. But the pressure frequently needed 1000 iterations. So I changed the "p_rghFinal relTol" from 0 to 0.01. The results were the same. What is your experience? I didn't understand your comments on tolerance and convergence. Thank you very much in advance! Best regards, Sitajeje |
Question about fvOptions
Hy Foamers,
I work with scalarCodedSource. My solver is buoyantBoussinesqSimpleFoam and I use the version OpenFoam 4.1. I would like to create a volumentric source that uses a constant power. I have deduced from the energy equation that I need the specific power first. This value I then divide by the density rho [kg / m^3] and the heat capacity Cp [J / (kgK)]. By integrating the equation, I would have to multiply this value by the cell volume. My questions are the following: 1. How does the solver handle the fvOptions value? 2. Does the fvOptions(T) function return the calculated value? 3. Is my derivation correct? 4. Is it correct if I use eqn.source() as my variable, if my performance is constant? 5. Can I use this fvOptions also for the solver buoyantBoussinesqPimpleFoam? Thanks in advance for your help. Regards, ChrisBa |
Hello, I hope someone can help me ...
If I want to set a fixed pressure gradient, can I? to a cyclic domain (pipe). Could anyone teach me how to configure these options in my fvOptions? Thanks. |
Coded Source table input
Hi there
I am trying to implement a heat sink through scalarCodedSource using a table of calculated Heat fluxes as my input. Can anyone give me any advice on the implementation of this? I am familiar with using tables to specify boundary conditions but am unsure how to implement them in the source. Any help would be appreciated! |
Hi all,
My case was porous medium with heat transfer. But I only need to generate heat source on wall of the solid body (ie. on surface). Not from fluid body. These are my BC for wall surface which i have to create heat source (at this BC's) wall-mp-1 wall-mp-2 wall-dp-1 wall-dp-2 And I have used cyclicAMI type for interfacing the fluid regions and for measure the pressure values. So I succeed with cyclicAMI, now i have to create a heat source at wall(ie @surface). I need to only check heat distribution from those BC's. Solver i am using is porousSimpleFoam.. Running mpirun -np no.ofprocessor porousSimpleFoam -parallel Now my case is with heat transfer,incompressible fluid, steady state I have an input like heat flux (W/m2) and heat generation (W) value. I am getting this error while running. I know i have to include energy equation.. I don't have an idea about header file creation.. Code:
--> FOAM Warning : https://www.cfd-online.com/Forums/op...tml#post743697 Please correct me what i have to modify in this EEqn.H file Code:
{ Vishsel |
Hi,
I'm trying to import a source term which depends on height of the rode. Code:
z: height (0 to 0.3 meter) Code:
codedSource Code:
Selecting finite volume options type scalarCodedSource Kind regards, |
Quote:
file: constant/MYREGION/fvOptions.codedSource at line 24. [0] [0] From void Foam::codedBase::createLibrary(Foam::dynamicCode&, const Foam::dynamicCodeContext&) const [0] in file db/dynamicLibrary/codedBase/codedBase.C at line 240. |
All times are GMT -4. The time now is 10:48. |