[Lagrangian] Injection Model Start of Injection timestep Mistake?
Hi everyone,
[OF 2.2.2] Looking at the lagrangian injection Model : InjectionModel.C, I find in the membre function PrepareForTheNextTimestep something I don't Understand : // Make times relative to SOI scalar t0 = timeStep0_ - SOI_; scalar t1 = time - SOI_; In my mind, because timestep0_ is the last time step, so the first delta Time between current time and SOI is miss, indeed function parcelsToinject require t0 > 0 so in my mind, if SOI = 0.5 at first step time =1 (dt=1) timeStep_0=0 so t0=-0.5 so no parcel to inject ... [But we want to inject parcel, no?] at second step time time =2 timestep_0 = 1 so t0 = 0.5 and t1 = 1.5 so inject parcel give us t1-t0 = dt =1 But we have forget the first par of injection from SOI = 0.5 to time =1 Is it right? Where is my missunderstanding? If someone can enlighten me, it will be great! Have a nice day! |
Has anybody looked into this? InjectionModel seems good, but the derived injection model's parcelsToInject disallows time0<0 as you noted Emeline.
e.g. I am using coneNozzleInjection with SOI = 10.010. See log file, the first injection time step 10.0101 is missed...!? May be a bug? (albeit minor I suppose!) Quote:
|
The answer to your question should lie in the call to parcelsToInject function in one of the InjectionModel derived classes as opposed to looking at the base class.
For example, take a look at the PatchFlowRateInjection derived class. You'll see that the parcesToInject() function won't necessarily return a positive value even if t>SOI. Here it introduces some randomness to the injection process while still meeting the concentration criteria you set in the kinematicCloud dictionary. My understanding is the purpose is to remove a timestep dependency to the injection rates. I actually think its a pretty clever implementation. I hope that helps! Cheers, Kyle |
All times are GMT -4. The time now is 16:08. |