# Electromagnetics

Solve problems that model electric and magnetic fields

Solve PDEs that model static electric and magnetic fields. A typical programmatic workflow for solving an electromagnetic problem includes the following steps:

• Create a special electromagnetic model container for an electrostatic or magnetostatic analysis.

• Define a geometry and mesh it.

• Assign electromagnetic properties of the material, such as relative permittivity and relative permeability.

• Specify charge or current density within the geometry.

• Specify voltage or magnetic potential values on the boundaries.

• Solve and plot results, such as the resulting electric or magnetic potentials, fields, and flux densities.

## Functions

expand all

 `createpde` Create model `electromagneticProperties` Assign properties of material for electromagnetic model `electromagneticSource` Specify current density or charge density for electromagnetic model `electromagneticBC` Apply boundary conditions to electromagnetic model `solve` Solve heat transfer, structural analysis, or electromagnetic analysis problem `assembleFEMatrices` Assemble finite element matrices
 `interpolateElectricPotential` Interpolate electric potential in electrostatic result at arbitrary spatial locations `interpolateElectricField` Interpolate electric field in electrostatic result at arbitrary spatial locations `interpolateElectricFlux` Interpolate electric flux density in electrostatic result at arbitrary spatial locations `interpolateMagneticPotential` Interpolate magnetic potential in magnetostatic result at arbitrary spatial locations `interpolateMagneticField` Interpolate magnetic field in magnetostatic result at arbitrary spatial locations `interpolateMagneticFlux` Interpolate magnetic flux density in magnetostatic result at arbitrary spatial locations
 `pdeplot` Plot solution or mesh for 2-D problem `pdeplot3D` Plot solution or surface mesh for 3-D problem `pdegplot` Plot PDE geometry `pdemesh` Plot PDE mesh `pdeviz` Create and plot PDE visualization object
 `findElectromagneticProperties` Find electromagnetic material properties assigned to geometric region `findElectromagneticSource` Find electromagnetic source assigned to geometric region `findElectromagneticBC` Find electromagnetic boundary conditions assigned to geometric region

## Objects

 `ElectromagneticModel` Electromagnetic model object `ElectrostaticResults` Electrostatic solution and derived quantities `MagnetostaticResults` Magnetostatic solution and derived quantities

## Properties

 ElectromagneticMaterialAssignment Properties Electromagnetic material properties assignments ElectromagneticBCAssignment Properties Boundary condition for electromagnetic model ElectromagneticSourceAssignment Properties Electromagnetic source assignments PDEVisualization Properties PDE visualization of mesh and nodal results

## Topics

### Electrostatic and Magnetostatic Problems

Electrostatic Potential in Air-Filled Frame

Find the electric potential in an air-filled annular quadrilateral frame.

Electrostatic Analysis of Transformer Bushing Insulator

Compute an electric field intensity in a bushing insulator.

Magnetic Field in Two-Pole Electric Motor

Find the static magnetic field induced by the stator windings in a two-pole electric motor.

Magnetic Flux Density in Electromagnet

Compute a magnetic flux density in a solenoid with an iron core using a 3-D model and a 2-D axisymmetric model.

Magnetic Flux Density in H-Shaped Magnet

Compute a magnetic flux density in a ferromagnetic frame.

### Electromagnetic Equations

Electrostatics and Magnetostatics

Partial differential equations for electrostatics and magnetostatics problems.

## Support Get trial now