CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

DieselFoam spray

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree2Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 2, 2008, 07:13
Default No, you have misunderstood the
  #41
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
No, you have misunderstood the massFlowRateProfile.

The format of the massFlowRateProfile is
massFlowRateProfile
(
(time1 kgPers1)
(time2 kgPers2)
(time3 kgPers3)
)

If you have injection between time1 and time2
the massflowrate at that time is linearly interpolated.
the first entry is the start of injection and
the last entry is the end of injection.

What you would like to do is something like this
(lets say you want to inject them each millisecond)
massFlowRateProfile
(
(0.0 1.0)
(1.0e-7 1.0)
(1.1e-7 0)

(0.999999e-3 0)
(1.000000e-3 1)
(1.000001e-3 1)
(1.000002e-3 0)

(1.999999e-3 0)
(2.000000e-3 1)
(2.000001e-3 1)
(2.000002e-3 0)

et.c....
);

If you have nParcels set to 20 and the mass corresponds to 20 drops, 1 drop will be injected at t=1.0 ms and then nothing until t=2.0 etc...

clear?
niklas is offline   Reply With Quote

Old   July 2, 2008, 07:23
Default Actually, this is better mass
  #42
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
Actually, this is better
massFlowRateProfile
(
(0.0 1.0)
(1.0e-7 0)

(1.000000e-3 0)
(1.000001e-3 1)
(1.000002e-3 0)

(2.000000e-3 0)
(2.000001e-3 1)
(2.000002e-3 0)

et.c....
);

Another approach is to set up 20 injectors and have each injector injecting just 1 parcel,
thats quite simple since its just to copy/paste and then change the injection time for each injector.
niklas is offline   Reply With Quote

Old   July 2, 2008, 07:56
Default Oh... And you need to be care
  #43
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
Oh...
And you need to be careful so that the area under each injection occasion in the massFlowRateProfile is the same, otherwise the parcels will not contain the same mass.
niklas is offline   Reply With Quote

Old   July 2, 2008, 08:14
Default Thank you again Mr Nordin for
  #44
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
Thank you again Mr Nordin for your incredible patience. I think I understood how the massprofile works and will try to implement your example on my own.
sebastian_vogl is offline   Reply With Quote

Old   July 3, 2008, 13:07
Default Hallo again, I implemented
  #45
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
Hallo again,

I implemented the following massFlowProfile as you suggested, Mr Nordin, however the injector either injects the two parcels right from the beginning or I have 4 parcels in my system. In the latter case the parcels doesn't start from the injector position but from the centerpoint of the geometry which is very confusing, as I didn't tell the injector to do so. The mass for each parcel was reckoned by taking a diameter of 50µm and multiplying it with the density for C7H16 at 320K (662,6874288 kg/m³) using the NSRDS function5. So there should 2 parcels come out of the injector, each at the specified time, but it doesn't happen. Furthermore, when setting the endtime of injection 1 to 1.0e-11 or 10e-9 instead of1.0e-8 the solver stops because the temperature in the system should have exceeded 5000K and the injector pressure was around 100bar. This seems unrealistic because todays diesel enginges inject with 2000 bar and the temperature is far lower. Could you please give me some hints please?

Sincerely,
Sebastian Vogl

unitInjectorProps
{
position (0 0.0995 0);
direction (0 -1 0);
diameter 0.00005;
Cd 0.9;
mass 8.6745581581e-11;
temperature 320;
nParcels 2;

X
(
1.0
);

massFlowRateProfile
(
(0.0 1.0)
(1.0e-8 0.0)

(0.9999999999e-3 0.0)
(1.0000000000e-3 1.0)
(1.0000000001e-3 0.0)
);
sebastian_vogl is offline   Reply With Quote

Old   July 4, 2008, 05:37
Default you are using unitInjector to
  #46
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
you are using unitInjector to inject and
for this case that is not a very good idea, since
massFlowRate and injector diamerer is used to
calculate the injection velocity.

Here's what you probably want.
This is an injection of 20 drops, separated with 0.1 ms.
I am using nozzle diameter to set the diameter of
the drops and a velocityProfile to specify the
drop-velocity, thats why Im using definedInjector instead of unitInjector. In this case I just set it to 100 m/s.

In the case I set the number of outputs pretty close to make an animation
http://files.nequam.se/drops20.avi

(You might want to reduce the elasticity coefficient to not have such a 'bouncy' wall interaction)

http://files.nequam.se/drop.tgz
niklas is offline   Reply With Quote

Old   July 4, 2008, 06:05
Default There is a possibility that yo
  #47
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
There is a possibility that you might experience some weird effects if your drops are too small.

In the file
OpenFOAM-1.4.1/src/lagrangian/dieselSpray/parcel/parcel.C

you have this statement (on line 303)
// remove parcel if it is 'small'
if (m() < 1.0e-12)

You might want to change this to..for example
if (m() < 1.0e-20)

then do 'wmake libso' in the dieselSpray directory.
niklas is offline   Reply With Quote

Old   July 7, 2008, 08:55
Default I now implemented your example
  #48
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
I now implemented your example, however with 5 droplets first. There's quite a difference between our results. My droplets dont't flow in a row, as in your video above, but have an offset. Moreover the last parcels don't seem to fly fast enough, because the can't reach the first ones. My parcels have a diameter of 50µm and a verlocity of 100 m/s (as in your example). I also used the defined injector.

5_droplets.avi.gz
sebastian_vogl is offline   Reply With Quote

Old   July 7, 2008, 09:29
Default Maybe I should mention that th
  #49
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
Maybe I should mention that the velocity of the surrounding air is still 0 m/s and for the drag model the "standartdragModel" is used.
Do you know why our results differ?

Yours,
Sebastian Vogl
sebastian_vogl is offline   Reply With Quote

Old   July 8, 2008, 04:31
Default Have you looked at what spray
  #50
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
Have you looked at what spray angle you have specified in the sprayProperties?
niklas is offline   Reply With Quote

Old   July 8, 2008, 04:45
Default Hello everyone, I wanted to
  #51
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
Hello everyone,

I wanted to repeat the case with the incection of 5 parcels in a row. The solution process, which was done on more processors (solution was parallelised), was completed normally after the specified end time. However during the reconstruction process I got the following error message:

--> FOAM FATAL IO ERROR : IOstream::check(const char* operation) : error in IOstream "/scratch1/aachenBombInjektorvergleich/definedInjector/5_droplets_dt_1e-4/0.0002 3/phi" for operation Ostream& operator<<(Ostream&, const Scalar&)

file: /scratch1/aachenBombInjektorvergleich/definedInjector/5_droplets_dt_1e-4/0.00023 /phi at line 491692.

From function IOstream::check(const char* operation) const
in file db/IOstreams/IOstreams/IOcheck.C at line 54.

FOAM exiting


The strange thing about it is that the file "phi" of time step 0.00023 doesn't have 491692 lines.

Could anyone please tell me what that message means?

Yours,
Sebastian Vogl
sebastian_vogl is offline   Reply With Quote

Old   July 8, 2008, 05:26
Default Hello again, the last probl
  #52
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
Hello again,

the last problem dealing with the reconstruction of a case is now solved. The problem was not caused by OpenFoam but simply that the disc had no place left for writing the time steps.

Yours,
Sebastian Vogl
sebastian_vogl is offline   Reply With Quote

Old   July 8, 2008, 07:45
Default The spray angle I used was 0.0
  #53
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
The spray angle I used was 0.0
sebastian_vogl is offline   Reply With Quote

Old   July 9, 2008, 09:32
Default try removing the words inject
  #54
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
try removing the words
injector1
injector2
injector3

Im guessing you will be back soon after that is solved
niklas is offline   Reply With Quote

Old   July 9, 2008, 09:59
Default As you anticipated correctly,
  #55
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
As you anticipated correctly, I am back very soon. However, removing the entries didn't solve my problem completely. This time the program says:

Constructing Spray
Selecting injectorType definedInjector
Selecting injectorType definedInjector
Selecting injectorType definedInjector
Selecting atomizationModel off
Selecting dragModel standardDragModel
Selecting evaporationModel off
Selecting heatTransferModel RanzMarshall
Selecting wallModel reflect
Selecting breakupModel off
Selecting collisionModel off
Selecting dispersionModel off
Selecting injectorModel constInjector


--> FOAM FATAL ERROR : constInjector::constInjector(const dictionary& dict, spray& sm)
Wrong number of entries in dropletNozzleDiameterRatio#0 Foam::error::printStack(Foam:stream&) in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libOpenFOAM.so"
#1 Foam::error::abort() in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libOpenFOAM.so"
#2 Foam::constInjector::constInjector(Foam::dictionar y const&, Foam::spray&) in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libdieselSpray.so"
#3 Foam::injectorModel::adddictionaryConstructorToTab le<foam::constinjector>::New(F oam::dictionary const&, Foam::spray&) in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libdieselSpray.so"
#4 Foam::injectorModel::New(Foam::dictionary const&, Foam::spray&) in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libdieselSpray.so"
#5 Foam::spray::spray(Foam::volPointInterpolation const&, Foam::GeometricField<foam::vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double,> const&, Foam::GeometricField<double,> const&, Foam::GeometricField<double,> const&, Foam::combustionMixture const&, Foam::PtrList<foam::sutherlandtransport<foam::spec iethermo<foam::janafthermo<foa m::perfectgas> > > > const&, Foam::dictionary const&, Foam::dictionary const&) in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libdieselSpray.so"
#6 main in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linux64GccDPOpt/dieselFoam "
#7 __libc_start_main in "/lib64/libc.so.6"
#8 Foam::regIOobject::readIfModified() in "/home/singh/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linux64GccDPOpt/dieselFoam "


FOAM aborting

Aborted


The only thing I can understand from this message is that I have to change my sprayproperties file for multiple injectors, too. But how?
By the way, do you know why the parcels in my video above leave the injector with an offset, instead of flying in a row?

Thank you once more for your help!
sebastian_vogl is offline   Reply With Quote

Old   July 9, 2008, 10:47
Default You now have more than 1 injec
  #56
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
You now have more than 1 injector.
You have not specified spray angle and drop/nozzle -ratio for the second injector.
Thats what the error message is telling you.
'Wrong number of entries in dropletNozzleDiameterRatio'.

for 2 injectors it would look something like this.
constInjectorCoeffs
{
dropletNozzleDiameterRatio
(
1.0
1.0
);

sprayAngle
(
0.0
0.0
);
}

> By the way, do you know why the parcels in my video above leave the injector with an offset, instead of flying in a row?
Nope.
In my example I set droplet/nozzle=1 and used
the injector diameter to specify drop-size.
The only thing I can think of is that the true injection position is randomly positioned around the injection position within a distance set by the nozzle diameter.

So if you have a large nozzle diameter and use a small drop/nozzle ratio to set the drop diameter you could get that behaviour.
niklas is offline   Reply With Quote

Old   July 9, 2008, 12:37
Default Thank you very much for your h
  #57
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
Thank you very much for your help Mr Nordin! The problem could be solved.
sebastian_vogl is offline   Reply With Quote

Old   July 9, 2008, 13:44
Default The case ran without any probl
  #58
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
The case ran without any problems. However the flow of the droplets isn't uniform again. The droplets of each injector behave differently and again they have an offset in their flow although I set my drop/nozzle ratio to 1 (as I had also done before) and specified the droplet diameter by nozzle diameter. The short movie below shows my results. Collision model and evaporation were set "off" for this case. Droplet velocity was 100m/s. Also interesting is the fact that the latter parcels can't reduce the distance to the first 2 of each injector.


sebastian_vogl is offline   Reply With Quote

Old   July 9, 2008, 14:44
Default I'm sorry, I forgot the video
  #59
Member
 
Sebastian Vogl
Join Date: Mar 2009
Location: Munich, Germany
Posts: 62
Rep Power: 17
sebastian_vogl is on a distinguished road
I'm sorry, I forgot the video of my case. I had to reduce the size dramatically to post it here, but my problems with the droplet behaviour will become clear:

3injectors_10droplets_smallsize.avi.gz
sebastian_vogl is offline   Reply With Quote

Old   July 10, 2008, 03:40
Default gravity? Its impossible for m
  #60
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
gravity?
Its impossible for me to say with the info I have.
Best thing for you would be to attach the case.
niklas is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
DieselFoam Spray Evaporation Continuity Error spv24 OpenFOAM Running, Solving & CFD 14 December 30, 2010 11:50
DieselFoam and ReactingFoam matteo_rosa_sentinella OpenFOAM Pre-Processing 4 September 28, 2009 11:35
Problem in dieselFoam skherad OpenFOAM Running, Solving & CFD 0 July 6, 2006 05:48
Problem in dieselFoam skherad OpenFOAM Running, Solving & CFD 0 July 6, 2006 05:45
About dieselFoam tsjb00 OpenFOAM Running, Solving & CFD 3 August 16, 2005 17:59


All times are GMT -4. The time now is 09:17.