|
[Sponsors] |
SprayFoam, vapor penetration shorter than the liquid penetration |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
June 13, 2018, 10:13 |
SprayFoam, vapor penetration shorter than the liquid penetration
|
#1 |
New Member
heruitian
Join Date: Jun 2018
Posts: 6
Rep Power: 8 |
Hi,
I am trying to simulate the n-dodecane evaporation based on sprayFoam in OF. The ambient temperature and pressure is 900K, 3.96MPa respectively. With the C12H26 file in each time documents, I define the vapor penetration just like the definition in other commercial software(converge). But the vapor penetration is shorter than the liquid penetration in the initial time,about 0.3ms. It's unacceptable in the experiments. I wonder if there're mistakes in the definition of vapor penetration or the problems of the setup values, such as KHRT parameters in OF,which can let the droplet evaporate faster in the initial time? Also, I try to add ORourke model, distortedspheredrag model. But the problem is still there. Could anyone give me a hand? I will be really grateful. Thank you! |
|
June 13, 2018, 21:40 |
|
#2 |
Senior Member
Yan Zhang
Join Date: May 2014
Posts: 120
Rep Power: 12 |
Can you show your code about vapor penetration?
__________________
https://openfoam.top |
|
June 13, 2018, 22:18 |
|
#3 |
New Member
heruitian
Join Date: Jun 2018
Posts: 6
Rep Power: 8 |
Dear zhangyan,
Thank you for your reply. I want to upload the definition document but the problem is that I don't define it in OF. So it's not convenient to understand. Can I explain it for you with the core code? The definition of the vapor penetration is "maximum distance from the nozzle outlet to where the fuel mass is 0.1%" by Sandia lab. Actually I output the center of meshes and write a really simple script outside OF to read the "c12h26" document. The code searches the values which are larger than 0.001 in "c12h26", and find the relative positions in "mesh center.txt". At the end, the farthest position is obtained by each "c12h26" document, which is the vapor penetration. Here is the core code. If I cannot explain it clearly, please let me know. Thank you very much! if float(lines[22+i])>0.001: if y[i]>max_y: max_y = y[i] f_.write(iter+','+str(max_y)+'\r\n') f.close() f_.close() |
|
June 13, 2018, 22:26 |
|
#4 |
Senior Member
Yan Zhang
Join Date: May 2014
Posts: 120
Rep Power: 12 |
I think you are right. But I cannot find what the trouble is.
Here is my codes for outputting vapor penetration in OF solver. I hope it helps. Code:
const dictionary& subModelDict = parcels.subModelProperties(); vector position = subModelDict.subDict ( "injectionModels" ).subDict("model1").lookup("position"); vector direction = subModelDict.subDict ( "injectionModels" ).subDict("model1").lookup("direction"); scalar vaporPenetration(0); const word fuel(thermo.lookup("fuel")); const label fuelIndex(composition.species()[fuel]); forAll (Y[fuelIndex],cellI) { if (Y[fuelIndex][cellI] >= 0.001) { vector raw = position - mesh.C()[cellI]; if (mag(raw&direction) > vaporPenetration) { vaporPenetration = mag(raw&direction); } } } reduce(vaporPenetration, maxOp<scalar>());
__________________
https://openfoam.top |
|
June 13, 2018, 22:52 |
|
#5 |
New Member
heruitian
Join Date: Jun 2018
Posts: 6
Rep Power: 8 |
Hi zhangyan,
I wonder if there is the problem in the "spraycloudsproperties/injectionmodel/flowtype". I use both the "pressureDriven velocity" and "flowrateanddischarge" respectively. The phenomenon that the liquid penetration is larger than the vapor one is not so obviouly with the "pressureDriven velocity" type. Thank you! |
|
August 29, 2018, 15:41 |
|
#6 |
New Member
Will
Join Date: Aug 2018
Posts: 2
Rep Power: 0 |
Hello,
thank you zhangyan for showing us your code. I am also using sprayFoam to simulate a n-heptane injection and want to examine the vapor penetration. The problem is that i'm using the coneNozzleInjection model, where the parcels are sprayed in an angle to conical shape and this direction at which i want to measure the penetration is not identical with the nozzle direction. I already tried to specify the vector as the injection direction but this didn't work well. Does anyone have an idea how to output the vapor penetration in this case? Thanks in advance! |
|
August 18, 2020, 11:15 |
|
#7 |
New Member
Roman Reinhardt
Join Date: Jun 2020
Location: Germany
Posts: 4
Rep Power: 6 |
Hi guys,
I want to extract the vapor penetration length of a n-heptane injection as well, post simulation (sprayFoam). My goal is to get VPL along the axis of injection. So basically I want to do the same as heruitian described above. But I cannot make out how to extract the values for the center line of my mesh, which is also the injection axis (x-axis). My time directories contain a "C7H16" file each, which contains the values of the volScalarField for each cell. But which cell has which position? I hope some of you guys can help the little OpenFOAM-Newbie that I am. Thank you. Greetings, Roman |
|
August 19, 2020, 05:18 |
|
#8 | |
Senior Member
Yan Zhang
Join Date: May 2014
Posts: 120
Rep Power: 12 |
Quote:
https://github.com/ZhangYanTJU/ZYsprayFoam
__________________
https://openfoam.top |
||
August 20, 2020, 11:58 |
|
#9 | |
New Member
Roman Reinhardt
Join Date: Jun 2020
Location: Germany
Posts: 4
Rep Power: 6 |
Quote:
thank you for your reply. Basically I know what I have to do, but my problem still is to understand where the connection between the scalarfield of my fuel and the cell vectors/coordinates is made. I can't see any links there in my case data. Which entry from the fuel scalar field belongs to which cell? From your code: if (Y_fuel[cellI] >= 0.001) { vector raw = position - mesh.C()[cellI]; if (mag(raw&direction) > vaporPenetration) { vaporPenetration = mag(raw&direction); I don't understand how I can make that link between my values and the position/cell in my mesh. I almost feel like if I'm missing some data there. Can you give me some more information about that? I really want to understand the background instead of just using your solver. Thank you, Roman |
||
Tags |
evaporation, penetration, sprayfoam |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Extracting Liquid Penetration Length | ahcai007 | OpenFOAM Running, Solving & CFD | 15 | April 18, 2022 10:01 |
Fluctuating Liquid Penetration for Wedge sprayFoam | ahcai007 | OpenFOAM Running, Solving & CFD | 15 | March 22, 2018 03:53 |
Liquid penetration length | a.elwardany | FLUENT | 0 | March 28, 2015 05:11 |
Add liquid length to sprayFoam solver | ENKIME | OpenFOAM Running, Solving & CFD | 0 | May 14, 2014 14:11 |
ploting liquid penetration | mooyii | OpenFOAM | 2 | September 9, 2011 19:24 |