Electromagnetic Analysis
Professor, I've been doing structural FEA for a while, but my new project involves an electric motor. The mechanical team says I need "electromagnetic analysis" — is that completely different from what I already know?
The FEM concept is the same — you mesh a geometry, apply governing equations, and solve. But the physics is completely different. Instead of equilibrium equations, you're solving Maxwell's equations, which describe how electric and magnetic fields interact. Everything electromagnetic — from why a motor spins to how a transformer steps up voltage — comes out of just four equations.
Maxwell's equations — I remember the name from university but they always looked intimidating. Can you give me the actual intuition before the math?
Sure. Think of it this way: a changing magnetic field creates an electric field — that's how a generator produces voltage. And a current, or a changing electric field, creates a magnetic field — that's how an electromagnet works. The other two equations say that magnetic field lines have no beginning or end (no magnetic monopoles), and that electric field lines spread out from charges. In CAE, we discretize and solve these four laws over a mesh of your geometry.
Maxwell's Equations — The Physical Foundation
All electromagnetic simulation is ultimately a numerical solution of Maxwell's equations. In differential form for a linear, isotropic medium:
$$\nabla \times \mathbf{H} = \mathbf{J} + \frac{\partial \mathbf{D}}{\partial t} \quad \text{(Ampere's law with displacement current)}$$ $$\nabla \times \mathbf{E} = -\frac{\partial \mathbf{B}}{\partial t} \quad \text{(Faraday's law of induction)}$$ $$\nabla \cdot \mathbf{B} = 0 \quad \text{(No magnetic monopoles)}$$ $$\nabla \cdot \mathbf{D} = \rho_f \quad \text{(Gauss's law)}$$where H is magnetic field intensity [A/m], J is current density [A/m²], D = εE is electric displacement [C/m²], E is electric field [V/m], B = μH is magnetic flux density [T], and ρf is free charge density [C/m³]. The constitutive relations (B = μH, D = εE, J = σE) complete the material description that every electromagnetic solver must incorporate.
Do I always solve all four equations at once? Or are there simpler cases — like how structural analysis has "linear static" as a starting point?
Great analogy — yes, exactly. For a DC electromagnet or permanent magnet, nothing changes in time, so the time-derivative terms drop out completely: that's magnetostatics, the simplest case. For a 50 Hz motor or transformer, you keep the low-frequency eddy-current terms but drop the displacement current — that's the quasi-static or eddy-current regime. Only at megahertz frequencies and above — antennas, radar, microwave circuits — do you need the full set of equations, including the displacement current. That full-wave problem is much more expensive to solve.
So the motor I'm working on — since it runs at 50 Hz — that's in the eddy-current category?
Exactly right. Motor simulation at power-line frequencies lives squarely in the eddy-current / time-harmonic regime. You'd use a tool like ANSYS Maxwell or JMAG to compute the magnetic flux density in the stator core, the induced eddy currents in the rotor bars, and ultimately the torque. A full-wave solver like HFSS would be complete overkill there and would take weeks to converge on a geometry that size.
Four Main Electromagnetic Analysis Types
| Analysis Type | Governing Equations | Frequency Range | Typical Applications |
|---|---|---|---|
| Magnetostatics | ∇×H = J, ∇·B = 0 | DC (0 Hz) | Permanent magnets, DC solenoids, magnetic shielding, NdFeB actuator force |
| Electrostatics | ∇·D = ρf, E = −∇φ | DC (0 Hz) | Capacitor design, high-voltage insulation, ESD analysis |
| Eddy Current / Time-Harmonic | Quasi-static Maxwell (no displacement current) | Hz to kHz | AC motors, transformers, induction heating, eddy-current brakes |
| Full-Wave (RF / Microwave) | Complete Maxwell equations | MHz to GHz+ | Antennas, radar, PCB signal integrity, MRI coils, EMC chamber simulation |
What industries actually use electromagnetic CAE the most? I always assumed it was only for electrical engineers in power systems.
It's much broader than that. The EV boom has made motor and inverter simulation mainstream in automotive. Medical device companies use it to design MRI coils and to verify that implants won't dangerously heat up inside a scanner — that's a regulatory requirement under ISO 10974. Telecom companies simulate antenna patterns for 5G base stations and satellite links. And EMC — electromagnetic compatibility — is mandatory pre-market certification for practically every electronic product sold in the EU or the US under FCC Part 15 and CE marking rules.
EMC testing — that's the process where you put a product in a shielded room and check whether it interferes with other equipment, right? How does CAE help with that?
Exactly. Physical EMC testing in an anechoic chamber is expensive — a single test campaign can run $5,000 to $20,000, and if you fail you have to fix the product and retest. Electromagnetic CAE lets you simulate the radiated emission pattern of your product before you build a prototype, identify which cable or PCB trace is the dominant emitter, and fix it in software. You go to the chamber with a much higher chance of passing on the first attempt. It's the same cost argument as structural FEA — find problems at the CAD stage, not after tooling is cut.
Key Application Areas
- Electric motors and generators: Torque-speed characteristics, cogging torque minimization, iron loss prediction in stator laminations, demagnetization risk of permanent magnets under fault currents
- Transformers: Core loss (hysteresis + eddy current), winding leakage inductance, hot-spot temperature when combined with thermal analysis, short-circuit force assessment
- EMC / EMI: Radiated emission prediction, shielding effectiveness evaluation, cable harness coupling analysis, conducted interference on power lines
- Antennas and wireless: Impedance matching, radiation pattern and gain, SAR (specific absorption rate) for mobile device certification, phased-array beam steering simulation
- MRI and medical devices: RF coil B1-field homogeneity, implant RF heating safety (ISO 10974), gradient coil acoustic noise analysis
- Induction heating: Workpiece heating uniformity, coil efficiency optimization, frequency selection to target a specific skin depth in the workpiece
- High-voltage insulation: Electric field stress distribution around conductors and insulators, partial discharge inception risk, dielectric strength margins in transformers and cables
When I mesh structural parts I use solid hexahedra or tetrahedra. Is the meshing the same for electromagnetic problems?
The geometry meshing looks similar, but there's a critical difference in element type. For electromagnetic vector fields, using ordinary nodal elements — the same ones you'd use for displacement in structural FEA — can produce spurious, unphysical oscillating solutions, especially in full-wave problems. The preferred approach is edge elements, also called Nédélec elements or Whitney elements, where the degrees of freedom are assigned to the edges rather than the nodes. This naturally enforces the correct continuity of tangential field components across material interfaces.
I've never seen "edge elements" in structural FEA. Why aren't nodal elements sufficient here?
Because the physics enforce different interface conditions. At the boundary between two materials, the tangential component of E and H must be continuous, while the normal components of B and D can jump. Nodal elements enforce pointwise continuity at vertices — which over-constrains the normal component. Edge elements encode the circulation around element edges, which is exactly what Faraday's law and Ampere's law describe in integral form. There's also the gauging issue: the magnetic vector potential A is not unique — you can add the gradient of any scalar and still get the same B field — so a gauge condition like Coulomb's gauge (∇·A = 0) must be imposed to make the discrete system uniquely solvable.
FEM Formulation for Electromagnetic Problems
Edge Elements (Nédélec / Whitney)
The standard formulation uses the magnetic vector potential A (defined by B = ∇×A) as the primary unknown. The weak form of the eddy-current equation is:
$$\int_\Omega \frac{1}{\mu} (\nabla \times \mathbf{A}) \cdot (\nabla \times \mathbf{W})\, d\Omega + \int_\Omega j\omega\sigma \mathbf{A} \cdot \mathbf{W}\, d\Omega = \int_\Omega \mathbf{J}_s \cdot \mathbf{W}\, d\Omega$$where W are edge-element test functions, μ is magnetic permeability, σ is electrical conductivity, ω is angular frequency, and Js is the applied source current density.
| Element Type | DOFs Located At | Enforces | Suitable For |
|---|---|---|---|
| Nodal (Lagrange) | Vertices | C0 continuity (scalar fields) | Electric potential φ, temperature (thermal coupling) |
| Edge (Nédélec) | Edges | Tangential continuity of vector fields | Magnetic vector potential A, electric field E |
| Facet (Raviart-Thomas) | Faces | Normal continuity of flux | Current density J, magnetic flux density B |
Gauging Strategies
- Coulomb gauge: ∇·A = 0 — explicit constraint added to the system, commonly used in magnetostatics and low-frequency analysis
- Tree-cotree gauging: Implicit graph-theory technique on the mesh topology; preferred in commercial FEM solvers for robustness and no additional equations
One thing that worries me about my motor project — the magnetic losses generate heat, and I suspect that heat changes the winding resistance and even the magnet properties. Do I need to account for all of that simultaneously?
You've nailed the core challenge of electromagnetic-thermal coupling. For a preliminary sizing study, most engineers do it one-way: compute losses in the EM solver, pass them to a thermal solver as heat sources, and manually iterate a couple of times. For a more rigorous simulation — especially when the motor is near its thermal limits — you'd want a two-way iterative or fully coupled simulation where the temperature feeds back into the EM material properties each step.
And what about structural effects? I heard that in motor NVH there are vibration and noise issues tied to the magnetic field itself.
Absolutely. The Maxwell stress tensor describes the force that the magnetic field exerts on the stator core — these radial magnetic pressure waves at harmonic frequencies are the main driver of motor "whine" noise, which is a significant challenge in EV powertrains where the combustion engine masking is gone. Tackling that properly requires a three-way coupling: EM computes the magnetic forces, structural analysis computes the resulting stator deformation, and an acoustic solver predicts the radiated sound pressure. That's cutting-edge multiphysics work.
Multi-Physics Coupling in Electromagnetic Analysis
Electromagnetic–Thermal (Joule Heating and Core Loss)
Power dissipation density from eddy currents is transferred to the thermal solver as a volumetric heat source:
$$q_v = \frac{|\mathbf{J}|^2}{\sigma} = \sigma |\mathbf{E}|^2$$For ferromagnetic materials, core loss (hysteresis + eddy current) is typically described by the Steinmetz equation:
$$P_{core} = k_h f B_{max}^\alpha + k_e f^2 B_{max}^2$$where kh, ke, and α are material-specific coefficients fitted to manufacturer loss data. This heat source is mapped onto the thermal mesh as a body load.
Electromagnetic–Structural (Lorentz Force / Maxwell Stress)
The magnetic stress tensor acting on a material surface is:
$$T_{ij} = \frac{1}{\mu_0}\left(B_i B_j - \frac{1}{2}\delta_{ij} B^2\right)$$Integrating over the enclosing surface yields the net electromagnetic force. Applications include motor torque computation, solenoid valve stroke prediction, electromagnetic forming, and stator vibration analysis for NVH.
| Coupling Type | Data Transferred | Typical Approach | Application Example |
|---|---|---|---|
| EM → Thermal | Volumetric heat source qv, core loss Pcore | One-way or iterative | Motor winding temperature, transformer hot spot |
| Thermal → EM | Temperature-dependent σ(T), μ(T) | Iterative or fully coupled | Induction heating process control, motor thermal runaway |
| EM → Structural | Lorentz force density, Maxwell stress tensor | One-way or two-way | Solenoid force, busbar short-circuit forces, electromagnetic forming |
| EM → Structural → Acoustic | Magnetic forces → stator displacement → sound pressure | Sequential three-way coupling | EV motor NVH, transformer hum (100 Hz tonal noise) |
My company already has an ANSYS license. But I keep hearing that JMAG is the tool of choice specifically for motors. What's the real difference?
ANSYS Maxwell is an excellent general-purpose electromagnetic FEM solver with strong rotating machine workflows and tight integration with the rest of the ANSYS ecosystem — Fluent for thermal, Mechanical for structural. JMAG, developed by JSOL in Japan, has deeper motor-specific features: its iron loss models are extremely mature, its demagnetization analysis for rare-earth permanent magnets is very accurate, and its efficiency map calculation with direct FEA is widely trusted in Japanese and European EV motor development. If your primary deliverable is motor performance verification for EV certification, JMAG might be the better tool. If you need tight EM-to-thermal-to-structural coupling within a single platform, ANSYS Workbench wins.
Is there an open-source option I could use to build intuition before working with the commercial tools?
Yes — Elmer FEM is probably the most capable free option. It was developed by CSC in Finland and handles magnetostatics, eddy currents, and even full-wave problems. It's used in serious academic and industrial research. For antennas and RF, OpenEMS is a free FDTD solver with GPU acceleration that is genuinely competitive for PCB antenna and planar structure design. GetDP — the solver engine behind Gmsh — lets you define your own weak-form equations and has decades of use in electromagnetic research. All three are real tools, not just toys.
Software Comparison for Electromagnetic Simulation
| Software | Developer | Method | Strengths | License |
|---|---|---|---|---|
| ANSYS Maxwell | Ansys Inc. | FEM (low-freq) | Rotating machine wizard, adaptive mesh, seamless Workbench integration for EM-thermal-structural | Commercial |
| JMAG | JSOL Corp. (Japan) | FEM (low-freq) | Motor-specific workflows, best-in-class iron loss accuracy, demagnetization analysis, efficiency maps | Commercial |
| COMSOL Multiphysics | COMSOL AB | FEM (full range) | Seamless multiphysics coupling, parametric sweeps, easy EM-thermal in one environment | Commercial |
| ANSYS HFSS | Ansys Inc. | Full-wave FEM | Industry standard for 3D RF/microwave, complex geometries, SIwave for PCB SI/PI | Commercial |
| CST Studio Suite | Dassault Systèmes | FDTD + FEM | Antenna analysis, EMC, fast transient FDTD with GPU acceleration | Commercial |
| Elmer FEM | CSC, Finland | FEM (full range) | Full Maxwell capability, open-source, well-documented, community support | Open Source (LGPL) |
| OpenEMS | Community | FDTD | Free FDTD solver, GPU acceleration, MATLAB/Octave scripting, competitive for PCB antennas | Open Source (GPL) |
| GetDP | Univ. Liège / Gmsh team | FEM | Flexible weak-form definition language, tightly coupled to Gmsh mesher, decades of EM research use | Open Source (GPL) |
Browse Subcategories
New to electromagnetic CAE? Start with Magnetostatics (marked START) — it's the DC case where the math is simplest.
Learning Roadmap
| Level | Topics | Recommended Path |
|---|---|---|
| Beginner | Magnetostatics, vector potential concept, basic FEM formulation for EM | Magnetostatics Basics → Biot-Savart vs FEM → Permanent Magnet Force |
| Intermediate | Eddy current analysis, iron loss models, time-harmonic AC motor simulation | Eddy Currents → Skin Effect → Iron Loss (Steinmetz) → Motor Torque |
| Advanced | Full-wave FEM/FDTD, coupled EM-thermal, nonlinear B-H curve hysteresis | Full-Wave Maxwell → EMC Pre-Compliance → EM-Thermal Coupling → Motor NVH |