# Force of interaction between magnets

hi,

I'm a student and i have an electromagnet and a bar magnet paced head on coaxially and i want to calculate the force between these two when the distance is around 0.5 cm. please help i'm unable to find anything useful after browsing various websites.

hi,

I'm a student and i have an electromagnet and a bar magnet paced head on coaxially and i want to calculate the force between these two when the distance is around 0.5 cm. please help i'm unable to find anything useful after browsing various websites.

This problem definitely requires computational analysis. It's the very fact that matter is composed of atomic particles (hard particles) and their distribution it's what makes net forces in space. Without finite element method we actually couldn't make aproximations to engineering problems that seems impossible to solve by conventional math. My conclusion is that you need to apply finite element method to accurately solve this kind of problem. But you have also to define properties of the magnets, their composition and so on... Surely computational analysis is needed.

Gravity problems themselves are easily solved accurately enough because planet earth is much bigger than bodies such as ours and we can plot forces like being in the same direction. But that is an illusion. That only gives us the chance to predict bodies behavior in an easy way by conventional math but it has it's uncertaintities.

Last edited:
This problem definitely requires computational analysis. It's the very fact that matter is composed of atomic particles (hard particles) and their distribution it's what makes net forces in space. Without finite element method we actually couldn't make aproximations to engineering problems that seems impossible to solve by conventional math. My conclusion is that you need to apply finite element method to accurately solve this kind of problem. But you have also to define properties of the magnets, their composition and so on... Surely computational analysis is needed.

Gravity problems themselves are easily solved accurately enough because planet earth is much bigger than bodies such as ours and we can plot forces like being in the same direction. But that is an illusion. That only gives us the chance to predict bodies behavior in an easy way by conventional math but it has it's uncertaintities.

sir i'm highly obliged that you sincerely participated in my problem and shared your knowledge but as i said earlier i'm a student and have not enough resources so now what way should i choose for the computational analysis so that i can solve this problem.

Meir Achuz
Homework Helper
Gold Member
The force depends on the geometry and size of the ends of the magnetss .
What are these? If the ends are flat, I could tell you how to proceed if I knew their areas.

vanhees71
Gold Member
If you don't put the magnets not too close to each other, you can treat it as dipole-dipole interaction. The formulae are found in some textbooks on electromagnetism. I'm pretty sure, Jackson will have it somewhere. You find the potential as well as the force. The potential is more save concerning the force on which dipole is written down; I've not checked by taking the gradient of the potential which force is exactly quoted (I hate the notation $\vec{F}_{ab}$; I'm never sure whether they mean the force on a due to b or vice versa ;-), and the notation may change from one book/paper/website to the other).

The force depends on the geometry and size of the ends of the magnetss .
What are these? If the ends are flat, I could tell you how to proceed if I knew their areas.

Shape of both electromagnet and the permanent magnet is cylindrical with flat circular ends and the area can be varied according to desired result.
At this moment the best process for the calculation is computational analysis, if i want to do it through a code then i need to know the expression for the same otherwise i need to work on a software which can make such calculations but don't know any of them.

If you don't put the magnets not too close to each other, you can treat it as dipole-dipole interaction. The formulae are found in some textbooks on electromagnetism. I'm pretty sure, Jackson will have it somewhere. You find the potential as well as the force. The potential is more save concerning the force on which dipole is written down; I've not checked by taking the gradient of the potential which force is exactly quoted (I hate the notation $\vec{F}_{ab}$; I'm never sure whether they mean the force on a due to b or vice versa ;-), and the notation may change from one book/paper/website to the other).

In my case i want to calculate the repulsion force between two magnets when the clearance between these two are around 1-5 mm. Is there any expression through which i can calculate the same??

Meir Achuz
Homework Helper
Gold Member
If the distance between the parallel faces is small compared to their diameters, you can treat them the same way you would two uniformly charged sheets. This gives $F=2\pi MM'A$, where M is the magnetization and A the smaller area. This is in Gaussian units where $B=H+4\pi M$ with B and H in gauss..

If the distance between the parallel faces is small compared to their diameters, you can treat them the same way you would two uniformly charged sheets. This gives $F=2\pi MM'A$, where M is the magnetization and A the smaller area. This is in Gaussian units where $B=H+4\pi M$ with B and H in gauss..
i can't take this approximation as the area is also about 50 mm which is comparable to the distance

Meir Achuz
Homework Helper
Gold Member
What does "the area is also about 50 mm" mean. Do you mean 50 mm^2?
If so, the approximation would not be that bad for d=1mm.
For d~ 5 mm, it would be like the force between two uniformly charged plates with surface charge densities
M and M'. This is a difficult but solvable problem using Legendre polynomials.

What does "the area is also about 50 mm" mean. Do you mean 50 mm^2?
If so, the approximation would not be that bad for d=1mm.
For d~ 5 mm, it would be like the force between two uniformly charged plates with surface charge densities
M and M'. This is a difficult but solvable problem using Legendre polynomials.

So can i take "F=2πMM′A" as a good approximation when the distance between them is increased to 5 mm. Thanks for this valuable answer and but i don't understand how to use legendre polynomials for this.

And also what is the effect of the second face (apposite poles) of the magnet as it tends to decrease the force which is not taken into consideration in the aforesaid formula.

Meir Achuz
Homework Helper
Gold Member
So can i take "F=2πMM′A" as a good approximation when the distance between them is increased to 5 mm. Thanks for this valuable answer and but i don't understand how to use legendre polynomials for this. And also what is the effect of the second face (apposite poles) of the magnet as it tends to decrease the force which is not taken into consideration in the aforesaid formula.
If the area is 25mm^2, and d=5 mm, it is not a good approximation to use the simple formula.
It should work for d up to about 2 mm.
And also what is the effect of the second face (apposite poles) of the magnet as it tends to decrease the force which is not taken into consideration in the aforesaid formula.

I assume the second faces are far enough away to be neglected. If necessary, they could be included as point magnetic charges of magnitude MA.

If the area is 25mm^2, and d=5 mm, it is not a good approximation to use the simple formula.
It should work for d up to about 2 mm.
And also what is the effect of the second face (apposite poles) of the magnet as it tends to decrease the force which is not taken into consideration in the aforesaid formula.

I assume the second faces are far enough away to be neglected. If necessary, they could be included as point magnetic charges of magnitude MA.

To simplify this problem i'm increasing area to 250mm^2 while the distance is kept 5mm but in this case if i don't make force as a function of distance then it will exert the same but apposite force as exerted by first pole/face on the other magnet which will give net force equals to zero.

It would be very helpful if i get an expression for force as a function of distance between two magnets for calculating the force exerted by the end face while the force by the front face can be calculated by considering the assumption told by you earlier.

Last edited:
Meir Achuz
Homework Helper
Gold Member
How long are the magnetls? I thought they were long. If not, it is much more complicated.

How long are the magnetls? I thought they were long. If not, it is much more complicated.

The length of electromagnet is around 60 cm and that for permanent magnet is about 30cm.

these are the maxm. length so that you can choose an approximation which suits this condition.

Meir Achuz
Homework Helper
Gold Member
With that length, you can neglect any effect of the back faces.
for d/R (d=distance between the magnets, and R= radius of the smaller face) less than about 1/4, you can use the simple formula. As d/R gets large the force decreases in a complicated calculation.

With that length, you can neglect any effect of the back faces.
for d/R (d=distance between the magnets, and R= radius of the smaller face) less than about 1/4, you can use the simple formula. As d/R gets large the force decreases in a complicated calculation.

Thanks for sharing your knowledge with me but what is the percentage error would i likely to get when using "F=2∏MM'A" by taking d/r around 1/10

Meir Achuz
Homework Helper
Gold Member
Thanks for sharing your knowledge with me but what is the percentage error would i likely to get when using "F=2∏MM'A" by taking d/r around 1/10
That would be difficult to tell without making the more exact, but difficult, calculation of the force between 2 charged discs. Incidentally, what is usually called the 'strength' of a magnet in gauss is given by 2##\pi## M.

That would be difficult to tell without making the more exact, but difficult, calculation of the force between 2 charged discs. Incidentally, what is usually called the 'strength' of a magnet in gauss is given by 2##\pi## M.

To calculate M i used "M=(B-B/(Km*mu))/4π
where, Km = relative permiability of the material and mu= permiability of the space taking all of them in gauss. In the similar way M' is also calculated.
when putting these value in force equation and also keeping the smaller area in CGS units i.e mm^2
then the force obtained would be in dyne??

I'm not sure if you can do this, but assuming you created the magnetic field with a solenoid maybe treat that that like a cylindrical bar magnet and then try to manipulate the equations to fit to that situation.
Just a thought, hope that helps!

I'm not sure if you can do this, but assuming you created the magnetic field with a solenoid maybe treat that that like a cylindrical bar magnet and then try to manipulate the equations to fit to that situation.
Just a thought, hope that helps!

But on that wiki link there is no formula even for calculation of force between two bar magnets which are not identical

It looks like each of the independent values are squared so it seems like instead of a squared value, you just multiply both together and that would be the equivalent expression. This might be making to many assumptions but it might give a good estimate.
Hope this helps!

It looks like each of the independent values are squared so it seems like instead of a squared value, you just multiply both together and that would be the equivalent expression. This might be making to many assumptions but it might give a good estimate.
Hope this helps!
are you certain for this?? I'm using "F=2∏MM'A"