Step-by-step Tutorial: Geometry Import, Mesh and Simulation Setup
To make the meshing and simulation process easier, faster and prone to less errors, the meshes and simulations have been setup, ready for the user to assign the new meshes and re-assign entities. To this end the following step-by-step has been setup to simply guide the user as to which entities must be assigned to which refinement or boundary condition. The guide will also provide some information as to why the simulation has been setup in this way. More information about geometry modification can be found in the document provided in the OnShape project and information in obtaining results on the simulated design can be found in the post processing guide.
Step 1: Copy the project
Open the link:
From here you can make your own copy of the project by clicking the options item and Make a Copy.
Figure 1: Showing how to copy the project into your own dashboard.
The following steps will guide the user through importing their own geometry to this copied project, meshing from the example meshes and using the simulation setups to test your own designs.
Step 2: Import Geometry from OnShape
To Import a geometry from OnShape simply click on Import under the Geometry section.
Figure 2: Import from onshape.
From here, log into your OnShape account and select the part studio in which your modified geometry lies, and then Import the geometry.
Figure 3: Importing the part studio of the modified geometry.
Once this is done a representation of all the parts and the ground will be present, this is a good time to do one last check of the geometry, ensuring that all parts are present, hollow areas are hollow and not filled by a solid and that no parts are overlapping.
Step 3: Creating mesh from example setup
Once checked, an example mesh may be selected to mesh the geometry. Depending upon the type of geometry you selected to base your design upon (Inline or Symmetrical) you can now duplicate the representative mesh. In this example the Inline design will be used.
Right click the Inline - Example Mesh and Duplicate the mesh.
Figure 4: Duplicating the example mesh so that the modified geometry can be assigned to it.
Rename the copied geometry to something that represents your design iteration, in this example I’ll simply use the naming convention design 1.
Figure 5: Renaming the copied Geometry.
Now that the mesh has been copied, it can be used to mesh the new geometry with the predefined settings. In the drop down box under the naming field, select your new geometry, in this example the new Geometry is In-Line Design - Demo.
Figure 6: Changing the geometry assigned to the mesh.
Once the new geometry has been reassigned, you will notice that some of the refinements turn from green lights to red lights, this indicates that the refinement needs assigning to the new geometry.
Figure 7: Refinements requiring re-assignment is communicated to the user by showing a red indicator alongside them.
The three refinements that need reassigning are the surface refinement, which needs assigning to all walls, a tube assignment, which gives additional levels of refinement to the ventilation piping and the drop hole, and layers to all walls.
Firstly, create a rubber band selection and remove the faces of the ground geometry that don’t need to be assigned, do this by dragging from right to left (right to left includes all faces the selection touches, whereas left to right includes only face entirely within the band).
Figure 8: Selecting the bottom ground faces which don’t need assignment.
Figure 9: Hiding the selection.
Once this has been done all faces for the geometry and the top ground face should be visible, it is important to ensure that the pit faces and the top ground face are still visible.
Figure 10: Checking visible faces.
For both the surface refinement and the layer refinement, assign all visible faces.
Figure 11: Assigning all visible faces to the refinements; Layers and Surface.
The tube refinement will require for the Walls and Roof Geometry parts to be hidden by selecting the eye next to the part.
Figure 12: Hiding the Walls and Roof Geometry.
Once this is hidden, create a band selection as before, in the same direction right to left, along the top of the vent pipes looking at the bottom plane.
Figure 13: Selecting faces associated with the vent pipe using rubber band selection tool.
Finally, add the inner faces of the drop holes to the selection and save.
Figure 14: Selecting inner faces of the drop hole in the same selection.
Now that all refinements have been re-defined the meshing process can be started.
Figure 15: Starting the mesh.
Once this process has been done once you might find it fairly straight forward to redo over and over without instruction, but always remember to check the assignments before starting the simulation visually. The resulting mesh will be under 5 million cells, depending upon the geometry.
Step 4: Creating the simulation from the example
Once the mesh has completed, the example simulation can be duplicated and the new mesh assigned, much like the process of reassigning faces to refinements in the meshing stage, the new simulation will also need re-assignment of faces to the boundary condition.
To study the design we need to understand how it will perform under different wind directions, to that end several simulations will need to be setup. For the Inline design, wind across the design will be symmetrical, therefore, for the Inline design will be analysed with only 3 directions, Northerly wind, Southerly Wind and an easterly wind (where Westerly winds would produce the same results as an easterly wind but in the opposite direction). The Symmetrical design however has two planes of symmetry and therefore will only need analysing in two directions.
Figure 16: Showing north direction, where X Low bounding face is where the Northerly wind originates.
In this example, only one wind direction will be setup, so the above image will need to be used along with the knowledge that the wind direction is named after the direction in which it is coming from (commonly mistaken using where the wind is blowing too).
Start the Simulation process by again duplicating the appropriate simulation, in this example we are analysing the In-line design in the Northerly Direction.
Figure 17: Duplicate the appropriate simulation.
Once duplicated, rename the simulation to something relevant. For this example I will use the naming convention Design 1 - Inline - Northerly Since this describes the design iteration, its geometry and the direction of wind used for the test.
Figure 18: Rename the simulation.
Under the domain item, select the appropriate mesh, Design 1 and save.
Figure 19: Selecting Design 1 mesh as the simulation Domain.
As before, with the new domain, once selected the boundary conditions that need reassigning are highlighted in red. We shall remedy the re-assignment requirements starting with assigning a material to the new domain.
Do this by selecting Air under Materials and then select the domain in the viewer and save.
Figure 20: Assigning the Domain to the material Air
The next assignment to make is the correct face to the inlet. As mentioned before, this will be different depending upon the wind direction you are testing. For the northerly wind as depicted in figure 16, the north face is the low x face.
Figure 21: Assigning the North face (Low X bounding face) to the inlet for a Northerly wind.
The next boundary condition to assign is the outlet face, this is simply the opposite face to the inlet face.
Figure 22: Selecting the opposite face to the inlet as the outlet.
Now that the inlet and outlet assignments have been made, the slip boundaries need to be assigned. These boundaries are slip walls so that they do not affect the flow in any way but ensure flow is only in parallel with them.
The slip walls are the two side boundaries and the top boundary.
Figure 23: Selecting the slip wall boundaries.
Finally, we shall assign all other boundaries to no-slip wall conditions. The easiest way to do that is to either select the already assigned faces and invert assignment or simply hide the faces already assigned and assign all visible. I shall demonstrate the second as then the assigned faces can be inspected.
Firstly toggle the assignment to off under the No-slip boundary condition (as shown below) and select the faces and then hide them by using the hide selection button.
Figure 24: Showing the method to turn off assignment, select faces and hide the selection.
Once the already assigned faces have been hidden, turn the assignment toggle back on and assign all visible.
Figure 25: Assigning all visible after turning assignment back on.
Figure 26: Showing the final assignment and saving.
The only thing left to do is to sanity check the setup, and create a run. To do this navigate to Simulation Runs, and press plus. A dialogue window will appear to create a run or will display any warnings or errors, in this example, no errors or warnings should be produced, if they are please go back and rectify, otherwise continue and make a new run leaving the default name.
Figure 27: Creating a new run.
Figure 28: creating a new run with default name.
Once the run has finished solving the convergence can be checked by looking at the convergence plot and prob plot. Results can be inspected in the online post-processor or downloaded to use paraview. To obtain the performance of the design you will need to download the results and use the states provided to obtain the numbers. Therefore the run can be right clicked and download results can be selected.
Figure 28: Downloading the results for local post processing