DPMFoam - Serious Error --particle-laden flow in simple geometric config
1 Attachment(s)
Dear Foamers,
I am currently studying multiphase flows in very small geometric configurations using OpenFOAM. I am quite new with OpenFOAM and thought of tryinng DPMFoam:). My goal is to simulate particle-laden laminar flow in the following geometry (G5.png). I have designed the geometry and mesh in ANSYS Fluent, after which I converted the case file to OpenFOAM format and then ran numerical simulations in OpenFOAM. The properties of the computational domain and particles are: 3 mm by 1 mm. Inlet velocity at 1 mm/s. Fluid: Air. Laminar Flow. Solid Particles are Polystyrene. Moreover, I've modified the 0, constant, & system files as follows: kinematicCloudProperties: Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
/*--------------------------------*- C++ -*----------------------------------*\ After running DPMFoam I get the following error...the solution diverges and the time-step continuity errors/Courant number gets extremely large after every iteration executed, as well as the linear momentum and energies! I highlighted these errors in red. I initially thought I input the incorrect particle properties but that wasn't the case. So I suspect it's to do with the properties in KinematicCloud file. I 'm not sure if I've input the correct details in "injectionModels". For instance, since I've designed the geometry in OpenFOAM with the dimensions above, I'm not sure if it's to do with the incorrect coordinates for point of injection. I'm not sure where the error lies and I would be extremely grateful if someone could guide me to right direction.. Many thanks in advance Regards, |
This is the Error I got when running DPMFoam:
Code:
|
Hi!!
From what i can see, you dont have any problems with particle ínjection (if you did, your simulation will crash at the beginning)... The reason for your crash is that some of the bc's are incorrectly defined (especially the p bc's) as indicated by the error flags.. Code:
Additionally, i can see that your particle size is 0.00005m, hence correspondingly the maxinteractiondistance defined in the kinematiccloudproperties file must also be 0.00005. Additionally, if you want better control over your simulations, i would advice you to setup your case from scratch,i.e geometry and meshing, in OF (your setup is relatively simple)... In this way you are sure that the solutions are not affected by the different ways in which your case has been meshed... Hope this msg will help you :) Kind regards ansubru |
3 Attachment(s)
Hi,
Thank you for your reply. Indeed the B.C.s have been incorrectly assigned. I changed the P inlet & outlet boundaries to fixedValue. I also designed a simple clear channel geometry and mesh in OF (see attached file ee22.png). The same B.C.s and properties have been applied (got rid of bc's for obstacle wall) with corrections to he P inlet/outlet B.C.s as you've mentioned. After executing DPMFoam, I get the error (see ERROR Injection.txt). Someone raised this query before: http://www.cfd-online.com/Forums/ope...cro-scale.html He solved it by assigning an injection point away from the boundary planes. I tried that but I still get the same error:confused: Not too sure where I went wrong?? Any help greatly appreciated:) Many thanks & BR, Kevin Quote:
|
Hi Kevin!!
I have a few suggestions for you : --> Firstly run the command çheckMesh' to see mesh statistics... I have a feeling you have not followed the 'right hand rule' while assigning patches and that your mesh is quite poor (please read the blockMesh help in detail before you begin meshing)... refer here..http://www.openfoam.org/docs/user/blockMesh.php --> Secondly, you need to define your injection correctly, if your mesh has been 'drawn' in a different co-ordinate system, you could have issues when injections have to be initialized... And try to use alternate particle injection strategies.. I use patchinjection, and that seems to work quite well for me :)... --> Thirdly, try not to use the exact young's modulus while computing... Use a value 1000 times lower (for example try not to exceed the value used in the DPMFoam tutorial)... Your simulation will still be correct, dont worry.. Its an approximation almost all DEM works use so as to ease the computational burden... I have commented on a post regarding the same.. read more here.. http://www.cfd-online.com/Forums/ope...tml#post513475 Hope that helped!! Regards ansubru |
kinematiccloudproperties
Dear Ananda,
Thank you very much for your assistance! I went through the websites you posted and took note of the meshing procedure in OF. By following the right hand rule, and using patchinjection, I was able to execute the solver without any issues:). I'm going to try cone injection model and try and modify particle properties using different size distribution model and see how it goes... However, in the KinematicCloudProperties file, I'm still not sure what the following terms mean and I'm not sure how or under what situations should I modify those terms (highlighted in red). DPMFoam uses hard sphere model and Hertzian contact if i'm not mistaken?..According to http://www.cfd-online.com/Forums/ope...e-dpmfoam.html does this mean a non adhesive Hertzian contact model is used or adhesive contact i.e. JKR/DMT? Can we select other contact models? And what is the difference between using the openfoam solver DPMFoam and CFDEM (liggghts+openfoam) when it comes to simulating particle-fluid flows? According to website, both codes have 4-way coupling functionality i.e. particle-particle and particle-fluid interactions. So i'm not sure if one of them has something the other doesn't have? Any distinct difference between them:confused:? Many thanks again for your assistance!!!:) Kevin Code:
pairCollisionCoeffs |
Hi Kevin!!
Firstly, DPM-Foam is a 'soft sphere' contact model based solver. The entire concept of CFD-DEM has been developed by Tsuji et.al (look at the paper below) while studying plug flow conveying. All relevant parameters for the method of DEM are detailed in their paper, you can have a detailed read and I am sure that will answer all your questions... https://www.dropbox.com/sh/6bis355hp...ihf45kyra?dl=0 Equivalent size is a concept that comes into play when you have non spherical particles. My suggestion would be for you to read about hertzian contact models and why they are universally accepted as one of the best contact models available for simulating multi-particle contact. Additionally, the DPMFoam solver can also account for cohension, but I am not very aware of the models behind that. The config file you have shared is for 'non-adhesive' contacts. As of now, DPMFoam only uses linear and hertzian contact pair spring slider dashpot models for contact. Any new model, will unfortunately have to be developed you... And finally, about the differences between the various solvers (i.e CFDEM-LIGGGHTS, etc.) there is'nt much. They have the same features and are equally effective in resolving granular flow physics. LIGGGHTS has one major advantage that there are lot of supporting documentation/tutorials on setting up and analyzing a simulation. Apart from that, there is also the added capability of modelling dynamic meshes- moving geometries (which unfortunately cant be done with DPMFoam right now)... However, DPMFoam is more malleable to your needs than LIGGGHTS, i.e if you of course read and understand the source code. Else both tools are equally capable and its a matter of choice really. Personally, I couldnt get LIGGGHTS to work :( some incompatibility with my hardware, hence I adopted DPMFoam :) Hope that helped All the best in your quest!! ansubru :) |
Hi Ananda,
Thank you very much for your reply. I did have some compatibility issues with liggghts as well. After spending some time with the installation, I did manage to install it using Ubuntu 12 LTS and OpenFOAM 2.1.1. I used either Helyx or Salome for meshing. Thanks for sharing the document pertaining to CFD-DEM developed by Tsuji (1993):). I've read two of Tsuji's papers. I see they use the spring dashpot model for the forces whilst the Hertz theory is used to evaluate the stiffness. So DPMFoam allows users to select either linear-spring–dashpot model or non-linear Hertzian-spring–dashpot by setting b=1 or 1.5 respectively: Code:
[OpenFOAM-2.3.x/src/lagrangian/intermediate/submodels/Kinematic/CollisionModel/PairCollision/PairModel/PairSpringSliderDashpot/PairSpringSliderDashpot.H Code:
OpenFOAM-2.3.x/src/lagrangian/intermediate/submodels/Kinematic/CollisionModel/PairCollision/PairModel/PairSpringSliderDashpot/PairSpringSliderDashpot.C Code:
OpenFOAM-2.3.x/src/lagrangian/intermediate/submodels/Kinematic/CollisionModel/PairCollision/PairModel/PairSpringSliderDashpot/PairSpringSliderDashpot.H Code:
pairSpringSliderDashpotCoeffs Thank you very much for your time! Kevin |
Hi Benz25,
Even I am a new Open foam user. I would like to know that in your example you have mentioned number of particles to be 500, yet in the kinematicCloudPositions file, you have given only one value of position i.e (0.0005 0.0018 0) I want to know how will open foam assign co-ordinates to remaining 499 particles? |
Particle Injection
Hi Ameya T,
I deleted the KinematicCloudPositions file for my simulations and also instead of using manualInjection, I used patchInjection (as ansubru has mentioned in this thread). I defined the area of injection at the inlet using patchInjection. The settings for the paricle injections is shown below. I used patch injection to generate particles at random locations along the walls of the inlet. SOI is the start of injection time during simulation. A linear cohesion model (cohesion energy density) is the only model available in DPM/MPPICFoam to account for particle adhesiveness that is predominant in submicron particles. This could be deployed for simulation. Anyways, hope this helps. Any queries let me know. Benz Code:
injectionModels |
Thanks Kevin for the reply. One more thing which I want to know is would you still be able to use DPMfoam for solid particles in liquid phase?
Also how would you specify number of particles for patchInjection? As in your example you have just kept it as 1. |
Also I would like to know why fixedFluxPressure BCs are applied? Normally I would apply zeroGradient to walls and inlet and fixed value at the outlet. Would this not work?
|
fixedfluxpressure
Hello Ameya,
Unlike the p file in the simpleFOAM solver, the p values for DPMFoam have the phi term embedded...technically I think it should yield the same results but according to this post it's known to have a better convergence? I went through the post before as I had the same question See for example posts #5, #6: HTML Code:
http://www.cfd-online.com/Forums/openfoam-solving/82581-i-need-explanations-about-fixedfluxpressure.html Hope that helps:D Cheers Kevin |
Hi Kevin!
Thanks again for the reply. |
Hi,
I am quite new to OpenFOAM and using DPMFoam. The continuous phase field must essentially be air as fluid or it could be water?
|
Hi there!!
The continuous phase can be any fluid. The relevant properties are entered in the kinematiccloudproperties file. The forces incorporated would also change, and these will have to be individually turned on using the kinematiccloudproperties file again. For instance, when you have water, history forces become important. Regards ansubru |
Thanks for your help kind help.
The properties of the closed rectangular computational domain and particles are: 24mm by 77 mm. Inlet velocity at 10 cm/s and have two outlets. Fluid: water Laminar Flow. Solid Particles are made of silica having diameter of 100nm. For me 4-way coupling is very important. Is it a good decision to use DPMFoam solver? |
Hi again!!
From the very brief description of your system it does look plausible that CFD-DEM codes could work. However, as the size of your particles are smaller (nm order of magnitude), I would advise you to calculate the Knudsen numbers to see if rarefied flow dynamics prevail. If that is the case, then you will not be able to treat the fluid as a continuum, as the particles directly interact with the water molecules, so treatment of the system would be markedly different. Either ways for four-way coupled systems DPMFoam is a good alternative. But be sure that in your case you have a continuum effect as DPMFoam resolves the surrounding fluid as a continuum. Kind regards ansubru |
Hello, need help again!!!
I have calculated the Knudsen number and its value is less than 0.01m, So continuum approach is valid. In addition i have made modifications according to my case but now I am getting the following error, usman@dionysius:~/OpenFOAM/usman-2.3.x/run/lagrangian_src/ZigZagSpacer_Test> #0 Foam::error:rintStack(Foam::Ostream&) in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/lib/libOpenFOAM.so" #1 Foam::sigFpe::sigHandler(int) in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/lib/libOpenFOAM.so" #2 in "/lib64/libc.so.6" #3 Foam::symGaussSeidelSmoother::smooth(Foam::word const&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::Field<double> const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, unsigned char, int) in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/lib/libOpenFOAM.so" #4 Foam::symGaussSeidelSmoother::smooth(Foam::Field<d ouble>&, Foam::Field<double> const&, unsigned char, int) const in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/lib/libOpenFOAM.so" #5 Foam::smoothSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/lib/libOpenFOAM.so" #6 Foam::fvMatrix<Foam::Vector<double> >::solveSegregated(Foam::dictionary const&) in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/bin/DPMFoam" #7 Foam::fvMatrix<Foam::Vector<double> >::solve(Foam::dictionary const&) in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/bin/DPMFoam" #8 Foam::fvMatrix<Foam::Vector<double> >::solve() in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/bin/DPMFoam" #9 in "/nfs/opt/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/bin/DPMFoam" #10 __libc_start_main in "/lib64/libc.so.6" #11 at /home/abuild/rpmbuild/BUILD/glibc-2.14.1/csu/../sysdeps/x86_64/elf/start.S:116 I couldn't figure out which kind of error is it. |
Hi again!!
Well, it very hard to try and catch the error you have obtained using the stack you have provided. Some general tips maybe - 1) From the first error in your stack, we could maybe speculate that you are trying to access an unset object. So recheck your setup - geometry, meshing and problem setup including bc's. I would pay particular attention to the geometry and mesh. 2) If you need more help, you may need to furnish some more details of your case (i.e. what are the changes you have made with respect to a working tutorial setup) 3) If you are running the case for the first time, I would suggest you to run OF in debug mode , in that way you are actually pointed to the file and line no. where the first and subsequent errors occur. This is most useful in fine tuning and better understanding how your case behaves. I hope that helps. Happy debugging :) ansubru |
All times are GMT -4. The time now is 03:19. |