Rick's Blog

Groovy Grading

Cylinder In Wind Tunnel With Grading

Quick Update 

 I thought I was going to delve into SwiftBlock and understand the mysteries of setting curved edges.........not so much.  Those mysteries still elude me.  But, I got edge grading to work, so it wasn't a complete loss! :)

The setup was another basic wind tunnel. This time however, I used symmetry faces, so I only needed to model the top half. In the 'test cell' section, I intended to put a cylinder and figure out curved edges. That didn't work, so I made a planar approximation with (essentially) an eight-sided cylinder. On my initial OpenFOAM run, the area around the cylinder was, understandably, a bit rough. My first thought was, 'Well, let's crank up the divisions to about 1 Million!!' As fulfilling as that would have been, it turns out there is a better way.

Inside Blender, SwiftBlock's edge settings allow grading, i.e., the divisions do not all need to be equal.  With the wind tunnel selected in Edit mode, select one or more edges you wish to grade (make non-uniform).  Enter the ration of the first grid to the last grid (e.g., if you want the last grid to be 10x larger than the first, enter 10) and select 'Set grading'.  When you preview the mesh, you will see the results.  If the grading is going in the wrong direction, delete the preview mesh, select the offending edges and select 'Flip edge'.  After some trial and error, I concentrated the mesh, near the cylinder.

Slightly Related Tangent.... 

 By the way, in case you are thinking that you can subdivide the mesh to have more control of it, great minds think alike!  However, whenever I did that, the 'Diagnose' button basically hated the entire mesh. I t turns out, contrary to typical Blender habits, internal faces are necessary!  If you make a loop cut are the initial cube, for example, you will need to go in and create faces for each division.  I just saved you 4 hours of cursing........you're welcome. :)

Back to Our Regularly Scheduled Program.... 

​The results with grading looked a little more efficient, at least near the cylinder where we are probably more interested.  

By the way, I did give into my initial impulse and increased the divisions to a large number.  After crunching numbers for a ridiculously long time, OpenFOAM crashed.  The morale of the story is Brute Force Isn't Always the Answer......But It Is Fun! ;)

If anyone understands how the Set Edges function works, please leave a comment.  Otherwise I'll keep baby-stepping. 

Publish or Perish - My SketchFab Mantra
A Basic Wind Tunnel

Related Posts

 

Comments

No comments made yet. Be the first to submit a comment
Already Registered? Login Here
Guest
Sunday, 29 March 2020

Captcha Image

Rick's Blog

Groovy Grading

Cylinder In Wind Tunnel With Grading

Quick Update 

 I thought I was going to delve into SwiftBlock and understand the mysteries of setting curved edges.........not so much.  Those mysteries still elude me.  But, I got edge grading to work, so it wasn't a complete loss! :)

The setup was another basic wind tunnel. This time however, I used symmetry faces, so I only needed to model the top half. In the 'test cell' section, I intended to put a cylinder and figure out curved edges. That didn't work, so I made a planar approximation with (essentially) an eight-sided cylinder. On my initial OpenFOAM run, the area around the cylinder was, understandably, a bit rough. My first thought was, 'Well, let's crank up the divisions to about 1 Million!!' As fulfilling as that would have been, it turns out there is a better way.

Inside Blender, SwiftBlock's edge settings allow grading, i.e., the divisions do not all need to be equal.  With the wind tunnel selected in Edit mode, select one or more edges you wish to grade (make non-uniform).  Enter the ration of the first grid to the last grid (e.g., if you want the last grid to be 10x larger than the first, enter 10) and select 'Set grading'.  When you preview the mesh, you will see the results.  If the grading is going in the wrong direction, delete the preview mesh, select the offending edges and select 'Flip edge'.  After some trial and error, I concentrated the mesh, near the cylinder.

Slightly Related Tangent.... 

 By the way, in case you are thinking that you can subdivide the mesh to have more control of it, great minds think alike!  However, whenever I did that, the 'Diagnose' button basically hated the entire mesh. I t turns out, contrary to typical Blender habits, internal faces are necessary!  If you make a loop cut are the initial cube, for example, you will need to go in and create faces for each division.  I just saved you 4 hours of cursing........you're welcome. :)

Back to Our Regularly Scheduled Program.... 

​The results with grading looked a little more efficient, at least near the cylinder where we are probably more interested.  

By the way, I did give into my initial impulse and increased the divisions to a large number.  After crunching numbers for a ridiculously long time, OpenFOAM crashed.  The morale of the story is Brute Force Isn't Always the Answer......But It Is Fun! ;)

If anyone understands how the Set Edges function works, please leave a comment.  Otherwise I'll keep baby-stepping. 

Publish or Perish - My SketchFab Mantra
A Basic Wind Tunnel

Related Posts

 

Comments

No comments made yet. Be the first to submit a comment
Already Registered? Login Here
Guest
Sunday, 29 March 2020

Captcha Image