CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Community Contributions

[swak4Foam] Ellipsoid Particles using funkySetFields

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 24, 2017, 13:31
Smile Ellipsoid Particles using funkySetFields
  #1
New Member
 
iain
Join Date: Oct 2016
Posts: 1
Rep Power: 0
beatsy is on a distinguished road
Hi all, I am new to OpenFOAM and i am trying to implement two ellipsoid shaped particles using funkySetFields to run using interFoam to simulate sintering. I have already successfully done this with two spheres but am unable to alter the formula correctly to change the shape.

I would like to make the centre of the two ellipsoids to be (0.01,0.0105,0.0105) and (0.011,0.0105,0.0105) respectively. With the dimensions in the x,y,z directions to be 0.0005,0.0008,0.0005 for both.

The two approaches i have already tried is:

funkySetFields -time 0 -keepPatches -field alpha.water -expression "pow(pos().x-((0.01)/0.0005),2) + pow(pos().y-((0.0105)/0.0008),2) + pow(pos().z-((0.0105)/0.0005),2)<1 || pow(pos().x-((0.011)/0.0005),2) + pow(pos().y-((0.0105)/0.0008),2) + pow(pos().z-((0.0105)/0.0005),2)<1 ? 1:0"

funkySetFields -time 0 -keepPatches -field alpha.water -expression "mag(pos()-vector(0.01/0.0005,0.0105/0.0008,0.0105/0.0005))<1 || mag(pos()-vector(0.011/0.0005,0.0105/0.0008,0.0105/0.0005))<1 ? 1:0"

If anyone could give any suggestions it would be much appreciated.

(For reference the equation of an ellipsoid is (x^2)/(a^2)+(y^2)/(b^2)+(z^2)/(c^2)=1)
beatsy is offline   Reply With Quote

Reply


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
how to determine the number of particles injected. welch FLUENT 2 January 18, 2024 05:08
dsmcFoam - micro-hole limiting the number of dsmc particles Araist OpenFOAM Running, Solving & CFD 0 June 25, 2015 07:50
Add lagrangian particles to OpenFoam solver luchen2408 OpenFOAM 0 June 2, 2015 04:10
trying to simulate two-phase jet flow with particles in surface injection ajkratos FLUENT 5 March 3, 2015 22:33
particles model ati_ros61 FLOW-3D 3 December 6, 2009 17:03


All times are GMT -4. The time now is 03:47.