|
[Sponsors] |
November 17, 2016, 13:13 |
|
#241 |
Member
Roman Gobitz-Pfeifer
Join Date: Dec 2009
Location: Stuttgart
Posts: 83
Rep Power: 16 |
Hi,
is it possible that swiftBlock doesn't work on windows machines? I have to work with the windows version of openFOAM and therefore I want to create my blockMesh with blender and swiftBlock. Although everything is installed poperly, blender is not able to show my any grid when pressing the review button (no blockMesh found). I assume that the path to blockmesh isn't set in the system variables. Anybody facing the same problem? cheers wikie |
|
November 18, 2016, 05:00 |
|
#242 |
Senior Member
Karl-Johan Nogenmyr
Join Date: Mar 2009
Location: Linköping
Posts: 279
Rep Power: 21 |
Hi,
you are using Mikko's version, so I'll let him answer this. He has the advantage of supporting multigrading, but his preview function relies on blockMesh itself for generating a preview outside of blender. My version does not support multigrading, but my preview function is done within blender. I have almost exclusively been running swiftblock in windows without problems. Regards, Kalle |
|
November 18, 2016, 05:04 |
|
#243 |
Senior Member
Mikko
Join Date: Jul 2014
Location: The Hague, The Netherlands
Posts: 243
Rep Power: 13 |
Hi Roman,
Sorry, I have never tried blockMesh/Blender/OpenFOAM on Windows. This version should work with Windows because it is not calling blockMesh in the background. Otherwise, I think you should run Blender from command prompt where you have firstly loaded the OpenFOAM environment. Additionally, maybe you will have to change in the preview.py file the "blockMesh" command to "blockMesh.exe" (2 times). Best, Mikko |
|
November 18, 2016, 08:10 |
|
#244 |
Member
Roman Gobitz-Pfeifer
Join Date: Dec 2009
Location: Stuttgart
Posts: 83
Rep Power: 16 |
Thanks Kalle and Mikko for your fast reply.
I'm working with blender 2.75-windows64 and I installed the version from Mikko (https://github.com/flowkersma/swiftBlock). I'll give the version from Kalle a try. Thanks Roman |
|
November 18, 2016, 08:57 |
|
#245 |
Member
Roman Gobitz-Pfeifer
Join Date: Dec 2009
Location: Stuttgart
Posts: 83
Rep Power: 16 |
Kalle's version is working on my windows machine.
I also tried to replace the "blockMesh" command with "blockMesh.exe" in Mikko's version as recommended which doesn't solve the problem |
|
November 24, 2016, 10:09 |
wedge type mesh in swiftBlock?
|
#246 |
Member
Roman Gobitz-Pfeifer
Join Date: Dec 2009
Location: Stuttgart
Posts: 83
Rep Power: 16 |
swiftBlock is great!! I aleady set up some smaller cases (mainly pipes and other simple geometries) for practise and it's working perfect.
Is it possible to create a wedge type mesh using swiftBlock? I'm still playing around and want to simulate the flow through a pipe by using the symmetry axis of the pipe to fasten the simulation. If so, does anybody have any tutorials or other tipps and tricks? cheers Roman |
|
November 24, 2016, 10:17 |
|
#247 |
Senior Member
Karl-Johan Nogenmyr
Join Date: Mar 2009
Location: Linköping
Posts: 279
Rep Power: 21 |
Thanks!
Well, you cannot do wedges, but I had the same problem as you. I made a 2D flat mesh, and used this tool to create a wedge: https://openfoamwiki.net/index.php/C.../MakeAxialMesh Also see this: https://openfoamwiki.net/index.php/Contrib/SwiftBlock K |
|
July 19, 2017, 06:37 |
|
#248 | |
Member
Join Date: Mar 2014
Posts: 39
Rep Power: 12 |
First and foremost: Great work from both of you Karl and Mikko !
I am currently testing Blender with the swiftBlock addon and it seems to work well. My current configuration where I succeeded in doing some tutorials is Blender 2.78c (and also 2.75a) with OpenFOAM-3.0.1 and the swiftBlock fork of flowkersma. I noticed that I cannot simply change the cubes resolution in x, y, z by applying a varying maxdx to a single edge + parallel edges. After setting the maxdx I see the correct edge resolution when using "Get edges" but the mesh doesn´t change like required. Looks like the block gets divided into the same number of cells in each direction regardless of my specific edge resolution which should lead to different cell counts in x, y and z !? What puzzles me is the fact that the grading feature is working as expected. Right now I modify the blockMeshDict afterwards to modify the number of cells in each direction. Is that feature not a current part of swiftBlock or am I missing something ? Quote:
|
||
July 30, 2017, 18:39 |
|
#249 |
Senior Member
Mikko
Join Date: Jul 2014
Location: The Hague, The Netherlands
Posts: 243
Rep Power: 13 |
Hi Traction,
I merged my fork of SwiftBlock with another repository in the beginning of the month and changed also a bit my code. I did not test the new code properly and it is very possible that there were errors. Sorry about that! For now, I rollbacked to the old release. I have been lately developing swiftBlock a bit and I plan to soon publish what I have done. I will make a new video then as well. Best, Mikko |
|
September 13, 2017, 07:29 |
|
#250 |
Senior Member
Mikko
Join Date: Jul 2014
Location: The Hague, The Netherlands
Posts: 243
Rep Power: 13 |
Hi,
A new version of my fork is available. It has several new features which are described on the GitHub page. It supports the new surface projection algorithm of blockMesh (also Kalle's blockMeshBodyFit). Unfortunately, it currently has a dependency to the latest Numpy 1.13. I have rewritten most of the code and changed the GUI quite bit. Let me now if you try it! Example video how to mesh a sphere Happy meshing! |
|
September 13, 2017, 08:52 |
|
#251 |
Senior Member
Karl-Johan Nogenmyr
Join Date: Mar 2009
Location: Linköping
Posts: 279
Rep Power: 21 |
Impressed! Really good work, Mikko! This is definitely an alternative to commercial block meshing software... I am sure it is also a lot faster too. Great work with the GUI. Nice with edge direction visualization!
Kalle |
|
September 13, 2017, 10:44 |
|
#252 |
Senior Member
Mikko
Join Date: Jul 2014
Location: The Hague, The Netherlands
Posts: 243
Rep Power: 13 |
Thanks Kalle! The more I learn Blender, the more I understand how powerful it is. It is also a lot of fun to work with.
|
|
November 3, 2017, 09:48 |
swiftBlock
|
#253 |
Member
|
Hi All
I have installed blender 2.78c, plus the GitHub version of swiftBlock. Once installed I opened a terminal and enabled OF 5.0 environment (alias as I have several version of OF/foam installed) and in the same terminal I then started blender 2.78 and installed swiftBlock as per the GitHub page instructions (including python and numpy) and tried swiftBlock. Then I took the blender mesh of the domain and selected blockMesh -> Build Blocking, this returned several blocks however it did not generate all blocks in domain (refer to figures). Before trying to generate the blocks I ensured that all redundant faces, edges and faces had been removed. Also confirmed there are no non-manifold edges or loose geometry. I have tried both the blockMeshMG and blockMeshBofyFit options with and without Numba activated. With Numba activated I receive the following error message. Code:
Beginning automatic block detection Traceback (most recent call last): File "/home/jfm/.config/blender/2.78/scripts/addons/swiftBlock/__init__.py", line 396, in invoke log, block_verts, block_edges, face_info, all_edges, faces_as_list_of_nodes = blockBuilder.blockFinder(edges, verts, disabled = disabled, numba = ob.useNumba) File "/home/jfm/.config/blender/2.78/scripts/addons/swiftBlock/blockBuilder.py", line 102, in blockFinder from . import cycleFinderNumba File "/home/jfm/.config/blender/2.78/scripts/addons/swiftBlock/cycleFinderNumba.py", line 1, in <module> from numba import jit ImportError: No module named 'numba' Regards JFM |
|
November 3, 2017, 10:05 |
|
#254 |
Senior Member
Mikko
Join Date: Jul 2014
Location: The Hague, The Netherlands
Posts: 243
Rep Power: 13 |
Hi John,
How many blocks do you have on the list in the SwiftBlock panel? Is it only the six blocks that are visible or more? You should not use numba unless the block detection (build blocking) algorithm is taking too long. Then you will have to install the numba Python library. You should use blockMeshMG and I will take the other option away in the next release. Best, Mikko |
|
November 3, 2017, 10:23 |
swiftBlock
|
#255 |
Member
|
Hi Mikko
Thanks for replying - there is only 6 blocks listed. I have attached the blender file for information. Regards John |
|
November 3, 2017, 10:46 |
|
#256 |
Senior Member
Mikko
Join Date: Jul 2014
Location: The Hague, The Netherlands
Posts: 243
Rep Power: 13 |
Hi John,
You are missing the internal edges and that is why SwiftBlock cannot find the blocks. Each block must always have 8 vertices and 12 edges. I have implemented an operator "extrude blocks" which retains the internal edges. You can find it by pressing ALT+E. I attached a modified file which can now find 111 blocks. However, the measures might be wrong. I just removed the top surface of the blocking and extruded the lower surface 1.726m to the normal direction. Best, Mikko |
|
November 6, 2017, 18:43 |
The projection to object fails for me
|
#257 |
New Member
Eero Kokkonen
Join Date: Nov 2010
Posts: 4
Rep Power: 15 |
Hi!
I switched to the new fork and tried the 'flow around a sphere' example mentioned by flowkersma without succeeding in the projection of the mesh to the sphere. I am running Blender 2.79 (also tried with previous ones without any help), I have OF-dev from this week and I followed the install instructions from the README file. I only get this: Screenshot_20171107_003609.jpg Wonder where's the problem... |
|
November 7, 2017, 05:09 |
|
#258 |
Senior Member
Mikko
Join Date: Jul 2014
Location: The Hague, The Netherlands
Posts: 243
Rep Power: 13 |
Hi Eero,
If you don't see any errors, then the installation should be OK. Can you see the projections on the list of the SwiftBlock panel (there should be 6 faces, 12 edges and 8 vertices for cube to sphere projection)? Regards, Mikko |
|
November 7, 2017, 06:32 |
|
#259 |
New Member
Eero Kokkonen
Join Date: Nov 2010
Posts: 4
Rep Power: 15 |
Hi Mikko,
Yes to my understanding it should be ok and work. Please find my test case attached: test.blend.tar.gz |
|
November 8, 2017, 06:15 |
|
#260 |
Member
Vignesh
Join Date: Oct 2012
Location: Darmstadt, Germany
Posts: 66
Rep Power: 14 |
Hi Mikko,
I am trying the meshing sphere in block tutorial. To begin with i just stopped after creating the sphere inside the block (see the attached pic) not extending it as you did. Then i initialized swiftblock, when i click blockMeshMG, i get the following error Code:
Beginning automatic block detection Traceback (most recent call last): File "/home/local/CSI/guru/blender/2.77/scripts/addons/swiftBlock/__init__.py", line 396, in invoke log, block_verts, block_edges, face_info, all_edges, faces_as_list_of_nodes = blockBuilder.blockFinder(edges, verts, disabled = disabled, numba = ob.useNumba) File "/home/local/CSI/guru/blender/2.77/scripts/addons/swiftBlock/blockBuilder.py", line 105, in blockFinder tmp_v,tmp_e = cycleFinder(edges,range(len(vertices_coord))) File "/home/local/CSI/guru/blender/2.77/scripts/addons/swiftBlock/blockBuilder.py", line 59, in cycleFinder temp, u = np.unique(np.sort(faces), axis=0, return_index=True) TypeError: unique() got an unexpected keyword argument 'axis' location: <unknown location>:-1 location: <unknown location>:-1 Can you tell me what i am doing wrong and how to rectify it ? PS: I am using Blender-2.77 with openfoam 5 Regards Vignesh
__________________
Thanks and Regards Vignesh |
|
|
|