Robust Meshing for FEA with ANSYS

Meshing is one of the most important aspects of a simulation process and yet it can be one of the most frustrating and difficult to get right.  Whether you are using CAD based simulation tools or more powerful flagship simulation tools, there are different approaches to take when it comes to meshing complicated assemblies for structural or thermal analysis.

ANSYS has grown into the biggest simulation company globally by acquiring powerful technologies, but more importantly, integrating their capabilities into a single platform.  This is true for meshing as well.  Many of ANSYS’ acquisitions have come with several strong meshing capabilities and functionalities and ANSYS Workbench integrates all of that into what we call Workbench Meshing.  It is a single meshing tool that incorporates a variety of global and local mesh operations to ensure that the user not only gets a mesh, but gets a good quality mesh without needing to spend a lot of time in the prep process. We’ll take a look at a couple examples here.

 

TRACTOR AXLE

This is a Tractor Axle assembly that has 58 parts including bolts, gaskets and flanges.  The primary pieces of the assembly also has several holes and other curved surfaces.  Taking this model into Workbench Meshing yielded a good mesh even with default settings. From here by simply adding a few sizing controls and mesh methods we quickly get a mesh that is excellent for structural analysis.

Tractor Axle Geometry

Tractor Axle Default Mesh

Tractor Axle Refined Mesh

 

RIVETING MACHINE

The assembly below, which is a model from Grabcad of a riveting machine, was taken directly into Workbench Meshing and a mesh was created with no user input. As you can see the model has 5,282 parts of varying sizes, shapes and complexity.  Again without needing to make any adjustments, Workbench Meshing is able to mesh this entire geometry with 6.6 million elements in only a few minutes on a laptop.

Riveting Machine

Riveting Machine

Riveting Machine Default Mesh

Riveting Machine Default Mesh

 

The summary of the meshing cases are shown below:

Case # of Parts User Operations # of Elements # of Nodes Time [s]
Tractor Axle 58 0 415,735 723,849 34
Tractor Axle Refined 58 5 Body Sizings

2 Local Mesh Methods

930,406 1,609,703 43
Riveting Machine 5,282 0 2,481,275 6,670,385 790

 

Characteristics of a robust meshing utility are:

  • Easy to use with enough power under the hood
  • Able to handle complex geometry and/or large number of parts
  • Quick and easy user specified mesh operations
  • Fast meshing time

ANSYS Meshing checks all of these boxes completely.  It has a lot of power under the hood to handle large and/or complex geometry but makes it simple and easy for users to create a strong quality mesh for FEA analysis.

Here is the link to download the geometry used in this model

If you would like a more detailed step-by-step explanation of this process, check out the video below!

If you have any questions feel free to reach out to me at manoj@padtinc.com

 

Credit to Manoj Abraham from Grabcad for Riveting Machine Model. And no I didn’t choose this model just because he shared my name

Assembly Modeling with ANSYS

In my previous article, I wrote about how you get what you pay for with your analysis package.  Well, buckle up for some more…but this time we’ll just focus on handling assemblies in your structural/thermal simulations.  If all you’re working on are single components, count yourself lucky.  Almost every simulation deals with one part interacting with another.  You can simplify your boundary conditions a bit to make it equivalent, but if you have significant bearing stresses, misalignments, etc…you need to include the supporting parts.  Better hope your analysis package can handle contact…

Image result for get what you pay for

First off, contact isn’t just for structural simulations.  Contact allows you to pass loads across difference meshes, meaning you don’t need to create a conformal mesh between two parts in order to simulate something.  Here’s a quick listing on the degrees of freedom supported in ANSYS (don’t worry…you don’t need to know how to set these options as ANSYS does it for you when you’re in Workbench):

image

You can use contact for structural, thermal, electrical, porous domain, diffusion, or any combination of those.  The rest of this article is going to focus on the structural side of things, but realize that the same concepts apply to essentially any analysis you can do within ANSYS Mechanical..

First, it’s incredibly easy to create contact in your assembly.  Mechanical automatically looks for surfaces within a certain distance from one another and builds contact.  You can further customize the automated process by defining your own connection groups, as I previous wrote about.  These connection groups can create contact between faces, edges, solids bodies, shell bodies, and line bodies.

image

Second, not only can you create contact to transfer loads across different parts, but you can also automatically create joints to simulate linkages or ‘linearize’ complicated contacts (e.g. cylindrical-to-cylindrical contact for pin joints).  With these joints you can also specify stops and locks to simulate other components not explicitly modeled.  If you want to really model a threaded connection you can specify the pitch diameter and actually ‘turn’ your screw to properly develop the shear stress under the bolt head for a bolted joint simulation without actually needing to model the physical threads (this can also be done using contact geometry corrections)

image Look ma, no threads (modeled)!

image

If you’re *just* defining contact between two surfaces, there’s a lot you simulate.  The default behavior is to bond the surfaces together, essentially weld them closed to transmit tensile and compressive loads.  You also have the ability to let the surfaces move relative to each other by defining frictionless, frictional, rough (infinite coefficient of friction), or no-separation (surfaces don’t transmit shear load but will not separate).

image

Some other ‘fancy’ things you can do with contact is simulate delamination by specifying adhesive properties (type I, II, or III modes of failure).  You can add a wear model to capture surface degradation due to normal stress and tangential velocity of your moving surfaces.  You can simulate a critical bonding temperature by specifying at what temperature your contacts ‘stick’ together instead of slide.  You can specify a ‘wetted’ contact region and see if the applied fluid pressure (not actually solving a CFD simulation, just applying a pressure to open areas of the contact interface) causes your seal to open up.

image

Now, it’s one thing to be able to simulate all of these behaviors.  The reason you’re running a finite element simulation is you need to make some kind of engineering judgement.  You need to know how the force/heat/etc transfers through your assembly.  Within Mechanical you can easily look at the force for each contact pair by dragging/dropping the connection object (contact or joint) into the solution.  This will automatically create a reaction probe to tell you the forces/moments going through that interface.  You can create detailed contour plots of the contact status, pressure, sliding distance, gap, or penetration (depending on formulation used).

image

image

Again, you can generate all of that information for contact between surface-to-surface, surface-to-edge, or edge-to-edge.  This allows you to use solids, shells, beams, or any combination you want, for any physics you want, to simulate essentially any real-world application.  No need to buy additional modules, pay for special solvers, fight through meshing issues by trying to ‘fake’ an assembly through a conformal mesh.  Just import the geometry, simplify as necessary (SpaceClaim is pretty awesome if you haven’t heard), and simulate it.)

For a more detailed, step-by-step look at the process, check out the following video!


Combining ANSYS Simulation with HPC

Engineering simulation has become much more prevalent in engineering organizations than it was even 5 years ago.  Commercial tools have gotten significantly easier to use whether you are looking at tools embedded within CAD programs or the standalone flagship analysis tools.  The driving force behind these changes are to ultimately let engineers and companies understand their design quicker with more fidelity than before.

Engineering simulation is one of those cliché items where everyone says “We want more!”  Engineers want to analyze bigger problems, more complex problems and even do large scale design of experiments with hundreds of design variations – and they want these results instantaneously.   They want to be able to quickly understand their designs and design trends and be able to make changes accordingly so then can get their products optimized and to the market quicker.

ANSYS, Inc. spends a significant amount of R&D in helping customers get their results quicker and a large component of that development is High Performance Computing, or HPC.  This technology allows engineers to solve their structural, fluid and/or electromagnetic analyses across multiple processors and even across multiple computing machines.  Engineers can leverage HPC on laptops, workstations, clusters and even full data centers.

PADT is fortunate to be working with Nimbix, a High Performance Computing Platform that easily allowed us to quickly iterate through different models with various cores specified.  It was seamless, easy to use, and FAST!

Let’s take a look at four problems: Rubber Seal FEA, Large Tractor Axle Model, Quadrocopter CFD model and a Large Exhaust CFD model.  These problems cover a nice spectrum of analysis size and complexity. The CAD files are included in the link below.

Click here to download geometry files that were used in the following benchmarks

TRACTOR AXLE FEA

This model has several parts all with contact defined and has 51 bolts that have pretension defined.  A very large but not overly complex FEA problem.  As you can see from the results, even by utilizing 8 cores you can triple your analysis throughput for a work day.  This leads to more designs being analyzed and validated which gives engineers the results they need quicker.

SUMMARY

  • 58 Parts
  • 51 x Bolts with Pretension
  • Gaskets
  • 928K Elements, 1.6M Nodes

Cores

Elapsed Time
[s]

Estimated Models Per 8 [hours]

2

14,525

2

4

9,710

3

8

5,233

6

16 4,009

7

 

RUBBER SEAL FEA

The rubber seal is actually a relatively small size problem, but quite complex.  Not only does it need full hyperelastic material properties defined with large strain effects included, it also includes a leakage test.  This will pressurize any exposed areas of the seal.  This will of course cause some deformation which will lead to more leaked surfaces and so on.  It basically because a pressure advancing solution.

From the results, again you can see the number of models that can be analyzed in the same time frame is signifcantly more.  This model was already under an hour, even with the large nonlinearity, and with HPC it was down to less than half an hour.

SUMMARY

  • 6 Parts
  • Mooney Rivlin Hyperelastic Material
  • Seal Leakage with Advancing Pressure Load
  • Frictional Contact
  • Large Deformation
  • 42K Elements, 58K Nodes

Cores

Elapsed Time
[s]
Estimated Models Per 8 [hours]

2

3,353

9

4

2,489

12

8 1,795

16

 


QUADROCOPTER DRONE CFD

The drone model is a half symmetry model that includes 2 rotating domains to account for the propellers.  This was ran as a steady state simulation using ANSYS Fluent.  Simply utilizing 8 cores will let you solve 3 designs versus 1.

SUMMARY

  • Multiple Rotating Domains
  • 2M Elements, 1.4M Nodes

Cores

Elapsed Time
[hours]
Speedup

2

2.1

1

4

1.2

1.8

6

0.8

2.6

8 0.7

3

 

EXHAUST CFD

The exhaust model is a huge model with 33 million elements with several complicated flow passages and turbulence.  This is a model that would take over a week to run using 1 core but with HPC on a decent workstation you can get that down to 1 day.  Leveraging more HPC hardware resources such as a cluster or using a cloud computing platform like Nimbix will see that drop to 3 hours.  Imagine getting results that used to take over 1 week that now will only take a few hours.  You’ll notice that this model scaled linearly up to 128 cores.  In many CFD simulations the more hardware resources and HPC technology you throw at it, the faster it will run.

SUMMARY

  • K-omega SST Turbulence
  • Multi-Domain
  • 33M Elements, 7M Nodes

Cores

Elapsed Time
[hours]
Speedup

16

26.8

1

32

13.0

2.1

64

6.8

3.9

96

4.3

6.2

128 3.3

8.2

As seen from the results leveraging HPC technology can be hugely advantageous.  Many simulation tools out there do not fully leverage solving on multiple computing machines or even multiple cores.  ANSYS does and the value is easily a given.  HPC makes large complex simulation more practical as a part of the design process timeline.  It allows for greater throughput of design investigations leading to better fidelity and more information to the engineer to develop an optimized part quicker.

If you’re interested in learning more about how ANSYS leverages HPC or if you’d like to know more about NIMIBX, the cloud computing platform that PADT leverages, please reach out to me at manoj@padtinc.com

 

ANSYS Workbench Polyhedral Meshing

The ANSYS App Store contains all sorts of free and paid apps developed by ANSYS as well as trusted partners. These apps improve workflows and allow users to build in best practices. An app that has been of particular interest to me is Workbench Poly Meshing for Fluent

This app enables the power and capacity of Fluent Meshing, most notably the polyhedral meshing feature, with the ease of use of the ANSYS Workbench Meshing environment. In order to show the functionality of this app, I will demonstrate with the generation of a polyhedral mesh on a sample geometry from the Fluent Meshing tutorials.

To start out, I have imported a .igs file of an exhaust manifold into ANSYS SpaceClaim Direct Modeler, which has powerful repair and prepare tools that will come in handy. I notice that the geometry is comprised of 250 surfaces, which I need to fix in order to create a solid body. By navigating into the ‘Repair’ tab and selecting the ‘Stitch’ operation, SpaceClaim notes there are two stitchable edges in my geometry. I select the green check mark to perform this operation and am greeted with a solid geometry. I complete my tasks in SpaceClaim by extracting the fluid volume using the ‘Volume Extract’ tool in the ‘Prepare’ tab.

I setup my workflow in ANSYS workbench with my added ‘Fluent Meshing’ ACT module between the ‘Mesh’ module and ‘Fluent’ module. I can then proceed to create my desired surface mesh in ANSYS meshing and setup a few required inputs for Fluent Meshing.


Once this process has been completed, I can update my ‘Fluent Meshing’ cell and open the ‘Fluent’ setup cell to display my polyhedral mesh!

IMPORTANT NOTE: all named selections must be lowercase with no spaces, and the file path(s) cannot contain any spaces.

 

Advanced ANSYS Functionality

Just like any other marketplace, there are a lot of options in simulation software.  There are custom niche-codes for casting simulations to completely general purpose linear algebra solvers that allow you to write your own shape functions.  Just like with most things in life, you truly get what you pay for.

Image result for get what you pay for

 

For basic structural and thermal simulations pretty much any FE-package should suffice.  The difference there will be in how easy it is to pre/post process the work and the support you receive from the vendor.  How complicated is the geometry to mesh, how long does it take to solve, if you can utilize multiple cores how well does it scale, how easy is it to get reactions at interfaces/constraints…and so on.  I could make this an article about all the productivity enhancements available within ANSYS, but instead I’ll talk about some of the more advanced functionalities that differentiate ANSYS from other software out there.

  • Radiation

You can typically ignore radiation if there isn’t a big temperature gradient between surfaces (or ambient) and just model your system as conduction/convection cooled.  Once that delta is large enough to require radiation to be modeled there are several degrees of numerical difficulty that need to be handled by the solver.

First, radiating to ambient is fairly basic but the heat transfer is now a function of T^4.  The solver can also be sensitive to initial conditions since large DT results in a large heat transfer, which can then result in a large change in temperature from iteration to iteration.  It’s helpful to be able to run the model transiently or as a quasi-static to allow the solver to allow some flexibility.

Next, once you introduce surface to surface radiation you now have to calculate view factors prior to starting the thermal solution. If you have multiple enclosures (surfaces that can’t see each other, or enclosed regions) hopefully there are some processes to simplify the view factor calculations (not wasting time calculating a ‘0’ for elements that can’t radiate to each other).  The view factors can sometimes be sensitive to the mesh density, so being able to scale/modify those view factors can be extremely beneficial.

Lastly you run into the emissivity side of things.  Is the emissivity factor a function of temperature?  A function of wavelength?  Do you need to account for absorption in the radiation domain?

Luckily ANSYS does all of this.  ANSYS Mechanical allows you to easily define radiation to ambient or surface-to-surface.  If you’re using symmetry in your model the full radiating surface will be captured automatically.  You can define as many enclosures as possible, each with different emissivity factors (or emissivity vs Temperature).  There are more advanced features that can help with calculating view factors (simplify the radiating surface representation, use more ray traces, etc) and there is functionality to save the calculated view factors for later simulations.  ANSYS fluid products (CFX and Fluent) can also account for radiation and have the ability to capture frequency-based emissivity and participating media.

image

Automatic expansion of radiating surfaces across symmetry planes

image

Different enclosures to simplify view factor calculations

Long story short…you don’t have to know what the Stefan-Boltzman constant is if you want to include radiation in your model (bonus points if you do).  You don’t have to mess with a lot of settings to get your model to run.  Just insert radiation, select the surface, and run.  Additional options and technical support is there if necessary.

  • Multiple/Multi-physics

I’d expect that any structural/thermal/fluids/magnetics code should be able to solve the basic fundamental equations for the environment it simulates.  However, what happens when you need to combine physics, like a MEMs device.  Or maybe you want to take some guess-work/assumptions out of how one physics loads another, like what the actual pressure load is from a CFD simulation on a structural model.  Or maybe you want to capture the acoustic behavior of an electric motor, accounting for structural prestress/loads such as Joule heating and magnetic forces.

image

ANSYS allows you to couple multiple physics together, either using a single model or through data mapping between different meshes.  Many of the data mapping routines allow for bi-directional data passing so the results can converge.  So you can run an magnetic simulation on the holding force between a magnet and a plate, then capture the deflected shape due to an external load, and pass that deformed shape back to the magnetic simulation to capture the updated force (and repeat until converged).

image

If you have vendor-supplied data, or are using another tool to calculate some other results you can read in point cloud data and apply it to your model with minimal effort.

image

To make another long story short…you can remove assumptions and uncertainty by using ANSYS functionality.

  • Advanced Material Models

 

Any simulation tool should be able to handle simple linear material models.  But there are many different flavors of ‘nonlinear’ simulation.  Does the stiffness change due to deflection/motion (like a fishing rod)?  Are you working with ductile metals that experience plastic deformation?  Does the stiffness change due to parts coming into/out-of contact?  Are surfaces connected through some adhesive property that debonds under high loads?  Are you working with elastomers that utilize some polynomial form hyper-elasic formulation?  Are you working with shape memory alloys?  Are you trying to simulate porous media through some geomechanical model?  Are you trying to simulate a stochastic material variation failure in an impact/explosive simulation?

image

Large deflection stiffness calculations, plasticity, and contact status changes are easy in ANSYS.  Debonding has been available since ANSYS 11 (reminder, we’re at release 18.0 now).  ANSYS recently integrated some more advanced geomechanical models for dam/reservoir/etc simulations.  The explicit solver allows you to introduce stochastic variation in material strengths for impact/explosive simulations.

image

ANSYS also has all the major flavors of hyper-elastic material models.  You can choose from basic Neo-Hookean, Arruda-Boyce, Gent, all the way through multiple variations of Mooney-Rivlin, Yeoh, Ogden, and more.  In addition to having these material models available (and the curve fitting routines to properly extract the constants from test data) ANSYS also has the ability to dynamically remesh a model.  Most of the time when you’re analyzing the behavior of a hyperelastic part there is a lot of deformation, and what starts out as a well-shaped mesh can quickly turn into a bad mesh.  Using adaptive meshing, you can have the solve automatically pause the solution, remesh the deformed shape, map the previous stress state onto the new nodes/elements, and continue with the solution.  I should note that this nonlinear adaptive remesh is NOT just limited to hyperelastic simulations…it is just extremely helpful in these instances.

The ending of this story is pretty much the same as others.  If you have a complicated material response that you’re trying to capture you can model it in ANSYS.  If you already know how to characterize your material, just find the material model and enter the constants.  We’ve worked with several customers in getting their material tested and properly characterized.  So while most structural codes can do basic linear-elastic, and maybe some plastic…very few can capture all the material responses that ANSYS can.

  • MEMs/Piezo/Etc

I know I’ve already discussed multiple physics and advanced materials, but once you start making parts smaller you start to get coupling between physics that may not work well for vector-based coupling (passing load vectors/deformations from one mesh to another).  Luckily ANSYS has a range of multi-physics elements that can solve use either weak or strong coupling to solve a host of piezo or MEM-related problems (static, transient, modal, harmonic).  Some codes allow for this kind of coupling but either require you to write your own governing equations or pay for a bunch of modules to access.

If you have the ANSYS Enterprise-level license you can download a free extension that exposes all of these properties in the Mechanical GUI.  No scripting, no compiling, just straight-up menu clicks.

image

Using this extension you can define the full complex piezoelectric matrix, couple it with an anisotropic elasticity matrix, and use frequency dependent losses to capture the actual response of your structure.  Or if you want you can use simplified material definitions to get the best approximation possible (especially if you’re lacking a full material definition from your supplier).

 

Long story short…there are a lot of simulation products out there.  Pretty much any of them should be able to handle the basics (single part, structural/thermal, etc).  What differentiates the tools is in how easy it helps you implement more real-world conditions/physics into your analysis.  Software can be expensive, and it’s important that you don’t paint yourself into a corner by using a single point-solution or low-end tool.

When the going gets tough, the tough use ANSYS for CFD Meshing

If you do CFD simulations then you know the struggle that is involved in meshing. It is a fine balance of accuracy, speed, and ease of set up. If you have complex geometry, large assemblies, or any difficulty meshing then this blog article is for you.

Why should I spend time making a good mesh?

The mesh is arguably one of the most important parts of any simulation set up. A good mesh can solve significantly faster and provide more accurate results. Conversely, a poor mesh can make the simulation have inaccurate results and be slow to converge or not converge at all. If you have done any simulation then you know that hitting the solve button can feel like rolling the dice if you don’t have a robust meshing tool.

When is it going to matter?

A good mesh is going to matter on a Friday afternoon when you need to get the simulation started before you leave for the weekend because it takes two days to run and you need to deliver results on Monday but you are up against the clock because you have to get to your kid’s soccer game by 5pm and the mesh keeps crashing.

A poor mesh can do more than just reorganizing you’re social agenda. A poor mesh can drastically change results like pressure drop in an internal flow passage or drag over a body. If you go into that meeting on Monday and tell your boss that the new design is going to perform 10% better than the previous design – you need to be confident that the design is 10% better not 10% worse.

What should I do when I need to create a good mesh?

If you’re the poor soul reading this on a Friday afternoon because you are trying to frantically fix you’re mesh so you can get your simulation running before the weekend – I pity you. Continue reading for my proprietary step by step approach titled “How to get you’re CFD mesh back on track!” (Patent pending).

Step 1) Know your tools

ANSYS has been developing its meshing technology since the beginning of time (not really but almost) – it’s no surprise that its meshing algorithms are the best in the business. In ANSYS you have a large number of tools at your disposal, know how to use them.

The first tool in your toolbox is the ANSYS automatic meshing technology. It is able to predictively apply settings for your part to get the most accurate automatic mesh possible. It has gotten so good that the automatic mesh is a great place to start for any preliminary simulations. If you want to get into the details, ANSYS meshing has two main groups of mesh settings – Global Meshing Parameters and Local Meshing Parameters. Global mesh parameters are great for getting a good mesh on the entire model without going into detailed mesh settings for each part.

But when you do have to add detailed meshing settings on a part by part basis then local mesh settings won’t let you down.

Step 2) Know your physics

What is your primary result of interest? Drag? Pressure drop? Max velocity? Stagnation? If you can quantify what you are most interested in then you can work to refine the mesh in that region so as to capture the physics accurately. ANSYS allows you set local sizing parameters on bodies, faces, lines, and regions which allow you to get the most accurate mesh possible but without having to use a fine mesh on the entire part.

Step 3) Know your mesh quality statistics

Mesh quality statistics can be a good way to gauge the health of your mesh. They are not a foolproof method for creating a mesh that will be accurate but you will be able to get an idea of how well it will converge. In ANSYS meshing there is a number of mesh quality statistics at your fingertips. A quick and easy way to check your mesh is to look at the Minimum Orthogonal Quality statistic and make sure it is greater than 0.1 and Maximum Skewness is less than 0.95.

Step 4) Know your uncertainty

Every test, simulation, design, process etc… has uncertainty. The goal of engineering is to reduce that uncertainty. In simulation meshing is always a source of uncertainty but it can be minimized by creating high quality meshes that accurately model the actual physical process. To reduce the uncertainty in meshing we can perform what is called a mesh refinement study. Using the concept of limits we can say that in the limit of the mesh elements getting infinitely small than the results will asymptotically approach the exact solution. In the graph below it can be seen that as the number of elements in the model are increased from 500 – 1.5million the result of interest approached the dotted line which we can assume is close to the exact solution.

By completing a mesh refinement study as shown above you can be confident that the mesh you have created is accurately capturing the physics you are modeling because you can quantify the uncertainty.

If you currently just skip over the meshing part of your CFD analysis thinking that it’s good enough or if your current meshing tool doesn’t give you any more details than just a green check mark or a red X then it’s time dig into the details of meshing and start creating high quality meshes that you can count on.

For more info about advanced meshing techniques in ANSYS – see this PDF presentation that is a compilation of ANSYS training material on the meshing subject.

Advanced Techniques in ANSYS Meshing_Blog

If you still haven’t figured out how to get your mesh to solve and its 5pm on Friday see below*

*Common pitfalls and mistakes for CFD meshing:

  • Choose your turbulence model wisely and make sure your mesh meets the quality metrics for that model.
  • Make sure you don’t have boundary conditions near an area of flow recirculation. If you are getting reverse flows at the boundary then you need to move your boundary conditions further away from the feature that’s causing the flow to swirl in and out of the boundary.