Isolated Propeller

Isolated Propeller#

This example demonstrates the simulation of an isolated propeller with Flow360 Python API. We show how to set up the geometry, define a rotating mesh zone, specify operating conditions, and configure unsteady simulation parameters.

 1import flow360 as fl
 2from flow360.examples import IsolatedPropeller
 3
 4IsolatedPropeller.get_files()
 5
 6project = fl.Project.from_geometry(IsolatedPropeller.geometry, name="Isolated Propeller")
 7
 8geometry = project.geometry
 9geometry.group_edges_by_tag("edgeId")
10geometry.group_faces_by_tag("faceName")
11
12
13with fl.SI_unit_system:
14    rotating_cylinder = fl.Cylinder(
15        name="Rotating zone", center=[0, 0, 0], axis=[1, 0, 0], outer_radius=2, height=0.8
16    )
17    refinement_cylinder = fl.Cylinder(
18        name="Refinement zone", center=[1.9, 0, 0], axis=[1, 0, 0], outer_radius=2, height=4
19    )
20    slice = fl.Slice(name="Slice", normal=[1, 0, 0], origin=[0.6, 0, 0])
21    volume_zone_rotating_cylinder = fl.RotationCylinder(
22        name="Rotation cylinder",
23        spacing_axial=0.05,
24        spacing_radial=0.05,
25        spacing_circumferential=0.05,
26        entities=[rotating_cylinder],
27        enclosed_entities=[geometry["*"]],
28    )
29    farfield = fl.AutomatedFarfield(name="Farfield")
30    params = fl.SimulationParams(
31        meshing=fl.MeshingParams(
32            defaults=fl.MeshingDefaults(
33                surface_max_edge_length=1, boundary_layer_first_layer_thickness=0.1 * fl.u.mm
34            ),
35            refinements=[
36                fl.UniformRefinement(
37                    name="Uniform refinement", spacing=0.025, entities=[refinement_cylinder]
38                )
39            ],
40            volume_zones=[farfield, volume_zone_rotating_cylinder],
41        ),
42        reference_geometry=fl.ReferenceGeometry(
43            area=1, moment_center=[0, 0, 0], moment_length=[1, 1, 1]
44        ),
45        operating_condition=fl.AerospaceCondition(velocity_magnitude=20),
46        models=[
47            fl.Wall(name="Wall", surfaces=[geometry["*"]]),
48            fl.Freestream(name="Freestream", surfaces=[farfield.farfield]),
49            fl.Fluid(
50                navier_stokes_solver=fl.NavierStokesSolver(relative_tolerance=0.01),
51                turbulence_model_solver=fl.SpalartAllmaras(
52                    relative_tolerance=0.01, hybrid_model=fl.DetachedEddySimulation()
53                ),
54            ),
55            fl.Rotation(
56                name="Rotation",
57                volumes=[rotating_cylinder],
58                spec=fl.AngularVelocity(value=200 * fl.u.rpm),
59            ),
60        ],
61        time_stepping=fl.Unsteady(
62            steps=600,
63            step_size=0.0025,
64            max_pseudo_steps=35,
65            CFL=fl.AdaptiveCFL(
66                min=0.1, max=10000, max_relative_change=1, convergence_limiting_factor=0.5
67            ),
68        ),
69        outputs=[
70            fl.SurfaceOutput(
71                name="Surface output",
72                output_fields=["Cp", "yPlus", "Cf", "CfVec"],
73                surfaces=[geometry["*"]],
74            ),
75            fl.SliceOutput(
76                name="Slice output",
77                output_fields=["qcriterion", "vorticity", "Mach"],
78                slices=[slice],
79            ),
80        ],
81    )
82
83
84project.run_case(params, name="Isolated propeller case")

Technical Details#

  • The propeller is modeled using a rotating cylindrical mesh zone with a rotational speed of 200 RPM.

  • A second cylinder is used as a refinement region to increase mesh density around the propeller.

  • Outputs include volumetric data (q-criterion, vorticity) on a slice plane and surface data (Cp, yPlus) .