Inlet - problem with volumetric flow rate

edited March 2021 in DualSPHysics v5.0

Hi,

I would like to ask about settings of inlet condition. In my problem, I have box filled with fluid. At the bottom of the tank is tube that fills the tank, sketch attached. (It's a simulation of weir.)

Inflow is located as pointed in figure. I know volumetric flow rate and diameter of inlet pipe as input data. Buffer was fitted (so particles infront couldn't go backward around the buffer) to inlet pipe and inlet velocity was chosen to satisfy prescribed VFR.

From simulation was obvious, that volume flow is significantly lower than has been set. (Due to knowledge of the real system.) After that observation, three methods have been used to determine actual volumetric flow rate. First of all, I measured velocity in the inlet pipe (as shown in figure), then I added box and measured volume of fluid flowing to the box over the weir and finally I used outlet channel to measure velocity of water flowing away from system to compute volume flow. So I could be pretty sure the volumetric flow rate goes wrong.

I tried to play with inlet velocity and diameter of inlet buffer. (Each time I also changed model, specifically diameter of the pipe, so buffer was fitted perfectly. Square profile was also tried, results are same.) If I used smaller area for buffer with higher inlet

velocity I obtained described volumetric flow rate. But with this solution came other problems like rapids and "air capsules" and I don't think that's ideal way how to solve it.

I tested different inlet options in DualSPH v5 (I tried both refilling options, 1:simple below zsurf, 2:advanced for reverse flows) but the results were even worse then results obtained by v4.4. I noticed same problem also in case of vertically oriented pipe with normal oriented against gravity vector.

With proper velocity and smaller diameter of inlet, I'm able to achieve right volumetric flow rate. But if the diameter of inlet pipe is higher (with adjustment for inlet velocity, buffer perfectly fitted), the VFR drops below set value.

I would like to ask you about some ideas of settings for this type of tasks. Is it something what can be solved with proper inlet settings or is this caused by any incompatibility or something?

I will be grateful for your answers.


Comments

  • So I made a bit of progress.

    There are the results with ver. 4.4, with and without shifting. With filled system as initial condition (boxfill used) and inlet velocity straight to prescribed value lead to the problem described above. BUT with slowly increasing velocity from zero to my desirable value, everything works fine! (Thanks to Dr. Tafuni and discussion in the 5th workshop!)

    Then I used latest version (5.0.3) and found new problems.

    I tried all possible options (simple fill, reverse flow) but result are mostly same (some better, some worse). Then I tried to employ shifting and DT (all possible options), things gets slightly better. (Although some particle goes trough boundaries.) Results usually looks like this.

    Inlet is fitted to the pipe with maximum possible size of buffer. I omitted the geometry, but you can imagine with help of working case. VFR doesn't match either.

    Eventually I found, that with options stf3 DT1/2 results look better, stf3 DT2 even satisfy the desirable VFR.

    Question1: What there is different with inlet compare to previous version? Is there something I'm completely missing or doing wrong? 

    Question2: What Inflow_World means? Should that VF be enters the simulation domain?

    For measurement of VFR, I used flowtool and velocities from measuretool to compute flow trough some flow area. Values obtained from velocities (using mt) agree with prescribed VF value. But doesn't match Inflow_World (Outflow_World) neither Inflow_box (Outflow_Box). Inflow_World (Outflow_World) usually gives higher number then prescribed value. I would like to note, that flow-tool box has unit length. Shouldn't be values of VFR through all cuts (using flowtool) same, with constant inflow? Why is there difference? (Values obtained from velocity remains constant in all cuts.)

    Thank you for your advices and hints. Next, I want to look at mDBC and 2D case, but I decided to ask at first place. If you are interested, I can send you full overview of my tests of inlet performed with v4.4 and v5.0, with try to set my problem.

  • Dear @TomasCTU I would suggest to send email to Angelo Tafuni and José Domínguez directly to ask for these problems.

    They can explain better what is different in v5.0 compared with previous version.

    Jose can also explain to you better the output information from FlowTool

    REgards

  • Hello @TomasCTU

    I'm having a similar problem. If you can solve it or have progress, could you share it in the forum?

    And could you attach the XML file of the best version?

    Greetings

    Pablo

  • edited December 2021

    Hi @pschiesa ,

    I'm going to try summarize some thought. I also had asked Dr. Tafuni about this problem so I'll add his points to the topic.

    Best result I have obtained are accomplished with DualSPHysics v4.4. BUT! It's necessary to start with slow inlet velocity and then run up to desirable value otherwise I had problem to obtain predescribed volume flow. 

    (Angelo pointed out, that is not good idea to start from zero velocity, it's better to start with some small value. I have to admit, I have not try this yet, maybe it could help with the problem in version 5.x.)

    In 4.4., with shifting it's also fine, but with option "full", there is some fluid going through the walls. (You can see on original picture.) With version 5.x I wasn't able to obtain some satisfying results. (And I tested almost all combinations of settings.)

    In the case of flooded inlet, you need to set "imposerhop=2". Angelo also recommend to set determinant value of "deterlimit = 1e-3" to obtain ghost node pressure with second order accuracy. (Actually, he recommended to try "imposerhop" with both, 1 and 2 and "deterlimit" with 1e-3 and 1e+3 as I did.)

    I played with all possible combinations and the best results are these you can see. With full shifting (opt 3) I was able to obtain desirable volume flow, but some of the fluid goes through wall (last picture of pipe in post above).

    Some of the next point from the response:

    • "Keep in mind that the buffers are sensitive to the flow initial conditions, so large gradients will likely give you trouble. It should be ideal to start with small velocity and set the same velocity as initial condition. The best way however would be to patch your velocity domain so to have a fluid velocity that matches the inlet's in the vicinity of the inlet, and goes to zero gradually near the walls."

    I have to admit I tested initial condition only with fixed value and not with velocity profile. Due to imported geometry I haven't used mDBC. (I did some 2d test case eventually, but did not finish it out. Maybe one should start here.) I would like to send you some .XML, but in DualSPHysics v4.4. works almost everything and in newest version I dont have any good enough.

    Summary:

    • In ideal world, you want to use mDBC, start with very slow velocity, then ramp up and set velocity profile for the inlet. You also want to ensure to consistency with velocity of initial condition. In the settings should be "imposerho=2" (opt 1 could also wok) and "determlimit=1e-3".

    In ideal world, I would have already tried all these things myself. But, but... 

  • Just a comment; I am not doing these kind of simulations my self, but I have found this thread really interesting and highly beneficial, thanks for taking the time to write this out and document your interaction with Tafuni.

    To me it seems there is still some way to go for the SPH methodology to reach a satisfactory level in modelling fixed in- and outlet, compared to finite volume method atleast.

    Kind regards

  • I agree. Thank you very much for your contribution!!! 
    I will follow your recommendations, both with 4.4 and 5.0.4
    Kind regards
    


  • Hello @TomasCTU,I import the STL model of the pipe and simulate the inflow and outflow, but there are also particles passing through the wall. How do you solve it? Is it better to increase the inlet speed from a small value rather than a fixed value? In addition, how can external STL models use MDBC, we cannot use "layers vdp = " on STL.

    Best regards.

  • edited April 2022

    @liyt54299

    Hi, I would need to know more details. I didn´t have problem with particles leaks over walls unless shifting was employed. Although if your inlet points into backpressure, there could be problems like that.

    Its always better to increase inlet speed from fixed value. Inlet velocity profile would also help. Optimal way is patch the velocity profile for the inlet. Moreover, the fluid velocity in the domain should be consistent with the inlet in case of pipe. I know, sometimes you don't want that, but I am afraid here we are limited with robustness of the inlet realisation.

    About the mDBC and stl geometry, you can check this:


    Please, take my statements with reserve. Although I played with DualSPHysics inlet A LOT (I even did my own implementation of the bufferzones to check where could be the problem), there are many trick hidden. But if you send me details, I can try some ideas.

Sign In or Register to comment.