# how do you know the size of the magnetic field with respect to the amount of electricity? Answered

for example you have an electromagnet and it has an electromagnetic field how can you know how much electricity to put to make a magnetic field with a specific size
(like this many volts equals this many meters in diameter)

Tags:

## Discussions

The forums are retiring in 2021 and are now closed for new topics and comments.

Magnetic fields are caused by electric currents, or, more generally, by moving electric charge.

I think the most simple arrangement to understand mathematically, is the long solenoid, described here,

https://en.wikipedia.org/wiki/Solenoid#Infinite_co...

The field is uniform and everywhere inside the solenoid it has magnitude,

B = muzero*N*I/L

B is zero everywhere outside the solenoid.

N is number of turns per length L, I is electric current. muzero is a constant.

( I had to use an uppercase L, because this font makes lowercase el, "l", and uppercase eye, "I", look exactly the same.)

Anyway, thats the simple case, but the simple case and more complicated ones share some features in common. For example B at someplace outside a real electromagnet tends to be proportional to I, the electric current in the wire, and also proportional to N, the number of turns.

Also note, generally speaking B is a vector field.

https://en.wikipedia.org/wiki/Vector_field

It has magnitude and direction at every microscopic point in space surrounding the magnet, or electromagnet, or current carrying wires, or whatever.