|
[Sponsors] |
January 22, 2014, 05:57 |
sprayEngineFoam (dieselEngine)
|
#1 |
New Member
Devayan Bir
Join Date: Jul 2013
Posts: 15
Rep Power: 13 |
I am trying to sinulate diesel engine in sprayEngineFoam but my simulation keeps crashing.
Foam fatal error: Integrating outside table 0..0.00583333 not implemented. t:0.00582967 t2:0.00583337 I suppose this has to do something with my mass flow profile. please advice |
|
January 22, 2014, 13:00 |
|
#2 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
See this bug report: http://www.openfoam.org/mantisbt/view.php?id=837#c2190
|
|
January 23, 2014, 03:05 |
sprayCloudProperties
|
#3 |
New Member
Devayan Bir
Join Date: Jul 2013
Posts: 15
Rep Power: 13 |
I read the bug report but I still can't understand the injectionmodel section of the sparycloudproperties.
I can't figure out how to make the flow rate profile. how do I specify intake temperature ? How to calculate the no, of parcels and the mass. please advice |
|
January 23, 2014, 19:15 |
|
#4 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
Just add an extra line to the flow rate profile as described in the bug report. Temperature is specified in constantProperties, mass is set as massTotal and the parcels are specified by parcelsPerSecond (these are all in the injectionModel submodels).
|
|
January 24, 2014, 08:35 |
|
#5 |
Member
Ayhan Eses
Join Date: Mar 2009
Posts: 35
Rep Power: 17 |
Code:
... Selecting injection model coneNozzleInjection Constructing 3-D injection Selecting distribution model RosinRammler --> FOAM FATAL ERROR: Integrating outside table 0..0.000666667 not implemented. t1:0 t2:0.00111111 From function linearInterpolationWeights::integrationWeights(..) in file interpolations/interpolationWeights/linearInterpolationWeights/linearInterpolationWeights.C at line 180. FOAM exiting sprayCloudProperties Code:
... injectionModels { model1 { type coneNozzleInjection; SOI -178; // to just try massTotal 1.14e-6; parcelBasisType mass; ... duration 5; position ( 0 0.0005 0.109 ); direction ( 0 0 -1 ); parcelsPerSecond 20000000; //crank angle ?? //mass flow ?? // i put values random. flowRateProfile table ( (0 0.5) (1 1) (4 1) (4.5 0.5) (5 0) (1000 0) ); ... In aachenbomb case, left column is time (seconds) flowRateProfile table and the right is massflow rate (kg/second i suppose) In a sprayEngineFoam case, is left column enginetime (CAdegree) flowRateProfile table and the right massflow rate (kg/second i suppose) ? How can i calculate injected fuel mass while i create a flowRateProfile table ? rpm 1500 1 min 360 degree 25 1 seconds (ave.) 1 degree 0,069444444 1 seconds (ave.) degree kg/s ?? injected fuel kg (-178) 0 0,5 (0,06944444*0,5) 0,034722222 Thanks in advance. sorry my english |
|
January 24, 2014, 13:21 |
|
#6 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
If you look at the code of the spray classes in the Lagrangian library (which I highly recommend) the flow rate profile is in crank angle degrees. However, what happens is that the rate is integrated, normalized and scaled so that it starts at SOI, lasts for the duration and injects the mass specified.
|
|
October 14, 2014, 05:49 |
|
#7 |
New Member
Mateus Dias Ribeiro
Join Date: Jun 2013
Location: Guaratinguetá, Brazil
Posts: 20
Rep Power: 13 |
Hi Marco,
just to be sure if I got your last answer right. If I want to inject 8.8 mg (8.8 E-6 kg) of isooctane in the engine during 30 CAD, lets say with SOI at 210 CAD before TDC and just for simplicity with constant mass flow rate during the entire injection duration. So my sprayCloudProperties should look like this: type coneNozzleInjection; SOI -210; massTotal 8.8e-6; parcelBasisType mass; injectionMethod disc; flowType flowRateAndDischarge; outerDiameter 0.001; innerDiameter 0; duration 30; position ( 0 -0.0062 0.00719 ); direction ( 0 0 -1 ); parcelsPerSecond 1000000; flowRateProfile table ( (0 2.933e-7) (30 2.933e-7) ); As you can see, I calculate the mass flow rate dividing the total mass (8.8 E-6 kg) by the entire injection duration (30 CAD). So 8.8 E-6 / 30 = 2.9333 E-7. Is that right? I looked the tutorial aachenBomb (sprayFoam) and there the injection duration is 1.25e-3 s and the mass total 6e-6 kg, giving an average mass flow rate of 4.8e-3 kg/s. If you look the flowRateProfile table, which is not constant, you find values in an order of magnitude 1000 times bigger, giving me the impression that in the table the mass flow is given in g/s. So in the case of sprayEngineFoam it should be given in g/CAD. That means I would have a massFlowRate of 2.933e-4 instead of 2.933e-7. Did I get it right? Thanks in advance, Mateus |
|
October 14, 2014, 06:59 |
|
#8 |
Member
Ayhan Eses
Join Date: Mar 2009
Posts: 35
Rep Power: 17 |
in my opinion below code is enough
if your injection profile is uniform same amount fuel per CA degree 8,8/30=0.2933 Code:
massTotal 8.8e-6; duration 30; flowRateProfile table ( (0 0.2933) (1 0.2933) (2 0.2933) (3 0.2933) (4 0.2933) (5 0.2933) (6 0.2933) (7 0.2933) (8 0.2933) (9 0.2933) (10 0.2933) (11 0.2933) (12 0.2933) (13 0.2933) (14 0.2933) (15 0.2933) (16 0.2933) (17 0.2933) (18 0.2933) (19 0.2933) (20 0.2933) (21 0.2933) (22 0.2933) (23 0.2933) (24 0.2933) (25 0.2933) (26 0.2933) (27 0.2933) (28 0.2933) (29 0.2933) (30 0) (1000 0) ); |
|
October 14, 2014, 08:21 |
|
#9 | |
New Member
Mateus Dias Ribeiro
Join Date: Jun 2013
Location: Guaratinguetá, Brazil
Posts: 20
Rep Power: 13 |
Quote:
Thanks in advance, Mateus |
||
October 15, 2014, 10:23 |
|
#10 | |
Member
Ayhan Eses
Join Date: Mar 2009
Posts: 35
Rep Power: 17 |
i get same errors. i don't know these answers sorry.
I use foam extend 3-1(FE31) dieselEngineFoam There is nParcels instead of parcelsPerSecond in FE31 I try to handle with trial and error mass nParcels 2 mg 15000 7 mg 30000 12.81889832e-6 35000 16 mg 50000 (these values work on my case) i suppose it depends on mesh quality (SOI value if near the TDC the problem occurs due to cell size becomes smaller) and hardware (memory ram) i think we can not inject many parcels in a short range. to reduce deltaT (controlDict) to reduce flowRateProfile time step may be solve the problem 8.8/120=0.07333 flowRateProfile table ( (0 0.07333) (0.25 0.07333) (0.5 0.07333) (0.75 0.07333) (1 0.07333) (1.25 0.07333) (1.5 0.07333) (1.75 0.07333) (2 0.07333) * * * (30 0) (1000 0) I really wonder these answers. Quote:
i hope more professional helps come. best regards. |
||
October 15, 2014, 14:03 |
|
#11 | |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
Quote:
Code:
( (0 2.933e-7) (30 2.933e-7) (30.1 0) ); Code:
( (0 1) (1 1) (1.1 0) ); As for parcels, the more you have the better your spray characterization, though it will slow down your simulation. Having the right mesh density also helps. Last edited by mturcios777; October 16, 2014 at 14:05. Reason: Formatting |
||
October 16, 2014, 05:11 |
|
#12 |
New Member
Mateus Dias Ribeiro
Join Date: Jun 2013
Location: Guaratinguetá, Brazil
Posts: 20
Rep Power: 13 |
Thank you Marco and Ayhan for the very clever answers!
I am running the intake stroke at the moment. I will use your suggestions for the injection and come back to tell the results! |
|
June 16, 2015, 06:31 |
Diifferent numbers of particle injection?
|
#13 |
New Member
Mamadou Camara
Join Date: Mar 2015
Posts: 12
Rep Power: 11 |
Dear Foamers,
I'm currently working with the solver iconUncoupledKinematicParcelFoam (lagrangian). I need to inject a different number of particles at each time step. I'm currently using the model "patchInjection" in the file kinematicCloudProperties. The problem is, I dont know how to make the number of particels vary. Is there a way to force the number of particles to vary by wether providing a table (for number of particles vs. time) or as a function? Any suggestions, ideas are very welcome. Please, my master thesis depends on this. Regards! Mamadou. |
|
May 3, 2018, 07:03 |
|
#14 | |
New Member
Shailja
Join Date: Nov 2017
Posts: 16
Rep Power: 9 |
Quote:
Can anybody please explain how flowrate profile is written in spraycloud properties of sprayFoam injectionModels { model1 { type coneNozzleInjection; SOI 0; massTotal 6.0e-6; parcelBasisType mass; injectionMethod disc; flowType flowRateAndDischarge; outerDiameter 1.9e-4; innerDiameter 0; duration 1.25e-3; position (0 0.0995 0); direction (0 -1 0); parcelsPerSecond 20000000; flowRateProfile table ( (0 0.1272) (4.16667e-05 6.1634) (8.33333e-05 9.4778) (0.000125 9.5806) (0.000166667 9.4184) (0.000208333 9.0926) (0.00025 8.7011) (0.000291667 8.2239) (0.000333333 8.0401) (0.000375 8.8450) (0.000416667 8.9174) (0.000458333 8.8688) (0.0005 8.8882) (0.000541667 8.6923) (0.000583333 8.0014) (0.000625 7.2582) (0.000666667 7.2757) (0.000708333 6.9680) (0.00075 6.7608) (0.000791667 6.6502) (0.000833333 6.7695) (0.000875 5.5774) (0.000916667 4.8649) (0.000958333 5.0805) (0.001 4.9547) (0.00104167 4.5613) (0.00108333 4.4536) (0.001125 5.2651) (0.00116667 5.2560) (0.00120833 5.1737) (0.00125 3.9213) (0.001251 0.0000) (1000 0.0000) ); Here it is mentioned in theabove post that it the second entry given is in terms of crank angle. Please clear it how to convert mass flow rate into cranck angle related flow rate. regards Shailja |
||
May 3, 2018, 14:04 |
|
#15 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
The flowrate profile is used to determine how much mass should be introduced into the domain for a given time. What matters more is the shape of your profile, rather than the actual magnitudes. The total mass that needs to be injected is set by massTotal. The profile you give is normalized and scaled such that is lasts as long as you specify in duration. This functionality for coneNozzle injectors was probably implemented to make it easy to change the mass injected with just one entry rather than recalculating the profile.
Note that the parcel velocity is set by the flowType, which can be either constant, pressureDriven and flowRateAndDischarge. Only flowRateAndDischarge and pressureDriven. pressureDriven will calculate the velocity using the Bernoulli equation, based on the pInj entry. pInj can be a constant or specified with a table. |
|
May 7, 2018, 02:32 |
|
#16 |
New Member
Shailja
Join Date: Nov 2017
Posts: 16
Rep Power: 9 |
Thanks for quick reply Marco !
So the flow rate Table defines a particular way of mass injection profile w.r.t time and it depends on plnj entry, but I am sorry i dont understand what quantity is plnj ? I found a post in which Niklas has mentioned that second entry in flow rate table is kgPers (DieselFoam spray). I understood this as kg-Parcel/s i.e. mass of 1 parcel multiplied by no. of parcels injected in that specfic time period, is this right?? I doubt that because when I try to back calculate with normalizing the nos. given in the Table by dividing every no. in table by Parcel/s to get total injected mass which is 6.0 mg, but I get 10.6 mg. what is I am doing wrong.... I am sorry for inconvenience but I am really stuck at this point. regards Shailja |
|
May 7, 2018, 14:03 |
|
#17 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
No problem. The thread you are referencing refers to the older version of the lagrangian libraries, which are different after version 2.0.
You have also misinterpreted the kgPers. What this entry is is kg/s. The parcels per second is an upper limit on the number of parcels that can possible be injected per second during your simulation. Explaining this would require a deep dive into the coneNozzleInjection class. For the moment just try integrating the flowRateTable as it is and see if you get 6.0 mg. What you can also do is run the provided tutorial and look at the logFile to see that the injected mass is indeed 6 mg. As further confirmation, try changing the mass flow rate and see if the injected mass changes; you should see that as long as massTotal is constant, the total injected mass will always be the same (this is because we've set the parcelBasis to mass). |
|
November 19, 2020, 15:19 |
|
#18 | |
Member
Join Date: Mar 2019
Posts: 81
Rep Power: 7 |
Quote:
I am trying to simulate a pure pressure driven flow through a nozzle using speayFoam in OpenFoam1812. Imagine there is a nozzle between a large body of pressurized liquid and low pressure vapor on the other side. I would like to obtain the mass flow rate through the nozzle. Here is the relevant info from sprayCloudProperties file: Code:
injectionModels { model1 { type coneNozzleInjection; SOI 0; massTotal 1e-5; parcelBasisType mass; injectionMethod disc; flowType pressureDrivenVelocity; Pinj constant 1e6; outerDiameter 2e-4; innerDiameter 0; duration 50e-3; position (0 0.5 0); direction (0 -1 0); parcelsPerSecond 20000000; flowRateProfile constant 1; I really appreciate your thoughts on this. Regards, MJ |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
sprayEngineFoam problems in 2.2.x | mturcios777 | OpenFOAM Running, Solving & CFD | 9 | June 25, 2013 17:44 |
Tutorial for sprayEngineFoam | ed_teller | OpenFOAM Running, Solving & CFD | 4 | May 27, 2013 08:03 |
sprayEngineFoam - floating point exception error | ris | OpenFOAM Running, Solving & CFD | 3 | May 27, 2013 08:01 |
sprayEngineFoam crashes in parallel OF-2.1x | Peter_600 | OpenFOAM | 5 | March 21, 2013 18:47 |
SprayEngineFoam - multiple injections | ris | OpenFOAM Running, Solving & CFD | 2 | January 4, 2013 13:10 |