Configuration of boundary conditions and fvOptions file
Hello everyone,
I am implementing the chtMultiRegionSimpleFoam. My geometry consists of three solid regions (Hot, Cold and Pipe). Hot box and Cold box are connected using pipe between them. I am making one box hot by generating the heat source using fvOptions file. My fvOptions file is given below: Code:
heatSource According to my understanding the power that I am putting in the fvOptions file (h (1000 0)) is related to the temperature change by the formula below: Q = k*A*(delta T)/L where A is the area of the pipe, k is thermal conductivity and L is the length of the pipe, and delta-T is the temperature gradient. when I put the power as Q in the above relation, it doesn't give me the same temperature gradient as I got in simulation. I don't know where is the mistake OR what I am doing wrong? I have checked various threads on this forum about using fvOptions, and most of them are saying that you can put directly your power in fvOptions like I did above. After checking all the possibilities I deduced that there might be a problem with my boundary conditions. I am giving my changeDictionaryDict file of all the three regions below: Cold box Code:
T Pipe Code:
T Code:
T Do I have any problem with the boundary conditions? OR fvOptions file? I would be really thankful if someone can figure out where is the mistake. I would be glad to give any further information if required. Thank you |
h(1000 0) with volumeMode absolute means there is a h (energy) source of 1000 W in every cell. That means you have to add up 1000 W times the number of cells affected. You also used selectionMode all which means every single cell in your domain has this heat source (including the cold box).
How do you calculate Q from h (1000 0)? You are specifying Power per cell, not total power. And are you sure you want to apply the source to all cells? |
Thank you so much for your reply.
I am sorry I am new to openfoam... I want to make only my hot box a heat source (Does it mean that all the cells of hot box will have a separate heat source?). and I have a power of 1000W but I exactly don't know that how to introduce that power into fvOptions file (or how to configure fvOption) file for it, so that I can be sure that my temperature gradient in the pipe is relating to the power I have given... I didn't calculate the power from Q, I just want to create a heat source that takes this power (1000W) as input and gives temperature as output, and that temperature will be transferred to cold box through pipe. But exactly don't know how to achieve it. |
1 Attachment(s)
Here is the result of the simulation, when I run my case.
|
You want a total power of 1000 W, but right now you are specifying 1000 W per cell.
You are using selectionMode all; Use selectionMode cellSet; or selectionMode cellZone; and then specify the proper cellSet or cellZone representing the hot region. volumeMode absolute; specifies the raw heat source in W. volumeMode specific; specifies the volumetric source in W/m^3. Probably volumeMode specific is closer to what you want. You need to know the total volume of the hot region to figure out what number to specify. |
I have edited my fvoptions file like this:
Code:
heatSource Code:
Adding fvOptions Code:
Quote:
Code:
Solving for solid region Cold Now I just want to verify this temperature change by hand calculation. |
You've specified 1000 W/m^3 over a volume of 900 000 m^3. That's not a Q of 1000W but 900 MW!
Also, does 900000 m^3 sound like the right volume for your hot box? Maybe you forgot to scale the mesh at some point? |
1 Attachment(s)
Thank you so much.
Quote:
And if I put the value of "h" as (0.001 0) then the simulation looks like in the attached image. Quote:
My volume is so high because my hot box dimensions are 300m*300m*10m. |
Hello LuckyTran,
My version of OpenFoam is 4.1. I have one question. I have searched alot on this forum and almost everywhere else. No one even encountered this error. Probably, I am doing a very stupid mistake. I am using topoSetDict to make a faceSet from a patch, and then I want to make cellSet using that faceSet. My topoSetDict file is given below: Code:
actions Code:
Create time Code:
--> FOAM FATAL ERROR: Thank you |
If you're only applying the heat source to the cells that are adjacent to a patch anyway... why not just use a heat flux boundary condition instead of trying to jack the volumetric heat source?
Maybe post what you did to get to the error. Some context would help.... I see that the error is complaining you're trying to assign cell number 8200 to the set hotcell and it can't because there are only 6396 cells and cell 8200 doesn't exist. I have no idea under what circumstances this can happen without some clues. |
2 Attachment(s)
Hi..
Thank you so much for your reply. Actually I am making heat source using fvOptions, and I am putting power in fvOptions to generate heat source. Now I want to have a heat source on one face. For that I created a faceSet. as you can see below in the figure (red face) Then I made cellSet from that faceSet. But that is something different. it is the red face with some triangular cells with it. you can see in the figure also. My problem is that I just want one face of a solid to be a heat source using fvOptions, and fvOptions should take power as a parameter. |
Hi,
I am attaching dropbox link to my case also, If you can find time to have a look, I would be highly thankful. Thank you so much. https://www.dropbox.com/sh/3fy3k575f...MLiNQ-WOa?dl=0 |
Quote:
Yes I understand that, hence my complaint. A heat source on a face is just a heat flux. The heat flux BC is wayyy easier to do. Why not just do that? You need to stop trying to make up your own language because that makes it really hard for anyone trying to help you because they don't know your language. Cells are not faces and faces are not cells! Let me tell you what you are doing... You marked the faces on your patch. You then marked the cells that are adjacent to this patch. You created a cellSet of the cells adjacent to the patch. These are cells, with volumes, not faces. You are now generating a heat source in this cellSet... which is not the same adding heat through faces. You can never apply a volumetric heat flux through a face. I'm not going to open your files. If you can't find the time to explain what you did, I am unwilling to spend the time to look at them. More importantly, I have no freakin clue what commands you type into the terminal to encounter the errors. |
Thank you for your reply.
I am sorry I am asking you this. but I don't have so much experience in Openfoam. Can you please guide me a little about how can I use heatflux BC on one face? Can I use the power of 65 W to give heat flux boundary condition on one face? Thank you |
I am sorry to annoy you with wrong language here. I am new to OpenFoam and hence not very familiar with the names.
Also, I realized that it was a wrong way to make a cellSet from the faceSet. I sent you my files because I felt I was unable to explain my problem correctly. I will try to explain you as good as I can. 1. I created a geomerty with 3 regions: i) hot , ii) cold and iii) pipe in salome. 2. In region "hot" , I defined a face called hotFace. 3. Now I import this geometry as unv file in openfoam. and ran Code:
ideasUnvToFoam heatTransfer_new.unv Code:
topoSet Code:
actions Code:
splitMeshRegions -cellZones -overwrite | tee log.splitMeshRegions 8. Based on the boundary file inside constant/region_name/polyMesh folder, I changed the changeDictionaryDict file. 9. I added fvOptions file in region "hot" which is given below: Code:
heatSource Code:
#!/bin/sh I tried my best to explain my problem here. Please let me know if you can't understand something. Thanks a lot for taking out time for this. |
Ok but at which point do you get the error.... You actually gave me an all run script and are asking me to find it?
|
Thank you for your reply.
I am getting this error when fvOption tries to select finite volume options. But if I am unable to explain it, I am attaching the error log below: Code:
Adding fvOptions Thank you |
All times are GMT -4. The time now is 16:36. |