PDF

Permanent Magnet
Introduction
This example shows how to model the magnetic field surrounding a permanent magnet. It also computes the force with which it acts on a nearby iron rod. Thanks to the symmetry of the geometry and the antisymmetry of the magnetic field, only one fourth of the geometry needs to be modeled.
Figure 1: A full 3D view of the geometry. Left-right and top-down symmetry is used to minimize the problem size.
Model Definition
In a current free region, where
it is possible to define the scalar magnetic potential, Vm, from the relation
This is analogous to the definition of the electric potential for static electric fields.
Using the constitutive relation between the magnetic flux density and magnetic field
where Br is the remanent flux density, and together with the equation
you can derive an equation for Vm,
The model uses this equation by selecting the Magnetic Fields, No Currents interface from the AC/DC Module.
Boundary Conditions
The magnetic field is symmetric with respect to the xy-plane and antisymmetric with respect to the xz-plane. These planes therefore serve as exterior boundaries to the geometry.
On the symmetry plane, the magnetic field is tangential to the boundary. This is described by the Magnetic Insulation condition:
On the antisymmetry plane, the magnetic field is perpendicular to the boundary. This condition is represented by a constant magnetic scalar potential. The model uses the Zero Magnetic Scalar Potential condition.
If the air box is sufficiently large, the boundary condition used on its remaining exterior boundaries has little influence on the field in the vicinity of the magnet. Although an infinite element domain would give the very best results, this model uses the magnetic insulation condition for convenience.
Results and Discussion
The force on the rod is calculated internally as an integral of the surface stress tensor over all boundaries of the rod. The expression for the stress tensor reads
where n1 is the boundary normal pointing out from the rod and T2 the stress tensor of air. The integration gives 3.64 N, which corresponds to one quarter of the rod. The actual force on the rod is therefore four times this value, or 14.6 N.
Application Library path: ACDC_Module/Introductory_Magnetostatics/permanent_magnet
Modeling Instructions
From the File menu, choose New.
New
In the New window, click  Model Wizard.
Model Wizard
1
In the Model Wizard window, click  3D.
2
In the Select Physics tree, select AC/DC>Magnetic Fields, No Currents>Magnetic Fields, No Currents (mfnc).
3
Click Add.
4
Click  Study.
5
In the Select Study tree, select General Studies>Stationary.
6
Geometry 1
Import 1 (imp1)
1
In the Home toolbar, click  Import.
2
In the Settings window for Import, locate the Import section.
3
Click  Browse.
4
5
Click  Import.
The imported geometry contains the permanent magnet and the rod that it is acting on. The following instructions show you how to create the air box and delete the part of the geometry that you do not want to include in the model.
Block 1 (blk1)
1
In the Geometry toolbar, click  Block.
2
In the Settings window for Block, locate the Size and Shape section.
3
In the Width text field, type 0.25.
4
In the Depth text field, type 0.1.
5
In the Height text field, type 0.1.
6
Locate the Position section. In the x text field, type -0.1.
7
Right-click Block 1 (blk1) and choose Build Selected.
The air box now covers only the parts of the magnet and the rod that you want to include in the model. Perform a Boolean geometry operation to get rid of the superfluous parts.
Compose 1 (co1)
1
In the Geometry toolbar, click  Booleans and Partitions and choose Compose.
2
Click in the Graphics window and then press Ctrl+A to select both objects.
3
In the Settings window for Compose, locate the Compose section.
4
In the Set formula text field, type blk1+imp1*blk1.
5
Click  Build All Objects.
6
Click the  Zoom Extents button in the Graphics toolbar.
The geometry now contains the air volume and one fourth of the imported objects.
Materials
Iron
1
In the Model Builder window, under Component 1 (comp1) right-click Materials and choose Blank Material.
2
In the Settings window for Material, type Iron in the Label text field.
3
4
Locate the Material Contents section. In the table, enter the following settings:
Air
1
Right-click Materials and choose Blank Material.
2
In the Settings window for Material, type Air in the Label text field.
3
4
Locate the Material Contents section. In the table, enter the following settings:
Add Material
1
In the Home toolbar, click  Add Material to open the Add Material window.
2
Go to the Add Material window.
3
In the tree, select AC/DC>Hard Magnetic Materials>Sintered NdFeB Grades (Chinese Standard)>N54 (Sintered NdFeB).
4
Click Add to Component in the window toolbar.
5
In the Home toolbar, click  Add Material to close the Add Material window.
Materials
N54 (Sintered NdFeB) (mat3)
1
In the Settings window for Material, locate the Geometric Entity Selection section.
2
Click  Paste Selection.
3
In the Paste Selection dialog box, type 3 in the Selection text field.
4
Magnetic Fields, No Currents (mfnc)
Magnet 1
1
In the Model Builder window, under Component 1 (comp1) right-click Magnetic Fields, No Currents (mfnc) and choose Magnet.
2
North 1
1
In the Model Builder window, click North 1.
2
South 1
1
In the Model Builder window, click South 1.
2
All exterior boundaries are magnetically insulated by default. Use the Symmetry Plane condition on those boundaries where antisymmetry holds.
Symmetry Plane 1
1
In the Physics toolbar, click  Boundaries and choose Symmetry Plane.
2
In the Model Builder window, click Symmetry Plane 1.
3
4
In the Settings window for Symmetry Plane, locate the Symmetry Plane section.
5
From the Symmetry type for the magnetic field list, choose Antisymmetry.
Next, add a force computation on the rod.
Force Calculation 1
1
In the Physics toolbar, click  Domains and choose Force Calculation.
2
3
In the Settings window for Force Calculation, locate the Force Calculation section.
4
In the Force name text field, type rod.
Mesh 1
Free Tetrahedral 1
To get an accurate force computation, you need a particularly fine mesh on the rod. It also makes sense to use a fine mesh in the magnet and its iron core, as this is where the magnetic field will be the strongest.
In the Mesh toolbar, click  Free Tetrahedral.
Size
1
In the Model Builder window, click Size.
2
In the Settings window for Size, locate the Element Size section.
3
From the Predefined list, choose Fine.
Size 1
1
In the Model Builder window, right-click Free Tetrahedral 1 and choose Size.
2
In the Settings window for Size, locate the Geometric Entity Selection section.
3
From the Geometric entity level list, choose Domain.
4
5
Locate the Element Size section. Click the Custom button.
6
Locate the Element Size Parameters section.
7
Select the Maximum element size check box. In the associated text field, type 0.0025.
8
Click  Build All.
Study 1
1
In the Model Builder window, click Study 1.
2
In the Settings window for Study, locate the Study Settings section.
3
Clear the Generate default plots check box.
4
In the Home toolbar, click  Compute.
Results
3D Plot Group 1
In the Home toolbar, click  Add Plot Group and choose 3D Plot Group.
Slice 1
1
Right-click 3D Plot Group 1 and choose Slice.
2
In the Settings window for Slice, click Replace Expression in the upper-right corner of the Expression section. From the menu, choose Component 1 (comp1)>Magnetic Fields, No Currents>Magnetic>mfnc.normB - Magnetic flux density norm - T.
3
Locate the Plane Data section. From the Plane list, choose xy-planes.
4
From the Entry method list, choose Coordinates.
5
In the z-coordinates text field, type 0.005.
6
Locate the Coloring and Style section. Click  Change Color Table.
7
In the Color Table dialog box, select Thermal>GrayBody in the tree.
8
9
In the 3D Plot Group 1 toolbar, click  Plot.
The plot shows the magnitude of the flux density just above the symmetry plane. Add an arrow plot to see its direction.
Arrow Volume 1
1
In the Model Builder window, right-click 3D Plot Group 1 and choose Arrow Volume.
2
In the Settings window for Arrow Volume, click Replace Expression in the upper-right corner of the Expression section. From the menu, choose Component 1 (comp1)>Magnetic Fields, No Currents>Magnetic>mfnc.Bx,...,mfnc.Bz - Magnetic flux density.
3
Locate the Arrow Positioning section. Find the x grid points subsection. In the Points text field, type 100.
4
Find the y grid points subsection. In the Points text field, type 50.
5
Find the z grid points subsection. From the Entry method list, choose Coordinates.
6
In the Coordinates text field, type 0.0051.
7
In the 3D Plot Group 1 toolbar, click  Plot.
The plot shows only the quarter of the geometry used for the computation.
Introduce additional mirror datasets to plot the solution in the complete geometry.
Symmetry Condition
1
In the Results toolbar, click  More Datasets and choose Mirror 3D.
2
In the Settings window for Mirror 3D, type Symmetry Condition in the Label text field.
3
Locate the Plane Data section. From the Plane list, choose xy-planes.
Antisymmetry Condition
1
In the Results toolbar, click  More Datasets and choose Mirror 3D.
2
In the Settings window for Mirror 3D, type Antisymmetry Condition in the Label text field.
3
Locate the Data section. From the Dataset list, choose Symmetry Condition.
4
Locate the Plane Data section. From the Plane list, choose zx-planes.
5
Click to expand the Advanced section. From the Vector transformation list, choose Antisymmetric.
3D Plot Group 1
1
In the Model Builder window, under Results click 3D Plot Group 1.
2
In the Settings window for 3D Plot Group, locate the Data section.
3
From the Dataset list, choose Antisymmetry Condition.
4
In the 3D Plot Group 1 toolbar, click  Plot.
Arrow Volume 1
1
In the Model Builder window, click Arrow Volume 1.
2
In the Settings window for Arrow Volume, click Replace Expression in the upper-right corner of the Expression section. From the menu, choose Component 1 (comp1)>Magnetic Fields, No Currents>Magnetic>mfnc.Bx,...,mfnc.Bz - Magnetic flux density.
3
In the 3D Plot Group 1 toolbar, click  Plot.
3D Plot Group 1
Finally, use Global Evaluation to evaluate the force on the rod.
Global Evaluation 1
1
In the Results toolbar, click  Global Evaluation.
2
In the Settings window for Global Evaluation, click Replace Expression in the upper-right corner of the Expressions section. From the menu, choose Component 1 (comp1)>Magnetic Fields, No Currents>Mechanical>Electromagnetic force - N>mfnc.Forcex_rod - Electromagnetic force, x-component.
The variable containing the force on a quarter of the rod will be added to the Expressions table. Multiply this value by 4 to compute the total force on the rod.
3
In the Expression column, change the expression to mfnc.Forcex_rod*4.
4
In the Description column, write Total force on the rod.
5
Click  Evaluate.
The total force on the rod evaluates to 14.6 N.