Level Up to Intermediate ANSYS Fluent Course — Ep 08
MHD & EHD: Magnetohydrodynamic Effect on Fluid Flow
- Lesson
- 08
- Run Time
- 18m 26s
- Published
- Jun 9, 2026
- Category
- ANSYS Fluent
- Course Progress
- 0%
This project simulates the flow of an electrically conductive fluid inside a simple square chamber using ANSYS Fluent, with magnetohydrodynamics as the central theme. MHD is the study of how electrically conducting fluids behave in the presence of a magnetic field: as the conductive material moves through the field it induces electric currents, and the interaction of those currents with the magnetic field produces a Lorentz force that, in turn, modifies the flow. The core of the study is this two-way coupling between the fluid-flow field and the magnetic field, captured through ANSYS Fluent's MHD module.
The MHD model is implemented using the magnetic-induction method, which introduces two user-defined scalar magnetic-flux fields in the x- and y-directions (the alternative electric-potential method instead uses a single voltage scalar). All four boundaries of the domain are set as insulating walls, meaning no electric current passes through them; the module also supports conducting-wall boundaries for fully conductive surfaces, coupled-wall conditions for shared solid–solid or solid–liquid interfaces, and thin-wall conditions for finite electrical conductivity. The energy equation, the Lorentz force equations and the MHD equations are all activated, with source terms applied to energy, momentum and the magnetic fluxes to define the field within the model.
The study is organised around three dimensionless parameters. It first examines the Prandtl number — the ratio of momentum diffusivity to thermal diffusivity — without the MHD model active. It then activates MHD and, at a fixed Prandtl number, varies the Hartmann number, which expresses the ratio of electromagnetic force to viscous force and changes with the magnitude of the applied magnetic flux. Finally, at a fixed Hartmann number, it varies the angle at which the magnetic field is applied to the flow.
The working fluid is defined with a density of 998.2 kg/m³, thermal conductivity of 0.6 W/m·K, dynamic viscosity of 0.001003 kg/m·s, thermal expansion coefficient of 0.000214 K⁻¹ and a high electrical conductivity of 1,000,000 S/m. The Prandtl number is varied through the specific heat capacity (taking values such as 0.01, 0.02, 0.03 and 0.004), while the Hartmann number is varied through the applied magnetic flux (0.003284, 0.006568, 0.013135 and 0.032838), applied vertically along the y-axis. In the final stage, with the flux held constant, its direction is changed across angles of 0° (along the x-axis), 45°, 60° and 90° (along the y-axis).
The geometry is a two-dimensional square cavity one metre on a side, bounded by top, bottom, left and right walls, created in Design Modeler and meshed in ANSYS Meshing with a structured grid of 10,000 elements. The simulation uses a pressure-based, steady, laminar solver with the energy equation active and gravity neglected; the lower wall is held at 587 K and the upper wall at 300 K, with the left and right boundaries set as pressure outlets.
The solution yields two-dimensional contours of pressure, velocity and temperature together with pathlines across the three stages of the study. The first stage, without MHD, compares the effect of four Prandtl numbers; the second, with MHD and a fixed Prandtl number, compares four Hartmann numbers at a fixed field direction; and the third, with both Prandtl and Hartmann numbers fixed, compares four field application angles. As a study in MHD modelling, the project demonstrates how the magnetic-induction approach, the Lorentz force and the associated source terms can be combined to capture the influence of a magnetic field — its strength, expressed through the Hartmann number, and its orientation — on the flow and heat transfer of an electrically conducting fluid.