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

Example of use of the solidParticlesolidParticleCloud classes

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

Like Tree1Likes

Reply
 
LinkBack Thread Tools Display Modes
Old   June 14, 2007, 19:23
Default Hello, is there any example of
  #1
Senior Member
 
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,880
Rep Power: 25
alberto will become famous soon enoughalberto will become famous soon enough
Hello, is there any example of how to use the solidParticle/solidParticleCloud classes of OpenFOAM 1.4?

Regards,
Alberto
__________________
Alberto

GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as live DVD/USB, hard drive image and virtual image.
GeekoCFD 32bit - The 32bit edition of GeekoCFD.
GeekoCFD text mode - A smaller version of GeekoCFD, text-mode only, with only OpenFOAM. Available in a variety of virtual formats.
alberto is offline   Reply With Quote

Old   February 27, 2008, 09:18
Default Hi Alberto I am also trying
  #2
New Member
 
Andreas Mehrle
Join Date: Mar 2009
Posts: 3
Rep Power: 7
braveandi is on a distinguished road
Hi Alberto

I am also trying to include the solidParticle/solidParticleCloud classes in OpenFOAM 1.4.1 with moderate success. Whenever I call solidParticleCloud's constructor I receive a compile error "undefinded reference".

Did you procceed any further?

br
Andreas
braveandi is offline   Reply With Quote

Old   October 4, 2008, 06:42
Default Hi, Any news on how to use
  #3
Senior Member
 
Håkan Nilsson
Join Date: Mar 2009
Location: Gothenburg, Sweden
Posts: 172
Rep Power: 7
hani is on a distinguished road
Hi,

Any news on how to use the solidParticle class? I made a grep on the entire OpenFOAM-1.5 installation, and it seems like there is no example.

There seems to be some problem since a copy of icoFoam will not compile if I simply add a link to the solidParticle and lagrangian classes in Make/options:
EXE_LIBS = \
-lfiniteVolume \
-llagrangian \
-lsolidParticle
No other modifications are made to icoFoam!

The error message is:
/home/hani/OpenFOAM/OpenFOAM-1.5/lib/linux64GccDPOpt/libsolidParticle.so: undefined reference to `Foam::Cloud<foam::solidparticle>::typeName'

The same error occurs also without the -llagrangian, and with other combinations of added libraries, so the problem seems to be related to -lsolidParticle. I tried re-compiling the solidParticle class, which went through nicely, but the problem is still there.

Any idea?

Håkan.
hani is offline   Reply With Quote

Old   October 4, 2008, 12:00
Default Make sure you use 1.5.x, 1.5 i
  #4
Super Moderator
 
Mattijs Janssens
Join Date: Mar 2009
Posts: 1,416
Rep Power: 15
mattijs is on a distinguished road
Make sure you use 1.5.x, 1.5 is missing a few bits.

1)
#include "solidParticleCloud.H"

2)
In the main create a cloud

solidParticleCloud particles(mesh);

and the gravity g. (readEnvironmentalProperties.H)

3)
Somewhere in your time loop do a

particles.move(g);
mattijs is offline   Reply With Quote

Old   October 7, 2008, 04:20
Default Thanks a lot Mattijs! I hav
  #5
Senior Member
 
Håkan Nilsson
Join Date: Mar 2009
Location: Gothenburg, Sweden
Posts: 172
Rep Power: 7
hani is on a distinguished road
Thanks a lot Mattijs!

I have added a code and case at the following location for anyone who would like to test the solidParticleCloud class:

http://openfoamwiki.net/index.php/Contrib_solidParticleFoam

Håkan
czhao86 likes this.
hani is offline   Reply With Quote

Old   October 7, 2008, 09:15
Default Splendid! /Niklas
  #6
Member
 
Niklas Wikstrom
Join Date: Mar 2009
Posts: 83
Rep Power: 7
wikstrom is on a distinguished road
Splendid!

/Niklas
wikstrom is offline   Reply With Quote

Old   October 14, 2008, 13:13
Default Hi All, The wikipage explains
  #7
Member
 
Sachin Kanetkar
Join Date: Mar 2009
Posts: 57
Rep Power: 7
sachin is on a distinguished road
Hi All,
The wikipage explains that solver is only for demo purpose, can anyone help me out how to use it for real world simulation.
Shall i try and compare this one with deiselEngineFoam...am i correct ? if not is there any other way ?

Sachin
sachin is offline   Reply With Quote

Old   October 14, 2008, 15:26
Default Hi Sachin, The purpose of t
  #8
Senior Member
 
Håkan Nilsson
Join Date: Mar 2009
Location: Gothenburg, Sweden
Posts: 172
Rep Power: 7
hani is on a distinguished road
Hi Sachin,

The purpose of that case was just to set up something for people to start with, so that you know what is needed to have something running. If you have a look at it you will see that it does not solve for any fluid motion, so if your 'real world' simulation has a need for that you must include it. I did not check every detail of the solidParticleCloud class yet, but at least I know that the particles do not interact and there is only one-way coupling. Again, if your 'real world' simulation requires this you must include it. For some 'real world' simulations the case set-up and its assumptions might be alright, the question is how you define your 'real world'. We always do assumptions of different kinds.

My advice: Use anything any way you like, but remember that you are responsible for the conclusions you draw from those results yourself. In other words - make sure what the code does, and validate it as much as you can before you draw any important conclusions.

dieselEngineFoam is of course much more developed, but it is also much more complicated. Also, it is not an example of the solidParticleCloud class, which was the purpose of the present test case.

Good luck!
Håkan
hani is offline   Reply With Quote

Old   October 17, 2008, 09:54
Default Thanks Håkan, I now want to k
  #9
Member
 
Sachin Kanetkar
Join Date: Mar 2009
Posts: 57
Rep Power: 7
sachin is on a distinguished road
Thanks Håkan,
I now want to know what is e and mu in solidParticleCloud class...I am not even able to guess these values ....

sachin
sachin is offline   Reply With Quote

Old   October 17, 2008, 10:11
Default Hi Sachin, Check the follow
  #10
Senior Member
 
Håkan Nilsson
Join Date: Mar 2009
Location: Gothenburg, Sweden
Posts: 172
Rep Power: 7
hani is on a distinguished road
Hi Sachin,

Check the following ang get back with a detailed explanation:
OpenFOAM-1.5.x/src/lagrangian/solidParticle/solidParticle.C

For instance:
void Foam::solidParticle::hitWallPatch
(
const wallPolyPatch& wpp,
solidParticle::trackData& td
)
{
vector nw = wpp.faceAreas()[wpp.whichFace(face())];
nw /= mag(nw);

scalar Un = U_ & nw;
vector Ut = U_ - Un*nw;

if (Un > 0)
{
U_ -= (1.0 + td.spc().e())*Un*nw;
}

U_ -= td.spc().mu()*Ut;
}

Have a nice weekend!
Håkan.
hani is offline   Reply With Quote

Old   October 17, 2008, 17:00
Default Hi Håkan, Infact i should hav
  #11
Member
 
Sachin Kanetkar
Join Date: Mar 2009
Posts: 57
Rep Power: 7
sachin is on a distinguished road
Hi Håkan,
Infact i should have mentioned in previous post...i was thinking whether it is related to elasticity factor and reflection...is it correct ?

i m trying to model dusty jet flow and i m not really sure which approach should i follow
1-As taken in this example
2-or the one taken in the sample code of icoLagrangianFoam (available on wikipages)
If 2 one is better somebody please explain me these lines (from IncompressibleCloud.c)

vector tmp=(random.vector01()-vector(0.5,0.5,0.5))*2;
vector pos=center+tmp*r0;
tmp=vector(random.GaussNormal(),random.GaussNormal (),random.GaussNormal())/sqrt( 3.);
vector vel=tmp*vel0+vel1;

scalar d=fabs(random.GaussNormal())*d1+d0;

label cellI=mesh_.findCell(pos);

...Are particle diameter,position,velocity generated randomly ....in that case..i think approach 1 would be nice as my particle would be injected from inlet boundary (i.e. position would be predefined)

Also is there any papers over implementation of lagrangian libraries in OpenFOAM...just to give some idea about it

sachin
sachin is offline   Reply With Quote

Old   October 23, 2008, 13:12
Default Håkan, Thanks for that wiki
  #12
Member
 
Scott Ripplinger
Join Date: Mar 2009
Posts: 30
Rep Power: 7
sripplinger is on a distinguished road
Håkan,

Thanks for that wiki page! I'm hoping that it provides a good starting point for my thesis simulations. I plan on integrating some surface forces (van der waals, and double layer) into the solver to simulate a colloidal suspension. I will also be adding two-way coupling and inter-particle collisions. Perhaps I'll post a new solver with just these as an intermediate step.
sripplinger is offline   Reply With Quote

Old   November 15, 2008, 16:44
Default Hi, I just added a new exam
  #13
Senior Member
 
Håkan Nilsson
Join Date: Mar 2009
Location: Gothenburg, Sweden
Posts: 172
Rep Power: 7
hani is on a distinguished road
Hi,

I just added a new example in the Wiki, where I modify the interFoam solver and the damBreak tutorial so that the solidParticles are included in that case. You have a step-by-step description at:
http://openfoamwiki.net/index.php/Contrib_solidParticleFoam#solidParticleDamBrea k

By coincidence the splash hits one of the particles so that it hits the wall. The other particle falls to the surface, decelerates in the heavy fluid due to buoyancy, and follows the fluid motion.

Have a nice evening!
Håkan.
hani is offline   Reply With Quote

Old   March 13, 2009, 08:27
Default I have just checked in some up
  #14
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,718
Rep Power: 19
hjasak will become famous soon enough
I have just checked in some updates - my fault (out of sync).

Please update and try again - works now.

Hrv

P.S. Impressive work, Hakan!
__________________
Hrvoje Jasak
hjasak is offline   Reply With Quote

Old   March 13, 2009, 09:36
Default Hrv, Thanks. That fixed it.
  #15
egp
Senior Member
 
egp's Avatar
 
Eric Paterson
Join Date: Mar 2009
Location: Blacksburg, VA
Posts: 193
Blog Entries: 1
Rep Power: 7
egp is on a distinguished road
Hrv, Thanks. That fixed it. I'm putting a bunch of the community developments off the Wiki into a openSuse + OpenFOAM-1.5-dev virtual machine for a training class, and a few were broken.
egp is offline   Reply With Quote

Old   March 28, 2009, 04:51
Default still undefined reference problem
  #16
Senior Member
 
ZHOU Bin
Join Date: Mar 2009
Location: Nanjing/Shanghai/Torino, Nanjing/Shanghai/Piemente, China/Italy
Posts: 164
Rep Power: 7
zhoubinwx is on a distinguished road
Send a message via ICQ to zhoubinwx Send a message via MSN to zhoubinwx Send a message via Skype™ to zhoubinwx
Hi Håkan,

I have followed the following step:
1. git clone git://repo.or.cz/OpenFOAM-1.5.x.git, so that I can get OF 1.5.x;
2. svn checkout http://openfoam-extend.svn.sourcefor...dParticleFoam/
3. cd solidParticleFoam/solidParticleFoam
4. wmake
5. However, I get the same error as in OpenFOAM 1.5 when I compile icoLagrantiamFoam solver:
Make/linuxGccDPOpt/solidParticleFoam.o: In function `Foam::Cloud<Foam::solidParticle>::type() const':
solidParticleFoam.C.text._ZNK4Foam5CloudINS_13so lidParticleEE4typeEv[Foam::Cloud<Foam::solidParticle>::type() const]+0x11): undefined reference to `Foam::Cloud<Foam::solidParticle>::typeName'
collect2: ld returned 1 exit status
make: *** [/home/zhou/OpenFOAM/zhou-1.5/applications/bin/linuxGccDPOpt/solidParticleFoam] Error 1

Would you please test it? Thank you for attention.

Bin
zhoubinwx is offline   Reply With Quote

Old   March 30, 2009, 13:04
Default
  #17
Senior Member
 
Håkan Nilsson
Join Date: Mar 2009
Location: Gothenburg, Sweden
Posts: 172
Rep Power: 7
hani is on a distinguished road
I don't see in your steps that you compiled 1.5.x. Did you?

Håkan.
hani is offline   Reply With Quote

Old   March 30, 2009, 13:12
Default
  #18
Senior Member
 
ZHOU Bin
Join Date: Mar 2009
Location: Nanjing/Shanghai/Torino, Nanjing/Shanghai/Piemente, China/Italy
Posts: 164
Rep Power: 7
zhoubinwx is on a distinguished road
Send a message via ICQ to zhoubinwx Send a message via MSN to zhoubinwx Send a message via Skype™ to zhoubinwx
Hi, Håkan,

You are right, just now I have found this stupid problem.

I add OpenFOAM 1.5.x/etc/barshrc in $HOME/.bashrc & first, then use ./Allwmake under the directory: OpenFOAM/OpenFOAM-1.5.x to compile it.

It is running now.

Thank you for your reply.

Bin
zhoubinwx is offline   Reply With Quote

Old   March 31, 2009, 16:17
Default
  #19
Senior Member
 
ZHOU Bin
Join Date: Mar 2009
Location: Nanjing/Shanghai/Torino, Nanjing/Shanghai/Piemente, China/Italy
Posts: 164
Rep Power: 7
zhoubinwx is on a distinguished road
Send a message via ICQ to zhoubinwx Send a message via MSN to zhoubinwx Send a message via Skype™ to zhoubinwx
Hi, Håkan,

Update my condition: I can use solidParticleFoam as you suggested in wiki. It is impressive.

Thank you.

Bin
zhoubinwx is offline   Reply With Quote

Old   April 20, 2009, 10:33
Default
  #20
Senior Member
 
ZHOU Bin
Join Date: Mar 2009
Location: Nanjing/Shanghai/Torino, Nanjing/Shanghai/Piemente, China/Italy
Posts: 164
Rep Power: 7
zhoubinwx is on a distinguished road
Send a message via ICQ to zhoubinwx Send a message via MSN to zhoubinwx Send a message via Skype™ to zhoubinwx
Hi, Håkan and other Foamers,

After I get my flow field(steady-state), I use this flow field to move my particles. It works fine here.

Now I want to generate particles continuously at each time step as well as move the previous generated particles.

Do you have any suggestions for this? I am thinking about this now.

Best regards,

Bin
zhoubinwx is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Finite Area Classes and Surface related Utilities philippose OpenFOAM 10 December 9, 2011 11:42
Understanding tmp%2360T classes nadine OpenFOAM Running, Solving & CFD 14 January 22, 2009 09:25
Adding functionality to classes sergio OpenFOAM 9 March 13, 2008 06:18
Parallel Computing Classes at San Diego Supercomputer Center Jan. 20-22 Amitava Majumdar Main CFD Forum 0 January 5, 1999 12:00


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