

The calculation of the forces in all boundaries is set by the set calculate force = true line. To print the values of the forces in the terminal we set verbosity to verbose. Thus, the walls have no effect on the flow of the fluid. Using slip condition, we assume that the fluid cannot go out in the normal direction, but that it can still flow from left to right without friction. In real life, the cylinder would be placed in a relatively infinite domain. This condition allows the simulation to be performed in a finite sized domain. The rest of the velocity components are set to 0.īc2 is applied at the top and bottom walls. As mentioned before, the fluid is moving in the x-direction and therefore its boundary condition is defined with a function having a u velocity equals to 1. This leads to a velocity of 0 for the fluid directly in contact with the walls of the cylinder.īc 1 determines the flow of the fluid from the left wall.

Iges manifold corresponding to a CAD geometry: the last two lines of the manifold 0 subsection are replaced by the following command set cad file = file_name.iges where the path to the cad file is specified.īc 0 identifies the cylinder where we apply noslip boundary conditions on its walls. In this example we set arg1 and arg2 to 8. Spherical manifold: The former can be used to describe any sphere, circle, hypesphere or hyperdisc in two or three dimensions and requires as arguments two or three geometrical locations depending on the dimension, that are used to create the circle center where the manifold will be build. Then the type of the manifold is specified. The boundary id is in this case set to 0 as we want to set a cylinder manifold and this is the corresponding id in this example. Then a subsection for each of the manifolds is created starting with the manifold 0. However, if another type of mesh is used in Lethe, it is possible to attach manifolds adding a section to the parameter file that looks as follows:įirst the number of manifolds is specified by the set number command. Manifolds ¶Īll the deal.II meshes supported by Lethe that correspond to the GridGenerator class, attach by default manifolds to meshes when needed. The result of this mesh adaptation can be clearly seen if we compare the initial mesh:Īnd the final mesh after being adapted 4 times: 2.4.3. To more details on the different parameters and options refer to the Parameters guide.

In this case the type is set to kelly which corresponds to the Kelly Error Estimator strategy as implemented in deal.II, and calculated with respect to the velocity variable. This means that the mesh will be adapted 4 times following the parameters specified in this subsection. For this example the following line is added: set number mesh adapt = 4. # -įor steady-state simulations, one can enable a fixed number of mesh adaptations in the simulation control subsection. Lethe supports the use of existing mesh files: Only the subsections of the parameter file that change significantly in comparison to the first two examples are explained in this section. The following schematic describes the geometry with its relevant quantities (taken from the article by Blais et al. We simulate the flow around a fixed cylinder with a constant upstream fluid velocity. Geometry file: /examples/incompressible_flow/2d_flow_around_cylinder/cylinder_structured.geo Mesh file: /examples/incompressible_flow/2d_flow_around_cylinder/cylinder_structured.msh Parameter file: /examples/incompressible_flow/2d_flow_around_cylinder/cylinder.prm Solver: gls_navier_stokes_2d (with Q1-Q1)ĭisplays the use of non-uniform mesh adaptation This example introduces several important features supported by Lethe. This is a classical problem studied in fluid mechanics.

This example corresponds to a flow around a fixed cylinder.
