CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Native Meshers: snappyHexMesh and Others

Insert Box of Water in SHM object

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

Like Tree1Likes
  • 1 Post By raysark

Reply
 
LinkBack Thread Tools Display Modes
Old   February 14, 2013, 13:32
Default Insert Box of Water in SHM object
  #1
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Hi,

I am new user in OpenFoam and I hope that you can help me.

I have created three connected tubes using AutoCad and used them as my snappyHexMesh object.

I want to enter a box of water inside this object. I am trying to set the coordinates in the setFieldsDict but nothing appears when I execute the simulation.

Any ideas on how I can do it?

Please help

Thank you

Stratos
raysark is offline   Reply With Quote

Old   February 14, 2013, 13:48
Default
  #2
Senior Member
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Leoben (Austria)
Posts: 1,100
Blog Entries: 6
Rep Power: 19
Tobi will become famous soon enough
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi Stratos,

well that is not a problem belong to my topic but I think I can help you. Open a new thread for that, couse in this one we only discuss about meshing with sHM and multi regions.

Maybe I got something wrong with your question but setFields you are using after meshing to get a user defined value like. alpha = 1 or U, p, T into a certain region of the mesh.
Tobi is offline   Reply With Quote

Old   February 15, 2013, 08:12
Default
  #3
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,503
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings to all!

Quote:
Originally Posted by Tobi View Post
well that is not a problem belong to my topic but I think I can help you. Open a new thread for that, couse in this one we only discuss about meshing with sHM and multi regions.
Done! I've moved Statos' post from this thread: multiple regions

@Stratos: It's hard to help you if you don't provide more information If possible, please share your case or provide enough information for us to make a better guess of what you are doing wrong, such as what are the geometrical limits and what you "setFieldsDict" looks like and so on.
I suggest you read this thread: How to give enough info to get help

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   February 17, 2013, 18:31
Default
  #4
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Dear Bruno,

Thanks for your interest. I was abroad and I could't reply sooner.

So I uploaded somes files with images in the following link.

Let me explain you. I have a normal blockMesh and then using snappyHexMesh is introduce and isolate the tubes you can see in the picture. In the setFieldsDict a set a boxToCell with water inside the tubes. But it doesn't appear. My first guess is that the problem is crated from the boxToCell. Please have a look and let me know if you need anything else.

If you can help it would be brilliant and lifesaving Thanks.

https://www.dropbox.com/sh/sgydndlw3rk1u0i/A4-Y6tU4hu
raysark is offline   Reply With Quote

Old   February 18, 2013, 05:07
Default
  #5
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,503
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Stratos,

How are you trying to visualize the water inside the domain? Have you tried applying the filter "Contours" with a value of 0.5, for the field alpha1?

edit: Did you use:
Code:
snappyHexMesh -overwrite
Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   February 18, 2013, 16:15
Default
  #6
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Hi Bruno,

Thanks for the help. I noticed a mistake that I have to fix before inserting the water.
I have merged some dictionaries from the damBreak case and the wigleyHull.

I will upload a second link if you could spare some time to see how it works and tell me your opinion for the issues. it should't take more than five minutes if you run blockMesh, setFields and snappyHexMesh.

Kind Regards,

I will come back very soon when I have the issues fixed.

Thanks a lot
Stratos
raysark is offline   Reply With Quote

Old   February 18, 2013, 16:20
Default
  #7
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,503
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
FYI, it's the other way around:
  1. blockMesh
  2. snappyHexMesh -overwrite
  3. setFields
wyldckat is offline   Reply With Quote

Old   February 18, 2013, 16:28
Default
  #8
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Did this too but no solution given. Actually the snappyHexMesh overwrite produces some fields ccx ccy ccz (remained from the wigleyHull case - thats the problem I have to solve).
If I don't use snappyHexMesh -overwrite what's the difference?

Here is the link

https://www.dropbox.com/sh/1dbdedtxtk5b9pi/yZfUA8gPnB
raysark is offline   Reply With Quote

Old   February 18, 2013, 16:45
Default
  #9
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,503
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
I think Dropbox is still syncing up... several files are missing, specially in "system".

"-overwrite" ensures that the mesh is overwritten. Otherwise, the new mesh is saved in one or more time folders, depending on the meshing stages. Which means that setFields will only have effect on... whatever time folder that it considers to be proper...
In addition, if the mesh is on a folder other than constant or zero, you have to adjust "system/controlDict" accordingly.
wyldckat is offline   Reply With Quote

Old   February 18, 2013, 16:54
Default
  #10
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Dropbox synced.

Many thanks for the time you spent I really appreciate that.

I will have a look on the setFields.
raysark is offline   Reply With Quote

Old   February 18, 2013, 17:37
Default
  #11
Senior Member
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Leoben (Austria)
Posts: 1,100
Blog Entries: 6
Rep Power: 19
Tobi will become famous soon enough
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Here your case.

Without -overwrite openfoam saves your mesh a new timestep folder like 0.001 (for castellated) and 0.002 (for snapped mesh).

Use Allrun

PS: Mistake in setFields

Tobi
Attached Images
File Type: jpg personal.jpg (18.8 KB, 12 views)
Attached Files
File Type: gz personal.tar.gz (11.8 KB, 4 views)
Tobi is offline   Reply With Quote

Old   February 18, 2013, 18:44
Default
  #12
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
I used Allrun but openFoam displays that file points in directory polyMesh is missing.


And why did you removed the snappyHexMeshDict?

Thanks

Last edited by raysark; February 18, 2013 at 19:02.
raysark is offline   Reply With Quote

Old   February 18, 2013, 19:41
Default
  #13
Senior Member
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Leoben (Austria)
Posts: 1,100
Blog Entries: 6
Rep Power: 19
Tobi will become famous soon enough
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Quote:
Originally Posted by raysark View Post
I used Allrun but openFoam displays that file points in directory polyMesh is missing.


And why did you removed the snappyHexMeshDict?

Thanks

Maybe you have a other system:

just type into the consol:

Code:
cp files/blockMeshDict constant/polyMesh/
blockMesh
snappyHexMesh -overwrite
createPatch -overwrite
rm -r 0
cp -r 0.org 0
setFields
done

If you have a look into the system folder you ll see that I do not remove the snappyHexMeshDict.
Tobi is offline   Reply With Quote

Old   February 18, 2013, 19:44
Default
  #14
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Create time

Reading createPatchDict

Create polyMesh for time = 0



--> FOAM FATAL ERROR:
Cannot find file "points" in directory "polyMesh" in times 0 down to constant

From function Time::findInstance(const fileName&, const word&, const IOobject::readOption, const word&)
in file db/Time/findInstance.C at line 188.

FOAM exiting



Anyway I am quite sleepy. I will try it again tomorrow and I will tell you. thanks for the help.
raysark is offline   Reply With Quote

Old   February 19, 2013, 02:13
Default
  #15
Senior Member
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Leoben (Austria)
Posts: 1,100
Blog Entries: 6
Rep Power: 19
Tobi will become famous soon enough
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi,

you should do it step by step.
"createPatch" you have to do after meshing!
Tobi is offline   Reply With Quote

Old   February 22, 2013, 10:26
Default
  #16
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Hi Tobi,

I was off of some days. You solved my problem thanks a lot.

The file points was a problem of OpenFOAM version i Tested it in 2.1.1-18 and worked (i habe 2.1.1-22 which seems quite strange).

If I have anything else I will ask again.

Best Regards,
Stratos
Tobi likes this.
raysark is offline   Reply With Quote

Old   March 11, 2013, 15:53
Default
  #17
New Member
 
Efstratios Mavrogiannis
Join Date: Dec 2012
Posts: 20
Rep Power: 4
raysark is on a distinguished road
Hi Tobi,

Sorry for asking again for help but I think you can help.

I posted this:

XiFoam simulation error

Could you help me with these case?

Thanks
raysark 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
Water Evaporation and condensation modeling Linjie CFX 8 April 23, 2015 18:30
Junction Box Routine Shared Object Library sam CFX 0 March 3, 2008 13:52
Liquid water, gaseous water and another gas Andy FLUENT 1 May 22, 2006 08:51
VOF and water falls Tysor FLUENT 0 March 17, 2006 04:10
uptodate water distribution network fredius,magige,tanzanian,(e.a) Main CFD Forum 0 January 27, 2002 08:10


All times are GMT -4. The time now is 21:16.